"getCursorPosition"

Returns the cursor position in a textEdit document.

Synopsis

dyn_int getCursorPosition(int &para, int &pos);

Parameters

Parameter Description
para X coordinate (row number) in a textEdit document
pos Y coordinate. The cursor position (position inside the paragraph) in a textEdit document.

Description

Returns the cursor position (Index 1 = Paragraph (== para) and Index 2 = Position inside the paragraph (== pos)) in a textEdit document.

Return Value

The position. See the example below.

Example

This example returns the cursor position in a textEdit document.

main()
{
  int para, pos;
  TEXT_EDIT1.getCursorPosition(para, pos);
  DebugN("getCursorPosition: Paragraph:", para, "Position:", pos);
}

Assignment

textEdit