[Xfce4-commits] [apps/xfce4-notifyd] 01/01: Improve layout of buttons in notification windows
noreply at xfce.org
noreply at xfce.org
Sat Oct 28 01:34:38 CEST 2017
This is an automated email from the git hooks/post-receive script.
o c h o s i p u s h e d a c o m m i t t o b r a n c h m a s t e r
in repository apps/xfce4-notifyd.
commit df65e86ea51088e5b690349fb2482db435590582
Author: Simon Steinbeiss <simon.steinbeiss at elfenbeinturm.at>
Date: Sat Oct 28 01:34:18 2017 +0200
Improve layout of buttons in notification windows
---
xfce4-notifyd/xfce-notify-window.c | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
diff --git a/xfce4-notifyd/xfce-notify-window.c b/xfce4-notifyd/xfce-notify-window.c
index 807422c..1a8f56c 100644
--- a/xfce4-notifyd/xfce-notify-window.c
+++ b/xfce4-notifyd/xfce-notify-window.c
@@ -173,7 +173,7 @@ static void
xfce_notify_window_init(XfceNotifyWindow *window)
{
GdkScreen *screen;
- GtkWidget *tophbox, *vbox;
+ GtkWidget *topvbox, *tophbox, *vbox;
gint screen_width;
gdouble padding = DEFAULT_PADDING;
#if GTK_CHECK_VERSION (3, 22, 0)
@@ -228,11 +228,15 @@ xfce_notify_window_init(XfceNotifyWindow *window)
"padding", &padding,
NULL);
- tophbox = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0);
+ topvbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, padding / 2);
+ gtk_box_set_homogeneous (GTK_BOX (topvbox), FALSE);
+ gtk_container_set_border_width (GTK_CONTAINER(topvbox), padding);
+ gtk_widget_show (topvbox);
+ gtk_container_add (GTK_CONTAINER(window), topvbox);
+ tophbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
gtk_box_set_homogeneous (GTK_BOX (tophbox), FALSE);
- gtk_container_set_border_width(GTK_CONTAINER(tophbox), padding);
- gtk_widget_show(tophbox);
- gtk_container_add(GTK_CONTAINER(window), tophbox);
+ gtk_widget_show (tophbox);
+ gtk_container_add (GTK_CONTAINER(topvbox), tophbox);
window->icon_box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_set_border_width(GTK_CONTAINER(window->icon_box), 0);
@@ -277,9 +281,9 @@ xfce_notify_window_init(XfceNotifyWindow *window)
window->button_box = gtk_button_box_new(GTK_ORIENTATION_HORIZONTAL);
gtk_button_box_set_layout(GTK_BUTTON_BOX(window->button_box),
GTK_BUTTONBOX_END);
- gtk_box_set_spacing(GTK_BOX(window->button_box), padding / 2);
- gtk_box_set_homogeneous(GTK_BOX(window->button_box), FALSE);
- gtk_box_pack_start(GTK_BOX(vbox), window->button_box, FALSE, FALSE, 0);
+ gtk_box_set_spacing (GTK_BOX(window->button_box), padding / 2);
+ gtk_box_set_homogeneous (GTK_BOX(window->button_box), FALSE);
+ gtk_box_pack_end (GTK_BOX(topvbox), window->button_box, FALSE, FALSE, 0);
}
static void
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list