ToggleGroup

open class ToggleGroup

A ToggleGroup may be set as an attribute in ToggleButton or RadioButton.

All Buttons that keep the same instance of a ToggleGroup belong to that ToggleGroup. Only one Button may be selected in a ToggleGroup. This means whenever a Button changes its selected state to true, all other Buttons in the same ToggleGroup get deselected.

An exception to this rule is, whenever a new ToggleButton or RadioButton that is currently selected gets added to the ToggleGroup.

See also

Constructors

Link copied to clipboard
fun ToggleGroup()

Creates a ToggleGroup.