Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.
The look and feel of the text can be controlled by changing its font settings. These font settings may include the name, style, size, color and other effects of the fonts as shown below in the figure:
Font settings in Microsoft Excel

Just like Microsoft Excel, Aspose.Cells also supports configuring the font settings of the cells.
Aspose.Cells provides a class, Workbook that represents a Microsoft Excel file. The Workbook class contains a WorksheetCollection that allows access to each worksheet in an Excel file. A worksheet is represented by the Worksheet class. The Worksheet class provides a Cells collection. Each item in the Cells collection represents an object of the Cell class.
Aspose.Cells provides the Cell class' setStyle method, used to set a cell’s formatting. Also, the object of the Style class provides properties for configuring font settings.
This article shows how to:
Apply a specific font to text in cells using the Font object’s setName property.
Set text to bold by setting the Font object’s setBold property to true.
Set the font size using the Font object’s setSize property.
Underline text with the Font object’s setUnderline property. Aspose.Cells offers various pre-defined font underline types in the FontUnderlineType enumeration.
| Font Underline Types | Description |
|---|---|
| NONE | No underline |
| SINGLE | A single underline |
| DOUBLE | Double underline |
| ACCOUNTING | A single accounting underline |
| DOUBLE_ACCOUNTING | Double accounting underline |
| DASH | Dashed Underline |
| DASH_DOT_DOT_HEAVY | Thick Dash-Dot-Dot Underline |
| DASH_DOT_HEAVY | Thick Dash-Dot Underline |
| DASHED_HEAVY | Thick Dashed Underline |
| DASH_LONG | Long Dashed Underline |
| DASH_LONG_HEAVY | Thick Long Dashed Underline |
| DOT_DASH | Dash-Dot Underline |
| DOT_DOT_DASH | Dash-Dot-Dot Underline |
| DOTTED | Dotted Underline |
| DOTTED_HEAVY | Thick Dotted Underline |
| HEAVY | Thick Underline |
| WAVE | Wave Underline |
| WAVY_DOUBLE | Double Wave Underline |
| WAVY_HEAVY | Heavy Wave Underline |
| WORDS | Underline Non-Space Characters Only |
Set the font color with the Font object’s setColor property. Select any color from the Color enumeration and assign the selected color to the Font object’s setColor property.
Strikeout text with the Font object’s setStrikeout property.
Make text superscript by using the Font object’s setSubscript property.
Apply superscript to text with the Font object’s setSuperscript property.
Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.