Class TextChangeEventArgs
Represents state for a TextChanged event.
Inheritance
System.Object
TextChangeEventArgs
Namespace: Loretta.CodeAnalysis.Text
Assembly: Loretta.CodeAnalysis.dll
Syntax
public class TextChangeEventArgs : EventArgs
Constructors
| Improve this Doc View SourceTextChangeEventArgs(SourceText, SourceText, IEnumerable<TextChangeRange>)
Initializes an instance of TextChangeEventArgs.
Declaration
public TextChangeEventArgs(SourceText oldText, SourceText newText, IEnumerable<TextChangeRange> changes)
Parameters
Type | Name | Description |
---|---|---|
SourceText | oldText | The text before the change. |
SourceText | newText | The text after the change. |
IEnumerable<TextChangeRange> | changes | A set of ranges for the change. |
TextChangeEventArgs(SourceText, SourceText, TextChangeRange[])
Initializes an instance of TextChangeEventArgs.
Declaration
public TextChangeEventArgs(SourceText oldText, SourceText newText, params TextChangeRange[] changes)
Parameters
Type | Name | Description |
---|---|---|
SourceText | oldText | The text before the change. |
SourceText | newText | The text after the change. |
TextChangeRange[] | changes | A set of ranges for the change. |
Properties
| Improve this Doc View SourceChanges
Gets the set of ranges for the change.
Declaration
public IReadOnlyList<TextChangeRange> Changes { get; }
Property Value
Type | Description |
---|---|
IReadOnlyList<TextChangeRange> |
NewText
Gets the text after the change.
Declaration
public SourceText NewText { get; }
Property Value
Type | Description |
---|---|
SourceText |
OldText
Gets the text before the change.
Declaration
public SourceText OldText { get; }
Property Value
Type | Description |
---|---|
SourceText |