tags:

views:

7

answers:

0

Hi,

I have a custom composite font as a resource in a library dll that I'd like to load but I'm unable to get the exact syntax. I tried:

FontFamily font = new FontFamily(
  new Uri("pack://application:,,,/MyLibraryDll"), 
  "./fonts/#My Font from composite font");

Which didn't work so I tried enumerating the fonts with:

ICollection<FontFamily> fonts = Fonts.GetFontFamilies(
   new Uri("pack://application:,,,/MyLibraryDll"), 
   "./fonts/#My Font from composite font");

And

ICollection<FontFamily> fonts = Fonts.GetFontFamilies(
  new Uri("pack://application:,,,/MyLibraryDll"),
  "./fonts/mycompositefont.compositefont#My Font from composite font");

And both return a count of 0. There is no documentation on these that I can find -- has anyone had any luck with this?