Cell

Overview

Cell is a class in Aspose.PDF FOSS for .NET.

Represents a cell in a table row.

This class provides 3 methods for working with Cell objects in .NET programs. Available methods include: Cell, Clone. All public members are accessible to any .NET application after installing the Aspose.PDF FOSS for .NET package. Properties: Alignment, BackgroundColor, BackgroundImage, BackgroundImageFile, Border, ColSpan, and 10 more.

Properties

NameTypeAccessDescription
ParagraphsParagraphsRead/WriteThe paragraphs (content) in this cell.
BorderBorderInfo?Read/WriteCell border.
BackgroundColorColor?Read/WriteCell background color.
MarginMarginInfo?Read/WriteCell padding (margin around content inside the cell).
ColSpanintRead/WriteNumber of columns this cell spans.
RowSpanintRead/WriteNumber of rows this cell spans.
IsNoBorderboolRead/WriteIf true, no border is drawn for this cell.
DefaultCellTextStateTextState?Read/WriteDefault text state for this cell.
IsWordWrappedboolRead/WriteWhether text in this cell should be word-wrapped.
VerticalAlignmentVerticalAlignmentRead/WriteVertical alignment of the cell content.
AlignmentHorizontalAlignmentRead/WriteHorizontal alignment of the cell content.
WidthdoubleReadWidth of the cell as laid out (set by the renderer; default 0).
BackgroundImageImage?Read/WriteBackground image painted behind cell content.
BackgroundImageFilestring?Read/WritePath to a file used as the background image.
IsOverrideByFragmentboolRead/WriteWhether the cell’s formatting can be overridden by a contained fragment’s text state.
TextstringRead/WriteConvenience property: gets or sets the text of the first TextFragment in Paragraphs.

Methods

SignatureDescription
Cell()Construct an empty cell with default formatting.
Cell(rect: Rectangle)Construct a cell sized to rect.
Clone()Create a shallow copy of this cell.

See Also