C# Class Microsoft.Languages.Editor.Extensions.TextBufferExtensions

Afficher le fichier Open project: Microsoft/RTVS

Méthodes publiques

Méthode Description
AddBufferDisposedAction ( this textBuffer, ICoreShell shell, ICoreShell>.Action callback ) : void
CurrentTextView ( this viewBuffer ) : ITextView
GetBufferGraph ( this viewBuffer ) : IBufferGraph

Given view buffer (top-level buffer in the projection tree) returns buffer graph.

GetChangedExtent ( this oldVersion, ITextVersion newVersion, Span &oldSpan, Span &newSpan ) : bool
GetContributingBuffers ( this textBuffer ) : IEnumerable
GetFileName ( this textBuffer ) : string
GetLineColumnFromPosition ( this textBuffer, int position, int &line, int &column ) : bool

Converts stream buffer position to line and column.

GetPositionFromLineColumn ( this textBuffer, int line, int column ) : int?

Converts line and column positions to a stream buffer position.

GetTextDocument ( this textBuffer ) : ITextDocument
IsContributingBuffer ( this buffer, ITextBuffer contributingBuffer ) : bool
IsSignatureHelpBuffer ( this textBuffer ) : bool
MapDown ( this viewBuffer, SnapshotPoint viewPoint, string contentTypeName ) : SnapshotPoint?

Given top-level text buffer (i.e. view buffer) maps location down the buffer graph to the project buffer of the specified content type, if any.

MapUp ( this viewBuffer, SnapshotPoint sourcePoint, string contentTypeName ) : SnapshotPoint?

Given top-level text buffer (i.e. view buffer) and location in the projected buffer maps location up the buffer graph from the buffer of the specified content type to the view buffer.

MapUp ( this viewBuffer, Span sourceSpan, string contentTypeName ) : SnapshotSpan?

Given top-level text buffer (i.e. view buffer) and location in the projected buffer maps location up the buffer graph from the buffer of the specified content type to the view buffer.

Method Details

AddBufferDisposedAction() public static méthode

public static AddBufferDisposedAction ( this textBuffer, ICoreShell shell, ICoreShell>.Action callback ) : void
textBuffer this
shell ICoreShell
callback ICoreShell>.Action
Résultat void

CurrentTextView() public static méthode

public static CurrentTextView ( this viewBuffer ) : ITextView
viewBuffer this
Résultat ITextView

GetBufferGraph() public static méthode

Given view buffer (top-level buffer in the projection tree) returns buffer graph.
public static GetBufferGraph ( this viewBuffer ) : IBufferGraph
viewBuffer this
Résultat IBufferGraph

GetChangedExtent() public static méthode

public static GetChangedExtent ( this oldVersion, ITextVersion newVersion, Span &oldSpan, Span &newSpan ) : bool
oldVersion this
newVersion ITextVersion
oldSpan Span
newSpan Span
Résultat bool

GetContributingBuffers() public static méthode

public static GetContributingBuffers ( this textBuffer ) : IEnumerable
textBuffer this
Résultat IEnumerable

GetFileName() public static méthode

public static GetFileName ( this textBuffer ) : string
textBuffer this
Résultat string

GetLineColumnFromPosition() public static méthode

Converts stream buffer position to line and column.
public static GetLineColumnFromPosition ( this textBuffer, int position, int &line, int &column ) : bool
textBuffer this
position int
line int
column int
Résultat bool

GetPositionFromLineColumn() public static méthode

Converts line and column positions to a stream buffer position.
public static GetPositionFromLineColumn ( this textBuffer, int line, int column ) : int?
textBuffer this
line int
column int
Résultat int?

GetTextDocument() public static méthode

public static GetTextDocument ( this textBuffer ) : ITextDocument
textBuffer this
Résultat ITextDocument

IsContributingBuffer() public static méthode

public static IsContributingBuffer ( this buffer, ITextBuffer contributingBuffer ) : bool
buffer this
contributingBuffer ITextBuffer
Résultat bool

IsSignatureHelpBuffer() public static méthode

public static IsSignatureHelpBuffer ( this textBuffer ) : bool
textBuffer this
Résultat bool

MapDown() public static méthode

Given top-level text buffer (i.e. view buffer) maps location down the buffer graph to the project buffer of the specified content type, if any.
public static MapDown ( this viewBuffer, SnapshotPoint viewPoint, string contentTypeName ) : SnapshotPoint?
viewBuffer this
viewPoint SnapshotPoint
contentTypeName string
Résultat SnapshotPoint?

MapUp() public static méthode

Given top-level text buffer (i.e. view buffer) and location in the projected buffer maps location up the buffer graph from the buffer of the specified content type to the view buffer.
public static MapUp ( this viewBuffer, SnapshotPoint sourcePoint, string contentTypeName ) : SnapshotPoint?
viewBuffer this
sourcePoint SnapshotPoint
contentTypeName string
Résultat SnapshotPoint?

MapUp() public static méthode

Given top-level text buffer (i.e. view buffer) and location in the projected buffer maps location up the buffer graph from the buffer of the specified content type to the view buffer.
public static MapUp ( this viewBuffer, Span sourceSpan, string contentTypeName ) : SnapshotSpan?
viewBuffer this
sourceSpan Span
contentTypeName string
Résultat SnapshotSpan?