changeset 41:6281cc38e5ca

Wed Apr 27 15:17:57 2005 John Ellis <johne@verizon.net> * bar_info.c, bar_sort.c: Update for new pref_toolbar_button args. * fullscreen.c, layout.c: Remove use of GDK_HINT_USER_SIZE as we never actually set these dimensions. Increase default size of main window. * layout_util.c: Use GTkToolbar for the main window toolbar. * pixbuf_util.[ch]: Add inline pixbufs for thumb and float icons. * rcfile.c: Add note to config file that it is autogenerated. * typedefs.h: Remove no longer used tooltip in LayoutWindow. * ui_misc.[ch]: pref_toolbar additions. * icons/icon_float.png, icons/icon_thumb.png: Icons in png format. * icons/icon_float.xpm, icons/icon_thumb.xpm: Remove xpm versions. * icons/Makefile.am: Add above icons to inline pixbuf list. ##### Note: GQview CVS on sourceforge is not always up to date, please use ##### ##### an offical release when making enhancements and translation updates. #####
author gqview
date Wed, 27 Apr 2005 19:29:15 +0000
parents dcc04a6a58bf
children 606fcf461a68
files ChangeLog TODO src/bar_info.c src/bar_sort.c src/fullscreen.c src/icons/Makefile.am src/icons/icon_float.png src/icons/icon_float.xpm src/icons/icon_thumb.png src/icons/icon_thumb.xpm src/layout.c src/layout_util.c src/pixbuf_util.c src/pixbuf_util.h src/rcfile.c src/typedefs.h src/ui_misc.c src/ui_misc.h
diffstat 18 files changed, 134 insertions(+), 205 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sat Apr 16 16:26:49 2005 +0000
+++ b/ChangeLog	Wed Apr 27 19:29:15 2005 +0000
@@ -1,3 +1,18 @@
+Wed Apr 27 15:17:57 2005  John Ellis  <johne@verizon.net>
+
+	* bar_info.c, bar_sort.c: Update for new pref_toolbar_button args.
+	* fullscreen.c, layout.c: Remove use of GDK_HINT_USER_SIZE as we
+	never actually set these dimensions. Increase default size of main
+	window.
+	* layout_util.c: Use GTkToolbar for the main window toolbar.
+	* pixbuf_util.[ch]: Add inline pixbufs for thumb and float icons.
+	* rcfile.c: Add note to config file that it is autogenerated.
+	* typedefs.h: Remove no longer used tooltip in LayoutWindow.
+	* ui_misc.[ch]: pref_toolbar additions.
+	* icons/icon_float.png, icons/icon_thumb.png: Icons in png format.
+	* icons/icon_float.xpm, icons/icon_thumb.xpm: Remove xpm versions.
+	* icons/Makefile.am: Add above icons to inline pixbuf list.
+
 Sat Apr 16 12:29:42 2005  John Ellis  <johne@verizon.net>
 
 	* pan-view.c: Add option to ignore symbolic links to folders when
--- a/TODO	Sat Apr 16 16:26:49 2005 +0000
+++ b/TODO	Wed Apr 27 19:29:15 2005 +0000
@@ -57,6 +57,9 @@
    > under consideration:
      > split view
 
+d> fix window size hints not to use USER_SIZE as we do not use gtk_window_resize to set the hint's attribute, and
+   apparently GTK passes in unitialized values for this case (definite programming error, but also a GTK bug?).
+
  > the info dialog is not set as a transient of the calling window, this causes it to be behind
    a full screen window when 'stay above other windows' is enabled.
 
--- a/src/bar_info.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/bar_info.c	Wed Apr 27 19:29:15 2005 +0000
@@ -1115,18 +1115,18 @@
 
 	tbar = pref_toolbar_new(bd->group_box, GTK_TOOLBAR_ICONS);
 
-	pref_toolbar_button(tbar, GTK_STOCK_INDEX, NULL,
+	pref_toolbar_button(tbar, GTK_STOCK_INDEX, NULL, FALSE,
 			_("Edit favorite keywords list."),
 			G_CALLBACK(bar_keyword_edit_cb), bd);
 	pref_toolbar_spacer(tbar);
-	bd->button_set_add = pref_toolbar_button(tbar, GTK_STOCK_ADD, NULL,
+	bd->button_set_add = pref_toolbar_button(tbar, GTK_STOCK_ADD, NULL, FALSE,
 			_("Add keywords to selected files"),
 			G_CALLBACK(bar_info_set_add), bd);
-	bd->button_set_replace = pref_toolbar_button(tbar, GTK_STOCK_CONVERT, NULL,
+	bd->button_set_replace = pref_toolbar_button(tbar, GTK_STOCK_CONVERT, NULL, FALSE,
 			_("Add keywords to selected files, replacing the existing ones."),
 			G_CALLBACK(bar_info_set_replace), bd);
 	pref_toolbar_spacer(tbar);
-	bd->button_save = pref_toolbar_button(tbar, GTK_STOCK_SAVE, NULL,
+	bd->button_save = pref_toolbar_button(tbar, GTK_STOCK_SAVE, NULL, FALSE,
 			_("Save comment now"),
 			G_CALLBACK(bar_info_save), bd);
 
--- a/src/bar_sort.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/bar_sort.c	Wed Apr 27 19:29:15 2005 +0000
@@ -545,7 +545,6 @@
 GtkWidget *bar_sort_new(LayoutWindow *lw)
 {
 	SortData *sd;
-	GtkWidget *button;
 	GtkWidget *buttongrp;
 	GtkWidget *label;
 	GtkWidget *tbar;
@@ -583,43 +582,24 @@
 
 	sd->folder_group = pref_box_new(sd->vbox, FALSE, GTK_ORIENTATION_VERTICAL, 0);
 
-	buttongrp = gtk_radio_button_new_with_label(NULL, _("Copy"));
-	if (sd->action == BAR_SORT_COPY) gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(buttongrp), TRUE);
-	g_signal_connect(G_OBJECT(buttongrp), "clicked",
-			 G_CALLBACK(bar_sort_set_copy_cb), sd);
-	gtk_box_pack_start(GTK_BOX(sd->folder_group), buttongrp, FALSE, FALSE, 0);
-	gtk_widget_show(buttongrp);
-
-	button = gtk_radio_button_new_with_label(gtk_radio_button_get_group(GTK_RADIO_BUTTON(buttongrp)), _("Move"));
-	if (sd->action == BAR_SORT_MOVE) gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), TRUE);
-	g_signal_connect(G_OBJECT(button), "clicked",
-			 G_CALLBACK(bar_sort_set_move_cb), sd);
-	gtk_box_pack_start(GTK_BOX(sd->folder_group), button, FALSE, FALSE, 0);
-	gtk_widget_show(button);
-
-	button = gtk_radio_button_new_with_label(gtk_radio_button_get_group(GTK_RADIO_BUTTON(buttongrp)), _("Link"));
-
-	if (sd->action == BAR_SORT_LINK) gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), TRUE);
-	g_signal_connect(G_OBJECT(button), "clicked",
-			 G_CALLBACK(bar_sort_set_link_cb), sd);
-	gtk_box_pack_start(GTK_BOX(sd->folder_group), button, FALSE, FALSE, 0);
-	gtk_widget_show(button);
+	buttongrp = pref_radiobutton_new(sd->folder_group, NULL,
+					 _("Copy"), (sd->action == BAR_SORT_COPY),
+					 G_CALLBACK(bar_sort_set_copy_cb), sd);
+	pref_radiobutton_new(sd->folder_group, buttongrp,
+			     _("Move"), (sd->action == BAR_SORT_MOVE),
+			     G_CALLBACK(bar_sort_set_move_cb), sd);
+	pref_radiobutton_new(sd->folder_group, buttongrp,
+			     _("Link"), (sd->action == BAR_SORT_LINK),
+			     G_CALLBACK(bar_sort_set_link_cb), sd);
 
 	sd->collection_group = pref_box_new(sd->vbox, FALSE, GTK_ORIENTATION_VERTICAL, 0);
 
-	buttongrp = gtk_radio_button_new_with_label(NULL, _("Add image"));
-	if (sd->selection == BAR_SORT_SELECTION_IMAGE) gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(buttongrp), TRUE);
-	g_signal_connect(G_OBJECT(buttongrp), "clicked",
-			 G_CALLBACK(bar_sort_set_selection_image_cb), sd);
-	gtk_box_pack_start(GTK_BOX(sd->collection_group), buttongrp, FALSE, FALSE, 0);
-	gtk_widget_show(buttongrp);
-
-	button = gtk_radio_button_new_with_label(gtk_radio_button_get_group(GTK_RADIO_BUTTON(buttongrp)), _("Add selection"));
-	if (sd->selection == BAR_SORT_SELECTION_SELECTED) gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), TRUE);
-	g_signal_connect(G_OBJECT(button), "clicked",
-			 G_CALLBACK(bar_sort_set_selection_selected_cb), sd);
-	gtk_box_pack_start(GTK_BOX(sd->collection_group), button, FALSE, FALSE, 0);
-	gtk_widget_show(button);
+	buttongrp = pref_radiobutton_new(sd->collection_group, NULL,
+					 _("Add image"), (sd->selection == BAR_SORT_SELECTION_IMAGE),
+					 G_CALLBACK(bar_sort_set_selection_image_cb), sd);
+	pref_radiobutton_new(sd->collection_group, buttongrp,
+			     _("Add selection"), (sd->selection == BAR_SORT_SELECTION_SELECTED),
+			     G_CALLBACK(bar_sort_set_selection_selected_cb), sd);
 
 	sd->bookmarks = bookmark_list_new(SORT_KEY_FOLDERS, bar_sort_bookmark_select, sd);
 	gtk_box_pack_start(GTK_BOX(sd->vbox), sd->bookmarks, TRUE, TRUE, 0);
@@ -627,10 +607,10 @@
 
 	tbar = pref_toolbar_new(sd->vbox, GTK_TOOLBAR_ICONS);
 
-	sd->add_button = pref_toolbar_button(tbar, GTK_STOCK_ADD, NULL,
+	sd->add_button = pref_toolbar_button(tbar, GTK_STOCK_ADD, NULL, FALSE,
 					     _("Add Bookmark"),
 					     G_CALLBACK(bar_sort_add_cb), sd);
-	sd->undo_button = pref_toolbar_button(tbar, GTK_STOCK_UNDO, NULL,
+	sd->undo_button = pref_toolbar_button(tbar, GTK_STOCK_UNDO, NULL, FALSE,
 					      _("Undo last image"),
 					      G_CALLBACK(bar_sort_undo_cb), sd);
 
--- a/src/fullscreen.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/fullscreen.c	Wed Apr 27 19:29:15 2005 +0000
@@ -283,7 +283,7 @@
 	gtk_window_set_geometry_hints(GTK_WINDOW(fs->window), fs->window, &geometry,
 				      GDK_HINT_MIN_SIZE | GDK_HINT_MAX_SIZE | GDK_HINT_BASE_SIZE |
 				      GDK_HINT_WIN_GRAVITY |
-				      GDK_HINT_USER_POS | GDK_HINT_USER_SIZE);
+				      GDK_HINT_USER_POS);
 
 	gtk_window_set_default_size(GTK_WINDOW(fs->window), w, h);
 	gtk_window_move(GTK_WINDOW(fs->window), x, y);
--- a/src/icons/Makefile.am	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/icons/Makefile.am	Wed Apr 27 19:29:15 2005 +0000
@@ -7,7 +7,9 @@
 	folder_up.png		\
 	scroller.png		\
 	sheet_broken.png	\
-	gqview_logo.png
+	gqview_logo.png		\
+	icon_float.png		\
+	icon_thumb.png
 
 ICONS_INLINE_PAIRS = \
 	folder_closed		$(srcdir)/folder_closed.png	\
@@ -16,7 +18,9 @@
 	folder_up		$(srcdir)/folder_up.png		\
 	icon_scroller		$(srcdir)/scroller.png		\
 	icon_broken		$(srcdir)/sheet_broken.png	\
-	gqview_logo		$(srcdir)/gqview_logo.png
+	gqview_logo		$(srcdir)/gqview_logo.png	\
+	icon_float		$(srcdir)/icon_float.png	\
+	icon_thumb		$(srcdir)/icon_thumb.png
 
 icons_inline.h: $(ICONS_INLINE)
 	gdk-pixbuf-csource --raw --extern --build-list $(ICONS_INLINE_PAIRS) > icons_inline.h
@@ -33,8 +37,6 @@
 	config.xpm		\
 	dialog.xpm		\
 	icon.xpm		\
-	icon_float.xpm		\
-	icon_thumb.xpm		\
 	marker.xpm		\
 	tools.xpm		\
 	view.xpm
Binary file src/icons/icon_float.png has changed
--- a/src/icons/icon_float.xpm	Sat Apr 16 16:26:49 2005 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,28 +0,0 @@
-/* XPM */
-static char * icon_float_xpm[] = {
-"10 20 5 1",
-" 	c None",
-".	c #000000",
-"+	c #FFFFFF",
-"@	c #CFCFCF",
-"#	c #797D79",
-"          ",
-" .......  ",
-" .++@+@.# ",
-" .+@+@@.# ",
-"  .@@@.## ",
-"  .+@@.## ",
-"  .@@@.#  ",
-"  .+@@.#  ",
-" .++@@@.  ",
-".++@+@+@. ",
-".+@@@@@@.#",
-".........#",
-"  #.@.####",
-"   .+.#   ",
-"   .+.#   ",
-"   .+.#   ",
-"   .+.#   ",
-"    .##   ",
-"     #    ",
-"          "};
Binary file src/icons/icon_thumb.png has changed
--- a/src/icons/icon_thumb.xpm	Sat Apr 16 16:26:49 2005 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,26 +0,0 @@
-/* XPM */
-static char * icon_thumb_xpm[] = {
-"20 20 3 1",
-" 	c None",
-".	c #000000",
-"+	c #797D79",
-"                    ",
-"                    ",
-"  ......            ",
-"  ......+  . .      ",
-"  ......+ . . .     ",
-"  ......+  + + +    ",
-"   ++++++           ",
-"                    ",
-"  ......            ",
-"  ......+ . . . .   ",
-"  ......+  . . . .  ",
-"  ......+   + + + + ",
-"   ++++++           ",
-"                    ",
-"  ......            ",
-"  ......+  . . .    ",
-"  ......+ . . . .   ",
-"  ......+  + + + +  ",
-"   ++++++           ",
-"                    "};
--- a/src/layout.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/layout.c	Wed Apr 27 19:29:15 2005 +0000
@@ -31,10 +31,10 @@
 
 #include "icons/tools.xpm"
 
-#define MAINWINDOW_DEF_WIDTH 620
-#define MAINWINDOW_DEF_HEIGHT 400
+#define MAINWINDOW_DEF_WIDTH 700
+#define MAINWINDOW_DEF_HEIGHT 500
 
-#define MAIN_WINDOW_DIV_HPOS -1
+#define MAIN_WINDOW_DIV_HPOS 270
 #define MAIN_WINDOW_DIV_VPOS 200
 
 #define TOOLWINDOW_DEF_WIDTH 260
@@ -171,9 +171,6 @@
 	GtkWidget *box;
 	GtkWidget *menu_bar;
 	GtkWidget *tabcomp;
-#if 0
-	GtkWidget *popwin;
-#endif
 
 	box = gtk_vbox_new(FALSE, 0);
 
@@ -191,9 +188,6 @@
 	gtk_box_pack_start(GTK_BOX(box), tabcomp, FALSE, FALSE, 0);
 	gtk_widget_show(tabcomp);
 
-#if 0
-	popwin = gtk_widget_get_toplevel(GTK_COMBO(tabcomp)->list);
-#endif
 	g_signal_connect(G_OBJECT(lw->path_entry->parent), "changed",
 			 G_CALLBACK(layout_path_entry_changed_cb), lw);
 
@@ -1089,7 +1083,7 @@
 
 		if (save_window_positions)
 			{
-			hints = GDK_HINT_USER_POS | GDK_HINT_USER_SIZE;
+			hints = GDK_HINT_USER_POS;
 			}
 		else
 			{
@@ -1401,10 +1395,6 @@
 	lw->info_details = NULL;
 	lw->info_zoom = NULL;
 
-#if 0
-	if (lw->menu_fact) g_object_unref(G_OBJECT(lw->menu_fact));
-	lw->menu_fact = NULL;
-#endif
 	if (lw->ui_manager) g_object_unref(lw->ui_manager);
 	lw->ui_manager = NULL;
 	lw->action_group = NULL;
@@ -1593,10 +1583,6 @@
 
 	layout_bars_close(lw);
 
-#if 0
-	if (lw->menu_fact) g_object_unref(G_OBJECT(lw->menu_fact));
-#endif
-	if (lw->tooltips) g_object_unref(G_OBJECT(lw->tooltips));
 	gtk_widget_destroy(lw->window);
 
 	g_free(lw->path);
@@ -1675,7 +1661,7 @@
 
 	if (save_window_positions)
 		{
-		hints = GDK_HINT_USER_POS | GDK_HINT_USER_SIZE;
+		hints = GDK_HINT_USER_POS;
 		}
 	else
 		{
@@ -1708,14 +1694,6 @@
 
 	layout_keyboard_init(lw, lw->window);
 
-#if 0
-	gtk_widget_realize(lw->window);
-#endif
-
-	lw->tooltips = gtk_tooltips_new();
-	g_object_ref(G_OBJECT(lw->tooltips));
-	gtk_object_sink(GTK_OBJECT(lw->tooltips));
-
 	lw->main_box = gtk_vbox_new(FALSE, 0);
 	gtk_container_add(GTK_CONTAINER(lw->window), lw->main_box);
 	gtk_widget_show(lw->main_box);
--- a/src/layout_util.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/layout_util.c	Wed Apr 27 19:29:15 2005 +0000
@@ -37,9 +37,6 @@
 
 #include <gdk/gdkkeysyms.h> /* for keyboard values */
 
-#include "icons/icon_thumb.xpm"
-#include "icons/icon_float.xpm"
-
 
 #define MENU_EDIT_ACTION_OFFSET 16
 
@@ -471,17 +468,6 @@
 	layout_views_set(lw, lw->tree_view, (gtk_radio_action_get_current_value(action) == 1));
 }
 
-#if 0
-static void layout_menu_icon_cb(gpointer data, guint action, GtkWidget *widget)
-{
-	LayoutWindow *lw = data;
-
-	if (!GTK_CHECK_MENU_ITEM(widget)->active) return;
-
-	layout_views_set(lw, lw->tree_view, TRUE);
-}
-#endif
-
 static void layout_menu_tree_cb(GtkToggleAction *action, gpointer data)
 {
 	LayoutWindow *lw = data;
@@ -980,7 +966,7 @@
 {
 	LayoutWindow *lw = data;
 
-	layout_thumb_set(lw, GTK_TOGGLE_BUTTON(widget)->active);
+	layout_thumb_set(lw, gtk_toggle_tool_button_get_active(GTK_TOGGLE_TOOL_BUTTON(widget)));
 }
 
 static void layout_button_home_cb(GtkWidget *widget, gpointer data)
@@ -1038,75 +1024,50 @@
 	layout_tools_float_toggle(lw);
 }
 
-GtkWidget *layout_button(GtkWidget *box, gchar **pixmap_data, const gchar *stock_id, gint toggle,
-			 GtkTooltips *tooltips, const gchar *tip_text,
-			 GCallback func, gpointer data)
+static void layout_button_custom_icon(GtkWidget *button, const gchar *key)
 {
-	GtkWidget *button;
 	GtkWidget *icon;
-
-	if (toggle)
-		{
-		button = gtk_toggle_button_new();
-		}
-	else
-		{
-		button = gtk_button_new();
-		}
+	GdkPixbuf *pixbuf;
 
-	g_signal_connect(G_OBJECT(button), "clicked", func, data);
-	gtk_box_pack_start(GTK_BOX(box), button, FALSE, FALSE, 0);
-	gtk_widget_show(button);
-	gtk_tooltips_set_tip(tooltips, button, tip_text, NULL);
+	pixbuf = pixbuf_inline(key);
+	if (!pixbuf) return;
 
-	if (stock_id)
-		{
-		icon = gtk_image_new_from_stock(stock_id, GTK_ICON_SIZE_BUTTON);
-		}
-	else
-		{
-		GdkPixbuf *pixbuf;
+	icon = gtk_image_new_from_pixbuf(pixbuf);
+	g_object_unref(pixbuf);
 
-		pixbuf = gdk_pixbuf_new_from_xpm_data((const char **)pixmap_data);
-		icon = gtk_image_new_from_pixbuf(pixbuf);
-		gdk_pixbuf_unref(pixbuf);
-		}
-
-	gtk_button_set_relief(GTK_BUTTON(button), GTK_RELIEF_NONE);
-
-	gtk_container_add(GTK_CONTAINER(button), icon);
+	pref_toolbar_button_set_icon(button, icon, NULL);
 	gtk_widget_show(icon);
-
-	return button;
 }
 
 GtkWidget *layout_button_bar(LayoutWindow *lw)
 {
 	GtkWidget *box;
-	GtkTooltips *tooltips;
+	GtkWidget *button;
+
+	box =  pref_toolbar_new(NULL, GTK_TOOLBAR_ICONS);
 
-	tooltips = lw->tooltips;
-
-	box = gtk_hbox_new(FALSE, 0);
+	button = pref_toolbar_button(box, NULL, _("_Thumbnails"), TRUE,
+				     _("Show thumbnails"), G_CALLBACK(layout_button_thumb_cb), lw);
+	layout_button_custom_icon(button, PIXBUF_INLINE_ICON_THUMB);
+	lw->thumb_button = button;
 
-	lw->thumb_button = layout_button(box, (gchar **)icon_thumb_xpm, NULL, TRUE,
-		      tooltips, _("Show thumbnails"), G_CALLBACK(layout_button_thumb_cb), lw);
-	layout_button(box, NULL, GTK_STOCK_HOME, FALSE,
-		      tooltips, _("Change to home folder"), G_CALLBACK(layout_button_home_cb), lw);
-	layout_button(box, NULL, GTK_STOCK_REFRESH, FALSE,
-		      tooltips, _("Refresh file list"), G_CALLBACK(layout_button_refresh_cb), lw);
-	layout_button(box, NULL, GTK_STOCK_ZOOM_IN, FALSE,
-		      tooltips, _("Zoom in"), G_CALLBACK(layout_button_zoom_in_cb), lw);
-	layout_button(box, NULL, GTK_STOCK_ZOOM_OUT, FALSE,
-		      tooltips, _("Zoom out"), G_CALLBACK(layout_button_zoom_out_cb), lw);
-	layout_button(box, NULL, GTK_STOCK_ZOOM_FIT, FALSE,
-		      tooltips, _("Fit image to window"), G_CALLBACK(layout_button_zoom_fit_cb), lw);
-	layout_button(box, NULL, GTK_STOCK_ZOOM_100, FALSE,
-		      tooltips, _("Set zoom 1:1"), G_CALLBACK(layout_button_zoom_1_1_cb), lw);
-	layout_button(box, NULL, GTK_STOCK_PREFERENCES, FALSE,
-		      tooltips, _("Configure options"), G_CALLBACK(layout_button_config_cb), lw);
-	layout_button(box, (gchar **)icon_float_xpm, NULL, FALSE,
-		      tooltips, _("Float Controls"), G_CALLBACK(layout_button_float_cb), lw);
+	pref_toolbar_button(box, GTK_STOCK_HOME, NULL, FALSE,
+			    _("Change to home folder"), G_CALLBACK(layout_button_home_cb), lw);
+	pref_toolbar_button(box, GTK_STOCK_REFRESH, NULL, FALSE,
+			    _("Refresh file list"), G_CALLBACK(layout_button_refresh_cb), lw);
+	pref_toolbar_button(box, GTK_STOCK_ZOOM_IN, NULL, FALSE,
+			    _("Zoom in"), G_CALLBACK(layout_button_zoom_in_cb), lw);
+	pref_toolbar_button(box, GTK_STOCK_ZOOM_OUT, NULL, FALSE,
+			    _("Zoom out"), G_CALLBACK(layout_button_zoom_out_cb), lw);
+	pref_toolbar_button(box, GTK_STOCK_ZOOM_FIT, NULL, FALSE,
+			    _("Fit image to window"), G_CALLBACK(layout_button_zoom_fit_cb), lw);
+	pref_toolbar_button(box, GTK_STOCK_ZOOM_100, NULL, FALSE,
+			    _("Set zoom 1:1"), G_CALLBACK(layout_button_zoom_1_1_cb), lw);
+	pref_toolbar_button(box, GTK_STOCK_PREFERENCES, NULL, FALSE,
+			    _("Configure options"), G_CALLBACK(layout_button_config_cb), lw);
+	button = pref_toolbar_button(box, NULL, _("_Float"), FALSE,
+				     _("Float Controls"), G_CALLBACK(layout_button_float_cb), lw);
+	layout_button_custom_icon(button, PIXBUF_INLINE_ICON_FLOAT);
 
 	return box;
 }
@@ -1155,7 +1116,7 @@
 	gtk_toggle_action_set_active(GTK_TOGGLE_ACTION(action), lw->thumbs_enabled);
 	g_object_set(action, "sensitive", !lw->icon_view, NULL);
 
-	gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(lw->thumb_button), lw->thumbs_enabled);
+	gtk_toggle_tool_button_set_active(GTK_TOGGLE_TOOL_BUTTON(lw->thumb_button), lw->thumbs_enabled);
 	gtk_widget_set_sensitive(lw->thumb_button, !lw->icon_view);
 }
 
--- a/src/pixbuf_util.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/pixbuf_util.c	Wed Apr 27 19:29:15 2005 +0000
@@ -98,6 +98,8 @@
 	{ PIXBUF_INLINE_SCROLLER,	icon_scroller },
 	{ PIXBUF_INLINE_BROKEN,		icon_broken },
 	{ PIXBUF_INLINE_LOGO,		gqview_logo },
+	{ PIXBUF_INLINE_ICON_FLOAT,	icon_float },
+	{ PIXBUF_INLINE_ICON_THUMB,	icon_thumb },
 	{ NULL, NULL }
 };
 
--- a/src/pixbuf_util.h	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/pixbuf_util.h	Wed Apr 27 19:29:15 2005 +0000
@@ -28,6 +28,9 @@
 #define PIXBUF_INLINE_BROKEN		"broken"
 #define PIXBUF_INLINE_LOGO		"logo"
 
+#define PIXBUF_INLINE_ICON_FLOAT	"icon_float"
+#define PIXBUF_INLINE_ICON_THUMB	"icon_thumb"
+
 
 GdkPixbuf *pixbuf_copy_rotate_90(GdkPixbuf *src, gint counter_clockwise);
 GdkPixbuf *pixbuf_copy_mirror(GdkPixbuf *src, gint mirror, gint flip);
--- a/src/rcfile.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/rcfile.c	Wed Apr 27 19:29:15 2005 +0000
@@ -194,6 +194,9 @@
 	fprintf(f,"#                         GQview config file         version %7s #\n", VERSION);
 	fprintf(f,"######################################################################\n");
 	fprintf(f,"\n");
+	fprintf(f,"# Note: This file is autogenerated. Options can be changed here,\n");
+	fprintf(f,"#       but user comments and formatting will be lost.\n");
+	fprintf(f,"\n");
 	fprintf(f,"##### General Options #####\n\n");
 
 	write_int_option(f, "layout_style", layout_style);
@@ -303,7 +306,7 @@
 	filter_write_list(f);
 
 	fprintf(f,"\n##### External Programs #####\n");
-	fprintf(f,"# Maximum of 8 programs (external_1 through external 8)\n");
+	fprintf(f,"# Maximum of 10 programs (external_1 through external_10)\n");
 	fprintf(f,"# format: external_n: \"menu name\" \"command line\"\n\n");
 
 	for (i = 0; i < GQVIEW_EDITOR_SLOTS; i++)
--- a/src/typedefs.h	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/typedefs.h	Wed Apr 27 19:29:15 2005 +0000
@@ -309,8 +309,6 @@
 	GtkWidget *h_pane;
 	GtkWidget *v_pane;
 
-	GtkTooltips *tooltips;
-
 	/* menus, path selector */
 
 	GtkActionGroup *action_group;
--- a/src/ui_misc.c	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/ui_misc.c	Wed Apr 27 19:29:15 2005 +0000
@@ -749,13 +749,37 @@
 	return tbar;
 }
 
-GtkWidget *pref_toolbar_button(GtkWidget *toolbar, const gchar *stock_id, const gchar *label,
+GtkWidget *pref_toolbar_button(GtkWidget *toolbar,
+			       const gchar *stock_id, const gchar *label, gint toggle,
 			       const gchar *description,
 			       GCallback func, gpointer data)
 {
 	GtkWidget *item;
 
-	item = GTK_WIDGET(gtk_tool_button_new_from_stock(stock_id));
+	if (toggle)
+		{
+		if (stock_id)
+			{
+			item = GTK_WIDGET(gtk_toggle_tool_button_new_from_stock(stock_id));
+			}
+		else
+			{
+			item = GTK_WIDGET(gtk_toggle_tool_button_new());
+			}
+		}
+	else
+		{
+		if (stock_id)
+			{
+			item = GTK_WIDGET(gtk_tool_button_new_from_stock(stock_id));
+			}
+		else
+			{
+			item = GTK_WIDGET(gtk_tool_button_new(NULL, NULL));
+			}
+		}
+	gtk_tool_button_set_use_underline(GTK_TOOL_BUTTON(item), TRUE);
+
 	if (label) gtk_tool_button_set_label(GTK_TOOL_BUTTON(item), label);
 
 	if (func) g_signal_connect(item, "clicked", func, data);
@@ -773,6 +797,18 @@
 	return item;
 }
 
+void pref_toolbar_button_set_icon(GtkWidget *button, GtkWidget *widget, const gchar *stock_id)
+{
+	if (widget)
+		{
+		gtk_tool_button_set_icon_widget(GTK_TOOL_BUTTON(button), widget);
+		}
+	else if (stock_id)
+		{
+		gtk_tool_button_set_stock_id(GTK_TOOL_BUTTON(button), stock_id);
+		}
+}
+
 GtkWidget *pref_toolbar_spacer(GtkWidget *toolbar)
 {
 	GtkWidget *item;
--- a/src/ui_misc.h	Sat Apr 16 16:26:49 2005 +0000
+++ b/src/ui_misc.h	Wed Apr 27 19:29:15 2005 +0000
@@ -137,9 +137,11 @@
 
 
 GtkWidget *pref_toolbar_new(GtkWidget *parent_box, GtkToolbarStyle style);
-GtkWidget *pref_toolbar_button(GtkWidget *toolbar, const gchar *stock_id, const gchar *label,
+GtkWidget *pref_toolbar_button(GtkWidget *toolbar,
+			       const gchar *stock_id, const gchar *label, gint toggle,
 			       const gchar *description,
 			       GCallback func, gpointer data);
+void pref_toolbar_button_set_icon(GtkWidget *button, GtkWidget *widget, const gchar *stock_id);
 GtkWidget *pref_toolbar_spacer(GtkWidget *toolbar);