RichText Class

A text whose parts have their own style: fonts, size, paint, decorations. Built by RichTextBuilder.

public sealed class RichText

Remarks

The spans follow each other and cover the text. A span is not a paragraph and not a line: letters of two spans can kern, join and form a ligature when their spans only differ by what is painted (brush, decorations).

A rich text is immutable.

Properties

NameDescription
SpansGets the spans, in the order of the text.
TextGets the whole text.

Gets the spans, in the order of the text.

public IReadOnlyList<TextSpan> Spans { get; }

Gets the whole text.

public string Text { get; }

Property value

string