121 #define ui_scrolledwindow0(obj) for(ui_scrolledwindow_create(obj, (UiFrameArgs){ 0 });ui_container_finish(obj);ui_container_begin_close(obj)) |
121 #define ui_scrolledwindow0(obj) for(ui_scrolledwindow_create(obj, (UiFrameArgs){ 0 });ui_container_finish(obj);ui_container_begin_close(obj)) |
122 #define ui_tabview0(obj) for(ui_tabview_create(obj, (UiTabViewArgs){ 0 });ui_container_finish(obj);ui_container_begin_close(obj)) |
122 #define ui_tabview0(obj) for(ui_tabview_create(obj, (UiTabViewArgs){ 0 });ui_container_finish(obj);ui_container_begin_close(obj)) |
123 |
123 |
124 #define ui_tab(obj, label) for(ui_tab_create(obj, label);ui_container_finish(obj);ui_container_begin_close(obj)) |
124 #define ui_tab(obj, label) for(ui_tab_create(obj, label);ui_container_finish(obj);ui_container_begin_close(obj)) |
125 |
125 |
126 void ui_end(UiObject *obj); |
126 UIEXPORT void ui_end(UiObject *obj); |
127 |
127 |
128 UIWIDGET ui_vbox_create(UiObject *obj, UiContainerArgs args); |
128 UIEXPORT UIWIDGET ui_vbox_create(UiObject *obj, UiContainerArgs args); |
129 UIWIDGET ui_hbox_create(UiObject *obj, UiContainerArgs args); |
129 UIEXPORT UIWIDGET ui_hbox_create(UiObject *obj, UiContainerArgs args); |
130 UIWIDGET ui_grid_create(UiObject *obj, UiContainerArgs args); |
130 UIEXPORT UIWIDGET ui_grid_create(UiObject *obj, UiContainerArgs args); |
131 UIWIDGET ui_frame_create(UiObject* obj, UiFrameArgs args); |
131 UIEXPORT UIWIDGET ui_frame_create(UiObject* obj, UiFrameArgs args); |
132 UIWIDGET ui_expander_create(UiObject* obj, UiFrameArgs args); |
132 UIEXPORT UIWIDGET ui_expander_create(UiObject* obj, UiFrameArgs args); |
133 UIWIDGET ui_scrolledwindow_create(UiObject* obj, UiFrameArgs args); |
133 UIEXPORT UIWIDGET ui_scrolledwindow_create(UiObject* obj, UiFrameArgs args); |
134 UIWIDGET ui_tabview_create(UiObject* obj, UiTabViewArgs args); |
134 UIEXPORT UIWIDGET ui_tabview_create(UiObject* obj, UiTabViewArgs args); |
135 |
135 |
136 void ui_tab_create(UiObject* obj, const char* title); |
136 UIEXPORT void ui_tab_create(UiObject* obj, const char* title); |
137 |
137 |
138 UIWIDGET ui_scrolledwindow_deprecated(UiObject *obj); |
138 UIEXPORT UIWIDGET ui_scrolledwindow_deprecated(UiObject *obj); |
139 |
139 |
140 UIWIDGET ui_sidebar(UiObject *obj); |
140 UIEXPORT UIWIDGET ui_sidebar(UiObject *obj); |
141 |
141 |
142 UIWIDGET ui_hsplitpane(UiObject *obj, int max); |
142 UIEXPORT UIWIDGET ui_hsplitpane(UiObject *obj, int max); |
143 UIWIDGET ui_vsplitpane(UiObject *obj, int max); |
143 UIEXPORT UIWIDGET ui_vsplitpane(UiObject *obj, int max); |
144 |
144 |
145 UIWIDGET ui_tabview_deprecated(UiObject *obj); |
145 UIEXPORT UIWIDGET ui_tabview_deprecated(UiObject *obj); |
146 |
146 |
147 void ui_select_tab(UIWIDGET tabview, int tab); |
147 UIEXPORT void ui_select_tab(UIWIDGET tabview, int tab); |
148 |
148 |
149 // box container layout functions |
149 // box container layout functions |
150 void ui_layout_fill(UiObject *obj, UiBool fill); |
150 UIEXPORT void ui_layout_fill(UiObject *obj, UiBool fill); |
151 // grid container layout functions |
151 // grid container layout functions |
152 void ui_layout_hexpand(UiObject *obj, UiBool expand); |
152 UIEXPORT void ui_layout_hexpand(UiObject *obj, UiBool expand); |
153 void ui_layout_vexpand(UiObject *obj, UiBool expand); |
153 UIEXPORT void ui_layout_vexpand(UiObject *obj, UiBool expand); |
154 void ui_layout_width(UiObject *obj, int width); |
154 UIEXPORT void ui_layout_width(UiObject *obj, int width); |
155 void ui_layout_height(UiObject* obj, int width); |
155 UIEXPORT void ui_layout_height(UiObject* obj, int width); |
156 void ui_layout_colspan(UiObject *obj, int cols); |
156 UIEXPORT void ui_layout_colspan(UiObject *obj, int cols); |
157 void ui_layout_rowspan(UiObject* obj, int rows); |
157 UIEXPORT void ui_layout_rowspan(UiObject* obj, int rows); |
158 void ui_newline(UiObject *obj); |
158 UIEXPORT void ui_newline(UiObject *obj); |
159 |
159 |
160 |
160 |
161 UiTabbedPane* ui_tabbed_document_view(UiObject *obj); |
161 UIEXPORT UiTabbedPane* ui_tabbed_document_view(UiObject *obj); |
162 |
162 |
163 UiObject* ui_document_tab(UiTabbedPane *view); |
163 UIEXPORT UiObject* ui_document_tab(UiTabbedPane *view); |
164 |
164 |
165 |
165 |
166 /* used for macro */ |
166 /* used for macro */ |
167 void ui_container_begin_close(UiObject *obj); |
167 UIEXPORT void ui_container_begin_close(UiObject *obj); |
168 int ui_container_finish(UiObject *obj); |
168 UIEXPORT int ui_container_finish(UiObject *obj); |
169 |
169 |
170 #define UI_APPLY_LAYOUT1(obj, args) \ |
170 #define UI_APPLY_LAYOUT1(obj, args) \ |
171 if(args.fill != UI_DEFAULT) ui_layout_fill(obj, args.fill == UI_ON ? 1 : 0 ); \ |
171 if(args.fill != UI_DEFAULT) ui_layout_fill(obj, args.fill == UI_ON ? 1 : 0 ); \ |
172 if(args.hexpand) ui_layout_hexpand(obj, 1); \ |
172 if(args.hexpand) ui_layout_hexpand(obj, 1); \ |
173 if(args.vexpand) ui_layout_vexpand(obj, 1); \ |
173 if(args.vexpand) ui_layout_vexpand(obj, 1); \ |