Selection Constructors

Definition

Overloads

Selection(TextRange, Boolean)

Instantiates a new Selection with the given extent. Anchor and active points are defined by isReversed, and the insertion point is located at the active point.

Selection(TextPosition, TextPosition, TextPosition)

Selection(TextRange, Boolean)

Instantiates a new Selection with the given extent. Anchor and active points are defined by isReversed, and the insertion point is located at the active point.

public Selection (Microsoft.VisualStudio.Extensibility.Editor.TextRange extent, bool isReversed = false);
new Microsoft.VisualStudio.Extensibility.Editor.Selection : Microsoft.VisualStudio.Extensibility.Editor.TextRange * bool -> Microsoft.VisualStudio.Extensibility.Editor.Selection
Public Sub New (extent As TextRange, Optional isReversed As Boolean = false)

Parameters

extent
TextRange

The span that the selection covers.

isReversed
Boolean

True implies that ActivePosition comes before AnchorPosition. The InsertionPosition is set to the ActivePosition.

Applies to

Selection(TextPosition, TextPosition, TextPosition)

public Selection (Microsoft.VisualStudio.Extensibility.Editor.TextPosition activePosition, Microsoft.VisualStudio.Extensibility.Editor.TextPosition anchorPosition, Microsoft.VisualStudio.Extensibility.Editor.TextPosition insertionPosition);
new Microsoft.VisualStudio.Extensibility.Editor.Selection : Microsoft.VisualStudio.Extensibility.Editor.TextPosition * Microsoft.VisualStudio.Extensibility.Editor.TextPosition * Microsoft.VisualStudio.Extensibility.Editor.TextPosition -> Microsoft.VisualStudio.Extensibility.Editor.Selection
Public Sub New (activePosition As TextPosition, anchorPosition As TextPosition, insertionPosition As TextPosition)

Parameters

activePosition
TextPosition
anchorPosition
TextPosition
insertionPosition
TextPosition

Applies to