diff -r 5223de7979e2 -r d51e334c1439 ui/gtk/container.c --- a/ui/gtk/container.c Thu Aug 20 17:14:27 2015 +0200 +++ b/ui/gtk/container.c Sat Oct 10 15:29:31 2015 +0200 @@ -123,6 +123,13 @@ ct->layout.newline = FALSE; } + if(ct->layout.fill != UI_LAYOUT_UNDEFINED) { + fill = ui_lb2bool(ct->layout.fill); + } + if(fill) { + gtk_widget_set_hexpand(widget, TRUE); + } + gtk_grid_attach(GTK_GRID(ct->widget), widget, grid->x, grid->y, 1, 1); grid->x++; @@ -202,10 +209,17 @@ } UIWIDGET ui_grid(UiObject *obj) { + return ui_grid_sp(obj, 0, 0); +} + +UIWIDGET ui_grid_sp(UiObject *obj, int columnspacing, int rowspacing) { UiContainer *ct = uic_get_current_container(obj); #ifdef UI_GTK3 GtkWidget *grid = gtk_grid_new(); + gtk_grid_set_column_spacing(GTK_GRID(grid), columnspacing); + gtk_grid_set_row_spacing(GTK_GRID(grid), rowspacing); + #elif defined(UI_GTK2) GtkWidget *grid = gtk_table_new(1, 1, FALSE); #endif