开发者

Encoding WPF path data

开发者 https://www.devze.com 2023-02-15 00:59 出处:网络
In WPF, is it posible to encode this into a single Path tag with a Data attribute? <Path Stroke=\"White\" StrokeThickness=\"2\">

In WPF, is it posible to encode this into a single Path tag with a Data attribute?

<Path Stroke="White" StrokeThickness="2">
    <Path.Data>
        <PathGeometry>
            <PathFigure StartPoint="7,32">
                <ArcSegment Point="7,18" Size开发者_Go百科="200,50" RotationAngle="0" IsLargeArc="False" />
            </PathFigure>
        </PathGeometry>
    </Path.Data>
</Path>

Something like this: (only this is a completely wrong shape)

<Path Stroke="DarkGoldenRod" StrokeThickness="3" 
Data="M 100,200 C 100,25 400,350 400,175 H 280" />


Try this:

<Path Data="M 7,32 A 200,50 0 0 0 7,18" .../>

See also Path Markup Syntax.

0

精彩评论

暂无评论...
验证码 换一张
取 消