Font
Source: aspose.
Encapsulates the font object used in a spreadsheet.
Methods
Methods
equals(font) → boolean
Checks if two fonts are equals.
Parameter
Name | Type | Optional | Description |
---|---|---|---|
font |
|
Compared font object. |
- Returns
-
boolean
True if equal to the compared font object.
getArgbColor()
Gets and sets the color with a 32-bit ARGB value.
getCapsType()
Gets and sets the text caps type. The value of the property is TextCapsType integer constant.
getCharset()
Represent the character set.
getColor()
Gets or sets the com.aspose.cells.Color of the font.
getDoubleSize()
Gets and sets the double size of the font.
getName()
Gets or sets the name of the Font.
Example
var font = style.getFont();
font.setName("Times New Roman");
cell.setStyle(style);
getSchemeType()
Gets and sets the scheme type of the font. The value of the property is FontSchemeType integer constant.
getScriptOffset()
Gets and sets the script offset,in unit of percentage
getSize()
Gets or sets the size of the font.
getStrikeType()
Gets the strike type of the text. The value of the property is TextStrikeType integer constant.
getThemeColor()
Gets and sets the theme color. If the font color is not a theme color, NULL will be returned.
getUnderline()
Gets or sets the font underline type. The value of the property is FontUnderlineType integer constant.
isBold()
Gets or sets a value indicating whether the font is bold.
isItalic()
Gets or sets a value indicating whether the font is italic.
isNormalizeHeights()
Indicates whether the normalization of height that is to be applied to the text run.
isStrikeout()
Gets or sets a value indicating whether the font is single strikeout.
isSubscript()
Gets or sets a value indicating whether the font is subscript.
isSuperscript()
Gets or sets a value indicating whether the font is super script.
setArgbColor()
Gets and sets the color with a 32-bit ARGB value.
setBold()
Gets or sets a value indicating whether the font is bold.
setCapsType()
Gets and sets the text caps type. The value of the property is TextCapsType integer constant.
setCharset()
Represent the character set.
setColor()
Gets or sets the com.aspose.cells.Color of the font.
setDoubleSize()
Gets and sets the double size of the font.
setItalic()
Gets or sets a value indicating whether the font is italic.
setName()
Gets or sets the name of the Font.
Example
var font = style.getFont();
font.setName("Times New Roman");
cell.setStyle(style);
setNormalizeHeights()
Indicates whether the normalization of height that is to be applied to the text run.
setSchemeType()
Gets and sets the scheme type of the font. The value of the property is FontSchemeType integer constant.
setScriptOffset()
Gets and sets the script offset,in unit of percentage
setSize()
Gets or sets the size of the font.
setStrikeType()
Gets the strike type of the text. The value of the property is TextStrikeType integer constant.
setStrikeout()
Gets or sets a value indicating whether the font is single strikeout.
setSubscript()
Gets or sets a value indicating whether the font is subscript.
setSuperscript()
Gets or sets a value indicating whether the font is super script.
setThemeColor()
Gets and sets the theme color. If the font color is not a theme color, NULL will be returned.
setUnderline()
Gets or sets the font underline type. The value of the property is FontUnderlineType integer constant.
toString() → String
Returns a string represents the current Cell object.
- Returns
-
String