[tepl] Notebook: expand horizontally and vertically



commit a0cae57f5558ffa9501dd9d042c1459c4d540255
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Sun Jul 23 15:23:31 2017 +0200

    Notebook: expand horizontally and vertically

 tepl/tepl-notebook.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/tepl/tepl-notebook.c b/tepl/tepl-notebook.c
index bc5935c..66e5300 100644
--- a/tepl/tepl-notebook.c
+++ b/tepl/tepl-notebook.c
@@ -297,6 +297,14 @@ static void
 tepl_notebook_init (TeplNotebook *notebook)
 {
        notebook->priv = tepl_notebook_get_instance_private (notebook);
+
+       /* The statusbar must always be at the bottom of the window (if there is
+        * a statusbar). More generally, the notebook is the main part of the
+        * window, so it needs to be expanded, to push other widgets on the
+        * sides, even if the notebook is empty.
+        */
+       gtk_widget_set_hexpand (GTK_WIDGET (notebook), TRUE);
+       gtk_widget_set_vexpand (GTK_WIDGET (notebook), TRUE);
 }
 
 /**


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]