Reputation: 1214
i am trying to change the background color of combobox dropdown or the popup containing options that opens when combobox header is clicked.
<Style TargetType="{x:Type ComboBox}" BasedOn="{StaticResource MaterialDesignComboBox}">
<Setter Property="Background" Value="White"></Setter>
</Style>
now this peace of code changes the background color of whole combobox . is there a way to keep the color of header transparent and change the color of dropdown ?
edit: i am using material design in xaml toolkit for styling
Upvotes: 1
Views: 3339
Reputation: 2045
One workaround that I've found is to override MaterialDesignPaper
color in ComboBox.Resources
:
<ComboBox.Resources>
<SolidColorBrush x:Key="MaterialDesignPaper" Color="Red"/>
</ComboBox.Resources>
Upvotes: 2