• Articles
  • API Documentation
Search Results for

    Show / Hide Table of Contents
    • SixLabors.Fonts
      • ColorFontSupport
      • Font
      • FontCollection
      • FontCollectionExtensions
      • FontDescription
      • FontException
      • FontFamily
      • FontFamilyNotFoundException
      • FontMetrics
      • FontRectangle
      • FontStyle
      • Glyph
      • GlyphBounds
      • GlyphColor
      • GlyphLayoutMode
      • GlyphMetrics
      • GlyphMissingException
      • GlyphRendererParameters
      • GlyphType
      • HintingMode
      • HorizontalAlignment
      • HorizontalMetrics
      • IColorGlyphRenderer
      • IFontCollection
      • IGlyphRenderer
      • IGlyphRendererExtensions
      • IMetricsHeader
      • IReadOnlyFontCollection
      • IReadOnlySystemFontCollection
      • InvalidFontFileException
      • InvalidFontTableException
      • KerningMode
      • LayoutMode
      • LayoutModeExtensions
      • MissingFontTableException
      • SystemFonts
      • TextAlignment
      • TextAttributes
      • TextDecorations
      • TextDirection
      • TextJustification
      • TextMeasurer
      • TextOptions
      • TextRenderer
      • TextRun
      • VerticalAlignment
      • VerticalMetrics
      • WordBreaking
    • SixLabors.Fonts.Tables.AdvancedTypographic
      • FeatureTags
      • GlyphClassDef
      • Tag
    • SixLabors.Fonts.Tables.TrueType
      • TrueTypeGlyphMetrics
    • SixLabors.Fonts.Unicode
      • ArabicJoiningClass
      • ArabicJoiningGroup
      • ArabicJoiningType
      • BidiCharacterType
      • BidiClass
      • BidiPairedBracketType
      • CodePoint
      • GraphemeClusterClass
      • IndicPositionalCategory
      • IndicSyllabicCategory
      • LineBreakClass
      • MemoryExtensions
      • ScriptClass
      • SpanCodePointEnumerator
      • SpanGraphemeEnumerator
      • VerticalOrientationType
    • SixLabors.Fonts.WellKnownIds
      • KnownNameIds

    Class TextRun

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

    Inheritance
    object
    TextRun
    RichTextRun
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: SixLabors.Fonts
    Assembly: SixLabors.Fonts.dll
    Syntax
    public class TextRun

    Properties

    | Edit this page View Source

    End

    Gets or sets the exclusive end index of the last grapheme in this TextRun.

    Declaration
    public int End { get; set; }
    Property Value
    Type Description
    int
    | Edit this page View Source

    Font

    Gets or sets the font for this run.

    Declaration
    public Font? Font { get; set; }
    Property Value
    Type Description
    Font
    | Edit this page View Source

    Start

    Gets or sets the inclusive start index of the first grapheme in this TextRun.

    Declaration
    public int Start { get; set; }
    Property Value
    Type Description
    int
    | Edit this page View Source

    TextAttributes

    Gets or sets the text attributes applied to this run.

    Declaration
    public TextAttributes TextAttributes { get; set; }
    Property Value
    Type Description
    TextAttributes
    | Edit this page View Source

    TextDecorations

    Gets or sets the text decorations applied to this run.

    Declaration
    public TextDecorations TextDecorations { get; set; }
    Property Value
    Type Description
    TextDecorations

    Methods

    | Edit this page View Source

    Slice(ReadOnlySpan<char>)

    Returns the slice of the given text representing this TextRun.

    Declaration
    public ReadOnlySpan<char> Slice(ReadOnlySpan<char> text)
    Parameters
    Type Name Description
    ReadOnlySpan<char> text

    The text to slice.

    Returns
    Type Description
    ReadOnlySpan<char>

    The ReadOnlySpan<T>.

    | Edit this page View Source

    ToString()

    Returns a string that represents the current object.

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    A string that represents the current object.

    Overrides
    object.ToString()
    • Edit this page
    • View Source
    In this article
    Back to top Generated by DocFX