0
我已經制作了以下XAML路徑,但想要將文本'Back'添加到它。XAML路徑 - 添加文本
這是我如何將它...
<Path Style="{StaticResource BackButton}">
</Path>
然而,當我添加路徑內的任何內容,我得到消息
The type 'Path' does not support direct content.
任何提示嗎?
編輯 - 這是風格
<Style x:Key="BackButton" TargetType="{x:Type Path}">
<Setter Property="Data" Value="F1 M 639.667,236.467L 645.092,236.467L 725.566,236.467L 725.566,253.513L 645.092,253.513L 639.673,253.513L 619.787,244.99L 639.667,236.467 Z " />
<Setter Property="Height" Value="30" />
<Setter Property="MinWidth" Value="100" />
<Setter Property="Fill" Value="#FFFFFFFF" />
<Setter Property="StrokeThickness" Value="1" />
<Setter Property="Stroke" Value="#FF999B9C" />
<Setter Property="Stretch" Value="Fill" />
<Setter Property="Cursor" Value="Hand" />
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="true">
<Setter Property="Fill" Value="#FFEEEEEE" />
</Trigger>
</Style.Triggers>
</Style>