Skip to content

Commit 3b8a0c6

Browse files
committed
Update size, font and shared names
1 parent 95d3900 commit 3b8a0c6

File tree

9 files changed

+24
-38
lines changed

9 files changed

+24
-38
lines changed

src/MahApps.Metro/Styles/Controls.Buttons.xaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1077,8 +1077,8 @@
10771077
</Style>
10781078

10791079
<Style x:Key="MahApps.Styles.Button.System.Mui" TargetType="ButtonBase" BasedOn="{StaticResource MahApps.Styles.Button.System.Base.Mui}">
1080-
<Setter Property="Width" Value="{DynamicResource SystemButtonWidth}" />
1081-
<Setter Property="Height" Value="{DynamicResource SystemButtonHeight}" />
1080+
<Setter Property="Width" Value="{DynamicResource MahApps.Sizes.Button.System.Width.Mui}" />
1081+
<Setter Property="Height" Value="{DynamicResource MahApps.Sizes.Button.System.Height.Mui}" />
10821082
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.ButtonText.Mui}"/>
10831083
<Style.Triggers>
10841084
<Trigger Property="IsMouseOver" Value="True">
@@ -1096,7 +1096,7 @@
10961096
</Style>
10971097

10981098
<Style x:Key="MahApps.Styles.Button.System.Close.Mui" TargetType="ButtonBase" BasedOn="{StaticResource MahApps.Styles.Button.System.Mui}">
1099-
<Setter Property="Width" Value="{DynamicResource CloseButtonWidth}" />
1099+
<Setter Property="Width" Value="{DynamicResource MahApps.Sizes.Button.Close.Width.Mui}" />
11001100
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.CloseButtonBackground.Mui}" />
11011101
<Style.Triggers>
11021102
<Trigger Property="IsMouseOver" Value="True">

src/MahApps.Metro/Styles/Controls.Calendar.xaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -602,7 +602,7 @@
602602
<ControlTemplate.Resources>
603603
<DataTemplate x:Key="{x:Static CalendarItem.DayTitleTemplateResourceKey}">
604604
<TextBlock x:Name="Text" FontWeight="Bold"
605-
FontSize="{DynamicResource DefaultFontSize}"
605+
FontSize="{DynamicResource MahApps.Sizes.Font.Default.Mui}"
606606
Foreground="{DynamicResource MahApps.Brushes.ItemText.Mui}"
607607
HorizontalAlignment="Center"
608608
Text="{Binding}"
@@ -722,7 +722,7 @@
722722
<Style x:Key="MahApps.Styles.CalendarDayButton.Mui" TargetType="CalendarDayButton" >
723723
<Setter Property="MinWidth" Value="5"/>
724724
<Setter Property="MinHeight" Value="5"/>
725-
<Setter Property="FontSize" Value="{DynamicResource DefaultFontSize}"/>
725+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Default.Mui}"/>
726726
<Setter Property="HorizontalContentAlignment" Value="Center"/>
727727
<Setter Property="VerticalContentAlignment" Value="Center"/>
728728
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
@@ -786,7 +786,7 @@
786786
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.ButtonText.Mui}" />
787787
<Setter Property="MinWidth" Value="40"/>
788788
<Setter Property="MinHeight" Value="42"/>
789-
<Setter Property="FontSize" Value="{DynamicResource DefaultFontSize}"/>
789+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Default.Mui}"/>
790790
<Setter Property="HorizontalContentAlignment" Value="Center"/>
791791
<Setter Property="VerticalContentAlignment" Value="Center"/>
792792
<Setter Property="FocusVisualStyle" Value="{x:Null}" />

src/MahApps.Metro/Styles/Controls.ContextMenu.xaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -605,8 +605,8 @@
605605
<!-- MUI -->
606606

607607
<Style x:Key="MahApps.Styles.ContextMenu.Mui" TargetType="{x:Type ContextMenu}">
608-
<Setter Property="FontFamily" Value="{DynamicResource DefaultFontFamily}"/>
609-
<Setter Property="FontSize" Value="{DynamicResource DefaultFontSize}" />
608+
<Setter Property="FontFamily" Value="{DynamicResource MahApps.Fonts.Default.Mui}"/>
609+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Default.Mui}" />
610610
<Setter Property="TextOptions.TextFormattingMode" Value="Display" />
611611
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.WindowBackground.Mui}" />
612612
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.ItemText.Mui}"/>

src/MahApps.Metro/Styles/Controls.DataGrid.xaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -807,8 +807,8 @@
807807
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.DataGridHeaderForeground.Mui}" />
808808
<Setter Property="BorderThickness" Value="0" />
809809
<Setter Property="FontWeight" Value="Bold" />
810-
<Setter Property="FontFamily" Value="{DynamicResource DefaultFontFamily}" />
811-
<Setter Property="FontSize" Value="{DynamicResource DefaultFontSize}" />
810+
<Setter Property="FontFamily" Value="{DynamicResource MahApps.Fonts.Default.Mui}" />
811+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Default.Mui}" />
812812
<Setter Property="Padding" Value="4,3,4,3"/>
813813
<Setter Property="HorizontalContentAlignment" Value="Center" />
814814
<Setter Property="VerticalContentAlignment" Value="Center" />

src/MahApps.Metro/Styles/Controls.TextBlock.xaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,20 +46,20 @@
4646

4747
<Style x:Key="MahApps.Styles.TextBlock.Small.Mui" TargetType="TextBlock">
4848
<Setter Property="FontFamily" Value="Segoe UI" />
49-
<Setter Property="FontSize" Value="{DynamicResource SmallFontSize}"/>
49+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Small.Mui}"/>
5050
<Setter Property="TextOptions.TextFormattingMode" Value="Display" />
5151
</Style>
5252

5353
<Style x:Key="MahApps.Styles.TextBlock.Emphasis.Mui" TargetType="TextBlock">
5454
<Setter Property="FontFamily" Value="Segoe UI" />
55-
<Setter Property="FontSize" Value="{DynamicResource SmallFontSize}"/>
55+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Small.Mui}"/>
5656
<Setter Property="FontWeight" Value="Bold" />
5757
<Setter Property="TextOptions.TextFormattingMode" Value="Display" />
5858
</Style>
5959

6060
<Style x:Key="MahApps.Styles.TextBlock.Fixed.Mui" TargetType="TextBlock">
61-
<Setter Property="FontFamily" Value="{DynamicResource FixedFontFamily}" />
62-
<Setter Property="FontSize" Value="{DynamicResource FixedFontSize}"/>
61+
<Setter Property="FontFamily" Value="{DynamicResource MahApps.Fonts.Fixed.Mui}" />
62+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Fixed.Mui}"/>
6363
<Setter Property="TextOptions.TextFormattingMode" Value="Display" />
6464
</Style>
6565

src/MahApps.Metro/Styles/Controls.Tooltip.xaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@
7070
<Setter Property="BorderBrush" Value="{DynamicResource MahApps.Brushes.WindowBorderActive.Mui}"/>
7171
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.WindowBackground.Mui}"/>
7272
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.WindowText.Mui}"/>
73-
<Setter Property="FontFamily" Value="{DynamicResource DefaultFontFamily}"/>
74-
<Setter Property="FontSize" Value="{DynamicResource DefaultFontSize}"/>
73+
<Setter Property="FontFamily" Value="{DynamicResource MahApps.Fonts.Default.Mui}"/>
74+
<Setter Property="FontSize" Value="{DynamicResource MahApps.Sizes.Font.Default.Mui}"/>
7575
<Setter Property="FontStyle" Value="Normal"/>
7676
<Setter Property="FontWeight" Value="Normal"/>
7777
<Setter Property="Padding" Value="5,1,5,4"/>

src/MahApps.Metro/Styles/Fonts.xaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@
4040

4141
<!-- MUI -->
4242

43-
<FontFamily x:Key="DefaultFontFamily">Segoe UI</FontFamily>
44-
<FontFamily x:Key="FixedFontFamily">Consolas</FontFamily>
43+
<FontFamily x:Key="MahApps.Fonts.Default.Mui">Segoe UI</FontFamily>
44+
<FontFamily x:Key="MahApps.Fonts.Fixed.Mui">Consolas</FontFamily>
4545

46-
<System:Double x:Key="DefaultFontSize">13</System:Double>
47-
<System:Double x:Key="FixedFontSize">13.333</System:Double>
48-
<System:Double x:Key="SmallFontSize">11</System:Double>
46+
<System:Double x:Key="MahApps.Sizes.Font.Default.Mui">13</System:Double>
47+
<System:Double x:Key="MahApps.Sizes.Font.Fixed.Mui">13.333</System:Double>
48+
<System:Double x:Key="MahApps.Sizes.Font.Small.Mui">11</System:Double>
4949

5050
</ResourceDictionary>

src/MahApps.Metro/Styles/Shared.xaml

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -49,18 +49,4 @@
4949
Duration="0:0:.2" />
5050
</Storyboard>
5151

52-
<!-- MUI -->
53-
54-
<Thickness x:Key="RootMargin">-42,-8,-16,-16</Thickness>
55-
<Thickness x:Key="ContentMargin">16,28,16,16</Thickness>
56-
<Thickness x:Key="StatusMargin">-16,16,0,0</Thickness>
57-
<Thickness x:Key="HeaderMargin">0,-28,44,0</Thickness>
58-
59-
<Thickness x:Key="SplitLeft">0,0,0,0</Thickness>
60-
<Thickness x:Key="SplitRight">16,0,0,0</Thickness>
61-
62-
<Style x:Key="ContentRoot" TargetType="FrameworkElement">
63-
<Setter Property="Margin" Value="{StaticResource ContentMargin}" />
64-
</Style>
65-
6652
</ResourceDictionary>

src/MahApps.Metro/Styles/Sizes.xaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010

1111
<!-- MUI -->
1212

13-
<System:Double x:Key="CloseButtonWidth">32</System:Double>
14-
<System:Double x:Key="SystemButtonHeight">24</System:Double>
15-
<System:Double x:Key="SystemButtonWidth">32</System:Double>
13+
<System:Double x:Key="MahApps.Sizes.Button.Close.Width.Mui">32</System:Double>
14+
<System:Double x:Key="MahApps.Sizes.Button.System.Height.Mui">24</System:Double>
15+
<System:Double x:Key="MahApps.Sizes.Button.System.Width.Mui">32</System:Double>
1616

1717
</ResourceDictionary>

0 commit comments

Comments
 (0)