如何将以下 XAML 代码集成到按钮背景中。我已经尝试了很多方法,但我很难让它发挥作用。PS 我是 XAML 的新手。
<Viewbox Width="55.247" Height="55.247"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Canvas Width="55.247" Height="55.247">
<Canvas>
<!-- button/circle -->
<Path StrokeThickness="1.0" Stroke="#ff335284" StrokeMiterLimit="1.0" Data="F1 M 54.747,27.624 C 54.747,42.603 42.603,54.747 27.624,54.747 C 12.644,54.747 0.500,42.603 0.500,27.624 C 0.500,12.644 12.644,0.500 27.624,0.500 C 42.603,0.500 54.747,12.644 54.747,27.624 Z">
<Path.Fill>
<RadialGradientBrush MappingMode="Absolute" GradientOrigin="392.717,-251.469" Center="392.717,-251.469" RadiusX="27.123" RadiusY="27.123">
<RadialGradientBrush.GradientStops>
<GradientStop Offset="0.00" Color="#ff00aae4"/>
<GradientStop Offset="1.00" Color="#ff2463a7"/>
</RadialGradientBrush.GradientStops>
<RadialGradientBrush.Transform>
<MatrixTransform Matrix="1.000,0.000,-0.000,-1.000,-365.093,-223.845" />
</RadialGradientBrush.Transform>
</RadialGradientBrush>
</Path.Fill>
</Path>
</Canvas>
</Canvas>
</Viewbox>