title: What is the equivalent of HTML class id's in WPF?
body: <p>I have some StackPanels I wish to have the same Width. However this should not affect all StackPanels and I do not want to subclass just for this. I know that the following is possible:</p>
  
  <pre><code>&lt;Style BasedOn="{StaticResource {x:Type TextBlock}}"
      TargetType="TextBlock"
      x:Key="TitleText"&gt;
          &lt;Setter Property="FontSize" Value="26"/&gt;
  &lt;/Style&gt;
  
  ...
  
  &lt;TextBlock Style="{StaticResource TitleText}"&gt; 
      Some Text 
  &lt;/TextBlock&gt;
  </code></pre>
  
  <p>But is there a way to keep the TextBlock ignorant of its Style (like it is when the
  HTML is separate from the CSS rule that applies to the element)?</p>
  
  <p>I would just like to give all the relevant StackPanels the same class id, and then apply
  the style to the class id.</p>