summaryrefslogtreecommitdiff
path: root/plugins/gtk+
diff options
context:
space:
mode:
authorJuan Pablo Ugarte <juanpablougarte@gmail.com>2020-09-21 19:37:44 -0300
committerJuan Pablo Ugarte <juanpablougarte@gmail.com>2020-09-25 16:31:27 -0300
commitccd09e9d86a52af5f720b2e79bd4f2ca7a1f1ddd (patch)
tree258a63f4c5dad2b3edc89d610d8b5235de7d7f9f /plugins/gtk+
parentfe428062ac9713202a563f055709ff98dd55ac6f (diff)
downloadglade-ccd09e9d86a52af5f720b2e79bd4f2ca7a1f1ddd.tar.gz
GladeCommand: adjust Box and Grid size automatically
Adjust container size in create and paste command. Properly fix issue #470 "Widgets of type need placeholders to add children"
Diffstat (limited to 'plugins/gtk+')
-rw-r--r--plugins/gtk+/glade-gtk-container.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/plugins/gtk+/glade-gtk-container.c b/plugins/gtk+/glade-gtk-container.c
index 971afa02..eb6552a3 100644
--- a/plugins/gtk+/glade-gtk-container.c
+++ b/plugins/gtk+/glade-gtk-container.c
@@ -83,6 +83,9 @@ glade_gtk_container_add_verify (GladeWidgetAdaptor *adaptor,
return FALSE;
}
+ else if (GTK_IS_BOX (container) || GTK_IS_GRID (container))
+ /* GtkBox and GtkGrid size is adjusted automaticaly in GladeCommand */
+ return TRUE;
else if (GLADE_WIDGET_ADAPTOR_USE_PLACEHOLDERS (adaptor) &&
/* Special case GtkBin since Windows can hace a placeholder in the titlebar */
((GTK_IS_BIN (container) &&