GETTEXTSIZE

Top  Previous  Next

Syntax

GETTEXTSIZE(win as WINDOW,text as STRING,vWidth as INT BYREF,vHeight as INT BYREF)

Description

Retrieves the size of a string in pixels when printed to the window.

Parameters

win - [in] Window for test.

text - [in] String to measure.

vWidth, vHeight - [out] Variables to receive text size.

Return value

None

Remarks

vWidth and vHeight must be variables of type INT. The size is calculated using the current font of the window and is useful for determining line positions.

Example usage

DEF tWidth, tHeight as INT
GETTEXTSIZE win1, "Tell me", tWidth, tHeight