mirror of
https://github.com/k1tbyte/Wand-Enhancer.git
synced 2026-08-28 22:01:17 +00:00
354 lines
19 KiB
XML
354 lines
19 KiB
XML
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||
|
||
<CircleEase EasingMode="EaseInOut" x:Key="BaseAnimationFunction"/>
|
||
|
||
<Style TargetType="{x:Type Button}">
|
||
<Style.Resources>
|
||
<CornerRadius x:Key="CornerRadius">3 3 3 3</CornerRadius>
|
||
</Style.Resources>
|
||
<Setter Property="Background" Value="Transparent"/>
|
||
<Setter Property="FocusVisualStyle" Value="{x:Null}"/>
|
||
<Setter Property="BorderBrush" Value="{DynamicResource Border}"/>
|
||
<Setter Property="BorderThickness" Value="1"/>
|
||
<Setter Property="Foreground" Value="{DynamicResource Foreground}"/>
|
||
<Setter Property="Cursor" Value="Hand"/>
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="Button">
|
||
<Border CornerRadius="{DynamicResource CornerRadius}"
|
||
BorderThickness="{TemplateBinding BorderThickness}"
|
||
Padding="{TemplateBinding Padding}"
|
||
BorderBrush="{TemplateBinding BorderBrush}"
|
||
Background="{TemplateBinding Background}">
|
||
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||
</Border>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
<Style.Triggers>
|
||
<Trigger Property="IsMouseOver" Value="True">
|
||
<Setter Property="Background" Value="{DynamicResource Secondary}"/>
|
||
</Trigger>
|
||
</Style.Triggers>
|
||
</Style>
|
||
|
||
<Style x:Key="ColoredButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
|
||
<Setter Property="Background" Value="{DynamicResource Primary}"/>
|
||
<Setter Property="Foreground" Value="{DynamicResource PrimaryForeground}"/>
|
||
<Style.Triggers>
|
||
<Trigger Property="IsEnabled" Value="False">
|
||
<Setter Property="Background" Value="{DynamicResource Muted}"/>
|
||
<Setter Property="Foreground" Value="{DynamicResource MutedForeground}"/>
|
||
</Trigger>
|
||
<Trigger Property="IsMouseOver" Value="True">
|
||
<Setter Property="Margin" Value="0 2 0 2"/>
|
||
<Setter Property="Background" Value="{DynamicResource Primary}"/>
|
||
</Trigger>
|
||
</Style.Triggers>
|
||
</Style>
|
||
|
||
<Style x:Key="IconButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="Button">
|
||
<Border CornerRadius="{DynamicResource CornerRadius}"
|
||
BorderThickness="{TemplateBinding BorderThickness}"
|
||
Padding="{TemplateBinding Padding}"
|
||
BorderBrush="{TemplateBinding BorderBrush}"
|
||
Background="{TemplateBinding Background}">
|
||
<Viewbox HorizontalAlignment="Center" VerticalAlignment="Center">
|
||
<Path x:Name="Icon" Stretch="Fill" Data="{TemplateBinding Tag}" Fill="{TemplateBinding Foreground}"/>
|
||
</Viewbox>
|
||
</Border>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
</Style>
|
||
|
||
<CircleEase EasingMode="EaseIn" x:Key="DefaultAnimationFunction"/>
|
||
|
||
<Style TargetType="{x:Type ContextMenu}">
|
||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||
<Setter Property="OverridesDefaultStyle" Value="True"/>
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="{x:Type ContextMenu}">
|
||
<Border x:Name="Content" CornerRadius="5" Margin="5"
|
||
Background="{StaticResource Background}"
|
||
BorderThickness="1"
|
||
BorderBrush="{DynamicResource Border}"
|
||
Padding="4">
|
||
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Cycle" />
|
||
<Border.Effect>
|
||
<DropShadowEffect BlurRadius="5" ShadowDepth="0" Color="Black" Opacity="0.4"/>
|
||
</Border.Effect>
|
||
<Border.RenderTransform>
|
||
<ScaleTransform ScaleX="0" ScaleY="0"/>
|
||
</Border.RenderTransform>
|
||
</Border>
|
||
<ControlTemplate.Triggers>
|
||
<EventTrigger RoutedEvent="Loaded">
|
||
<BeginStoryboard>
|
||
<Storyboard>
|
||
<DoubleAnimation Duration="0:0:0.15" Storyboard.TargetName="Content" EasingFunction="{StaticResource DefaultAnimationFunction}"
|
||
Storyboard.TargetProperty="(Border.RenderTransform).(ScaleTransform.ScaleY)" From="0" To="1"/>
|
||
<DoubleAnimation Duration="0:0:0.15" Storyboard.TargetName="Content" EasingFunction="{StaticResource DefaultAnimationFunction}"
|
||
Storyboard.TargetProperty="(Border.RenderTransform).(ScaleTransform.ScaleX)" From="0" To="1"/>
|
||
</Storyboard>
|
||
</BeginStoryboard>
|
||
</EventTrigger>
|
||
</ControlTemplate.Triggers>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
</Style>
|
||
|
||
<Style TargetType="{x:Type MenuItem}">
|
||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||
<Setter Property="OverridesDefaultStyle" Value="True"/>
|
||
<Setter Property="Foreground" Value="{DynamicResource Foreground}"/>
|
||
<Setter Property="BorderBrush" Value="{DynamicResource Border}"/>
|
||
<Setter Property="Cursor" Value="Hand"/>
|
||
<Setter Property="FontWeight" Value="Medium"/>
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="{x:Type MenuItem}">
|
||
<Border Name="Root" Height="30" Background="Transparent" CornerRadius="4">
|
||
<ContentPresenter Name="HeaderHost" Margin="10,0,10,0"
|
||
ContentSource="Header" MinWidth="100"
|
||
RecognizesAccessKey="True"
|
||
HorizontalAlignment="Left" VerticalAlignment="Center"
|
||
TextOptions.TextRenderingMode="ClearType" TextBlock.FontSize="12" TextBlock.FontWeight="{TemplateBinding FontWeight}" TextBlock.Foreground="{TemplateBinding Foreground}" TextOptions.TextFormattingMode="Display"/>
|
||
</Border>
|
||
<ControlTemplate.Triggers>
|
||
<Trigger Property="IsMouseOver" Value="True">
|
||
<Setter Property="Foreground" Value="{DynamicResource Foreground}"/>
|
||
<Setter TargetName="Root" Property="Background" Value="{DynamicResource Accent}"/>
|
||
</Trigger>
|
||
<Trigger Property="IsPressed" Value="True">
|
||
<Setter Property="Foreground" Value="{DynamicResource Background}"/>
|
||
<Setter TargetName="Root" Property="Background" Value="{DynamicResource Foreground}"/>
|
||
</Trigger>
|
||
</ControlTemplate.Triggers>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
</Style>
|
||
|
||
<Style x:Key="LabelCard" TargetType="{x:Type Border}">
|
||
<Setter Property="Background" Value="{DynamicResource Card}"/>
|
||
<Setter Property="Opacity" Value="0.9"/>
|
||
<Setter Property="CornerRadius" Value="10"/>
|
||
<Setter Property="Padding" Value="12 6"/>
|
||
<Setter Property="HorizontalAlignment" Value="Center"/>
|
||
<Setter Property="VerticalAlignment" Value="Center"/>
|
||
</Style>
|
||
|
||
<Style x:Key="Label" TargetType="{x:Type TextBlock}">
|
||
<Setter Property="Foreground" Value="{DynamicResource Foreground}"/>
|
||
<Setter Property="FontWeight" Value="Medium"/>
|
||
<Setter Property="FontSize" Value="13"/>
|
||
<Setter Property="VerticalAlignment" Value="Center"/>
|
||
<Setter Property="HorizontalAlignment" Value="Center"/>
|
||
<Setter Property="TextAlignment" Value="Center"/>
|
||
</Style>
|
||
|
||
|
||
<Style TargetType="CheckBox">
|
||
<Setter Property="Cursor" Value="Hand"></Setter>
|
||
<Setter Property="Content" Value=""/>
|
||
<Setter Property="FocusVisualStyle" Value="{x:Null}"/>
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="{x:Type CheckBox}">
|
||
<Border x:Name="Border" Height="17" Width="17"
|
||
CornerRadius="3"
|
||
Background="{DynamicResource Foreground}" BorderBrush="{DynamicResource Border}"
|
||
BorderThickness="0">
|
||
<TextBlock x:Name="Text" VerticalAlignment="Center" HorizontalAlignment="Center"
|
||
Foreground="{DynamicResource PrimaryForeground}"></TextBlock>
|
||
</Border>
|
||
<ControlTemplate.Triggers>
|
||
<Trigger Property="IsChecked" Value="False">
|
||
<Setter TargetName="Border"
|
||
Property="Background" Value="Transparent"/>
|
||
<Setter TargetName="Border"
|
||
Property="BorderThickness" Value="1"/>
|
||
</Trigger>
|
||
<Trigger Property="IsChecked" Value="True">
|
||
<Setter TargetName="Text"
|
||
Property="Text" Value="✓"/>
|
||
</Trigger>
|
||
<Trigger Property="IsChecked" Value="{x:Null}">
|
||
<Setter TargetName="Text"
|
||
Property="Text" Value="–"/>
|
||
</Trigger>
|
||
</ControlTemplate.Triggers>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
</Style>
|
||
|
||
|
||
<Style TargetType="TextBox" x:Key="TitledTextBox">
|
||
<Setter Property="Background" Value="Transparent" />
|
||
<Setter Property="Height" Value="30" />
|
||
<Setter Property="Foreground" Value="{StaticResource Foreground}" />
|
||
<Setter Property="FontSize" Value="13" />
|
||
<Setter Property="CaretBrush" Value="{DynamicResource MutedForeground}" />
|
||
<Setter Property="SelectionBrush" Value="{DynamicResource MutedForeground}" />
|
||
<Setter Property="FontWeight" Value="Medium" />
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="{x:Type TextBox}">
|
||
<Border BorderBrush="{StaticResource Border}" Cursor="IBeam"
|
||
BorderThickness="1" CornerRadius="3">
|
||
<Grid>
|
||
<Grid.ColumnDefinitions>
|
||
<ColumnDefinition Width="Auto" />
|
||
<ColumnDefinition Width="Auto" />
|
||
</Grid.ColumnDefinitions>
|
||
<Border BorderBrush="{DynamicResource Border}"
|
||
BorderThickness="0 0 1 0" IsHitTestVisible="False">
|
||
<TextBlock Text="{DynamicResource mw_folder_path}"
|
||
VerticalAlignment="Center"
|
||
FontSize="12"
|
||
Foreground="{DynamicResource MutedForeground}"
|
||
Padding="10 0" />
|
||
</Border>
|
||
<ScrollViewer
|
||
Grid.Column="1"
|
||
Margin="5 0"
|
||
VerticalAlignment="Center"
|
||
x:Name="PART_ContentHost" />
|
||
<TextBlock IsHitTestVisible="False"
|
||
Grid.Column="1"
|
||
Opacity="0.3"
|
||
Text="{DynamicResource mw_folder_not_found}"
|
||
Margin="7 0 5 1"
|
||
VerticalAlignment="Center"
|
||
Visibility="Collapsed"
|
||
x:Name="Placeholder" />
|
||
</Grid>
|
||
</Border>
|
||
<ControlTemplate.Triggers>
|
||
<Trigger Property="Text" Value="">
|
||
<Setter TargetName="Placeholder"
|
||
Property="Visibility" Value="Visible" />
|
||
</Trigger>
|
||
</ControlTemplate.Triggers>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
</Style>
|
||
|
||
<Style TargetType="{x:Type ComboBox}">
|
||
<Setter Property="Background" Value="Transparent"/>
|
||
<Setter Property="FocusVisualStyle" Value="{x:Null}"/>
|
||
<Setter Property="BorderBrush" Value="{DynamicResource Border}"/>
|
||
<Setter Property="BorderThickness" Value="1"/>
|
||
<Setter Property="Foreground" Value="{DynamicResource Foreground}"/>
|
||
<Setter Property="Height" Value="30"/>
|
||
<Setter Property="Cursor" Value="Hand"/>
|
||
<Setter Property="Padding" Value="10 0"/>
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="{x:Type ComboBox}">
|
||
<Grid>
|
||
<ToggleButton x:Name="ToggleButton"
|
||
Focusable="False"
|
||
Background="Transparent"
|
||
BorderBrush="{TemplateBinding BorderBrush}"
|
||
BorderThickness="{TemplateBinding BorderThickness}"
|
||
IsChecked="{Binding IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
|
||
ClickMode="Press">
|
||
<ToggleButton.Template>
|
||
<ControlTemplate TargetType="{x:Type ToggleButton}">
|
||
<Border x:Name="Border" CornerRadius="3"
|
||
BorderThickness="{TemplateBinding BorderThickness}"
|
||
BorderBrush="{TemplateBinding BorderBrush}"
|
||
Background="Transparent">
|
||
<Grid>
|
||
<Grid.ColumnDefinitions>
|
||
<ColumnDefinition/>
|
||
<ColumnDefinition Width="20"/>
|
||
</Grid.ColumnDefinitions>
|
||
<Border Grid.Column="1" BorderBrush="{DynamicResource Border}"
|
||
BorderThickness="1 0 0 0" Margin="0 5"/>
|
||
<Path x:Name="Arrow" Grid.Column="1"
|
||
HorizontalAlignment="Center" VerticalAlignment="Center"
|
||
Data="M0,0 L4,4 L8,0" Stroke="{DynamicResource MutedForeground}"
|
||
StrokeThickness="1.5"/>
|
||
</Grid>
|
||
</Border>
|
||
<ControlTemplate.Triggers>
|
||
<Trigger Property="IsMouseOver" Value="True">
|
||
<Setter TargetName="Border" Property="Background" Value="{DynamicResource Secondary}"/>
|
||
</Trigger>
|
||
</ControlTemplate.Triggers>
|
||
</ControlTemplate>
|
||
</ToggleButton.Template>
|
||
</ToggleButton>
|
||
<ContentPresenter x:Name="ContentSite"
|
||
IsHitTestVisible="False"
|
||
Content="{TemplateBinding SelectionBoxItem}"
|
||
ContentTemplate="{TemplateBinding SelectionBoxItemTemplate}"
|
||
ContentTemplateSelector="{TemplateBinding ItemTemplateSelector}"
|
||
Margin="10,0,25,0"
|
||
VerticalAlignment="Center"
|
||
HorizontalAlignment="Left"/>
|
||
<Popup x:Name="Popup"
|
||
Placement="Bottom"
|
||
IsOpen="{TemplateBinding IsDropDownOpen}"
|
||
AllowsTransparency="True"
|
||
Focusable="False"
|
||
PopupAnimation="Slide">
|
||
<Grid x:Name="DropDown"
|
||
SnapsToDevicePixels="True"
|
||
MinWidth="{TemplateBinding ActualWidth}"
|
||
MaxHeight="{TemplateBinding MaxDropDownHeight}">
|
||
<Border x:Name="DropDownBorder"
|
||
CornerRadius="3"
|
||
Margin="0 2 0 0"
|
||
Background="{DynamicResource Background}"
|
||
BorderBrush="{DynamicResource Border}"
|
||
BorderThickness="1">
|
||
<ScrollViewer Margin="4" SnapsToDevicePixels="True">
|
||
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Contained"/>
|
||
</ScrollViewer>
|
||
</Border>
|
||
</Grid>
|
||
</Popup>
|
||
</Grid>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
</Style>
|
||
|
||
<Style TargetType="{x:Type ComboBoxItem}">
|
||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||
<Setter Property="FocusVisualStyle" Value="{x:Null}"/>
|
||
<Setter Property="Foreground" Value="{DynamicResource Foreground}"/>
|
||
<Setter Property="Cursor" Value="Hand"/>
|
||
<Setter Property="Padding" Value="8 5"/>
|
||
<Setter Property="Template">
|
||
<Setter.Value>
|
||
<ControlTemplate TargetType="{x:Type ComboBoxItem}">
|
||
<Border x:Name="Border" CornerRadius="3" Padding="{TemplateBinding Padding}"
|
||
Background="Transparent">
|
||
<ContentPresenter/>
|
||
</Border>
|
||
<ControlTemplate.Triggers>
|
||
<Trigger Property="IsHighlighted" Value="True">
|
||
<Setter TargetName="Border" Property="Background" Value="{DynamicResource Secondary}"/>
|
||
</Trigger>
|
||
<Trigger Property="IsSelected" Value="True">
|
||
<Setter TargetName="Border" Property="Background" Value="{DynamicResource Accent}"/>
|
||
</Trigger>
|
||
</ControlTemplate.Triggers>
|
||
</ControlTemplate>
|
||
</Setter.Value>
|
||
</Setter>
|
||
</Style>
|
||
</ResourceDictionary> |