【发布时间】:2019-04-05 13:19:18
【问题描述】:
如何删除在 Xamarin 表单 UWP 中悬停按钮时显示的矩形边框。我已经参考了以下链接
Remove border of button when hover
我们必须更改边框宽度属性,这也失败了,因为我使用的是圆角按钮,只有在悬停和单击时才会出现边框。
以下屏幕截图将显示场景。
【问题讨论】:
标签: xamarin button xamarin.forms xamarin.uwp custom-renderer
如何删除在 Xamarin 表单 UWP 中悬停按钮时显示的矩形边框。我已经参考了以下链接
Remove border of button when hover
我们必须更改边框宽度属性,这也失败了,因为我使用的是圆角按钮,只有在悬停和单击时才会出现边框。
以下屏幕截图将显示场景。
【问题讨论】:
标签: xamarin button xamarin.forms xamarin.uwp custom-renderer
我在发布后几分钟就找到了我自己的问题的答案。
您可以在 UWP 项目的 App.xaml 中覆盖 ButtonBackgroundPointerOver。
<Application.Resources>
<SolidColorBrush x:Key="ButtonBackgroundPointerOver">Transparent</SolidColorBrush>
</Application.Resources>
【讨论】: