geometry - How can I set different stroke properties to in a path object in WPF -


i have path shape combine lines have different line thicknesses? strokethickness property set on path object cannot change different lines. same issue arise if wanted change line color.

the reason want can draw arrowhead. charles petzold arrowheads http://www.charlespetzold.com/blog/2007/04/191200.html don't work me. if line dashed closed arrowhead draws weirdly.

i figured way combine @ end of path/line new short line geometry thicker original path/line , had trianglelinecap, voila, got myself arrowhead. can't combine geometries have different line thicknesses , dashed types, etc.

any ideas?

just use multiple path objects in panel canvas or grid draw on top of each other:

<grid>     <path stroke="blue" strokethickness="2">         <path.data>             <ellipsegeometry center="20 20" radiusx="10" radiusy="10" />         </path.data>     </path>     <path stroke="green" strokethickness="1" strokedasharray="1 2">         <path.data>             <linegeometry startpoint="10 20" endpoint="30 20"/>         </path.data>     </path> </grid> 

Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -