mirror of
https://github.com/chev2/botw-toolset.git
synced 2025-10-30 08:12:17 +00:00
MenuItem Popup, TextBot caret color, remove MenuItem foreground declaration, Menu FontSize
170 lines
9.6 KiB
XML
170 lines
9.6 KiB
XML
<Application x:Class="BOTWToolset.App"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:local="clr-namespace:BOTWToolset"
|
|
StartupUri="Dashboard.xaml">
|
|
<Application.Resources>
|
|
<SolidColorBrush x:Key="BGTone0" Color="#262C35"/>
|
|
<SolidColorBrush x:Key="BGTone1" Color="#2C343E"/>
|
|
<SolidColorBrush x:Key="BGTone2" Color="#37424E"/>
|
|
<SolidColorBrush x:Key="BGTone3" Color="#3E4B59"/>
|
|
|
|
<SolidColorBrush x:Key="ButtonBG" Color="#303944"/>
|
|
<SolidColorBrush x:Key="ButtonSelected" Color="#586B7F"/>
|
|
|
|
<SolidColorBrush x:Key="TabSelected" Color="#455463"/>
|
|
|
|
<SolidColorBrush x:Key="BorderGray" Color="#506071"/>
|
|
|
|
<Style TargetType="{x:Type Label}">
|
|
<Setter Property="Foreground" Value="White"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type Button}">
|
|
<Setter Property="Background" Value="{StaticResource ButtonBG}"/>
|
|
<Setter Property="Foreground" Value="White"/> <!-- Text color -->
|
|
<Setter Property="BorderBrush" Value="White"/>
|
|
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type Button}">
|
|
<Border Background="{TemplateBinding Background}">
|
|
<Grid>
|
|
<ContentPresenter Content="{TemplateBinding Content}" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,0,0,0" />
|
|
</Grid>
|
|
</Border>
|
|
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
<Setter Property="Background" Value="{StaticResource BGTone3}"/>
|
|
<Setter Property="Foreground" Value="White"/>
|
|
</Trigger>
|
|
|
|
<Trigger Property="IsPressed" Value="True">
|
|
<Setter Property="Background" Value="{StaticResource ButtonSelected}"/>
|
|
<Setter Property="Foreground" Value="White"/>
|
|
</Trigger>
|
|
|
|
<Trigger Property="IsEnabled" Value="False">
|
|
<Setter Property="Background" Value="Transparent"/>
|
|
<Setter Property="Foreground" Value="{StaticResource BorderGray}"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style TargetType="{x:Type TabControl}">
|
|
<Setter Property="Background" Value="{StaticResource BGTone1}"/>
|
|
<Setter Property="Foreground" Value="White"/>
|
|
<Setter Property="BorderBrush" Value="Transparent"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type TabItem}">
|
|
<Setter Property="Background" Value="{StaticResource BGTone2}"/>
|
|
<Setter Property="Foreground" Value="White"/>
|
|
<Setter Property="BorderBrush" Value="Transparent"/>
|
|
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type TabItem}">
|
|
<Grid>
|
|
<Border
|
|
Name="Border"
|
|
Margin="0,0,-4,0"
|
|
Background="{StaticResource BGTone2}"
|
|
BorderBrush="Transparent"
|
|
BorderThickness="1,1,1,0"
|
|
CornerRadius="3,3,0,0" >
|
|
<ContentPresenter x:Name="ContentSite"
|
|
VerticalAlignment="Center"
|
|
HorizontalAlignment="Center"
|
|
ContentSource="Header"
|
|
Margin="12,2,12,2"
|
|
RecognizesAccessKey="True">
|
|
</ContentPresenter>
|
|
</Border>
|
|
</Grid>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsSelected" Value="True">
|
|
<Setter Property="Panel.ZIndex" Value="100"/>
|
|
<Setter TargetName="Border" Property="Background" Value="{StaticResource TabSelected}"/>
|
|
</Trigger>
|
|
<Trigger Property="IsEnabled" Value="False">
|
|
<Setter TargetName="Border" Property="Background" Value="#EEE"/>
|
|
<Setter TargetName="Border" Property="BorderBrush" Value="#AAA"/>
|
|
<Setter Property="Foreground" Value="#888"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style TargetType="{x:Type Menu}">
|
|
<Setter Property="Background" Value="{StaticResource BGTone2}"/>
|
|
<Setter Property="Foreground" Value="White"/>
|
|
<Setter Property="FontSize" Value="14"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type MenuItem}">
|
|
<Setter Property="BorderThickness" Value="0"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type TextBox}">
|
|
<Setter Property="Background" Value="Transparent"/>
|
|
<Setter Property="Foreground" Value="White"/>
|
|
<Setter Property="BorderBrush" Value="{StaticResource BorderGray}"/>
|
|
<Setter Property="CaretBrush" Value="White"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type Border}">
|
|
<Setter Property="BorderBrush" Value="{StaticResource BorderGray}"/>
|
|
<Setter Property="BorderThickness" Value="1"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type Image}">
|
|
<!--Smooth edges on transparent images-->
|
|
<Setter Property="RenderOptions.BitmapScalingMode" Value="HighQuality"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type Expander}">
|
|
<Setter Property="Foreground" Value="White"/>
|
|
</Style>
|
|
<Style TargetType="{x:Type CheckBox}">
|
|
<Setter Property="Foreground" Value="White"/>
|
|
</Style>
|
|
|
|
<Style x:Key="MenuItemPopup" TargetType="{x:Type MenuItem}">
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type MenuItem}">
|
|
<Grid SnapsToDevicePixels="True">
|
|
<DockPanel x:Name="MenuItemDockPanel">
|
|
<!--<ContentPresenter x:Name="Icon" ContentSource="Icon" Margin="0,0,0,0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="Center"/>
|
|
<Path x:Name="GlyphPanel" Fill="{TemplateBinding Foreground}" FlowDirection="LeftToRight" Margin="7,0,0,0" Visibility="Collapsed" VerticalAlignment="Center"/>-->
|
|
<ContentPresenter x:Name="Content"
|
|
ContentSource="Header"
|
|
Margin="{TemplateBinding Padding}"
|
|
RecognizesAccessKey="True"
|
|
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
|
|
TextBlock.Foreground="White"/>
|
|
</DockPanel>
|
|
<Popup x:Name="PART_Popup" AllowsTransparency="true" Focusable="false" HorizontalOffset="1" IsOpen="{Binding IsSubmenuOpen, RelativeSource={RelativeSource TemplatedParent}}" PopupAnimation="{DynamicResource {x:Static SystemParameters.MenuPopupAnimationKey}}" Placement="Bottom" VerticalOffset="-1">
|
|
<Border BorderThickness="0" Background="{StaticResource BGTone3}">
|
|
<ScrollViewer x:Name="SubMenuScrollViewer" CanContentScroll="true" Style="{DynamicResource {ComponentResourceKey ResourceId=MenuScrollViewer, TypeInTargetAssembly={x:Type FrameworkElement}}}">
|
|
<Grid RenderOptions.ClearTypeHint="Enabled">
|
|
<ItemsPresenter x:Name="ItemsPresenter"
|
|
KeyboardNavigation.DirectionalNavigation="Cycle"
|
|
Grid.IsSharedSizeScope="true"
|
|
Margin="2"
|
|
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
|
|
KeyboardNavigation.TabNavigation="Cycle"/>
|
|
</Grid>
|
|
</ScrollViewer>
|
|
</Border>
|
|
</Popup>
|
|
</Grid>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
<Setter TargetName="MenuItemDockPanel" Property="Background" Value="#11FFFFFF"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</Application.Resources>
|
|
</Application>
|