Switch
A Switch
is a representation of a physical switch that allows users to turn things on or off. Consider using a CheckBox
instead if you want the user to select or deselect values, for example in a list with multiple options.
Properties
checked
bool (in-out)
default: false
Whether the switch is checked or not.
enabled
bool default: false
When false, the switch can’t be pressed
has-focus
bool (out)
default: false
Set to true when the switch has keyboard focus
text
string default: ""
The text written next to the switch.
Callbacks
toggled()
The switch value changed
© 2024 SixtyFPS GmbH