32 #include "toolkit.h" |
32 #include "toolkit.h" |
33 #include "window.h" |
33 #include "window.h" |
34 |
34 |
35 #include <string.h> |
35 #include <string.h> |
36 #include <QBoxLayout> |
36 #include <QBoxLayout> |
|
37 #include <QGridLayout> |
37 |
38 |
38 #define ui_lb2bool(b) ((b) == UI_LAYOUT_TRUE ? TRUE : FALSE) |
39 #define ui_lb2bool(b) ((b) == UI_LAYOUT_TRUE ? TRUE : FALSE) |
39 #define ui_bool2lb(b) ((b) ? UI_LAYOUT_TRUE : UI_LAYOUT_FALSE) |
40 #define ui_bool2lb(b) ((b) ? UI_LAYOUT_TRUE : UI_LAYOUT_FALSE) |
40 #define ui_reset_layout(layout) memset(&(layout), 0, sizeof(UiLayout)) |
41 #define ui_reset_layout(layout) memset(&(layout), 0, sizeof(UiLayout)) |
41 |
42 |
67 UiBoxContainer(QBoxLayout *box); |
69 UiBoxContainer(QBoxLayout *box); |
68 |
70 |
69 virtual void add(QWidget *widget, bool fill); |
71 virtual void add(QWidget *widget, bool fill); |
70 }; |
72 }; |
71 |
73 |
|
74 class UiGridContainer : public UiContainer { |
|
75 public: |
|
76 QGridLayout *grid; |
|
77 int x = 0; |
|
78 int y = 0; |
|
79 QSpacerItem *space = NULL; |
|
80 |
|
81 UiGridContainer(QGridLayout *grid); |
|
82 |
|
83 virtual void add(QWidget *widget, bool fill); |
|
84 }; |
|
85 |
72 #endif /* CONTAINER_H */ |
86 #endif /* CONTAINER_H */ |
73 |
87 |