title: Change the color of ellipse when mouse over
body: <p>I'm totally new in WPF. It's kind of confusing, why the first code snippet works fine (when mouse over, the color changes) but the second one doesn't work?</p>
  
  <pre><code>&lt;Ellipse Height="50" Width="50" Opacity="0.5" Stroke="Black" &gt;
  &lt;Ellipse.Style&gt;
      &lt;Style TargetType="{x:Type Ellipse}"&gt;
          &lt;Setter Property="Fill" Value="Blue" /&gt;
          &lt;Style.Triggers&gt;
              &lt;Trigger Property="IsMouseOver" Value="True"&gt;
                  &lt;Setter Property="Fill" Value="Green"&gt;
                  &lt;/Setter&gt;
              &lt;/Trigger&gt;
          &lt;/Style.Triggers&gt;
      &lt;/Style&gt;
  &lt;/Ellipse.Style&gt;
  </code></pre>
  
  <p></p>
  
  <p>//</p>
  
  <pre><code>&lt;Ellipse Height="50" Width="50" Fill="Blue" Opacity="0.5" Stroke="Black" &gt;
  &lt;Ellipse.Style&gt;
      &lt;Style TargetType="{x:Type Ellipse}"&gt;
          &lt;Style.Triggers&gt;
              &lt;Trigger Property="IsMouseOver" Value="True"&gt;
                  &lt;Setter Property="Fill" Value="Green"&gt;
                  &lt;/Setter&gt;
              &lt;/Trigger&gt;
          &lt;/Style.Triggers&gt;
      &lt;/Style&gt;
  &lt;/Ellipse.Style&gt;
  </code></pre>
  
  <p></p>
  
  <p>thanks.</p>