In This Article

LocationToPositionAlgorithm Enum

Specifies a type of location to TextPosition algorithm.

public enum LocationToPositionAlgorithm

Fields

Name Description
Absolute

If the location is over a character, the character's position is returned.
Otherwise, TextPosition.Empty is returned.

BestFit

If the location is over the left half of a character, the character's position is returned.
If the location is over the right half of a character, the next character's position is returned. If the location is past the last character in a line and virtual space past the end of lines is disabled, the position of the last character in the line is returned. If the location is past the end of a document and virtual space past the end of the document is disabled, the position of the last character in the document is returned.

Block

If the location is over a character, the character's offset is returned.
If the location is past the last character in a line and virtual space past the end of lines is disabled, the position of the last character in the line is returned. If the location is past the end of a document and virtual space past the end of the document is disabled, the position of the last character in the document is returned.