Namespace: PdfSharp.Drawing
Represents a combination of XFontFamily, XFontWeight, XFontStyleEx, and XFontStretch.
public class XTypeface
Inheritance Object → XTypeface
Gets the font family from which the typeface was constructed.
public XFontFamily Family { get; }
Gets the style of the Typeface.
public XFontStyle Style { get; }
Gets the relative weight of the typeface.
public XFontWeight Weight { get; }
Gets the stretch value for the Typeface. The stretch value determines whether a typeface is expanded or condensed when it is displayed.
public XFontStretch Stretch { get; }
Initializes a new instance of the XTypeface class.
public XTypeface(string typefaceName)
typefaceName
String
Name of the typeface.
Initializes a new instance of the XTypeface class.
public XTypeface(XFontFamily family, XFontStyle style, XFontWeight weight, XFontStretch stretch)
family
XFontFamily
The font family of the typeface.
style
XFontStyle
The style of the typeface.
weight
XFontWeight
The relative weight of the typeface.
stretch
XFontStretch
The degree to which the typeface is stretched.
Tries the get GlyphTypeface that corresponds to the Typeface.
public bool TryGetGlyphTypeface(XGlyphTypeface& glyphTypeface)
glyphTypeface
XGlyphTypeface&
The glyph typeface that corresponds to this typeface,
or null if the typeface was constructed from a composite font.