Programmer's Reference >
ExcelApplication API >
Font
The Font Object
The Font object represents a font style that you can use when creating a reusable Style object, or when setting the style of a cell or set of cells. To set or return a Font object, use Style.Font .
Examples:
[csharp]
ExcelApplication xla = new ExcelApplication();
Workbook wb = xla.Create();
SoftArtisans.OfficeWriter.ExcelWriter.Style styl = wb.CreateStyle();
SoftArtisans.OfficeWriter.ExcelWriter.Font fnt = styl.Font;
[vbnet]
Dim xla As New ExcelApplication()
Dim wb As Workbook = xla.Create()
Dim styl As SoftArtisans.OfficeWriter.ExcelWriter.Style = wb.CreateStyle()
Dim fnt As SoftArtisans.OfficeWriter.ExcelWriter.Font = styl.Font
Font Enumerations
Name | Description |
Font.UnderlineStyle | An UnderlineStyle value specifies an underline style for a font.
|
Font.VerticalPosition | A Vertical value specifies the vertical position of a font in relation to other text.
|
Font Properties
Property |
Type |
Access |
Description |
Bold |
boolean
|
read write |
Sets or returns whether text will be displayed in bold face
|
Color |
Color
|
read write |
Sets or returns the color of the font
|
Italic |
boolean
|
read write |
Sets or returns whether text will be italicized
|
Name |
String
|
read write |
Sets or returns the name of the font (e.g., "Arial")
|
ScriptStyle |
Font.VerticalPosition
|
read write |
Sets or returns the vertical position of the font in relation to other text
|
Size |
double
|
read write |
Sets or returns the font size, in points
|
Strikethrough |
boolean
|
read write |
Sets or returns whether strikethrough formatting will be applied to the font
|
Underline |
Font.UnderlineStyle
|
read write |
Sets or returns the underline style for this font
|
This object does not have any methods defined.
Copyright 2005 © SoftArtisans, Inc. All Rights Reserved.
|