Method Get():posInBuffer() Foundation

Determines a position within the edit buffer based on screen coordinates.

:posInBuffer( <nRow>, <nCol> ) --> nPos
<nRow> is the row position on the screen.
<nCol> is the column position on the screen.

The method :posInBuffer() returns a numeric value indicating the position in the edit buffer that matches the screen coordinates. When the <nRow> and <nCol> coordinates are not located within the edit window, zero is returned.


The method :posInBuffer() determines the position within the edit buffer where the mouse pointer is located after a mouse click. A Get object generally displays its entire edit buffer in the visible edit area. However, if the formatting includes the PICTURE function @S, the edit buffer is wider than the visible edit area. In this case the exact position of the mouse pointer in the edit buffer can only be determined by :posInBuffer().


If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.