Table of Contents

Class RichTextRun

Namespace
SixLabors.ImageSharp.Drawing.Processing
Assembly
SixLabors.ImageSharp.Drawing.dll

Represents a run of drawable text spanning a series of graphemes within a string.

public class RichTextRun : TextRun
Inheritance
RichTextRun
Inherited Members

Properties

Brush

Gets or sets the brush used for filling this run.

public Brush? Brush { get; set; }

Property Value

Brush

OverlinePen

Gets or sets the pen used for drawing overline features for this run.

public Pen? OverlinePen { get; set; }

Property Value

Pen

Pen

Gets or sets the pen used for outlining this run.

public Pen? Pen { get; set; }

Property Value

Pen

StrikeoutPen

Gets or sets the pen used for drawing strikeout features for this run.

public Pen? StrikeoutPen { get; set; }

Property Value

Pen

UnderlinePen

Gets or sets the pen used for drawing underline features for this run.

public Pen? UnderlinePen { get; set; }

Property Value

Pen

Methods

GetDecorationOptions(TextDecorations)

Gets the geometry overrides to apply to the specified decoration, or null to use the values derived from the font's metrics.

public override TextDecorationOptions? GetDecorationOptions(TextDecorations decoration)

Parameters

decoration TextDecorations

The decoration to retrieve overrides for.

Returns

TextDecorationOptions

The TextDecorationOptions for the decoration, or null.

Remarks

The base implementation returns null for every decoration. Derived runs can override this to supply values sourced from styling that the font metrics do not describe, such as an explicit stroke width.