Skip to content

Commit eda71e1

Browse files
authored
Merge pull request #474 from jherbert/expander-patch
Foreground color updates header and icon
2 parents 87fd140 + ecda348 commit eda71e1

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

MaterialDesignThemes.Wpf/Themes/MaterialDesignTheme.Expander.xaml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
</VisualStateGroup>
7171
</VisualStateManager.VisualStateGroups>
7272
<wpf:PackIcon Kind="ChevronDown" Opacity=".38" x:Name="ExpandPath" RenderTransformOrigin="0.5,0.5"
73-
Height="24" Width="24">
73+
Height="24" Width="24" Foreground="{TemplateBinding Foreground}">
7474
<wpf:PackIcon.RenderTransform>
7575
<TransformGroup>
7676
<ScaleTransform/>
@@ -101,6 +101,7 @@
101101
<ToggleButton Grid.Row="0"
102102
Margin="0 16 0 16"
103103
HorizontalAlignment="Center"
104+
Foreground="{TemplateBinding Foreground}"
104105
IsChecked="{Binding Path=IsChecked, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
105106
Style="{StaticResource MaterialDesignExpanderToggleButton}"
106107
RenderTransformOrigin="0.5,0.5">
@@ -134,6 +135,7 @@
134135
<ToggleButton Grid.Row="0"
135136
Margin="0 16 0 16"
136137
HorizontalAlignment="Center"
138+
Foreground="{TemplateBinding Foreground}"
137139
IsChecked="{Binding Path=IsChecked, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
138140
Style="{StaticResource MaterialDesignExpanderToggleButton}"
139141
RenderTransformOrigin="0.5,0.5">
@@ -170,6 +172,7 @@
170172
<ToggleButton Grid.Column="1"
171173
Margin="16 0 16 0"
172174
VerticalAlignment="Center"
175+
Foreground="{TemplateBinding Foreground}"
173176
IsChecked="{Binding Path=IsChecked, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
174177
Style="{StaticResource MaterialDesignExpanderToggleButton}"/>
175178
<Border BorderBrush="{DynamicResource MaterialDesignDivider}" BorderThickness="0 0 0 1" Grid.ColumnSpan="2" SnapsToDevicePixels="True" />
@@ -197,6 +200,7 @@
197200
<ToggleButton IsChecked="{Binding Path=IsChecked, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
198201
Margin="16 0 16 0"
199202
VerticalAlignment="Center"
203+
Foreground="{TemplateBinding Foreground}"
200204
Style="{StaticResource MaterialDesignExpanderToggleButton}"
201205
RenderTransformOrigin="0.5,0.5"
202206
Grid.Column="1">
@@ -278,6 +282,7 @@
278282
Style="{StaticResource MaterialDesignExpanderDownHeaderStyle}"
279283
TextElement.FontSize="15"
280284
Opacity=".87"
285+
Foreground="{TemplateBinding Foreground}"
281286
Content="{TemplateBinding Header}"
282287
ContentTemplate="{TemplateBinding HeaderTemplate}"
283288
ContentTemplateSelector="{TemplateBinding HeaderTemplateSelector}"
@@ -347,4 +352,4 @@
347352
</Setter>
348353
</Style>
349354

350-
</ResourceDictionary>
355+
</ResourceDictionary>

0 commit comments

Comments
 (0)