getTextWidth() |
Top Previous Next |
getTextWidth( text [, fontName] [, fontSize] )
Returns the width of text in pixels.
Parameters
Usage
function main() { var myVar;
... ...
//return the width, in pixels, of the string //"Test Results" in a 24-point Arial font. myVar = getTextWidth( "Test Results", "Arial", 24 );
}
|