GUI Combo
App: apps/gui_combo/
Demonstrates all three comboBegin* variants: a text-item dropdown, a color-swatch dropdown with an embedded colorPicker, and a symbol (icon) dropdown.
Run from root
Section titled “Run from root”% ./plume3d gui_comboWhat it shows
Section titled “What it shows”- Label combo — standard item list;
comboItemLabelreturnstrueon selection. - Color combo — opens with a color swatch; embeds a
colorPickerinside the dropdown. Colors are0–255. - Symbol combo — opens with a Nuklear symbol icon; items are
comboItemSymbolLabel.
Key patterns
Section titled “Key patterns”// Label comboif (Gui.comboBeginLabel(_items[_selected], 200, 200)) { Gui.layoutRowDynamic(25, 1) for (i in 0..._items.count) { if (Gui.comboItemLabel(_items[i], 17)) _selected = i } Gui.comboEnd()}
// Color combo with inline picker (colors 0-255)if (Gui.comboBeginColor(_r, _g, _b, _a, 200, 300)) { Gui.layoutRowDynamic(120, 1) var result = Gui.colorPicker(_r, _g, _b, _a, 1) // returns [r,g,b,a] 0-255 _r = result[0] _g = result[1] _b = result[2] Gui.comboEnd()}