线与填充和描边 [英] Line with fill and stroke

查看:70
本文介绍了线与填充和描边的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在wpf中创建一条看起来像这样的行.

I'm trying to create a line that looks like this in wpf.

有人知道如何执行此操作吗?我需要绑定x和y坐标,因此一条线确实很好用,除非我无法使其看起来像这样.

Does anyone have any idea how to do this? I need to bind the x and y coordinates, so a line works really well except I can't make it look like this.

推荐答案

使用简单的行不能做到这一点,但是使用Border对象非常简单.

You can't do this with a simple line, but with a Border object it is very easy.

<Border Width="100" Height="10" Background="#FFFFDAAD" BorderBrush="Orange" BorderThickness="0,3"/>

这篇关于线与填充和描边的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆