Compartir a través de


IWpfTextViewLineCollection.GetMarkerGeometry Method

Definition

Overloads

GetMarkerGeometry(SnapshotSpan)

Creates a marker geometry for the provided bufferSpan. If the provided bufferSpan extends beyond one line, then GetLineMarkerGeometry(SnapshotSpan) is used to calculate the marker geometry, otherwise this method uses GetTextMarkerGeometry(SnapshotSpan) to construct the geometry.

GetMarkerGeometry(SnapshotSpan, Boolean, Thickness)

Creates a marker geometry for the provided bufferSpan. If the provided bufferSpan extends beyond one line, then GetLineMarkerGeometry(SnapshotSpan, Boolean, Thickness) is used to calculate the marker geometry, otherwise this method uses GetTextMarkerGeometry(SnapshotSpan, Boolean, Thickness) to construct the geometry.

GetMarkerGeometry(SnapshotSpan)

Creates a marker geometry for the provided bufferSpan. If the provided bufferSpan extends beyond one line, then GetLineMarkerGeometry(SnapshotSpan) is used to calculate the marker geometry, otherwise this method uses GetTextMarkerGeometry(SnapshotSpan) to construct the geometry.

public:
 System::Windows::Media::Geometry ^ GetMarkerGeometry(Microsoft::VisualStudio::Text::SnapshotSpan bufferSpan);
public System.Windows.Media.Geometry GetMarkerGeometry (Microsoft.VisualStudio.Text.SnapshotSpan bufferSpan);
abstract member GetMarkerGeometry : Microsoft.VisualStudio.Text.SnapshotSpan -> System.Windows.Media.Geometry
Public Function GetMarkerGeometry (bufferSpan As SnapshotSpan) As Geometry

Parameters

bufferSpan
SnapshotSpan

The span of text.

Returns

A Geometry that contains the bounds of all of the formatted text in bufferSpan.

Exceptions

bufferSpan is not a valid SnapshotSpan on the buffer.

Remarks

If the span extends beyond one line, then GetLineMarkerGeometry is used to calculate the marker geometry, otherwise this method uses GetTextMarkerGeometry to construct the geometry.

The returned geometry may contain several disjoint regions if the span contains a mix of conventional and bi-directional text.

Applies to

GetMarkerGeometry(SnapshotSpan, Boolean, Thickness)

Creates a marker geometry for the provided bufferSpan. If the provided bufferSpan extends beyond one line, then GetLineMarkerGeometry(SnapshotSpan, Boolean, Thickness) is used to calculate the marker geometry, otherwise this method uses GetTextMarkerGeometry(SnapshotSpan, Boolean, Thickness) to construct the geometry.

public:
 System::Windows::Media::Geometry ^ GetMarkerGeometry(Microsoft::VisualStudio::Text::SnapshotSpan bufferSpan, bool clipToViewport, System::Windows::Thickness padding);
public System.Windows.Media.Geometry GetMarkerGeometry (Microsoft.VisualStudio.Text.SnapshotSpan bufferSpan, bool clipToViewport, System.Windows.Thickness padding);
abstract member GetMarkerGeometry : Microsoft.VisualStudio.Text.SnapshotSpan * bool * System.Windows.Thickness -> System.Windows.Media.Geometry
Public Function GetMarkerGeometry (bufferSpan As SnapshotSpan, clipToViewport As Boolean, padding As Thickness) As Geometry

Parameters

bufferSpan
SnapshotSpan

The span of text.

clipToViewport
Boolean

If true, the created geometry will be clipped to the viewport.

padding
Thickness

A padding that's applied to the elements on a per line basis.

Returns

A Geometry that contains the bounds of all of the formatted text in bufferSpan.

Remarks

If the span extends beyond one line, then GetLineMarkerGeometry is used to calculate the marker geometry, otherwise this method uses GetTextMarkerGeometry.

Applies to