patch to make stock buttons look "nicer"



this patch has stock button layout match that of gnome 1, which i find
to look a lot nicer.  it also makes running gnome 1 and gtk 2 based apps
look less weird when run next to each other.  can i commit it?

jacob
-- 
"OOH!!!  Look at me!!  I'm Jacob Berkman!  I have a witty .signature
 that nobody fully appreciates but myself!!"  -- Anonymous


Index: gtkbutton.c
===================================================================
RCS file: /cvs/gnome/gtk+/gtk/gtkbutton.c,v
retrieving revision 1.68
diff -u -r1.68 gtkbutton.c
--- gtkbutton.c	2001/09/03 06:45:17	1.68
+++ gtkbutton.c	2001/09/08 16:56:26
@@ -405,6 +405,7 @@
   GtkWidget *label;
   GtkWidget *image;
   GtkWidget *hbox;
+  GtkWidget *outer_hbox;
 
   if (!button->constructed)
     return;
@@ -425,13 +426,16 @@
       gtk_label_set_mnemonic_widget (GTK_LABEL (label), GTK_WIDGET (button));
       
       image = gtk_image_new_from_stock (button->label_text, GTK_ICON_SIZE_BUTTON);
-      hbox = gtk_hbox_new (FALSE, 1);
+      hbox = gtk_hbox_new (FALSE, 2);
 
       gtk_box_pack_start (GTK_BOX (hbox), image, FALSE, FALSE, 0);
-      gtk_box_pack_end (GTK_BOX (hbox), label, TRUE, TRUE, 0);
+      gtk_box_pack_end (GTK_BOX (hbox), label, FALSE, FALSE, 0);
+
+      outer_hbox = gtk_hbox_new (FALSE, 0);
+      gtk_box_pack_start (GTK_BOX (outer_hbox), hbox, TRUE, FALSE, 0);
       
-      gtk_container_add (GTK_CONTAINER (button), hbox);
-      gtk_widget_show_all (hbox);
+      gtk_container_add (GTK_CONTAINER (button), outer_hbox);
+      gtk_widget_show_all (outer_hbox);
 
       return;
     }




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