ui/gtk/container.h

changeset 65
4697592e24ba
parent 59
eb6611be50c7
child 66
8d490d97aab8
equal deleted inserted replaced
64:6ef2c7f73a30 65:4697592e24ba
51 UI_LAYOUT_FALSE, 51 UI_LAYOUT_FALSE,
52 }; 52 };
53 53
54 struct UiLayout { 54 struct UiLayout {
55 UiLayoutBool fill; 55 UiLayoutBool fill;
56 UiBool newline;
57 char *label;
56 }; 58 };
57 59
58 struct UiContainer { 60 struct UiContainer {
59 GtkWidget *widget; 61 GtkWidget *widget;
60 void (*add)(UiContainer*, GtkWidget*, UiBool); 62 void (*add)(UiContainer*, GtkWidget*, UiBool);
64 typedef struct UiBoxContainer { 66 typedef struct UiBoxContainer {
65 UiContainer container; 67 UiContainer container;
66 UiBool has_fill; 68 UiBool has_fill;
67 } UiBoxContainer; 69 } UiBoxContainer;
68 70
71 typedef struct UiGridContainer {
72 UiContainer container;
73 int x;
74 int y;
75 } UiGridContainer;
76
77 typedef struct UiTabViewContainer {
78 UiContainer container;
79 } UiTabViewContainer;
80
69 GtkWidget* ui_gtk_vbox_new(); 81 GtkWidget* ui_gtk_vbox_new();
70 GtkWidget* ui_gtk_hbox_new(); 82 GtkWidget* ui_gtk_hbox_new();
71 83
72 UiContainer* ui_frame_container(UiObject *obj, GtkWidget *frame); 84 UiContainer* ui_frame_container(UiObject *obj, GtkWidget *frame);
73 void ui_frame_container_add(UiContainer *ct, GtkWidget *widget, UiBool fill); 85 void ui_frame_container_add(UiContainer *ct, GtkWidget *widget, UiBool fill);
74 86
75 UiContainer* ui_box_container(UiObject *obj, GtkWidget *box); 87 UiContainer* ui_box_container(UiObject *obj, GtkWidget *box);
76 void ui_box_container_add(UiContainer *ct, GtkWidget *widget, UiBool fill); 88 void ui_box_container_add(UiContainer *ct, GtkWidget *widget, UiBool fill);
89
90 UiContainer* ui_grid_container(UiObject *obj, GtkWidget *grid);
91 void ui_grid_container_add(UiContainer *ct, GtkWidget *widget, UiBool fill);
92
93 UiContainer* ui_tabview_container(UiObject *obj, GtkWidget *tabview);
94 void ui_tabview_container_add(UiContainer *ct, GtkWidget *widget, UiBool fill);
77 95
78 void ui_split_container_add1(UiContainer *ct, GtkWidget *widget, UiBool fill); 96 void ui_split_container_add1(UiContainer *ct, GtkWidget *widget, UiBool fill);
79 void ui_split_container_add2(UiContainer *ct, GtkWidget *widget, UiBool fill); 97 void ui_split_container_add2(UiContainer *ct, GtkWidget *widget, UiBool fill);
80 98
81 99

mercurial