title: Automatically apply default styles defined in separate assembly
body: <p>I have the following requirements:</p>
  
  <ol>
  <li><p>My WPF application consists of <strong>several modules (assemblies)</strong>, some of them UI-related.</p></li>
  <li><p>I want to create a single assembly containing a <strong>common set of styles</strong> for certain controls (e.g. a custom default button style) that should be applied automatically in all other UI-related assemblies, just by including that one assembly, and without me having to specify explicit resource keys.</p></li>
  <li><p>I do not provide styles for every kind of control, so those without a custom style should <strong>keep the default Aero theme</strong> (including content templates etc.).</p></li>
  <li><p>I do <strong>not</strong> want to write my <strong>own, extended Button class</strong>, or something like that.</p></li>
  <li><p>I want this to work in Visual Studio <strong>at design-time</strong> as well, both in the final app and within the other UI-related modules.</p></li>
  </ol>
  
  <p>As the styles are defined inside an assembly, I obviously <a href="https://stackoverflow.com/questions/10797558/wpf-using-styles-resources-from-another-assembly">cannot have an App.xaml there</a>. I therefore assume that I have to include them from Generic.xaml. As Generic.xaml only serves as a fallback when there is no style defined in the standard (Aero) theme, WPF ignores my styles in Generic.xaml. </p>
  
  <p>The next step would probably be to create my very own theme (that somehow merges the default Aero styles). But how do I tell VS to use that theme in both the app and the modules, instead of e.g. Aero? I guess I have to do this declaratively as I need design-time support for my custom styles.</p>