Name | Type | Description |
---|---|---|
game |
Core.Game | the game object |
txt |
String | the text itself (destined to be rendered) |
style |
String | 2d context styling (can be just color) |
font |
String | 2d cotext font description |
Methods
-
get the dimentions of text element if to be rendered.
Returns:
Type Description TextMetrics 2d context object that contains the desired width & height properties. -
gets currently set text
Returns:
Type Description String the text -
renders the text element
-
sets the text to display
Name Type Description txt
String the text to display