C00225155-02/C00225155/MegaRobo.C00225155/MegaRobo.C00225155App/res/ToolBarStyle.xaml

70 lines
3.3 KiB
XML

<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Style x:Key="toolbarStyle" TargetType="{x:Type ToolBar}">
<Setter Property="HorizontalAlignment" Value="Stretch"/>
<Setter Property="VerticalAlignment" Value="Stretch"/>
<Setter Property="OverridesDefaultStyle" Value="true"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ToolBar}">
<Border CornerRadius="2" BorderThickness="1" BorderBrush="#FFF0EEEE" >
<Border.Background>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#FFCAE0EA" Offset="0.09"/>
<!--<GradientStop Color="#FF70B0BF"/>-->
<GradientStop Color="#FFBCDEE7" Offset="0.982"/>
<GradientStop Color="#FFEEF3F6" Offset="0.657"/>
</LinearGradientBrush>
</Border.Background>
<ToolBarPanel IsItemsHost="true" Margin="10,1,2,2"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="ToolBar" x:Key="toolbarstyle" BasedOn="{StaticResource toolbarStyle}">
<Setter Property="HorizontalAlignment" Value="Stretch"/>
<Setter Property="VerticalAlignment" Value="Stretch"/>
<Setter Property="OverridesDefaultStyle" Value="true"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ToolBar}">
<Border CornerRadius="2" BorderThickness="1" BorderBrush="LightGray" Background="#FFEEF3F6">
<ToolBarPanel IsItemsHost="true" Margin="10,1,2,2"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="ToolBar" x:Key="toolbarstyle1" BasedOn="{StaticResource toolbarStyle}">
<Setter Property="HorizontalAlignment" Value="Stretch"/>
<Setter Property="VerticalAlignment" Value="Stretch"/>
<Setter Property="OverridesDefaultStyle" Value="true"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ToolBar}">
<Border CornerRadius="2" BorderThickness="0,0,0,2" BorderBrush="LightGray" Background="#FFEEF3F6">
<ToolBarPanel IsItemsHost="true" Margin="10,1,2,2"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="Button" x:Key="btnItemStyle">
<Setter Property="Foreground" Value="Black"/>
<Setter Property="FontFamily" Value="微软雅黑"/>
<Setter Property="Margin" Value="0,0"/>
<Setter Property="Width" Value="35"/>
<Setter Property="Height" Value="35"/>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Foreground" Value="#FFD77037"/>
</Trigger>
</Style.Triggers>
</Style>
</ResourceDictionary>