Skip to content

Commit 53206a9

Browse files
committed
FontSize is now amendable in DataGrid...
...however, the column header font size is specified differently (as per the material design spec). So to change the column header style a custom DataGridColumnHeader must be applied. Fixes #168
1 parent 53834da commit 53206a9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

MaterialDesignThemes.Wpf/Themes/MaterialDesignTheme.DataGrid.xaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@
147147
</Style>
148148

149149
<Style x:Key="MaterialDesignDataGridCell" TargetType="{x:Type DataGridCell}">
150-
<Setter Property="TextBlock.FontSize" Value="13" />
150+
<!--Setter Property="TextBlock.FontSize" Value="13" /-->
151151
<Setter Property="Padding" Value="{Binding RelativeSource={RelativeSource Self}, Path=(wpf:DataGridAssist.CellPadding)}" />
152152
<Setter Property="Background" Value="Transparent"/>
153153
<Setter Property="BorderBrush" Value="Transparent"/>
@@ -342,6 +342,7 @@
342342
<Setter Property="Foreground" Value="{DynamicResource MaterialDesignBody}"/>
343343
<Setter Property="BorderBrush" Value="{DynamicResource MaterialDesignTextBoxBorder}"/>
344344
<Setter Property="BorderThickness" Value="0"/>
345+
<Setter Property="FontSize" Value="13"/>
345346
<Setter Property="GridLinesVisibility" Value="Horizontal" />
346347
<Setter Property="RowDetailsVisibilityMode" Value="VisibleWhenSelected"/>
347348
<Setter Property="HeadersVisibility" Value="Column" />

0 commit comments

Comments
 (0)