Jump to content

MATLAB Programming/Psychtoolbox/Screen Commands/TextWidth

From Wikibooks, open books for an open world

Usage:

width=Screen(windowPtr,'TextWidth',text);

Get width of text string. Width is the change in horizontal pen position that would be produced by calling DrawText; it's negative for right-to-left scripts (e.g. Hebrew). The text may include 2-byte characters (e.g. Chinese).