[patch] Small fix to bonobo-ui-config-widget



Hi,

The toolbar style has four possible settings (icon, text, both and
both_horiz) but currently the config widget only supports three.  And
the priority text option really sets the style to text only.  

Here are two patches to fix those problems: one of them simply fixes the
config widget to set both_horiz instead of text; and the other adds
another option to the radio group.  I did both because we are in UI
freeze and the second obviously changes the UI.

HTH,
Gustavo


? autom4te.cache
? libbonoboui.config.patch
? libbonoboui.simple.patch
? stamp-h1
? bonobo/bonobo-ui-config-widget.c.complete
? bonobo/bonobo-ui-config-widget.c.simple
? doc/api/Makefile.in
Index: bonobo/bonobo-ui-config-widget.c
===================================================================
RCS file: /cvs/gnome/libbonoboui/bonobo/bonobo-ui-config-widget.c,v
retrieving revision 1.16
diff -u -r1.16 bonobo-ui-config-widget.c
--- bonobo/bonobo-ui-config-widget.c	5 Mar 2002 15:19:05 -0000	1.16
+++ bonobo/bonobo-ui-config-widget.c	21 May 2002 23:23:17 -0000
@@ -220,7 +220,7 @@
 		value = "both";
 
 	else if (button == config->priv->priority_text)
-		value = "text";
+		value = "both_horiz";
 
 	else
 		g_warning ("Unknown look selection");
? autom4te.cache
? libbonoboui.config.patch
? stamp-h1
? bonobo/bonobo-ui-config-widget.c.simple
? doc/api/Makefile.in
Index: bonobo/bonobo-ui-config-widget.c
===================================================================
RCS file: /cvs/gnome/libbonoboui/bonobo/bonobo-ui-config-widget.c,v
retrieving revision 1.16
diff -u -r1.16 bonobo-ui-config-widget.c
--- bonobo/bonobo-ui-config-widget.c	5 Mar 2002 15:19:05 -0000	1.16
+++ bonobo/bonobo-ui-config-widget.c	21 May 2002 23:20:57 -0000
@@ -36,6 +36,7 @@
 	GtkWidget    *tooltips;
 
 	GtkWidget    *icon;
+	GtkWidget    *text;
 	GtkWidget    *icon_and_text;
 	GtkWidget    *priority_text;
 
@@ -81,6 +82,10 @@
 		gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (config->priv->icon_and_text), TRUE);
 		break;
 
+	case BONOBO_UI_TOOLBAR_STYLE_TEXT_ONLY:
+		gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (config->priv->text), TRUE);
+		break;
+		
 	case BONOBO_UI_TOOLBAR_STYLE_PRIORITY_TEXT:
 		gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (config->priv->priority_text), TRUE);
 		break;
@@ -219,9 +224,12 @@
 	else if (button == config->priv->icon_and_text)
 		value = "both";
 
-	else if (button == config->priv->priority_text)
+	else if (button == config->priv->text)
 		value = "text";
 
+	else if (button == config->priv->priority_text)
+		value = "both_horiz";
+
 	else
 		g_warning ("Unknown look selection");
 	
@@ -257,7 +265,7 @@
 			  (GtkAttachOptions) (GTK_FILL), 0, 0);
 
 	frame6 = gtk_frame_new (_("Visible"));
-	gtk_box_pack_start (GTK_BOX (vbox6), frame6, TRUE, TRUE, 0);
+	gtk_box_pack_start (GTK_BOX (vbox6), frame6, FALSE, FALSE, 0);
 
 	vbox7 = gtk_vbox_new (FALSE, 0);
 	gtk_container_add (GTK_CONTAINER (frame6), vbox7);
@@ -322,6 +330,12 @@
 			  G_CALLBACK (look_cb), config);
 	look_group = gtk_radio_button_get_group (GTK_RADIO_BUTTON (priv->icon_and_text));
 	gtk_box_pack_start (GTK_BOX (vbox5), priv->icon_and_text, FALSE, FALSE, 0);
+
+	priv->text = gtk_radio_button_new_with_mnemonic (look_group, _("Text only"));
+	g_signal_connect (priv->text, "clicked",
+			  G_CALLBACK (look_cb), config);
+	look_group = gtk_radio_button_get_group (GTK_RADIO_BUTTON (priv->text));
+	gtk_box_pack_start (GTK_BOX (vbox5), priv->text, FALSE, FALSE, 0);
 
 	priv->priority_text = gtk_radio_button_new_with_mnemonic (look_group, _("_Priority text only"));
 	g_signal_connect (priv->priority_text, "clicked",


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