IVerticalFractionMap.GetFractionAtBufferPosition Method
Gets the fraction of the vertical extent of the view that corresponds to the specified buffer position.
Namespace: Microsoft.VisualStudio.Text.Editor
Assembly: Microsoft.VisualStudio.Text.UI (in Microsoft.VisualStudio.Text.UI.dll)
Syntax
'Déclaration
Function GetFractionAtBufferPosition ( _
bufferPosition As SnapshotPoint _
) As Double
double GetFractionAtBufferPosition(
SnapshotPoint bufferPosition
)
double GetFractionAtBufferPosition(
SnapshotPoint bufferPosition
)
abstract GetFractionAtBufferPosition :
bufferPosition:SnapshotPoint -> float
function GetFractionAtBufferPosition(
bufferPosition : SnapshotPoint
) : double
Parameters
- bufferPosition
Type: Microsoft.VisualStudio.Text.SnapshotPoint
The buffer position.
Return Value
Type: System.Double
The corresponding fraction of the vertical extent of the view.
Remarks
Different buffer positions can have the same fractions. This method is guaranteed only to be consistent: it will return the same fraction for the same position. The exact character returned depends on the implementation of the fraction map. In general, it is the first character on the line, but this is not guaranteed.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.