Class Run
A terminal element in text flow hierarchy - contains a uniformatted run of unicode characters
public class Run : Inline, INotifyPropertyChanged, IDataContextProvider, ILogical, IThemeVariantHost, IResourceHost, IResourceNode, IStyleHost, ISetLogicalParent, ISetInheritanceParent, ISupportInitialize, IStyleable, INamed
- Inheritance
-
Run
- Implements
- Inherited Members
- Extension Methods
Constructors
Run()
Initializes an instance of Run class.
public Run()
Run(string?)
Initializes an instance of Run class specifying its text content.
public Run(string? text)
Parameters
text
stringText content assigned to the Run.
Fields
TextProperty
Dependency property backing Text.
public static readonly StyledProperty<string?> TextProperty
Field Value
Remarks
Note that when a TextRange that intersects with this Run gets modified (e.g. by editing a selection in RichTextBox), we will get two changes to this property since we delete and then insert when setting the content of a TextRange.
Properties
Text
The content spanned by this TextElement.
[Content]
public string? Text { get; set; }
Property Value
Methods
OnPropertyChanged(AvaloniaPropertyChangedEventArgs)
Called when a avalonia property changes on the object.
protected override void OnPropertyChanged(AvaloniaPropertyChangedEventArgs change)
Parameters
change
AvaloniaPropertyChangedEventArgsThe property change details.