Skip to content

Text object Reference

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

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

Font
Change the font of the text.

Bold
De/activate bold

Gradient
Change the gradient of the text.

Italic
De/activate italic.

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.

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

Enable shadow
Enable or disable the shadow of the text.

Font size
Change the font size of a text object.

Outline color
Change the outline color of the text.

Enable outline
Enable or disable the outline of the text.

Outline thickness
Change the outline thickness of the text.

Shadow angle
Change the shadow angle of the text.

Shadow blur radius
Change the shadow blur radius of the text.

Shadow color
Change the shadow color of the text.

Shadow distance
Change the shadow distance of the text.

Shadow opacity
Change the shadow opacity of the text.

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

Object conditions

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.

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.

Font size
Compare the font size of a text object.

Outline enabled
Check if the text outline is enabled.

Shadow enabled
Check if the text shadow is enabled.

Outline thickness
Compare the outline thickness of the text.

Shadow angle
Compare the shadow angle of the text.

Shadow blur radius
Compare the shadow blur radius of the text.

Shadow distance
Compare the shadow distance of the text.

Shadow opacity
Compare the shadow opacity of the text.

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.FontSize() Return the font size of a text object.
Object.OutlineThickness() Return the outline thickness of the text.
Object.Padding() Padding
Object.ShadowAngle() Return the shadow angle of the text.
Object.ShadowBlurRadius() Return the shadow blur radius of the text.
Object.ShadowDistance() Return the shadow distance of the text.
Object.ShadowOpacity() Return the shadow opacity of the 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.