我想在我的Polygon
内插入一个Image
,可能在Polygon
的中心。可能吗?我该怎么办?
您可以使用
ImageBrush
作为多边形的Fill
。喜欢这个:
<Polygon.Fill>
<ImageBrush ImageSource="sampleImagesberries.jpg"
AlignmentX="..." AlignmentY="..." />
</Polygon.Fill>
可能是"Points"属性帮助你:
<Polygon Points="40,0 150,100 10,100" >
<Polygon.Fill>
<ImageBrush ImageSource="C:UsersPublicPicturesSample PicturesPenguins.jpg" Stretch="Uniform" AlignmentX="Left" />
</Polygon.Fill>
</Polygon>