Class ToggleButton2D

Class Hierarchy

Use the Toggle Button 2D node to create a 2D UI control that the user can interact with through clicking, tapping, or pressing a keyboard key, and that has multiple toggle states.

Inherits properties and message types from ToggleButton2DMetadata.

Synopsis

Methods
create()

Creates an instance of ToggleButton2D

ToggleButton2D:create(objectName)

Creates an instance of ToggleButton2D.

Parameters
objectName (string)

The name of the object.