Skip to content

Commit

Permalink
v0.9.3
Browse files Browse the repository at this point in the history
Both variants now available in own folders.
  • Loading branch information
Tally authored Feb 11, 2021
1 parent 9258250 commit 047338b
Show file tree
Hide file tree
Showing 58 changed files with 7,244 additions and 0 deletions.
113 changes: 113 additions & 0 deletions Magpie_Desktop/Constants.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib">

<sys:Double x:Key="FontSizeSmall">12</sys:Double>
<sys:Double x:Key="FontSize">14</sys:Double>
<sys:Double x:Key="FontSizeLarge">15</sys:Double>
<sys:Double x:Key="FontSizeLarger">20</sys:Double>
<sys:Double x:Key="FontSizeLargest">29</sys:Double>
<FontFamily x:Key="FontFamily">Trebuchet MS</FontFamily>
<Thickness x:Key="PopupBorderThickness">1</Thickness>
<Thickness x:Key="ControlBorderThickness">1</Thickness>
<sys:Double x:Key="EllipseBorderThickness">1</sys:Double>
<CornerRadius x:Key="ControlCornerRadius">0</CornerRadius>

<Color x:Key="BlackColor">#FF000000</Color>
<Color x:Key="WhiteColor">#FFFFFFFF</Color>
<Color x:Key="TextColor">#f2f2f2</Color>
<Color x:Key="TextColorDarker">#cacaca</Color>
<Color x:Key="TextColorDark">#FF000000</Color>
<Color x:Key="MainColor">#2b2b2b</Color>
<Color x:Key="MainColorDark">#202020</Color>
<Color x:Key="HoverColor">#4d4d4d</Color>
<Color x:Key="GlyphColor">#62C3DF</Color>
<Color x:Key="HighlightGlyphColor">#FFFF0000</Color>
<Color x:Key="PopupBackgroundColor">#121212</Color>
<Color x:Key="PopupBorderColor">#2B2B2B</Color>
<Color x:Key="BackgroundToneColor">#202020</Color>
<Color x:Key="GridItemBackgroundColor">#6c6c6c</Color>
<Color x:Key="PanelSeparatorColor">#282828</Color>

<SolidColorBrush x:Key="ControlBackgroundBrush" Color="{DynamicResource MainColorDark}" Opacity="0.7" />
<SolidColorBrush x:Key="TextBrush" Color="{DynamicResource TextColor}" />
<SolidColorBrush x:Key="TextBrushDarker" Color="{DynamicResource TextColorDarker}" />
<SolidColorBrush x:Key="TextBrushDark" Color="{DynamicResource TextColorDark}" />
<SolidColorBrush x:Key="NormalBrush" Color="{DynamicResource MainColor}" />
<SolidColorBrush x:Key="NormalBrushDark" Color="{DynamicResource MainColorDark}" />
<SolidColorBrush x:Key="NormalBorderBrush" Color="{DynamicResource ButtonBackgroundColor}"/>
<SolidColorBrush x:Key="HoverBrush" Color="{DynamicResource HoverColor}"/>
<SolidColorBrush x:Key="GlyphBrush" Color="{DynamicResource GlyphColor}" />
<SolidColorBrush x:Key="HighlightGlyphBrush" Color="{DynamicResource HighlightGlyphColor}" />
<SolidColorBrush x:Key="PopupBorderBrush" Color="{DynamicResource PopupBorderColor}" />
<SolidColorBrush x:Key="TooltipBackgroundBrush" Color="{DynamicResource BackgroundToneColor}" />
<SolidColorBrush x:Key="ButtonBackgroundBrush" Color="{DynamicResource ButtonBackgroundColor}"/>
<SolidColorBrush x:Key="GridItemBackgroundBrush" Color="{DynamicResource GridItemBackgroundColor}" Opacity="0.7 "/>
<SolidColorBrush x:Key="PanelSeparatorBrush" Color="{DynamicResource PanelSeparatorColor}" Opacity="1"/>
<SolidColorBrush x:Key="PopupBackgroundBrush" Color="{DynamicResource PopupBackgroundColor}" />

<SolidColorBrush x:Key="PositiveRatingBrush" Color="#78ffa0" />
<SolidColorBrush x:Key="NegativeRatingBrush" Color="#ff6b6b" />
<SolidColorBrush x:Key="MixedRatingBrush" Color="#fffca1" />

<SolidColorBrush x:Key="WarningBrush" Color="#ff6b6b" />

<SolidColorBrush x:Key="ExpanderBackgroundBrush" Color="Transparent" />

<!-- Spacer for alignment
with default theme -->

<SolidColorBrush x:Key="WindowBackgroundBrush" Color="{DynamicResource PopupBackgroundColor}"/>

<!-- Some ideas for custom glyph colors:
For grey try: #A6A6A6,
for gold try #FFD768,
for salmon try #FF7A68,
for red try #E34141,
for blue try #62C3DF -->

<!-- Magpie-Specific Variables-->

<sys:Boolean x:Key="UseAbsoluteExtraMetadataPath">true</sys:Boolean>
<sys:String x:Key="ExtraMetadataPath">C:\Users\Tally\AppData\Roaming\Playnite</sys:String>
<sys:String x:Key="AboutGameText">About the Game</sys:String>
<sys:Boolean x:Key="BGModeOn">false</sys:Boolean>

<sys:Double x:Key="ControlCornerRadiusDouble">0</sys:Double>
<sys:Double x:Key="GroupSeparatorOpacity">1</sys:Double>
<FontFamily x:Key="SymbolFont">seguisym.ttf#Segoe UI Symbol</FontFamily>
<Visibility x:Key="TitleTextVisibility">Visible</Visibility>
<sys:Double x:Key="DetailsViewPanelWidth">1280</sys:Double>

<!-- Magpie-Specific Colors -->
<Color x:Key="ButtonBackgroundColor">#2b2b2b</Color>
<Color x:Key="PlayButtonColor">#4BC937</Color>
<Color x:Key="ContextButtonColor">#385DA2</Color>
<Color x:Key="ContextButtonHighlightColor">#5C63BB</Color>
<Color x:Key="ClearFilterButtonColor">#e34141</Color>
<Color x:Key="PopupBackgroundTransparent">#00121212</Color>

<SolidColorBrush x:Key="CoverHighlightBrush" Color="#20FFFFFF" />

<Color x:Key="NormalBorderColor">#282828</Color>
<SolidColorBrush x:Key="TitlebarBrush" Color="{DynamicResource PopupBackgroundColor}" Opacity="0.7"/>
<SolidColorBrush x:Key="DisabledBackgroundBrush" Color="{DynamicResource MainColorDark}" />
<SolidColorBrush x:Key="DetailsButtonBrush" Color="{DynamicResource HoverColor}" Opacity=".7"/>
<SolidColorBrush x:Key="ButtonBorderBrush" Color="{DynamicResource ButtonBackgroundColor}" Opacity="1"/>
<SolidColorBrush x:Key="HoverBorderBrush" Color="{DynamicResource HoverColor}" Opacity="1" />
<SolidColorBrush x:Key="ButtonFocusBorderBrush" Color="{DynamicResource HoverColor}" Opacity="1" />
<SolidColorBrush x:Key="PanelBackgroundBrush" Color="{DynamicResource PopupBackgroundColor}" Opacity="0.7" />
<SolidColorBrush x:Key="DetailsPanelBrush" Color="{DynamicResource PopupBackgroundColor}" Opacity="0.7" />
<SolidColorBrush x:Key="DetailsViewGroupTextBrush" Color="{DynamicResource GlyphColor}" />

<SolidColorBrush x:Key="PlayButtonBrush" Color="{DynamicResource HoverColor}" Opacity="0.7" />
<SolidColorBrush x:Key="PlayBorderBrush" Color="{DynamicResource HoverColor}" Opacity="1" />
<SolidColorBrush x:Key="PlayButtonHighlightBrush" Color="{DynamicResource PlayButtonColor}" Opacity="0.7" />
<SolidColorBrush x:Key="PlayBorderHighlightBrush" Color="{DynamicResource PlayButtonColor}" Opacity="1" />
<SolidColorBrush x:Key="ContextButtonBrush" Color="{DynamicResource ContextButtonColor}" Opacity="0.7" />
<SolidColorBrush x:Key="ContextBorderBrush" Color="{DynamicResource ContextButtonColor}" Opacity="1" />
<SolidColorBrush x:Key="ClearFilterButtonBrush" Color="{DynamicResource ClearFilterButtonColor}" Opacity="0.7" />
<SolidColorBrush x:Key="ClearFilterBorderBrush" Color="{DynamicResource ClearFilterButtonColor}" Opacity="1" />
<SolidColorBrush x:Key="CoverOverlayBackgroundBrush" Color="{DynamicResource PanelBackgroundColor}" Opacity=".5" />

</ResourceDictionary>
80 changes: 80 additions & 0 deletions Magpie_Desktop/CustomControls/SliderEx.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

<Style x:Key="SliderExTrackButton" TargetType="{x:Type RepeatButton}">
<Setter Property="SnapsToDevicePixels" Value="True" />
<Setter Property="OverridesDefaultStyle" Value="true" />
<Setter Property="IsTabStop" Value="False" />
<Setter Property="Focusable" Value="False" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type RepeatButton}">
<Border Background="Transparent" />
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>

<Style TargetType="{x:Type SliderEx}" BasedOn="{StaticResource {x:Type Slider}}">
<Setter Property="SnapsToDevicePixels" Value="True" />
<Setter Property="Background" Value="{DynamicResource ControlBackgroundBrush}" />
<Setter Property="BorderBrush" Value="{DynamicResource TextBrush}" />
<Setter Property="BorderThickness" Value="0" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Slider}">
<Grid x:Name="GridRoot">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" MinHeight="{TemplateBinding MinHeight}" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<TickBar x:Name="TopTick" Visibility="Collapsed" Height="4" Placement="Top"
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" Fill="{DynamicResource GlyphBrush}" />
<Border x:Name="Border" Grid.Row="1" Margin="0" Height="6" CornerRadius="{DynamicResource ControlCornerRadius}"
Background="{TemplateBinding Background}" BorderBrush="{DynamicResource NormalBorderBrush}"
BorderThickness="{DynamicResource ControlBorderThickness}" />
<Track Grid.Row="1" x:Name="PART_Track">
<Track.Thumb>
<Thumb Width="25" />
</Track.Thumb>
<Track.DecreaseRepeatButton>
<RepeatButton Style="{StaticResource SliderExTrackButton}"
Command="Slider.DecreaseLarge" />
</Track.DecreaseRepeatButton>
<Track.IncreaseRepeatButton>
<RepeatButton Style="{StaticResource SliderExTrackButton}"
Command="Slider.IncreaseLarge" />
</Track.IncreaseRepeatButton>
</Track>
<TickBar x:Name="BottomTick" Visibility="Collapsed" Grid.Row="2" Height="4" Placement="Bottom"
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" Fill="{TemplateBinding Foreground}" />
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsFocused" Value="True">
<Setter TargetName="PART_Track" Property="FocusManager.FocusedElement" Value="{Binding ElementName=PART_Track}" />
</Trigger>
<Trigger Property="TickPlacement" Value="TopLeft">
<Setter Property="Visibility" Value="Visible" TargetName="TopTick" />
</Trigger>
<Trigger Property="TickPlacement" Value="BottomRight">
<Setter Property="Visibility" Value="Visible" TargetName="BottomTick" />
</Trigger>
<Trigger Property="TickPlacement" Value="Both">
<Setter Property="Visibility" Value="Visible" TargetName="TopTick" />
<Setter Property="Visibility" Value="Visible" TargetName="BottomTick" />
</Trigger>
<Trigger Property="Orientation" Value="Vertical">
<Setter Property="LayoutTransform" TargetName="GridRoot">
<Setter.Value>
<RotateTransform Angle="-90" />
</Setter.Value>
</Setter>
<Setter TargetName="PART_Track" Property="Orientation" Value="Horizontal" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>
18 changes: 18 additions & 0 deletions Magpie_Desktop/CustomControls/WindowBase.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

<Style TargetType="WindowBase">
<Setter Property="Background" Value="{DynamicResource WindowBackgroundBrush}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type WindowBase}">
<Border Background="{TemplateBinding Background}">
<AdornerDecorator>
<ContentPresenter />
</AdornerDecorator>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>
43 changes: 43 additions & 0 deletions Magpie_Desktop/DefaultControls/Button.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
mc:Ignorable="d">

<Style TargetType="{x:Type Button}" BasedOn="{StaticResource BaseStyle}">
<Setter Property="Background" Value="{DynamicResource ButtonBackgroundBrush}" />
<Setter Property="Foreground" Value="{DynamicResource GlyphBrush}" />
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrush}" />
<Setter Property="BorderThickness" Value="{DynamicResource ControlBorderThickness}" />
<Setter Property="SnapsToDevicePixels" Value="True" />
<Setter Property="Padding" Value="10,5,10,5" />
<Setter Property="Focusable" Value="False" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Button}">
<Border x:Name="Border" Cursor="Hand" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}"
CornerRadius="{DynamicResource ControlCornerRadius}" Style="{DynamicResource HighlightBorder}" BorderBrush="{TemplateBinding BorderBrush}">
<ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
Margin="{TemplateBinding Padding}" RecognizesAccessKey="True" />
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsFocused" Value="True">
<Setter Property="BorderBrush" Value="{DynamicResource HoverBorderBrush}"/>
<Setter Property="Foreground" Value="{DynamicResource TextBrush}" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Foreground" Value="{DynamicResource TextBrush}"/>
<Setter Property="Background" Value="{DynamicResource HoverBrush}"/>
<Setter Property="BorderBrush" Value="{DynamicResource HoverBorderBrush}"/>
</Trigger>
</Style.Triggers>
</Style>
</ResourceDictionary>
Loading

0 comments on commit 047338b

Please sign in to comment.