C# Class Microsoft.VisualStudio.Text.Editor.LegacySelection

Represents the selection on the screen.
Inheritance: Microsoft.VisualStudio.Text.Editor.DisplayTextRange
ファイルを表示 Open project: microsoft/vs-editor-api

Private Properties

Property Type Description

Public Methods

Method Description
Clear ( ) : void

When implemented in a derived class, resets any selection in the text.

ExtendSelection ( Microsoft.VisualStudio.Text.Editor.TextPoint newEnd ) : void

When implemented in a derived class, extends the selection from its current start point to the new end point. Ensures that the end point of the selection is visible on screen.

newEnd may become the new start point, if newEnd is before the current start point.

SelectAll ( bool moveCaret = true ) : void

When implemented in a derived class, selects all the text in the document. Ensures that the end point of the selection is visible on screen if moveCaret is true.

SelectRange ( Microsoft.VisualStudio.Text.Editor.TextPoint selectionStart, Microsoft.VisualStudio.Text.Editor.TextPoint selectionEnd ) : void

When implemented in a derived class, selects the given text range, reversing the selection if needed. Ensures that the end point of the selection is visible on screen.

If selectionStart is positioned after selectionEnd, then the selection is reversed.

SelectRange ( Microsoft.VisualStudio.Text.Editor.TextRange textRange ) : void

When implemented in a derived class, selects the given text range.

Method Details

Clear() public abstract method

When implemented in a derived class, resets any selection in the text.
public abstract Clear ( ) : void
return void

ExtendSelection() public abstract method

When implemented in a derived class, extends the selection from its current start point to the new end point. Ensures that the end point of the selection is visible on screen.
newEnd may become the new start point, if newEnd is before the current start point.
belongs to a different buffer.
public abstract ExtendSelection ( Microsoft.VisualStudio.Text.Editor.TextPoint newEnd ) : void
newEnd Microsoft.VisualStudio.Text.Editor.TextPoint /// The text point to which to extend the selection. ///
return void

SelectAll() public abstract method

When implemented in a derived class, selects all the text in the document. Ensures that the end point of the selection is visible on screen if moveCaret is true.
public abstract SelectAll ( bool moveCaret = true ) : void
moveCaret bool
return void

SelectRange() public abstract method

When implemented in a derived class, selects the given text range, reversing the selection if needed. Ensures that the end point of the selection is visible on screen.
If selectionStart is positioned after selectionEnd, then the selection is reversed.
public abstract SelectRange ( Microsoft.VisualStudio.Text.Editor.TextPoint selectionStart, Microsoft.VisualStudio.Text.Editor.TextPoint selectionEnd ) : void
selectionStart Microsoft.VisualStudio.Text.Editor.TextPoint The start point for the selection.
selectionEnd Microsoft.VisualStudio.Text.Editor.TextPoint The end point for the selection.
return void

SelectRange() public abstract method

When implemented in a derived class, selects the given text range.
public abstract SelectRange ( Microsoft.VisualStudio.Text.Editor.TextRange textRange ) : void
textRange Microsoft.VisualStudio.Text.Editor.TextRange The range to select.
return void