diff src/gtkimhtmltoolbar.c @ 10080:8e6329b8dcc1

[gaim-migrate @ 11062] A final change for today. This puts the conversation formatting toolbar in the same frame as the entry widget. It more closely associates the toolbar with the entry and also looks cooler. committer: Tailor Script <tailor@pidgin.im>
author Sean Egan <seanegan@gmail.com>
date Sun, 03 Oct 2004 22:59:26 +0000
parents ab5db2c5da79
children 9c174a7f9afc
line wrap: on
line diff
--- a/src/gtkimhtmltoolbar.c	Sun Oct 03 20:47:58 2004 +0000
+++ b/src/gtkimhtmltoolbar.c	Sun Oct 03 22:59:26 2004 +0000
@@ -33,7 +33,7 @@
 #include "gtkimhtmltoolbar.h"
 #include "gtkutils.h"
 
-static GtkVBoxClass *parent_class = NULL;
+static GtkHBoxClass *parent_class = NULL;
 
 static void do_bold(GtkWidget *bold, GtkIMHtmlToolbar *toolbar)
 {
@@ -849,22 +849,13 @@
 	GObjectClass   *gobject_class;
 	object_class = (GtkObjectClass*) class;
 	gobject_class = (GObjectClass*) class;
-	parent_class = gtk_type_class(GTK_TYPE_VBOX);
-	/*	signals[URL_CLICKED] = g_signal_new(url_clicked",
-						G_TYPE_FROM_CLASS(gobject_class),
-						G_SIGNAL_RUN_FIRST,
-						G_STRUCT_OFFSET(GtkIMHtmlClass, url_clicked),
-						NULL,
-						0,
-						g_cclosure_marshal_VOID__POINTER,
-						G_TYPE_NONE, 1,
-						G_TYPE_POINTER);*/
+	parent_class = gtk_type_class(GTK_TYPE_HBOX);
 	gobject_class->finalize = gtk_imhtmltoolbar_finalize;
 }
 
 static void gtk_imhtmltoolbar_init (GtkIMHtmlToolbar *toolbar)
 {
-	GtkWidget *hbox;
+	GtkWidget *hbox = GTK_HBOX(toolbar);
 	GtkWidget *button;
 	GtkWidget *sep;
 	GtkSizeGroup *sg;
@@ -878,16 +869,10 @@
 	toolbar->image_dialog = NULL;
 
 	toolbar->tooltips = gtk_tooltips_new();
-
+	
+	gtk_box_set_spacing(GTK_BOX(toolbar), 6);
 	sg = gtk_size_group_new(GTK_SIZE_GROUP_BOTH);
 
-	sep = gtk_hseparator_new();
-	gtk_box_pack_start(GTK_BOX(toolbar), sep, FALSE, FALSE, 0);
-	gtk_widget_show(sep);
-
-	hbox = gtk_hbox_new(FALSE, 6);
-	gtk_box_pack_start(GTK_BOX(toolbar), hbox, FALSE, FALSE, 0);
-
 	/* Bold */
 	button = gaim_pixbuf_toolbar_button_from_stock(GTK_STOCK_BOLD);
 	gtk_size_group_add_widget(sg, button);
@@ -1026,10 +1011,6 @@
 
 	toolbar->smiley = button;
 
-
-	sep = gtk_hseparator_new();
-	gtk_box_pack_start(GTK_BOX(toolbar), sep, FALSE, FALSE, 0);
-	gtk_widget_show(sep);
 	toolbar->sml = NULL;
 	gtk_widget_show_all(hbox);
 }
@@ -1056,7 +1037,7 @@
 			(GInstanceInitFunc) gtk_imhtmltoolbar_init
 		};
 
-		imhtmltoolbar_type = g_type_register_static(GTK_TYPE_VBOX,
+		imhtmltoolbar_type = g_type_register_static(GTK_TYPE_HBOX,
 				"GtkIMHtmlToolbar", &imhtmltoolbar_info, 0);
 	}