Search code examples
xamlwindows-store-appspolygon

Converting polygon to path


On a Windows app store project i have these polygons

<Polygon x:Name="AcItemTriangle" Stroke="#aa6861" Fill="#aa6861" Visibility="Collapsed" Points="0,0 28,0 14,35" />

and

<Polygon x:Name="AcItemTriangle" Points="0,0 28,0 14,35" Stroke="#67a0bb" Fill="#67a0bb" Visibility="Collapsed" />

I would like to know if there is a way i can convert my polygon points to a Path


Solution

  • This should work:

    <Path Data="M0,0 L28,0 14,35Z" Stroke="#aa6861" Fill="#aa6861" ... />