Skip to content
Auto
Products

MarkdownTable

Namespace: TagBites.Text.Markdown
Assembly: TagBites.Text.Markdown.dll
Product: TagBites.Text.Markdown v. 2.2.0

A table with a header row, written with the | marker.

public class MarkdownTable : TagBites.Text.Markdown.MarkdownElement

Inheritance: objectMarkdownElement → MarkdownTable

The table comes from the GitHub Flavored Markdown tables extension, where a cell holds inline content only. A cell escapes | and writes a line break as a space. The table pads every column to an equal width.

public MarkdownTable()

Gets the alignment of each column. A column without an entry uses MarkdownTableColumnAlignment.None.

public IList<MarkdownTableColumnAlignment> Alignments { get; }

IList<MarkdownTableColumnAlignment>

Gets the header of each column, which also sets the number of columns.

public IList<MarkdownText> Headers { get; }

IList<MarkdownText>

Gets the rows of the table, each holding the cells of one row.

public IList<IList<MarkdownText>> Rows { get; }

IList<IList<MarkdownText>>

Writes the element into renderer.

protected internal virtual void Resolve(MarkdownRenderer renderer)

SetAlignments(MarkdownTableColumnAlignment[])

Section titled “SetAlignments(MarkdownTableColumnAlignment[])”

Replaces the alignment of all columns with alignments.

public MarkdownTable SetAlignments(MarkdownTableColumnAlignment[] alignments)

MarkdownTable

Replaces all column headers with columns.

public MarkdownTable SetHeaders(MarkdownText[] columns)

MarkdownTable

To append a single header, use WithHeader(MarkdownText).

Replaces all column headers with columns.

public MarkdownTable SetHeaders(string[] columns)

MarkdownTable

To append a single header, use WithHeader(MarkdownText).

Appends a single column header.

public MarkdownTable WithHeader(MarkdownText text)

MarkdownTable

WithHeader(MarkdownText, MarkdownTableColumnAlignment)

Section titled “WithHeader(MarkdownText, MarkdownTableColumnAlignment)”

Appends a single column header with the given alignment.

public MarkdownTable WithHeader(MarkdownText text, MarkdownTableColumnAlignment alignment)

MarkdownTable

Appends a row built from the given cells.

public MarkdownTable WithRow(MarkdownText[] textCells)

MarkdownTable

Appends a row built from the given cells.

public MarkdownTable WithRow(string[] textCells)

MarkdownTable

Appends a row built from the given cells.

public MarkdownTable WithRow(IList<MarkdownText> textCells)

MarkdownTable

Appends a row built from the given cells.

public MarkdownTable WithRow(IList<string> textCells)

MarkdownTable