I want to be able to define a font family for my WPF application. Preferably using a resource dictionary as a theme referenced from App.xaml. I\'ve tried creati
Assuming your Window subclasses don't override DefaultStyleKey, you can simply add it to your Window style, since TextElement.FontFamilyProperty is an inherited property:
You also need to add the following to your App constructor after the InitializeComponent call:
FrameworkElement.StyleProperty.OverrideMetadata(typeof(Window), new FrameworkPropertyMetadata
{
DefaultValue = FindResource(typeof(Window))
});
How it works: After the App object finishes initializing, the Window style specified therein is made the default style for all windows.