IVsTextLayer Interface


Handles layout between a base buffer and a view.

Namespace:   Microsoft.VisualStudio.TextManager.Interop
Assembly:  Microsoft.VisualStudio.TextManager.Interop (in Microsoft.VisualStudio.TextManager.Interop.dll)

public interface IVsTextLayer

System_CAPS_pubmethodBaseLineIndexToLocal(Int32, Int32, Int32, Int32)

Converts base line coordinates to local coordinates.

System_CAPS_pubmethodCanReplaceLines(Int32, Int32, Int32, Int32, Int32)

Determines if specified number of replacement characters can be inserted into lines.

System_CAPS_pubmethodCopyLineText(Int32, Int32, Int32, Int32, IntPtr, Int32)

Puts the specified span of text into a caller-allocated buffer

System_CAPS_pubmethodCreateTrackingPoint(Int32, Int32, IVsTextTrackingPoint)

Creates a zero-length tracking point that is similar to a zero-length marker.

System_CAPS_pubmethodDeeperLayerLineIndexToLocal(UInt32, IVsTextLayer, Int32, Int32, Int32, Int32)

Converts deeper layer line coordinates to local line coordinates.

System_CAPS_pubmethodEnumLayerMarkers(Int32, Int32, Int32, Int32, Int32, UInt32, IVsEnumLayerMarkers)

Enumerates all markers.


Gets the base buffer of text lines.

System_CAPS_pubmethodGetLastLineIndex(Int32, Int32)

Returns the length and index of the last line.

System_CAPS_pubmethodGetLengthOfLine(Int32, Int32)

Returns the length of a line.


Returns the number of lines.

System_CAPS_pubmethodGetLineDataEx(UInt32, Int32, Int32, Int32, LINEDATAEX[], MARKERDATA[])

Gets all line data.

System_CAPS_pubmethodGetLineText(Int32, Int32, Int32, Int32, String)

Gets the specified span of text.

System_CAPS_pubmethodGetMarkerData(Int32, Int32, MARKERDATA[])

Gets the marker data of the specified line span.

System_CAPS_pubmethodLocalLineIndexToBase(Int32, Int32, Int32, Int32)

Converts local line coordinates to base coordinates.

System_CAPS_pubmethodLocalLineIndexToDeeperLayer(IVsTextLayer, Int32, Int32, Int32, Int32)

Converts local line coordinates to deeper layer line coordinates.


Locks the buffer as specified for reading and writing.

System_CAPS_pubmethodMapLocalSpansToTextOriginatingLayer(UInt32, IVsEnumTextSpans, IVsTextLayer, IVsEnumTextSpans)

Maps a set of local spans to the shallowest layer that originates text.


Releases previously obtained line data.


Releases previously obtained marker data.

System_CAPS_pubmethodReplaceLines(Int32, Int32, Int32, Int32, IntPtr, Int32, TextSpan[])

Handles line breaking/joining, etc.

System_CAPS_pubmethodReplaceLinesEx(UInt32, Int32, Int32, Int32, Int32, IntPtr, Int32, TextSpan[])

Handles line breaking/joining, etc.


Unlocks the buffer as specified for reading and writing.

An example is a function-at-a-time layer which hides the text before and after a function.

One text layer can act as a text layer upon another. The buffer itself is a text layer. Thus any number of text layers can modify the view’s "perception" of the underlying buffer.

This interface is derived from IVsTextLines

Notes to Implementers:

You cannot currently implement this interface.

Return to top