Dexif/Installer/Dexif_Installer/App.xaml

164 lines
9.2 KiB
Plaintext
Raw Normal View History

2023-07-08 16:03:26 +00:00
<Application x:Class="Dexif_Installer.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Dexif_Installer"
2023-07-09 04:15:23 +00:00
StartupUri="MainWindow.xaml"
xmlns:fa="http://schemas.fontawesome.io/icons/">
<Application.Resources>
<!--
TODO:
- Progressbar Style
- Checkbox Style
- Button Hover Style
- Button Pressed Style
- Checkbox Hover Style
-->
<Color x:Key="Yellow">#EBCB8B</Color>
<Color x:Key="Red">#BF616A</Color>
<Color x:Key="Orange">#D08770</Color>
<Color x:Key="Green">#A3BE8C</Color>
<Color x:Key="Violet">#B48EAD</Color>
<Color x:Key="PolarNight_0">#2E3440</Color>
<Color x:Key="PolarNight_1">#3B4252</Color>
<Color x:Key="PolarNight_2">#434C5E</Color>
<Color x:Key="PolarNight_3">#4C566A</Color>
<Color x:Key="SnowStorm_0">#D8DEE9</Color>
<Color x:Key="SnowStorm_1">#E5E9F0</Color>
<Color x:Key="SnowStorm_2">#ECEFF4</Color>
<Color x:Key="Frost_0">#8FBCBB</Color>
<Color x:Key="Frost_1">#88C0D0</Color>
<Color x:Key="Frost_2">#81A1C1</Color>
<Color x:Key="Frost_3">#5E81AC</Color>
<SolidColorBrush x:Key="Yellow_Brush" Color="{DynamicResource Yellow}"/>
<SolidColorBrush x:Key="Red_Brush" Color="{DynamicResource Red}"/>
<SolidColorBrush x:Key="Orange_Brush" Color="{DynamicResource Orange}"/>
<SolidColorBrush x:Key="Green_Brush" Color="{DynamicResource Green}"/>
<SolidColorBrush x:Key="Violet_Brush" Color="{DynamicResource Violet}"/>
<SolidColorBrush x:Key="PolarNight_0_Brush" Color="{DynamicResource PolarNight_0}"/>
<SolidColorBrush x:Key="PolarNight_1_Brush" Color="{DynamicResource PolarNight_1}"/>
<SolidColorBrush x:Key="PolarNight_2_Brush" Color="{DynamicResource PolarNight_2}"/>
<SolidColorBrush x:Key="PolarNight_3_Brush" Color="{DynamicResource PolarNight_3}"/>
<SolidColorBrush x:Key="SnowStorm_0_Brush" Color="{DynamicResource SnowStorm_0}"/>
<SolidColorBrush x:Key="SnowStorm_1_Brush" Color="{DynamicResource SnowStorm_1}"/>
<SolidColorBrush x:Key="SnowStorm_2_Brush" Color="{DynamicResource SnowStorm_2}"/>
<SolidColorBrush x:Key="Frost_0_Brush" Color="{DynamicResource Frost_0}"/>
<SolidColorBrush x:Key="Frost_1_Brush" Color="{DynamicResource Frost_1}"/>
<SolidColorBrush x:Key="Frost_2_Brush" Color="{DynamicResource Frost_2}"/>
<SolidColorBrush x:Key="Frost_3_Brush" Color="{DynamicResource Frost_3}"/>
<!-- STATUSES -->
<Style TargetType="{x:Type fa:FontAwesome}">
<Setter Property="TextWrapping" Value="NoWrap"/>
<Setter Property="TextTrimming" Value="None"/>
<Style.Triggers>
<Trigger Property="Icon" Value="QuestionCircleOutline">
<Setter Property="Foreground" Value="{DynamicResource Yellow_Brush}"/>
</Trigger>
<Trigger Property="Icon" Value="CheckCircleOutline">
<Setter Property="Foreground" Value="{DynamicResource Green_Brush}"/>
</Trigger>
<Trigger Property="Icon" Value="TimesCircleOutline">
<Setter Property="Foreground" Value="{DynamicResource Red_Brush}"/>
</Trigger>
</Style.Triggers>
</Style>
<!-- LABELS -->
<Style TargetType="{x:Type Label}">
<Setter Property="Foreground" Value="{DynamicResource Button.Static.Foreground}"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Padding" Value="5"/>
<Setter Property="HorizontalContentAlignment" Value="Left"/>
<Setter Property="VerticalContentAlignment" Value="Top"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Label}">
<Border Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="true">
<ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsEnabled" Value="false">
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="FocusVisual">
<Setter Property="Control.Template">
<Setter.Value>
<ControlTemplate>
<Rectangle Margin="2" StrokeDashArray="1 2" Stroke="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" SnapsToDevicePixels="true" StrokeThickness="1"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- BUTTONS -->
<SolidColorBrush x:Key="Button.Static.Background" Color="{DynamicResource PolarNight_0}"/>
<SolidColorBrush x:Key="Button.Static.Border" Color="{DynamicResource PolarNight_3}"/>
<SolidColorBrush x:Key="Button.Static.Foreground" Color="{DynamicResource SnowStorm_2}"/>
<SolidColorBrush x:Key="Button.MouseOver.Background" Color="{DynamicResource PolarNight_0}"/>
<SolidColorBrush x:Key="Button.MouseOver.Border" Color="{DynamicResource PolarNight_3}"/>
<SolidColorBrush x:Key="Button.Pressed.Background" Color="{DynamicResource PolarNight_0}"/>
<SolidColorBrush x:Key="Button.Pressed.Border" Color="{DynamicResource PolarNight_3}"/>
<SolidColorBrush x:Key="Button.Disabled.Background" Color="{DynamicResource PolarNight_0}"/>
<SolidColorBrush x:Key="Button.Disabled.Border" Color="{DynamicResource PolarNight_3}"/>
<SolidColorBrush x:Key="Button.Disabled.Foreground" Color="{DynamicResource PolarNight_3}"/>
<Style TargetType="{x:Type Button}">
<Setter Property="FocusVisualStyle" Value="{StaticResource FocusVisual}"/>
<Setter Property="Background" Value="{StaticResource Button.Static.Background}"/>
<Setter Property="BorderBrush" Value="{StaticResource Button.Static.Border}"/>
<Setter Property="Foreground" Value="{StaticResource Button.Static.Foreground}"/>
<Setter Property="BorderThickness" Value="1"/>
<Setter Property="HorizontalContentAlignment" Value="Center"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Padding" Value="1"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Border x:Name="border" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" SnapsToDevicePixels="true">
<ContentPresenter x:Name="contentPresenter" Focusable="False" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="Button.IsDefaulted" Value="true">
<Setter Property="BorderBrush" TargetName="border" Value="{DynamicResource {x:Static SystemColors.HighlightBrushKey}}"/>
</Trigger>
<Trigger Property="IsMouseOver" Value="true">
<Setter Property="Background" TargetName="border" Value="{StaticResource Button.MouseOver.Background}"/>
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource Button.MouseOver.Border}"/>
</Trigger>
<Trigger Property="IsPressed" Value="true">
<Setter Property="Background" TargetName="border" Value="{StaticResource Button.Pressed.Background}"/>
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource Button.Pressed.Border}"/>
</Trigger>
<Trigger Property="IsEnabled" Value="false">
<Setter Property="Background" TargetName="border" Value="{StaticResource Button.Disabled.Background}"/>
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource Button.Disabled.Border}"/>
<Setter Property="TextElement.Foreground" TargetName="contentPresenter" Value="{StaticResource Button.Disabled.Foreground}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- WINDOWS -->
<Style TargetType="{x:Type Window}">
<Setter Property="Background" Value="{DynamicResource PolarNight_0_Brush}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ContentControl}">
<ContentPresenter/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Application.Resources>
2023-07-08 16:03:26 +00:00
</Application>