Skip to content

PixelUI.RadioButton

Extends: PixelUI.Widget

A radio button widget for exclusive selection within a group. Only one radio button in a group can be selected at a time.

Properties

NameTypeDescription
labelstringLabel text displayed next to the radio button
valueanyValue associated with this radio button
groupstring?Group identifier for exclusive selection
selectedbooleanWhether this radio button is selected
focusBgPixelUI.Color?Background color when focused
focusFgPixelUI.Color?Foreground color when focused
onChangefun(self:PixelUI.RadioButton,

Methods

new

lua
new()

_registerWithGroup

lua
_registerWithGroup()

_unregisterFromGroup

lua
_unregisterFromGroup()

_notifyChange

lua
_notifyChange()

_applySelection

lua
_applySelection()

setLabel

lua
setLabel()

setValue

lua
setValue()

getValue

lua
getValue()

setGroup

lua
setGroup()

getGroup

lua
getGroup()

setOnChange

lua
setOnChange()

setSelected

lua
setSelected()

isSelected

lua
isSelected()

_activate

lua
_activate()

draw

lua
draw()

handleEvent

lua
handleEvent()

Released under the MIT License.