Skip to main content

TextRunProperties Class

Definition​

Assembly:Avalonia.Base
Package:Avalonia

Provides a set of properties, such as typeface or foreground brush, that can be applied to a TextRun object. This is an abstract class.

public class TextRunProperties

Inheritance: object -> TextRunProperties

Implements: IEquatable<TextRunProperties>

Remarks​

The text layout client provides a concrete implementation of this abstract class. This enables the client to implement text run properties in a way that corresponds with the associated formatting store.

Methods​

NameDescription
Equals (2 overloads)No summary available.
GetHashCodeNo summary available.

Equals overloads​

Equals Method​

public bool Equals(Avalonia.Media.TextFormatting.TextRunProperties other)
Parameters​

other Avalonia.Media.TextFormatting.TextRunProperties

Returns​

bool

Equals Method​

public bool Equals(object obj)
Parameters​

obj object

Returns​

bool

GetHashCode Method​

public int GetHashCode()

Returns​

int

Properties​

NameDescription
BackgroundBrushBrush used to paint background of run.
BaselineAlignmentRun vertical box alignment
CultureInfoRun text culture.
FontFeaturesOptional features of used font.
FontRenderingEmSizeEm size of font used to format and display text
ForegroundBrushBrush used to fill text.
TextDecorationsRun TextDecorations.
TypefaceRun typeface

BackgroundBrush Property​

Brush used to paint background of run.

public Avalonia.Media.IBrush BackgroundBrush { get; set; }

BaselineAlignment Property​

Run vertical box alignment

public Avalonia.Media.BaselineAlignment BaselineAlignment { get; set; }

CultureInfo Property​

Run text culture.

public System.Globalization.CultureInfo CultureInfo { get; set; }

FontFeatures Property​

Optional features of used font.

public Avalonia.Media.FontFeatureCollection FontFeatures { get; set; }

FontRenderingEmSize Property​

Em size of font used to format and display text

public double FontRenderingEmSize { get; set; }

ForegroundBrush Property​

Brush used to fill text.

public Avalonia.Media.IBrush ForegroundBrush { get; set; }

TextDecorations Property​

Run TextDecorations.

public Avalonia.Media.TextDecorationCollection TextDecorations { get; set; }

Typeface Property​

Run typeface

public Avalonia.Media.Typeface Typeface { get; set; }