API Docs for:
Show:

Object_Text Class

Module: gs

A game object used for custom texts in a scene.

Methods

restore

(
  • data
)

Restores the game object from a data-bundle.

Parameters:

  • data Object
    • The data-bundle.

toDataBundle

() Object

Serializes the object into a data-bundle.

Returns:

Object:

The data-bundle.

Properties

angle

Number

The rotation-angle of the picture in degrees. The rotation center depends on the anchor-point.

animator

gs.Component_Animator

The object's animator-component to execute different kind of animations like move, rotate, etc. on it.

behavior

gs.Component_TextBehavior

The object's behavior component for the text-specific behavior.

bitmap

gs.Bitmap

The object's bitmap used for visual presentation.

breakBindingChain

Boolean

Provided by the ui module.

Indicates if that UI object will break the binding-chain. If true the UI object will not change any binding-targets for the current binding-execution period.

color

gs.Color

The color of the object used for the visual presentation.

domain

String

The domain the object belongs to.

events

gs.Component_EventEmitter

Provided by the ui module.

An event-emitter to emit events.

font

gs.Font

The font used for the text.

margin

Object

Provided by the ui module.

The UI object's margin. The margin defines an extra space around the UI object. The default is { left: 0, top: 0, right: 0, bottom: 0 }.

mask

gs.Mask

The object's mask to execute masking-effects on it.

mirror

Boolean

Indicates if the object's visual presentation should be mirrored horizontally.

padding

ui.Space

Provided by the ui module.

The UI object's padding. The default is { left: 0, top: 0, right: 0, bottom: 0 }.

srcRect

gs.Rect

The object's source rectangle. It controls which part of the object's image is used for visual presentation.

text

String

The text to display.

textRenderer

gs.Component_TextRenderer

The text-renderer used to render the text.

tone

gs.Tone

The color tone of the object used for the visual presentation.

visual

gs.Component_Sprite

The object's visual-component to display the game object on screen.

wordWrap

Boolean

Indicates if word-wrap is enabled. If true line-breaks are automatically added.