Table of Contents

Constructor FontKey

Namespace
DocWright.Fonts
Assembly
DocWright.Fonts.dll

FontKey(string, int, int, FontStyle, Twips, Panose?)

Initializes a font key.

public FontKey(string familyName, int weight = 400, int stretch = 5, FontStyle style = FontStyle.Normal, Twips kerningThreshold = default, Panose? panose = null)

Parameters

familyName string

The requested family name.

weight int

The requested CSS-like weight class (1-1000; 400 normal, 700 bold).

stretch int

The requested width class (1-9; 5 normal).

style FontStyle

The requested slant style.

kerningThreshold Twips

The minimum em size (twips) at which kerning applies; zero disables kerning.

panose Panose?

An optional requested PANOSE hint used by fallback resolution.

Exceptions

ArgumentNullException

familyName is null.

ArgumentException

familyName is empty or whitespace.

ArgumentOutOfRangeException

weight or stretch is outside its supported range.