73 lines
3.9 KiB
XML
73 lines
3.9 KiB
XML
<ResourceDictionary
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:internals="clr-namespace:WPFDark.Controls.Internals"
|
|
xmlns:wpf="clr-namespace:WPFDark"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
|
<!--<ResourceDictionary.MergedDictionaries>
|
|
<ResourceDictionary Source="pack://application:,,,/WPFDark;component/Resources/Colors.xaml"/>
|
|
</ResourceDictionary.MergedDictionaries>-->
|
|
<Style TargetType="{x:Type internals:BiaSystemButton}">
|
|
<Setter Property="Foreground" Value="{DynamicResource AccentForegroundBrushKey}" />
|
|
<Setter Property="Background" Value="Transparent" />
|
|
<Setter Property="FontSize" Value="16" />
|
|
<Setter Property="IsTabStop" Value="False" />
|
|
<Setter Property="Margin" Value="0" />
|
|
<Setter Property="Padding" Value="0" />
|
|
<Setter Property="Width" Value="32.0" />
|
|
<Setter Property="Height" Value="32.0" />
|
|
<Setter Property="WindowChrome.IsHitTestVisibleInChrome" Value="True" />
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type internals:BiaSystemButton}">
|
|
<Border
|
|
Background="{TemplateBinding Background}"
|
|
BorderBrush="{TemplateBinding BorderBrush}"
|
|
Padding="10"
|
|
SnapsToDevicePixels="True"
|
|
TextElement.Foreground="{TemplateBinding Foreground}">
|
|
<Path
|
|
Fill="{Binding (TextBlock.Foreground), RelativeSource={RelativeSource AncestorType=internals:BiaSystemButton}}"
|
|
Stretch="Uniform"
|
|
x:Name="Face" />
|
|
</Border>
|
|
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="WindowAction" Value="Minimize">
|
|
<Setter Property="Data" TargetName="Face" Value="M20,14H4V10H20" />
|
|
</Trigger>
|
|
|
|
<Trigger Property="WindowAction" Value="Maximize">
|
|
<Setter Property="Data" TargetName="Face" Value="M4,4H20V20H4V4M6,8V18H18V8H6Z" />
|
|
</Trigger>
|
|
|
|
<Trigger Property="WindowAction" Value="Normalize">
|
|
<Setter Property="Data" TargetName="Face" Value="M4,8H8V4H20V16H16V20H4V8M16,8V14H18V6H10V8H16M6,12V18H14V12H6Z" />
|
|
</Trigger>
|
|
|
|
<Trigger Property="WindowAction" Value="Close">
|
|
<Setter Property="Data" TargetName="Face" Value="M13.46,12L19,17.54V19H17.54L12,13.46L6.46,19H5V17.54L10.54,12L5,6.46V5H6.46L12,10.54L17.54,5H19V6.46L13.46,12Z" />
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
|
|
|
|
<Style.Triggers>
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
<Setter Property="Background" Value="{DynamicResource ActiveBackgroundBrushKey}" />
|
|
<Setter Property="BorderBrush" Value="{DynamicResource ActiveBorderBrushKey}" />
|
|
<Setter Property="Foreground" Value="{DynamicResource AccentBrushKey}" />
|
|
</Trigger>
|
|
<Trigger Property="IsPressed" Value="True">
|
|
<Setter Property="Background" Value="{DynamicResource AccentBrushKey}" />
|
|
<Setter Property="BorderBrush" Value="{DynamicResource ActiveBorderBrushKey}" />
|
|
<Setter Property="Foreground" Value="{DynamicResource AccentForegroundBrushKey}" />
|
|
</Trigger>
|
|
<Trigger Property="IsEnabled" Value="False">
|
|
<Setter Property="Opacity" Value="0.6" />
|
|
</Trigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
|
|
</ResourceDictionary> |