SpreadsheetFontInfo

Inheritance: java.lang.Object

All Implemented Interfaces: com.groupdocs.viewer.fonts.IFontInfo

public final class SpreadsheetFontInfo implements IFontInfo

Encapsulates metainfo and binary data of one font from the Spreadsheet document, loaded into the Viewer instance. Spreadsheet documents cannot have embedded fonts, so this particular font, if returned by the Viewer.getAllFonts() method, is installed in the operating system where GroupDocs.Viewer is running.

Methods

Method Description
getFamilyName() Family name of the font, without style, never null or empty.
getStyle() Style of this font \u2014 may be Regular, Bold, Italic, or BoldItalic.
isStrikeout() Indicates whether the font is a single strikeout.
isUnderline() Indicates whether the font has an underline.
getColor() Color of this font.
getCharset() Character set of this font.
getContent() Content of this font as a byte array.
getFormat() Format of this font.
serializeToCss(Writer output) Serializes this font info as a @font-face at-rule and writes it to the specified writer.

getFamilyName()

public String getFamilyName()

Family name of the font, without style, never null or empty.

Returns: java.lang.String

getStyle()

public FontStyles getStyle()

Style of this font \u2014 may be Regular, Bold, Italic, or BoldItalic.

Returns: com.groupdocs.viewer.fonts.FontStyles

isStrikeout()

public boolean isStrikeout()

Indicates whether the font is a single strikeout.

Returns: boolean

isUnderline()

public boolean isUnderline()

Indicates whether the font has an underline.

Returns: boolean

getColor()

public Argb32Color getColor()

Color of this font.

Returns: Argb32Color

getCharset()

public int getCharset()

Character set of this font.

Returns: int

getContent()

public byte[] getContent()

Content of this font as a byte array. May be null if only meta info is available.

Returns: byte[]

getFormat()

public int getFormat()

Format of this font.

Returns: int

serializeToCss(Writer output)

public void serializeToCss(Writer output)

Serializes this font info as a @font-face at-rule and writes it to the specified writer.

Parameters:

Parameter Type Description
output java.io.Writer Device to write serialized text data into.