Style

Overview

Style is a class in Aspose.Cells FOSS for .NET.

Represents a mutable cell style facade that can be applied to one or more cells. var workbook = new Workbook(); var cell = workbook.Worksheets[0].Cells[“C3”]; var style = cell.GetStyle(); style.Font.IsBold = true; style.NumberFormat = “$#,##0.00”; style.HorizontalAlignment = HorizontalAlignmentType.Center; cell.SetStyle(style);

This class provides 4 methods for working with Style objects in Go programs. Available methods include: Copy, Equals, GetHashCode, Style. All exported members are accessible to any Go application after adding the package via go get github.com/aspose-pdf-foss/aspose-pdf-foss-for-go. Properties: BackgroundColor, Borders, Custom, Font, ForegroundColor, HorizontalAlignment, and 13 more.

Properties

NameTypeAccessDescription
FontFontReadGets the font.
BordersBordersReadGets the borders.
PatternFillPatternRead/WriteGets or sets the pattern.
ForegroundColorColorRead/WriteGets or sets the foreground color.
BackgroundColorColorRead/WriteGets or sets the background color.
NumberintRead/WriteGets or sets the number.
CustomstringRead/WriteGets or sets the custom.
NumberFormatstringRead/WriteGets or sets the number format.
HorizontalAlignmentHorizontalAlignmentTypeRead/WriteGets or sets the horizontal alignment.
VerticalAlignmentVerticalAlignmentTypeRead/WriteGets or sets the vertical alignment.
WrapTextboolRead/WriteGets or sets the wrap text.
IndentLevelintRead/WriteGets or sets the indent level.
TextRotationintRead/WriteGets or sets the text rotation.
ShrinkToFitboolRead/WriteGets or sets the shrink to fit.
ReadingOrderintRead/WriteGets or sets the reading order.
RelativeIndentintRead/WriteGets or sets the relative indent.
IsLockedboolRead/WriteGets or sets the is locked.
IsHiddenboolRead/WriteGets or sets the is hidden.
QuotePrefixboolRead/WriteGets or sets the quote prefix.

Methods

SignatureDescription
Style()Creates a new style instance
Copy(source: Style)Copies data from another style object.
Equals(obj: object)Determines whether two style instances are equal.
GetHashCode()Serves as a hash function for a style object.

See Also