Font

Font class

Encapsulates the font object used in a spreadsheet.

Properties

NameTypeDescription
CharsetintRepresent the character set.
IsItalicbooleanGets or sets a value indicating whether the font is italic.
IsBoldbooleanGets or sets a value indicating whether the font is bold.
CapsTypeintGets and sets the text caps type. The value of the property is TextCapsType integer constant.
StrikeTypeintGets the strike type of the text. The value of the property is TextStrikeType integer constant.
IsStrikeoutbooleanGets or sets a value indicating whether the font is single strikeout.
ScriptOffsetfloatGets and sets the script offset,in unit of percentage
IsSuperscriptbooleanGets or sets a value indicating whether the font is super script.
IsSubscriptbooleanGets or sets a value indicating whether the font is subscript.
UnderlineintGets or sets the font underline type. The value of the property is FontUnderlineType integer constant.
NameStringGets or sets the name of the Font .
DoubleSizefloatGets and sets the double size of the font.
SizeintGets or sets the size of the font.
ThemeColorThemeColorGets and sets the theme color. If the font color is not a theme color, NULL will be returned.
ColorColorGets or sets the com.aspose.cells.Color of the font.
ArgbColorintGets and sets the color with a 32-bit ARGB value.
IsNormalizeHeightsbooleanIndicates whether the normalization of height that is to be applied to the text run.
SchemeTypeintGets and sets the scheme type of the font. The value of the property is FontSchemeType integer constant.

Methods

NameDescription
setName
equalsChecks if two fonts are equals.
toStringReturns a string represents the current Cell object.

Font.Charset property

Represent the character set.

Type: int

Font.IsItalic property

Gets or sets a value indicating whether the font is italic.

Type: boolean

Font.IsBold property

Gets or sets a value indicating whether the font is bold.

Type: boolean

Font.CapsType property

Gets and sets the text caps type. The value of the property is TextCapsType integer constant.

Type: int

Font.StrikeType property

Gets the strike type of the text. The value of the property is TextStrikeType integer constant.

Type: int

Font.IsStrikeout property

Gets or sets a value indicating whether the font is single strikeout.

Type: boolean

Font.ScriptOffset property

Gets and sets the script offset,in unit of percentage

Type: float

Font.IsSuperscript property

Gets or sets a value indicating whether the font is super script.

Type: boolean

Font.IsSubscript property

Gets or sets a value indicating whether the font is subscript.

Type: boolean

Font.Underline property

Gets or sets the font underline type. The value of the property is FontUnderlineType integer constant.

Type: int

Font.Name property

Gets or sets the name of the Font .

Type: String

Font.DoubleSize property

Gets and sets the double size of the font.

Type: float

Font.Size property

Gets or sets the size of the font.

Type: int

Font.ThemeColor property

Gets and sets the theme color. If the font color is not a theme color, NULL will be returned.

Type: ThemeColor

Font.Color property

Gets or sets the com.aspose.cells.Color of the font.

Type: Color

Font.ArgbColor property

Gets and sets the color with a 32-bit ARGB value.

Type: int

Font.IsNormalizeHeights property

Indicates whether the normalization of height that is to be applied to the text run.

Type: boolean

Font.SchemeType property

Gets and sets the scheme type of the font. The value of the property is FontSchemeType integer constant.

Type: int

setName(name, type)

equals(font)

Checks if two fonts are equals.

ParameterTypeDescription
fontFontCompared font object.

Returns: True if equal to the compared font object.

toString()

Returns a string represents the current Cell object.