Combobox object

The Combobox widget lets users pick an item from a dropdown list or enter custom text

Event Description
Combobox:onChange() Event fired when Combobox has modified the Combobox text
Combobox:onClick() Event occurs when the user clicks on the Combobox
Combobox:onCreate() Event fired when Combobox has just been created
Combobox:onDrop() Event fired when the Combobox received a drag and drop content
Combobox:onHide() Event fired when the Combobox is hidden
Combobox:onSelect() Event fired when the user selects an item in the Combobox
Combobox:onShow() Event fired when the Combobox is shown
Property Description Access Type
Combobox.align Align the Combobox relative to its parent readwrite boolean
Combobox.allowdrop Controls whether the Combobox is a drag and drop target readwrite boolean
Combobox.count Get the count of items in the Combobox readonly number
Combobox.cursor Get/set the image of the mouse cursor as it hovers over the Combobox readwrite string
Combobox.enabled Controls whether the Combobox responds to mouse and other events readwrite boolean
Combobox.font Get/set the Combobox font readwrite string
Combobox.fontsize Get/set the Combobox font size readwrite number
Combobox.fontstyle Get/set the Combobox font style readwrite table
Combobox.height Get/set the Combobox's height readwrite number
Combobox.items Get/set the list of the Combobox items readwrite table
Combobox.parent Get the Combobox's parent widget readonly
Combobox.selected Get/set the selected Combobox item readwrite
Combobox.style Get/set the Combobox style readwrite string
Combobox.text Get/set the Combobox text content readwrite string
Combobox.visible Controls whether the Combobox appears on screen readwrite boolean
Combobox.width Get/set the Combobox's width readwrite number
Combobox.x Get/set the Combobox's horizontal position readwrite number
Combobox.y Get/set the Combobox's vertical position readwrite number
Methods Description Return value
Combobox:add() Add an item to the Combobox
Combobox:center() Centers the Combobox on the parent widget -
Combobox:clear() Remove all items from the Combobox -
Combobox:constructor() Combobox object constructor
Combobox:hide() Hides the Combobox -
Combobox:remove() Remove an item from the Combobox -
Combobox:show() Shows the Combobox -
Combobox:toback() Puts the widget to the back -
Combobox:tofront() Brings the widget in front -