<分区>
这个箭头的Path.Data
值是多少:
最大网格宽度和高度为 18x18
<分区>
这个箭头的Path.Data
值是多少:
最大网格宽度和高度为 18x18
最佳答案
MSDN 的 example default template for an Expander使用 M 0 4 L 4 0 L 8 4 Z
大多数路径以字母 “M”
和 x,y 坐标开头,后跟由字符标识的线段,后跟以空格分隔的参数数字,最后以字母结尾“Z”
。所以 M 0 4 L 4 0 L 8 4 Z
表示
我经常使用以下站点作为这种“几何迷你语言”的引用指南:rcosic.wordpress.com/2009/08/11/wpf-geometry-mini-language
<Path x:Name="CollapsedArrow"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Data="M 0 0 L 4 4 L 8 0 Z">
<Path.Fill>
<SolidColorBrush Color="{DynamicResource GlyphColor}" />
</Path.Fill>
</Path>
<Path x:Name="ExpandededArrow"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Visibility="Collapsed"
Data="M 0 4 L 4 0 L 8 4 Z">
关于c# - 用路径数据wpf绘制箭头,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8476766/