Difference between revisions of "Font:getWidth"

(Fixes type of line)
Line 7: Line 7:
 
</source>
 
</source>
 
=== Arguments ===
 
=== Arguments ===
{{param|number|line|A line of text.}}
+
{{param|string|line|A line of text.}}
 
=== Returns ===
 
=== Returns ===
 
{{param|number|width|The width of the line.}}
 
{{param|number|width|The width of the line.}}

Revision as of 12:58, 1 August 2011

Determines the horizontal size a line of text needs. Does not support line-breaks.

Function

Synopsis

width = Font:getWidth( line )

Arguments

string line
A line of text.

Returns

number width
The width of the line.

See Also


Other Languages