Set the text style.
name | type | arguments | Default | description |
---|---|---|---|---|
style | Phaser.Types.GameObjects.Text.TextStyle |
The style settings to set. |
||
updateText | boolean | <optional> | true |
Whether to update the text immediately. |
setDefaults | boolean | <optional> | false |
Use the default values is not set, or the local values. |
The parent Text object.
text.setStyle({
fontSize: '64px',
fontFamily: 'Arial',
color: '#ffffff',
align: 'center',
backgroundColor: '#ff00ff'
});