Skip to main content

TextCharacters Class

Definition

Assembly:Avalonia.Base
Package:Avalonia

A text run that holds text characters.

public class TextCharacters

Inheritance: object -> TextRun -> TextCharacters

Constructors

NameDescription
TextCharacters (2 overloads)No summary available.

TextCharacters overloads

TextCharacters Constructor

public TextCharacters(ReadOnlyMemory<char> text, Avalonia.Media.TextFormatting.TextRunProperties textRunProperties)
Parameters

text ReadOnlyMemory<char>

textRunProperties Avalonia.Media.TextFormatting.TextRunProperties

TextCharacters Constructor

Constructs a run for text content from a string.

public TextCharacters(string text, Avalonia.Media.TextFormatting.TextRunProperties textRunProperties)
Parameters

text string

textRunProperties Avalonia.Media.TextFormatting.TextRunProperties

Properties

NameDescription
LengthGets the text source length.
PropertiesA set of properties shared by every characters in the run
TextGets the text run's text.

Length Property

Gets the text source length.

public int Length { get; set; }

Properties Property

A set of properties shared by every characters in the run

public Avalonia.Media.TextFormatting.TextRunProperties Properties { get; set; }

Text Property

Gets the text run's text.

public ReadOnlyMemory<char> Text { get; set; }

Fields

NameDescription
DefaultTextSourceLengthInherited from TextRun.