PdfTableCell Class

A cell of a PdfTableRow: a text, broken into lines that fit the width of its column. The properties that are null take the value of the row, then of the table.

public sealed class PdfTableCell

Constructors

NameDescription
PdfTableCell(string)Initializes a new instance of the PdfTableCell class.

PdfTableCell(string)

PdfTableCell.cs

Initializes a new instance of the PdfTableCell class.

public PdfTableCell(string text)

Parameters

text string
The text of the cell. A line feed starts a new paragraph.

Properties

NameDescription
AlignmentGets or sets the horizontal alignment of the text, or null for the alignment of the column.
BackgroundGets or sets the color that fills the cell, or null for the background of the row.
ColumnSpanGets or sets the number of columns the cell spans, 1 or more. The default is 1.
FontGets or sets the font of the text, or null for the font of the row.
FontSizeGets or sets the font size of the text, or null for the font size of the row.
TextGets or sets the text of the cell. A line feed starts a new paragraph.
TextColorGets or sets the color of the text, or null for the color of the row.

Gets or sets the horizontal alignment of the text, or null for the alignment of the column.

public PdfTextAlignment? Alignment { get; set; }

Property value

PdfTextAlignment?

Background

PdfTableCell.cs

Gets or sets the color that fills the cell, or null for the background of the row.

public PdfColor? Background { get; set; }

Property value

PdfColor?

ColumnSpan

PdfTableCell.cs

Gets or sets the number of columns the cell spans, 1 or more. The default is 1.

public int ColumnSpan { get; set; }

Property value

int

Gets or sets the font of the text, or null for the font of the row.

public PdfFont? Font { get; set; }

Property value

PdfFont?

Gets or sets the font size of the text, or null for the font size of the row.

public double? FontSize { get; set; }

Property value

double?

Gets or sets the text of the cell. A line feed starts a new paragraph.

public string Text { get; set; }

Property value

string

Gets or sets the color of the text, or null for the color of the row.

public PdfColor? TextColor { get; set; }

Property value

PdfColor?