Skip to content

get_tpositionGetTpositionGetTpositionget_tpositionT_get_tpositionπŸ”—

Short descriptionπŸ”—

get_tpositionGetTpositionGetTpositionget_tpositionT_get_tposition β€” Get cursor position.

SignatureπŸ”—

get_tposition( window WindowHandle, out point.y Row, out point.x Column )void GetTposition( const HTuple& WindowHandle, HTuple* Row, HTuple* Column )static void HOperatorSet.GetTposition( HTuple windowHandle, out HTuple row, out HTuple column )def get_tposition( window_handle: HHandle ) -> Tuple[int, int]

Herror T_get_tposition( const Htuple WindowHandle, Htuple* Row, Htuple* Column )

void HWindow::GetTposition( Hlong* Row, Hlong* Column ) const

void HWindow.GetTposition( out int row, out int column )

DescriptionπŸ”—

get_tpositionGetTposition queries the current position of the text cursor in the output window. The position is measured in the image coordinate system. The next output of text in this window starts at the cursor position. The left end of the baseline for writing the next string (not considering descenders) is placed on this position. The position is changed by the output or input of text (write_stringWriteString, read_stringReadString) or by an explicit change of position by (set_tpositionSetTposition, new_lineNewLine).

AttentionπŸ”—

If the output text does not fit completely into the window, an exception is raised. This can be avoided by texttt{set_check(β€˜~text’)}.

Execution informationπŸ”—

Execution information
  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

ParametersπŸ”—

WindowHandlewindowHandlewindow_handle (input_control) window β†’ (handle)HTuple (HHandle)HWindow, HTuple (IntPtr)HHandleHtuple (handle)

Window handle.

Rowrowrow (output_control) point.y β†’ (integer)HTuple (Hlong)HTuple (int / long)intHtuple (Hlong)

Row index of text cursor position.

Columncolumncolumn (output_control) point.x β†’ (integer)HTuple (Hlong)HTuple (int / long)intHtuple (Hlong)

Column index of text cursor position.

ResultπŸ”—

get_tpositionGetTposition returns 2 (H_MSG_TRUE) if the window is valid. Otherwise an exception is raised.

Combinations with other operatorsπŸ”—

Combinations

Possible predecessors

open_windowOpenWindow, set_fontSetFont

Possible successors

set_tpositionSetTposition, write_stringWriteString, read_stringReadString, read_charReadChar

See also

new_lineNewLine, read_stringReadString, set_tpositionSetTposition, write_stringWriteString, set_checkSetCheck

ModuleπŸ”—

Foundation