C# Класс ICSharpCode.TextEditor.Document.SelectionManager

This class manages the selections in a document.
Наследование: IDisposable
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
ClearSelection ( ) : void Clears the selection.
Dispose ( ) : void
ExtendSelection ( Point oldPosition, Point newPosition ) : void
FireSelectionChanged ( ) : void
GetSelectionAt ( int offset ) : ISelection Returns a ISelection object giving the selection in which the offset points to.
GetSelectionAtLine ( int lineNumber ) : ICSharpCode.TextEditor.Document.ColumnRange
GreaterEqPos ( Point p1, Point p2 ) : bool
IsSelected ( int offset ) : bool Returns true if the given offset points to a section which is selected.
NextValidPosition ( int line ) : Point
RemoveSelectedText ( ) : void Removes the selected text from the buffer and clears the selection.
SelectionManager ( IDocument document ) : System

Creates a new instance of SelectionManager

SelectionManager ( IDocument document, TextArea textArea ) : System

Creates a new instance of SelectionManager

SetSelection ( ISelection selection ) : void Clears the selection and sets a new selection using the given ISelection object.
SetSelection ( Point startPosition, Point endPosition ) : void

Защищенные методы

Метод Описание
OnSelectionChanged ( EventArgs e ) : void

Приватные методы

Метод Описание
ClearWithoutUpdate ( ) : void
DocumentChanged ( object sender, ICSharpCode.TextEditor.Document.DocumentEventArgs e ) : void
Insert ( int offset, string text ) : void Used internally, do not call.
Remove ( int offset, int length ) : void Used internally, do not call.
Replace ( int offset, int length, string text ) : void Used internally, do not call.
SelectionsOverlap ( ISelection s1, ISelection s2 ) : bool

Описание методов

ClearSelection() публичный Метод

Clears the selection.
public ClearSelection ( ) : void
Результат void

Dispose() публичный Метод

public Dispose ( ) : void
Результат void

ExtendSelection() публичный Метод

public ExtendSelection ( Point oldPosition, Point newPosition ) : void
oldPosition Point
newPosition Point
Результат void

FireSelectionChanged() публичный Метод

public FireSelectionChanged ( ) : void
Результат void

GetSelectionAt() публичный Метод

Returns a ISelection object giving the selection in which the offset points to.
public GetSelectionAt ( int offset ) : ISelection
offset int
Результат ISelection

GetSelectionAtLine() публичный Метод

public GetSelectionAtLine ( int lineNumber ) : ICSharpCode.TextEditor.Document.ColumnRange
lineNumber int
Результат ICSharpCode.TextEditor.Document.ColumnRange

GreaterEqPos() публичный Метод

public GreaterEqPos ( Point p1, Point p2 ) : bool
p1 Point
p2 Point
Результат bool

IsSelected() публичный Метод

Returns true if the given offset points to a section which is selected.
public IsSelected ( int offset ) : bool
offset int
Результат bool

NextValidPosition() публичный Метод

public NextValidPosition ( int line ) : Point
line int
Результат Point

OnSelectionChanged() защищенный Метод

protected OnSelectionChanged ( EventArgs e ) : void
e System.EventArgs
Результат void

RemoveSelectedText() публичный Метод

Removes the selected text from the buffer and clears the selection.
public RemoveSelectedText ( ) : void
Результат void

SelectionManager() публичный Метод

Creates a new instance of SelectionManager
public SelectionManager ( IDocument document ) : System
document IDocument
Результат System

SelectionManager() публичный Метод

Creates a new instance of SelectionManager
public SelectionManager ( IDocument document, TextArea textArea ) : System
document IDocument
textArea TextArea
Результат System

SetSelection() публичный Метод

Clears the selection and sets a new selection using the given ISelection object.
public SetSelection ( ISelection selection ) : void
selection ISelection
Результат void

SetSelection() публичный Метод

public SetSelection ( Point startPosition, Point endPosition ) : void
startPosition Point
endPosition Point
Результат void