]> de.git.xonotic.org Git - xonotic/netradiant.git/blobdiff - libs/uilib/uilib.h
GTK: wrap gtk_table_attach
[xonotic/netradiant.git] / libs / uilib / uilib.h
index f02a51727939bc8ed1fa7f98b04b7e78065d5546..fe03b9d8cebc411f2c2375bf485e11b7c827c93e 100644 (file)
@@ -439,9 +439,24 @@ namespace ui {
     ,
     );
 
+    struct TableAttach {
+        unsigned int left, right, top, bottom;
+    };
+
+    struct TableAttachOptions {
+        // todo: type safety
+        unsigned int x, y;
+    };
+
+    struct TablePadding {
+        unsigned int x, y;
+    };
+
     WRAP(Table, Container, _GtkTable, (),
          Table(std::size_t rows, std::size_t columns, bool homogenous);
     ,
+         // 5 = expand | fill
+         void attach(Widget child, TableAttach attach, TableAttachOptions options = {5, 5}, TablePadding padding = {0, 0});
     );
 
     WRAP(TextView, Container, _GtkTextView, (),