diff options
author | Marvin Borner | 2020-10-28 18:22:38 +0100 |
---|---|---|
committer | Marvin Borner | 2020-10-28 18:22:38 +0100 |
commit | 913764dfca7b546719a004c17c081ca9f42ba13e (patch) | |
tree | 1f13680cb392d16e3d3d3f336475e03598619e24 /libgui/inc | |
parent | 197ea3ca20879b29fca41a07cf43e5b04b9c5083 (diff) |
Added container functions
And some other stuff - as always in this highly professional project
Diffstat (limited to 'libgui/inc')
-rw-r--r-- | libgui/inc/gui.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/libgui/inc/gui.h b/libgui/inc/gui.h index 8149381..14f2e4e 100644 --- a/libgui/inc/gui.h +++ b/libgui/inc/gui.h @@ -14,6 +14,13 @@ enum window_event_type { GUI_KEYBOARD = GFX_MAX + 1, GUI_MOUSE, GUI_MAX }; enum element_type { GUI_TYPE_CONTAINER, GUI_TYPE_BUTTON, GUI_TYPE_TEXTBOX }; +enum container_flags { SPLIT }; + +struct element_container { + u32 color_bg; + enum container_flags flags; +}; + struct element_button { char *text; u32 color_fg; @@ -59,8 +66,9 @@ struct gui_event_mouse { struct element *gui_init(const char *title, u32 width, u32 height); void gui_event_loop(struct element *container); -struct element_button *gui_add_button(struct element *container, int x, int y, - enum font_type font_type, char *text, u32 color_bg, - u32 color_fg); +struct element *gui_add_button(struct element *container, int x, int y, enum font_type font_type, + char *text, u32 color_bg, u32 color_fg); +struct element *gui_add_container(struct element *container, int x, int y, u32 width, u32 height, + u32 color_bg); #endif |