UsedFontInfo

UsedFontInfo structure

Represents metainfo and binary data of the one font, used in the content of the document, loaded into the Viewer instance

public struct UsedFontInfo

Properties

Name Description
Charset { get; } Character set of this font. Returns valid number only for the WordProcessing and Spreadsheet format families, for all other formats returns 0 (zero).
Content { get; } Content of this font as a byte array. If there is only metainfo about this font, but its binary content is unavailable, this property returns null.
Format { get; } Format of this font. Documents may use fonts in the next formats: TrueType, TrueType Collection, OpenType, Embedded OpenType. If there is only metainfo about this font, but its binary content is unavailable, this property returns an Unknown value.
IsEmbedded { get; } Indicates whether this font is embedded inside the document, loaded into the Viewer instance (true), or it is a system font (false). Spreadsheet documents cannot hold embedded fonts, so for them this property always returns false.
Name { get; } Name of the font, without style, never is null or empty string
Style { get; } Style of the font — may be Regular, Bold, Italic, or Bold Italic. For the PDF documents may be only Regular style.

Methods

Name Description
SerializeToCss(TextWriter) Serializes this font info as a @font-face at-rule and writes it to the specified text writer
override ToString() Returns a debug info about this font data as the next template: “name style, embedded/system, format”

Remarks

Immutable struct. Its instances are produced and returned by the GroupDocs.Viewer public API and normally should not be created by the user. For details, see the documentation.

See Also