TextEdit.GetCharacterIndexFromPoint(Point, Boolean) Method

Returns the insertion index for the specified point.

Namespace: DevExpress.Xpf.Editors

Assembly: DevExpress.Xpf.Core.v20.1.dll

Declaration

public int GetCharacterIndexFromPoint(
    Point point,
    bool snapToText
)
Public Function GetCharacterIndexFromPoint(
    point As Point,
    snapToText As Boolean
) As Integer

Parameters

Name Type Description
point Point

The point in the editor's coordinate-space for which to return an insertion index.

snapToText Boolean

true to return the nearest insertion index if there is no character at the specified point; false to return -1 if there is no character at the specified point.

Returns

Type Description
Int32

The insertion index for the specified point, -1 if the valid insertion index was not found.

See Also