Font.textWidth

Gets total width of the text, number of characters, and number of words.

class Font
textWidth
(
string text
,
uint len
)

Parameters

text string

The text to get width.

len uint

The byte length of the text.

Return Value

Type: TextWidth

On success, returns a TextWidth struct including calculation result.<br /> Otherwise, returns TextWidth struct whose attributes are all 0.

Meta