public static Font Create(StyleInfo style) { Font font = new Font(); if ((!style.IsFontFamilySet() && !style.IsFontSizeSet()) && ((!style.IsFontStretchSet() && !style.IsFontStyleSet()) && !style.IsFontWeightSet())) { return(null); } if ((style != null) && (style.FontFamily != null)) { string familyName = FontHelper.GetEquivalentEnglishFontName(style.FontFamily.Source); font.FontFamily = new FontFamily(familyName); } font.FontSize = style.FontSize; font.FontStretch = style.FontStretch; font.FontStyle = style.FontStyle; font.FontWeight = style.FontWeight; font.gdiCharSet = 0; return(font); }