Skip to content

Text object

An object that can be used to display any text on the screen: remaining life counter, some indicators, menu buttons, dialogues... Read more explanations about it.

Text

Displays a text on the screen.

Object actions

Angle
Modify the angle of a Text object.

Color
Change the color of the text. The color is white by default.

Text opacity
Change the opacity of a Text. 0 is fully transparent, 255 is opaque (default).

Scale
Modify the scale of the specified object (default scale is 1)

Scale on X axis
Modify the scale of the text on the X axis (default scale is 1)

Scale on Y axis
Modify the scale of the text on the Y axis (default scale is 1)

Bold
De/activate bold

Gradient
Change the gradient of the text.

Italic
De/activate italic.

Outline
Change the outline of the text. A thickness of 0 disables the outline.

Padding
Set the number of pixels around a text object. If the shadow or the outline around the text are getting cropped, raise this value.

Text shadow
Change the shadow of the text.

Alignment
Set the text alignment of a multiline text object (does not work with single line texts).

Wrapping
De/activate word wrapping. Note that word wrapping is a graphical option,
you can't get the number of lines displayed

Show Shadow
Show the shadow of the text.

Modify the text
Modify the text of a Text object.

Font size
Change the font size of a text object.

Wrapping width
Modify the word wrapping width of a Text object.

Object conditions

Angle
Compare the value of the angle of a Text object.

Bold
Check if the bold style is activated

Italic
Check if the italic style is activated

Wrapping
Test if the word wrapping style of an object is set.

Opacity
Compare the opacity of a Text object, between 0 (fully transparent) to 255 (opaque).

Padding
Compare the number of pixels around a text object. If the shadow or the outline around the text are getting cropped, raise this value.

Scale on X axis
Compare the scale of the text on the X axis

Scale on Y axis
Compare the scale of the text on the Y axis

Compare the text
Compare the text of a Text object.

Font size
Compare the font size of a text object.

Alignment
Compare the text alignment of a multiline text object.

Wrapping width
Test the word wrapping width of a Text object.

Object expressions

Expression Description
Object.Angle() Angle
Object.FontSize() Return the font size of a text object.
Object.Opacity() Opacity of a Text object
Object.Padding() Padding
Object.ScaleX() X Scale of a Text object
Object.ScaleY() Y Scale of a Text object
Object.String() Text

This page is an auto-generated reference page about the Text object feature of GDevelop, the open-source, cross-platform game engine designed for everyone. Learn more about all GDevelop features here.