title: easiest way to style combobox's foreground color
body: <p>I styled <code>TextBlock</code>'s foreground to white in my global dictionary, and this style applied to <code>Combobox</code> as well which made the combobox options unreadable. I can't find an easy way to style <code>Combobox</code>'s background for windows 8 or up. So I decided that I can live with a default <code>Combobox</code> style for now but still I can't seem to find an easy solution. I tried to set the <code>foreground</code> of <code>Combobox</code>, style <code>TextBlock</code> under <code>Combobox.Resources</code> and Style <code>ComboBoxItem</code> with no luck. </p>
  
  <p>It will be ideal if I can set the combobox's background to black without duplicating the whole <code>Combobox</code>'s control template. If not then it will be the best if I can style <code>Combobox</code>'s foreground in my dictionary, but I am open to solutions. </p>
  
  <p>Edit: minimum example included</p>
  
  <p>Dictionary1.xaml:</p>
  
  <pre><code>&lt;ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                      xmlns:local="clr-namespace:WpfApplication1"&gt;
      &lt;Style TargetType="TextBlock"&gt;
          &lt;Setter Property="Foreground" Value="WhiteSmoke"/&gt;
      &lt;/Style&gt;
  &lt;/ResourceDictionary&gt;
  </code></pre>
  
  <p>App.xaml:</p>
  
  <pre><code>&lt;Application x:Class="WpfApplication1.App"
               xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
               xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
               xmlns:local="clr-namespace:WpfApplication1"
               StartupUri="MainWindow.xaml"&gt;
      &lt;Application.Resources&gt;
          &lt;ResourceDictionary&gt;
              &lt;ResourceDictionary.MergedDictionaries&gt;
                  &lt;ResourceDictionary Source="Dictionary1.xaml"/&gt;
              &lt;/ResourceDictionary.MergedDictionaries&gt;
          &lt;/ResourceDictionary&gt;
      &lt;/Application.Resources&gt;
  &lt;/Application&gt;
  </code></pre>
  
  <p>mainwindow.xaml</p>
  
  <pre><code>&lt;Window x:Class="WpfApplication1.MainWindow"
          xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
          xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
          xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
          xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
          xmlns:local="clr-namespace:WpfApplication1"
          mc:Ignorable="d"
          Title="MainWindow" Height="350" Width="525"
          Closing="Window_Closing"&gt;
      &lt;Grid&gt;
          &lt;ComboBox Text="test" Height="50" Width="100" Foreground="Black"&gt;
              &lt;ComboBox.Resources&gt;
                  &lt;Style TargetType="ComboBoxItem"&gt;
                      &lt;Style.Setters&gt;
                          &lt;Setter Property="Foreground" Value="Black"/&gt;
                      &lt;/Style.Setters&gt;
                  &lt;/Style&gt;
  
                  &lt;Style TargetType="TextBlock"&gt;
                      &lt;Style.Setters&gt;
                          &lt;Setter Property="Foreground" Value="Black"/&gt;
                      &lt;/Style.Setters&gt;
                  &lt;/Style&gt;
              &lt;/ComboBox.Resources&gt;
              &lt;ComboBoxItem&gt;test1&lt;/ComboBoxItem&gt;
              &lt;ComboBoxItem&gt;test2&lt;/ComboBoxItem&gt;
          &lt;/ComboBox&gt;
      &lt;/Grid&gt;
  &lt;/Window&gt;
  </code></pre>
  
  <p>note that none of the foreground = black works. I am using windows 10. </p>