773 |
773 |
774 #ifdef UI_QT |
774 #ifdef UI_QT |
775 |
775 |
776 void application_startup(UiEvent *event, void *data) { |
776 void application_startup(UiEvent *event, void *data) { |
777 UiObject *obj = ui_window("My Window", NULL); |
777 UiObject *obj = ui_window("My Window", NULL); |
778 ui_button(obj, .label = "Button 1"); |
778 ui_grid(obj, .margin = 10, .columnspacing = 10, .rowspacing = 10) { |
779 ui_button(obj, .label = "Button 2"); |
779 ui_button(obj, .label = "Button 1"); |
780 ui_button(obj, .label = "Button 3"); |
780 ui_button(obj, .label = "Button 2"); |
|
781 ui_newline(obj); |
|
782 |
|
783 ui_button(obj, .label = "Button 3", .colspan = 2); |
|
784 } |
781 ui_show(obj); |
785 ui_show(obj); |
782 } |
786 } |
783 |
787 |
784 int main(int argc, char **argv) { |
788 int main(int argc, char **argv) { |
785 ui_init("app1", 0, NULL); |
789 ui_init("app1", 0, NULL); |