重命名
This commit is contained in:
57
NeoUI/Melskin/Controls/Separator.xaml
Normal file
57
NeoUI/Melskin/Controls/Separator.xaml
Normal file
@@ -0,0 +1,57 @@
|
||||
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
<!-- 水平分割 -->
|
||||
<Style x:Key="HorizontalSeparatorStyle" TargetType="{x:Type Separator}">
|
||||
<Setter Property="Background" Value="{DynamicResource BorderNormalBrush}" />
|
||||
<Setter Property="Margin" Value="0,4" />
|
||||
<Setter Property="Focusable" Value="false" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type Separator}">
|
||||
<Border
|
||||
Height="1"
|
||||
Background="{TemplateBinding Background}"
|
||||
BorderBrush="{TemplateBinding BorderBrush}"
|
||||
BorderThickness="{TemplateBinding BorderThickness}"
|
||||
SnapsToDevicePixels="true" />
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
<!-- 默认水平分割 -->
|
||||
<Style BasedOn="{StaticResource HorizontalSeparatorStyle}" TargetType="{x:Type Separator}" />
|
||||
<!-- 菜单分隔 -->
|
||||
<Style
|
||||
x:Key="{x:Static MenuItem.SeparatorStyleKey}"
|
||||
BasedOn="{StaticResource HorizontalSeparatorStyle}"
|
||||
TargetType="{x:Type Separator}">
|
||||
<Setter Property="Margin" Value="0,2" />
|
||||
</Style>
|
||||
|
||||
<!-- 垂直分割 -->
|
||||
<Style x:Key="VerticalSeparatorStyle" TargetType="{x:Type Separator}">
|
||||
<Setter Property="Background" Value="{DynamicResource BorderNormalBrush}" />
|
||||
<Setter Property="Margin" Value="2,0" />
|
||||
<Setter Property="Focusable" Value="false" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type Separator}">
|
||||
<Border
|
||||
Width="1"
|
||||
Background="{TemplateBinding Background}"
|
||||
BorderBrush="{TemplateBinding BorderBrush}"
|
||||
BorderThickness="{TemplateBinding BorderThickness}"
|
||||
SnapsToDevicePixels="true" />
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
<!-- 状态栏分割 -->
|
||||
<Style
|
||||
x:Key="{x:Static StatusBar.SeparatorStyleKey}"
|
||||
BasedOn="{StaticResource VerticalSeparatorStyle}"
|
||||
TargetType="{x:Type Separator}">
|
||||
<Setter Property="Margin" Value="4,2" />
|
||||
</Style>
|
||||
|
||||
|
||||
</ResourceDictionary>
|
||||
Reference in New Issue
Block a user