Macaw OS C reference

Buttons, lists and dialogs

#include <macawui.h>

#include <macawui.h> for the toolkit of buttons, sliders, text boxes and lists, and for the dialogs. The widgets are immediate mode: you don't make them once and keep them, but call them every frame from your _draw function, between ui_begin and ui_finish. Each one draws itself and returns 1 in the frame it's clicked or changed, and the values it changes live in your program. Apps explains the toolkit, and C says how C programs work.

Modules

The frame and layout
ui_begin, ui_beginex, ui_finish, ui_row, ui_space, ui_group and more
Widgets
ui_label, ui_heading, ui_separator, ui_button, ui_checkbox, ui_radio and more
The keyboard's focus, and where widgets are
ui_focus, ui_setfocus, ui_typing, ui_rect
Dialogs
Dialogs don't pause your program.
Drag and drop
ondrop, canpickfiles, pickfiles, startdrag, putondesktop