Embedded Fonts Shared Across Dynamically Loaded Modules

Topics: Prism v2 - Silverlight 3
Oct 3, 2009 at 10:48 PM

Hey All,

I am having a tough time dealing with a custom font and dynamic module loading.

I have a set of styles defined in the App.xaml file in the shell project. One of these styles has an embedded font (rockwell). I reference this style as a static resource in other modules.

Problem #1: The style does not appear to be applied to anything in any dynamically loaded module UNLESS there is some control in the Shell.xaml that uses that style. The workaround that I have used is to make a 0x0 textblock in the shell that uses this style.

Problem #2: The style cannot be applied to multiple dynamically loaded modules. If I use the above workaround the first view that I display from the first module actually displays the embedded font. However when I load the second module and add a view to the region I get the following error "Attribute {StaticResource RockwellFontTextBlock} value is out of range."

Any help would be greatly appreciated. Thanks!

Oct 14, 2009 at 4:49 AM

Any ideas here?