Exemple #1
0
 internal static FontInfo GetFontInfo(
     this OutlineTextBlock control)
 {
     return(new FontInfo(
                control.FontFamily,
                control.FontSize,
                control.FontStyle,
                control.FontWeight,
                control.FontStretch));
 }
Exemple #2
0
 internal static void SetFontInfo(
     this OutlineTextBlock control,
     FontInfo fontInfo)
 {
     if (control.GetFontInfo().ToString() != fontInfo.ToString())
     {
         control.FontFamily  = fontInfo.Family;
         control.FontSize    = fontInfo.Size;
         control.FontStyle   = fontInfo.Style;
         control.FontWeight  = fontInfo.Weight;
         control.FontStretch = fontInfo.Stretch;
     }
 }