I have a WPF Window style defined thusly:
<Style
x:Key="Applet"
TargetType="{x:Type Window}">
<Setter
Property="WindowStyle"
Value="None" />
<Setter
Property="WindowState"
Value="Maximized" />
<Setter
Property="Title"
Value="Hindenburg" />
<Setter
Property="FontFamily"
Value="Arial" />
<Setter
Property="Height"
Value="650" />
<Setter
Property="Width"
Value="850" />
</Style>
My application then defines several screens using this style (FlowWindow is just derived from Window with a few extra bits):
<uControl:FlowWindow
x:Class="KaleidoscopeApplication.DisposablesScan"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:u="clr-namespace:KaleidoscopeApplication"
xmlns:uControl="clr-namespace:KaleidoscopeApplication.Controls"
Style="{StaticResource Applet}"
Loaded="disposablesScanWindow_Loaded"
Unloaded="disposablesScanWindow_Unloaded">
<Canvas>
<!-- Top Bar Background -->
<Image
Source="Resources/Elements/Backgrounds/16.png" />
text etc etc...
</Canvas>
My question - How do I define a textblock that will be displayed on every Window that uses this style? For example, if I want a logo displayed in the upper right corner of every screen...
Since the style defines things like size and font and not the content of the canvas, I'm not sure how to go about this.
Thanks in advance!
EDIT: FlowWindow is not a UserControl. It is just part of my KaleidoscopeApplication.Controls namespace. It's defined as:
public class FlowWindow : Window
{
public FlowWindow()
: base()
{ }
/// <summary>
/// Transition smoothly to another FlowWindow.
/// </summary>
/// <param name="toWindow">The window to transtion to.</param>
public override void Transition(FlowWindow toWindow)
{
...
}
}