如何向边框或堆叠面板添加一点渐变,使其前部看起来像是有一点渐变或曲线使它看起来有点像3d
谢谢, 简
答案 0 :(得分:0)
您可以为边框定义自定义LinearGradientBrush,如此
<LinearGradientBrush StartPoint="0,0" EndPoint="0,1" x:Key="MyBorderBrush">
<GradientStop Offset="0" Color="#FFFFFF"/>
<GradientStop Offset="1" Color="#FFFFFF"/>
</LinearGradientBrush>
要应用边框,请在边框处添加边框画笔
<Border BorderBrush="{StaticResource MyBorderBrush}" BorderThickness="1" CornerRadius="4">
<!-- Content -->
</Border>