Name
TextHeight -- return the height of a string (V1.5)
Synopsis
height = TextHeight(string$)
Function
This function returns the height of the text specified by string$ if it was rendered on the display. So it takes care of the currently selected font as well as the font style.

Inputs
string$
source text
Results
height
height of the text
Example
height = TextHeight("Hello World")
pos = (480 - height) / 2
Locate(0, pos)
Print("Hello World")
The above code centers the text "Hello World" vertically on a 480 pixel-high display.

Show TOC