summaryrefslogtreecommitdiff
path: root/plugins/gnome
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/gnome')
-rw-r--r--plugins/gnome/Makefile.am44
-rw-r--r--plugins/gnome/bonobo.xml.in70
-rw-r--r--plugins/gnome/canvas.xml.in80
-rw-r--r--plugins/gnome/glade-gnome.c1746
-rw-r--r--plugins/gnome/gnome.xml.in390
-rw-r--r--plugins/gnome/icons/16x16/Makefile.am31
-rw-r--r--plugins/gnome/icons/16x16/bonobodock.pngbin0 -> 142 bytes
-rw-r--r--plugins/gnome/icons/16x16/bonobodockitem.pngbin0 -> 156 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomeabout.pngbin0 -> 221 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomeapp.pngbin0 -> 168 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomeappbar.pngbin0 -> 113 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomecanvas.pngbin0 -> 108 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomecolorpicker.pngbin0 -> 199 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomedateedit.pngbin0 -> 164 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomedialog.pngbin0 -> 206 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomedruid.pngbin0 -> 150 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomedruidpageedge.pngbin0 -> 150 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomedruidpagestandard.pngbin0 -> 155 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomeentry.pngbin0 -> 153 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomefileentry.pngbin0 -> 164 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomefontpicker.pngbin0 -> 291 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomehref.pngbin0 -> 121 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomeiconentry.pngbin0 -> 204 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomeiconlist.pngbin0 -> 241 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomeiconselection.pngbin0 -> 224 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomemessagebox.pngbin0 -> 229 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomepixmap.pngbin0 -> 268 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomepixmapentry.pngbin0 -> 164 bytes
-rw-r--r--plugins/gnome/icons/16x16/gnomepropertybox.pngbin0 -> 224 bytes
-rw-r--r--plugins/gnome/icons/22x22/Makefile.am31
-rw-r--r--plugins/gnome/icons/22x22/bonobodock.pngbin0 -> 147 bytes
-rw-r--r--plugins/gnome/icons/22x22/bonobodockitem.pngbin0 -> 174 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomeabout.pngbin0 -> 236 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomeapp.pngbin0 -> 181 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomeappbar.pngbin0 -> 122 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomecanvas.pngbin0 -> 115 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomecolorpicker.pngbin0 -> 168 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomedateedit.pngbin0 -> 177 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomedialog.pngbin0 -> 283 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomedruid.pngbin0 -> 143 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomedruidpageedge.pngbin0 -> 143 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomedruidpagestandard.pngbin0 -> 143 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomeentry.pngbin0 -> 170 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomefileentry.pngbin0 -> 177 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomefontpicker.pngbin0 -> 175 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomehref.pngbin0 -> 150 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomeiconentry.pngbin0 -> 226 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomeiconlist.pngbin0 -> 265 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomeiconselection.pngbin0 -> 274 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomemessagebox.pngbin0 -> 310 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomepixmap.pngbin0 -> 269 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomepixmapentry.pngbin0 -> 177 bytes
-rw-r--r--plugins/gnome/icons/22x22/gnomepropertybox.pngbin0 -> 263 bytes
-rw-r--r--plugins/gnome/icons/Makefile.am3
54 files changed, 2395 insertions, 0 deletions
diff --git a/plugins/gnome/Makefile.am b/plugins/gnome/Makefile.am
new file mode 100644
index 00000000..879751ef
--- /dev/null
+++ b/plugins/gnome/Makefile.am
@@ -0,0 +1,44 @@
+## Process this file with automake to produce Makefile.in
+
+SUBDIRS = icons
+
+libgladeui = $(top_builddir)/gladeui/libgladeui-1.la
+
+
+# libgladegnome
+
+gladegnome_LTLIBRARIES = libgladegnome.la
+gladegnomedir = $(pkglibdir)/modules
+
+libgladegnome_la_SOURCES = glade-gnome.c
+libgladegnome_la_CPPFLAGS = $(AM_CPPFLAGS)
+libgladegnome_la_CFLAGS = \
+ -g -Wall \
+ -I$(top_srcdir)/gladeui \
+ -I$(top_builddir)/gladeui \
+ -I$(top_srcdir)/plugins/gtk+ \
+ $(GNOME_CFLAGS) \
+ $(AM_CPPFLAGS)
+libgladegnome_la_LDFLAGS = -module -avoid-version $(GNOME_LIBS) $(AM_LDFLAGS)
+libgladegnome_la_LIBADD = $(libgladeui) $(GLADE_LIBS)
+
+if WITH_WIN32
+ libgladegnome_la_LDFLAGS += -no-undefined
+endif
+
+
+# catalog data
+
+catalogsdir = $(pkgdatadir)/catalogs
+catalogs_DATA = bonobo.xml \
+ canvas.xml \
+ gnome.xml \
+ bonobo.xml.in \
+ canvas.xml.in \
+ gnome.xml.in
+@INTLTOOL_XML_NOMERGE_RULE@
+
+
+CLEANFILES = bonobo.xml canvas.xml gnome.xml
+
+EXTRA_DIST = $(catalogs_DATA)
diff --git a/plugins/gnome/bonobo.xml.in b/plugins/gnome/bonobo.xml.in
new file mode 100644
index 00000000..9e9eddf2
--- /dev/null
+++ b/plugins/gnome/bonobo.xml.in
@@ -0,0 +1,70 @@
+<glade-catalog name="bonobo" library="gladegnome" depends="gnome" domain="glade-3">
+ <glade-widget-classes>
+ <glade-widget-class name="BonoboDock" generic-name="bonobodock" title="Bonobo Dock">
+ <set-property-function>glade_gnome_bonobodock_set_property</set-property-function>
+ <add-child-function>glade_gnome_bonobodock_add_child</add-child-function>
+ <remove-child-function>glade_gnome_bonobodock_remove_child</remove-child-function>
+ <replace-child-function>glade_gnome_bonobodock_replace_child</replace-child-function>
+ <get-children-function>glade_gnome_bonobodock_get_children</get-children-function>
+ <child-set-property-function>glade_gnome_bonobodock_set_child_property</child-set-property-function>
+ <child-get-property-function>glade_gnome_bonobodock_get_child_property</child-get-property-function>
+ <properties>
+ <property id="allow-floating" name="Allow Floating">
+ <tooltip>If floating dock iteam are allowed</tooltip>
+ <spec>glade_standard_boolean_spec</spec>
+ </property>
+ </properties>
+
+ <packing-properties>
+ <property id="placement">
+ <spec>glade_gnome_bonobo_dock_placement_spec</spec>
+ <displayable-values>
+ <value id="BONOBO_DOCK_LEFT" _name="Left"/>
+ <value id="BONOBO_DOCK_RIGHT" _name="Right"/>
+ <value id="BONOBO_DOCK_TOP" _name="Top"/>
+ <value id="BONOBO_DOCK_BOTTOM" _name="Bottom"/>
+ <value id="BONOBO_DOCK_FLOATING" _name="Floating"/>
+ </displayable-values>
+ </property>
+ <property id="band" name="Band">
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="position" name="Position">
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="offset" name="Offset">
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="behavior">
+ <spec>glade_gnome_bonobo_dock_item_behavior_spec</spec>
+ <displayable-values>
+ <value id="BONOBO_DOCK_ITEM_BEH_EXCLUSIVE" _name="Exclusive"/>
+ <value id="BONOBO_DOCK_ITEM_BEH_NEVER_FLOATING" _name="Never Floating"/>
+ <value id="BONOBO_DOCK_ITEM_BEH_NEVER_VERTICAL" _name="Never Vertical"/>
+ <value id="BONOBO_DOCK_ITEM_BEH_NEVER_HORIZONTAL" _name="Never Horizontal"/>
+ <value id="BONOBO_DOCK_ITEM_BEH_LOCKED" _name="Locked"/>
+ </displayable-values>
+ </property>
+ </packing-properties>
+ </glade-widget-class>
+ <glade-widget-class name="BonoboDockItem" generic-name="bonobodockitem" title="Bonobo Dock Item">
+ <properties>
+ <property id="shadow">
+ <displayable-values>
+ <value id="GTK_SHADOW_NONE" _name="None"/>
+ <value id="GTK_SHADOW_IN" _name="In"/>
+ <value id="GTK_SHADOW_OUT" _name="Out"/>
+ <value id="GTK_SHADOW_ETCHED_IN" _name="Etched In"/>
+ <value id="GTK_SHADOW_ETCHED_OUT" _name="Etched Out"/>
+ </displayable-values>
+ </property>
+ <property id="orientation">
+ <displayable-values>
+ <value id="GTK_ORIENTATION_HORIZONTAL" _name="Horizontal"/>
+ <value id="GTK_ORIENTATION_VERTICAL" _name="Vertical"/>
+ </displayable-values>
+ </property>
+ </properties>
+ </glade-widget-class>
+ </glade-widget-classes>
+</glade-catalog>
diff --git a/plugins/gnome/canvas.xml.in b/plugins/gnome/canvas.xml.in
new file mode 100644
index 00000000..5e2db28d
--- /dev/null
+++ b/plugins/gnome/canvas.xml.in
@@ -0,0 +1,80 @@
+<glade-catalog name="canvas" library="gladegnome" depends="gnome" domain="glade-3">
+ <glade-widget-classes>
+ <glade-widget-class name="GnomeCanvas" generic-name="gnomecanvas" title="Gnome Canvas">
+ <set-property-function>glade_gnome_canvas_set_property</set-property-function>
+ <properties>
+ <property id="scroll-x1" _name="Min X">
+ <_tooltip>The minimum x coordinate</_tooltip>
+ <spec>glade_standard_float_spec</spec>
+ </property>
+ <property id="scroll-y1" _name="Min Y">
+ <_tooltip>The minimum y coordinate</_tooltip>
+ <spec>glade_standard_float_spec</spec>
+ </property>
+ <property id="scroll-x2" _name="Max X">
+ <_tooltip>The maximum x coordinate</_tooltip>
+ <spec>glade_standard_float_spec</spec>
+ </property>
+ <property id="scroll-y2" _name="Max Y">
+ <_tooltip>The maximum y coordinate</_tooltip>
+ <spec>glade_standard_float_spec</spec>
+ </property>
+ <property id="pixels-per-unit" _name="Pixels per unit">
+ <_tooltip>The number of pixels corresponding to one unit</_tooltip>
+ <spec>glade_standard_float_spec</spec>
+ </property>
+ </properties>
+ </glade-widget-class>
+
+ <!-- This is deprecated -->
+ <glade-widget-class name="GnomeIconList" generic-name="gnomeiconlist" title="Gnome Icon List">
+ <post-create-function>glade_gnome_icon_list_post_create</post-create-function>
+ <set-property-function>glade_gnome_icon_list_set_property</set-property-function>
+ <properties>
+ <property id="scroll-x1" disabled="True"/>
+ <property id="scroll-y1" disabled="True"/>
+ <property id="scroll-x2" disabled="True"/>
+ <property id="scroll-y2" disabled="True"/>
+ <property id="pixels-per-unit" disabled="True"/>
+ <property id="selection-mode" _name="Selection Mode">
+ <_tooltip>The selection mode</_tooltip>
+ <spec>glade_gnome_icon_list_selection_mode_spec</spec>
+ <displayable-values>
+ <value id="GTK_SELECTION_SINGLE" _name="Single"/>
+ <value id="GTK_SELECTION_BROWSE" _name="Browse"/>
+ <value id="GTK_SELECTION_MULTIPLE" _name="Multiple"/>
+ </displayable-values>
+ </property>
+ <property id="icon-width" _name="Icon Width" default="78">
+ <_tooltip>The width of each icon</_tooltip>
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="row-spacing" _name="Row Spacing" default="4">
+ <_tooltip>The number of pixels between rows of icons</_tooltip>
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="column-spacing" _name="Column Spacing" default="2">
+ <_tooltip>The number of pixels between columns of icons</_tooltip>
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="text-spacing" _name="Text Spacing" default="2">
+ <_tooltip>The number of pixels between the text and the icon</_tooltip>
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="text-editable" _name="Text Editable" ignore="True">
+ <_tooltip>If the icon text can be edited by the user</_tooltip>
+ <spec>glade_standard_boolean_spec</spec>
+ </property>
+ <property id="text-static" _name="Text Static" ignore="True">
+ <_tooltip>If the icon text is static, in which case it will not be copied by the GnomeIconList</_tooltip>
+ <spec>glade_standard_boolean_spec</spec>
+ </property>
+ </properties>
+ </glade-widget-class>
+ </glade-widget-classes>
+
+ <glade-widget-group name="gnome-canvas" _title="GNOME Canvas">
+ <glade-widget-class-ref name="GnomeCanvas"/>
+ <glade-widget-class-ref name="GnomeIconList"/>
+ </glade-widget-group>
+</glade-catalog>
diff --git a/plugins/gnome/glade-gnome.c b/plugins/gnome/glade-gnome.c
new file mode 100644
index 00000000..893145f7
--- /dev/null
+++ b/plugins/gnome/glade-gnome.c
@@ -0,0 +1,1746 @@
+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
+/*
+ * Copyright (C) 2006 Juan Pablo Ugarte.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ * Authors:
+ * Juan Pablo Ugarte <juanpablougarte@gmail.com>
+ */
+
+#include <config.h>
+
+#include <glade.h>
+#include <glade-editor-property.h>
+#include <glade-gtk.h>
+
+#include <libbonoboui.h>
+#include <libgnome/libgnome.h>
+#include <libgnomeui/libgnomeui.h>
+
+#ifdef G_OS_WIN32
+#define GLADEGNOME_API __declspec(dllexport)
+#else
+#define GLADEGNOME_API
+#endif
+
+/* This function does absolutely nothing
+ * (and is for use in overriding post_create functions).
+ */
+void GLADEGNOME_API
+empty (GObject *container, GladeCreateReason reason)
+{
+}
+
+/* Catalog init function */
+void GLADEGNOME_API
+glade_gnomeui_init ()
+{
+ gchar *argv[2] = {"glade-3", NULL};
+ GtkStockItem items [] = {
+ { GNOME_STOCK_TIMER, "Gnome Timer", 0, },
+ { GNOME_STOCK_TIMER_STOP, "Gnome Timer stop", 0, },
+ { GNOME_STOCK_TRASH, "Gnome Trash", 0, },
+ { GNOME_STOCK_TRASH_FULL, "Gnome Trash Full", 0, },
+ { GNOME_STOCK_SCORES, "Gnome Scores", 0, },
+ { GNOME_STOCK_ABOUT, "Gnome About", 0, },
+ { GNOME_STOCK_BLANK, "Gnome Blank", 0, },
+ { GNOME_STOCK_VOLUME, "Gnome Volume", 0, },
+ { GNOME_STOCK_MIDI, "Gnome Midi", 0, },
+ { GNOME_STOCK_MIC, "Gnome Mic", 0, },
+ { GNOME_STOCK_LINE_IN, "Gnome Line In", 0, },
+ { GNOME_STOCK_MAIL, "Gnome Mail", 0, },
+ { GNOME_STOCK_MAIL_RCV, "Gnome Mail Recive", 0, },
+ { GNOME_STOCK_MAIL_SND, "Gnome Mail Send", 0, },
+ { GNOME_STOCK_MAIL_RPL, "Gnome Mail Reply", 0, },
+ { GNOME_STOCK_MAIL_FWD, "Gnome Mail Foward", 0, },
+ { GNOME_STOCK_MAIL_NEW, "Gnome Mail New", 0, },
+ { GNOME_STOCK_ATTACH, "Gnome Attach", 0, },
+ { GNOME_STOCK_BOOK_RED, "Gnome Book Red", 0, },
+ { GNOME_STOCK_BOOK_GREEN, "Gnome Book Green", 0, },
+ { GNOME_STOCK_BOOK_BLUE, "Gnome Book Blue", 0, },
+ { GNOME_STOCK_BOOK_YELLOW, "Gnome Book Yellow", 0, },
+ { GNOME_STOCK_BOOK_OPEN, "Gnome Book Open", 0, },
+ { GNOME_STOCK_MULTIPLE_FILE, "Gnome Multiple File", 0, },
+ { GNOME_STOCK_NOT, "Gnome Not", 0, },
+ { GNOME_STOCK_TABLE_BORDERS, "Gnome Table Borders", 0, },
+ { GNOME_STOCK_TABLE_FILL, "Gnome Table Fill", 0, },
+ { GNOME_STOCK_TEXT_INDENT, "Gnome Indent", 0, },
+ { GNOME_STOCK_TEXT_UNINDENT, "Gnome Unindent", 0, },
+ { GNOME_STOCK_TEXT_BULLETED_LIST, "Gnome Bulleted List", 0, },
+ { GNOME_STOCK_TEXT_NUMBERED_LIST, "Gnome Numbered List", 0, }
+ };
+
+ gnome_program_init ("glade-3", "1.0",
+ LIBGNOMEUI_MODULE, 1, argv,
+ GNOME_PARAM_NONE);
+
+ gtk_stock_add (items, sizeof (items) / sizeof (GtkStockItem));
+
+ glade_standard_stock_append_prefix ("gnome-stock-");
+}
+
+/* GnomeApp */
+void GLADEGNOME_API
+glade_gnome_app_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ static GladeWidgetAdaptor *menubar_adaptor = NULL, *dock_item_adaptor;
+ GnomeApp *app = GNOME_APP (object);
+ GladeWidget *gapp = glade_widget_get_from_gobject (object);
+ GladeProject *project = glade_widget_get_project (gapp);
+ GladeWidget *gdock, *gdock_item, *gmenubar;
+
+ gtk_window_set_default_size (GTK_WINDOW (object), 440, 250);
+
+ /* Add BonoboDock */
+ gdock = glade_widget_adaptor_create_internal
+ (gapp, G_OBJECT (app->dock),
+ "dock",
+ glade_widget_get_name (gapp),
+ FALSE,
+ GLADE_CREATE_LOAD);
+
+ if (reason != GLADE_CREATE_USER) return;
+
+ /* Add MenuBar */
+ if (menubar_adaptor == NULL)
+ {
+ dock_item_adaptor = glade_widget_adaptor_get_by_type (BONOBO_TYPE_DOCK_ITEM);
+ menubar_adaptor = glade_widget_adaptor_get_by_type (GTK_TYPE_MENU_BAR);
+ }
+
+ /* DockItem */
+ gdock_item = glade_widget_adaptor_create_widget (dock_item_adaptor, FALSE,
+ "parent", gdock,
+ "project", project, NULL);
+ glade_widget_add_child (gdock, gdock_item, FALSE);
+ glade_widget_pack_property_set (gdock_item, "behavior",
+ BONOBO_DOCK_ITEM_BEH_EXCLUSIVE |
+ BONOBO_DOCK_ITEM_BEH_NEVER_VERTICAL |
+ BONOBO_DOCK_ITEM_BEH_LOCKED);
+ /* MenuBar */
+ gmenubar = glade_widget_adaptor_create_widget (menubar_adaptor, FALSE,
+ "parent", gdock_item,
+ "project", project, NULL);
+
+ glade_widget_add_child (gdock_item, gmenubar, FALSE);
+
+ /* Add Client Area placeholder */
+ bonobo_dock_set_client_area (BONOBO_DOCK (app->dock),
+ glade_placeholder_new());
+
+ /* Add StatusBar */
+ glade_widget_property_set (gapp, "has-statusbar", TRUE);
+}
+
+GObject * GLADEGNOME_API
+glade_gnome_app_get_internal_child (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *name)
+{
+ GObject *child = NULL;
+ GnomeApp *app = GNOME_APP (object);
+ GladeWidget *gapp = glade_widget_get_from_gobject (object);
+
+ if (strcmp ("dock", name) == 0)
+ child = G_OBJECT (app->dock);
+ else if (strcmp ("appbar", name) == 0)
+ {
+ child = G_OBJECT (app->statusbar);
+ if (child == NULL)
+ {
+ /*
+ Create appbar, libglade handle this as an internal
+ widget but appbar is not created by GnomeApp.
+ So we need to create it here for loading purpouses since
+ "has-statusbar" property is not saved in the .glade file.
+ */
+ glade_widget_property_set (gapp, "has-statusbar", TRUE);
+ child = G_OBJECT (app->statusbar);
+ }
+ }
+
+ return child;
+}
+
+GList * GLADEGNOME_API
+glade_gnome_app_get_children (GladeWidgetAdaptor *adaptor,
+ GObject *object)
+{
+ GnomeApp *app = GNOME_APP (object);
+ GList *list = NULL;
+
+ if (app->dock) list = g_list_append (list, G_OBJECT (app->dock));
+ if (app->statusbar) list = g_list_append (list, G_OBJECT (app->statusbar));
+ if (app->contents) list = g_list_append (list, G_OBJECT (app->contents));
+
+ return list;
+}
+
+void GLADEGNOME_API
+glade_gnome_app_set_child_property (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child,
+ const gchar *property_name,
+ GValue *value)
+{
+ GnomeApp *app = GNOME_APP (container);
+
+ g_return_if_fail (GTK_IS_WIDGET (child));
+
+ gtk_container_child_set_property (GTK_CONTAINER (app->vbox),
+ (GNOME_IS_APPBAR (child))
+ ? gtk_widget_get_parent (GTK_WIDGET (child))
+ : GTK_WIDGET (child),
+ property_name,
+ value);
+}
+
+void GLADEGNOME_API
+glade_gnome_app_get_child_property (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child,
+ const gchar *property_name,
+ GValue *value)
+{
+ GnomeApp *app = GNOME_APP (container);
+
+ g_return_if_fail (GTK_IS_WIDGET (child));
+
+ gtk_container_child_get_property (GTK_CONTAINER (app->vbox),
+ (GNOME_IS_APPBAR (child))
+ ? gtk_widget_get_parent (GTK_WIDGET (child))
+ : GTK_WIDGET (child),
+ property_name,
+ value);
+}
+
+static void
+glade_gnome_app_set_has_statusbar (GObject *object, const GValue *value)
+{
+ GnomeApp *app = GNOME_APP (object);
+ GladeWidget *gapp = glade_widget_get_from_gobject (object), *gbar;
+
+ if (g_value_get_boolean (value))
+ {
+ if (app->statusbar == NULL)
+ {
+ GtkWidget *bar = gnome_appbar_new (TRUE, TRUE,
+ GNOME_PREFERENCES_NEVER);
+
+ gnome_app_set_statusbar (app, bar);
+
+ gbar = glade_widget_adaptor_create_internal
+ (gapp, G_OBJECT (bar), "appbar",
+ glade_widget_get_name (gapp),
+ FALSE, GLADE_CREATE_USER);
+
+ glade_widget_set_parent (gbar, gapp);
+ glade_widget_pack_property_set (gbar, "expand", FALSE);
+ }
+ }
+ else
+ {
+ if (app->statusbar)
+ {
+ /* FIXME: we need to destroy GladeWidgets too */
+ glade_project_remove_object (glade_widget_get_project (gapp),
+ G_OBJECT (app->statusbar));
+ gtk_container_remove (GTK_CONTAINER (app->vbox),
+ gtk_widget_get_parent (app->statusbar));
+ app->statusbar = NULL;
+ }
+ }
+}
+
+
+void GLADEGNOME_API
+glade_gnome_app_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "has-statusbar"))
+ glade_gnome_app_set_has_statusbar (object, value);
+ else if (!strcmp (id, "enable-layout-config"))
+ /* do nothing */;
+ else
+ GWA_GET_CLASS (GTK_TYPE_WINDOW)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomeAppBar */
+GType GLADEGNOME_API
+gnome_app_bar_get_type ()
+{
+ return gnome_appbar_get_type ();
+}
+
+void GLADEGNOME_API
+glade_gnome_app_bar_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ gnome_appbar_set_status (GNOME_APPBAR (object), _("Status Message."));
+}
+
+/* GnomeDateEdit */
+static void
+glade_gnome_date_edit_set_no_show_all (GtkWidget *widget, gpointer data)
+{
+ gtk_widget_set_no_show_all (widget, TRUE);
+}
+
+void GLADEGNOME_API
+glade_gnome_date_edit_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ /* DateEdit's "dateedit-flags" property hides/shows some widgets so we
+ * need to explicitly tell that they should not be affected by
+ * gtk_widget_show_all() (its, for example, called after a paste)
+ */
+ gtk_container_foreach (GTK_CONTAINER (object),
+ glade_gnome_date_edit_set_no_show_all, NULL);
+}
+
+/* GnomeDruid */
+static GladeWidget *
+glade_gnome_druid_add_page (GladeWidget *gdruid, gboolean edge)
+{
+ GladeWidget *gpage;
+ static GladeWidgetAdaptor *dps_adaptor = NULL, *dpe_adaptor;
+ GladeProject *project = glade_widget_get_project (gdruid);
+
+ if (dps_adaptor == NULL)
+ {
+ dps_adaptor = glade_widget_adaptor_get_by_type (GNOME_TYPE_DRUID_PAGE_STANDARD);
+ dpe_adaptor = glade_widget_adaptor_get_by_type (GNOME_TYPE_DRUID_PAGE_EDGE);
+ }
+
+ gpage = glade_widget_adaptor_create_widget (edge ? dpe_adaptor : dps_adaptor, FALSE,
+ "parent", gdruid,
+ "project", project, NULL);
+
+ glade_widget_add_child (gdruid, gpage, FALSE);
+
+ return gpage;
+}
+
+void GLADEGNOME_API
+glade_gnome_druid_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ GladeWidget *gdruid, *gpage;
+
+ if (reason != GLADE_CREATE_USER) return;
+
+ gdruid = glade_widget_get_from_gobject (object);
+
+ /* Add Start Page */
+ gpage = glade_gnome_druid_add_page (gdruid, TRUE);
+ glade_widget_property_set (gpage, "position", GNOME_EDGE_START);
+
+ /* Add Standard Pages */
+ glade_gnome_druid_add_page (gdruid, FALSE);
+
+ /* Add Finish Page */
+ gpage = glade_gnome_druid_add_page (gdruid, TRUE);
+ glade_widget_property_set (gpage, "position", GNOME_EDGE_FINISH);
+}
+
+static gboolean
+glade_gnome_druid_page_cb (GnomeDruidPage *druidpage,
+ GtkWidget *widget,
+ gpointer user_data)
+{
+ GnomeDruid *druid = GNOME_DRUID (widget);
+ GList *children, *l;
+ gboolean next = TRUE, back = TRUE;
+
+ children = l = gtk_container_get_children (GTK_CONTAINER (druid));
+ while (l)
+ {
+ if (druidpage == l->data) break;
+ l = l->next;
+ }
+
+ if (GPOINTER_TO_INT (user_data))
+ {
+ if (l->next)
+ {
+ gnome_druid_set_page (druid, (GnomeDruidPage *) l->next->data);
+ next = l->next->next != NULL;
+ }
+ }
+ else
+ {
+ if (l->prev)
+ {
+ gnome_druid_set_page (druid, (GnomeDruidPage *) l->prev->data);
+ back = l->prev->prev != NULL;
+ }
+ }
+
+ g_list_free (children);
+
+ gnome_druid_set_buttons_sensitive (druid, back, next, TRUE, TRUE);
+
+ return TRUE;
+}
+
+void GLADEGNOME_API
+glade_gnome_druid_add_child (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child)
+{
+ g_return_if_fail (GNOME_IS_DRUID_PAGE (child));
+
+ /*
+ Disconnect handlers just in case this child was already added
+ in another druid.
+ */
+ g_signal_handlers_disconnect_matched (child, G_SIGNAL_MATCH_FUNC, 0, 0, NULL,
+ glade_gnome_druid_page_cb, NULL);
+
+ gnome_druid_append_page (GNOME_DRUID (container), GNOME_DRUID_PAGE (child));
+
+ g_signal_connect (child, "next", G_CALLBACK (glade_gnome_druid_page_cb),
+ GINT_TO_POINTER (TRUE));
+ g_signal_connect (child, "back", G_CALLBACK (glade_gnome_druid_page_cb),
+ GINT_TO_POINTER (FALSE));
+}
+
+void GLADEGNOME_API
+glade_gnome_druid_remove_child (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child)
+{
+ g_return_if_fail (GNOME_IS_DRUID_PAGE (child));
+
+ g_signal_handlers_disconnect_matched (child, G_SIGNAL_MATCH_FUNC, 0, 0, NULL,
+ glade_gnome_druid_page_cb, NULL);
+
+ gtk_container_remove (GTK_CONTAINER (container), GTK_WIDGET (child));
+}
+
+static void
+glade_gnome_druid_insert_page (GnomeDruid *druid, GnomeDruidPage *page, gint pos)
+{
+ GList *children, *l;
+ GnomeDruidPage *back_page = NULL;
+ gint i = 0;
+
+ children = l = gtk_container_get_children (GTK_CONTAINER (druid));
+ while (l)
+ {
+ i++;
+ if (i >= pos)
+ {
+ back_page = (GnomeDruidPage *) l->data;
+ break;
+ }
+ l = l->next;
+ }
+
+ gnome_druid_insert_page (druid, back_page, page);
+
+ g_list_free (children);
+}
+
+static gint
+glade_gnome_druid_get_page_position (GnomeDruid *druid, GnomeDruidPage *page)
+{
+ GList *children, *l;
+ gint i = 0;
+
+ children = l = gtk_container_get_children (GTK_CONTAINER (druid));
+ while (l)
+ {
+ GnomeDruidPage *current = (GnomeDruidPage *) l->data;
+ if (current == page) break;
+ i++;
+ l = l->next;
+ }
+
+ g_list_free (children);
+
+ return i;
+}
+
+void GLADEGNOME_API
+glade_gnome_druid_set_child_property (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child,
+ const gchar *property_name,
+ GValue *value)
+{
+ g_return_if_fail (GNOME_IS_DRUID_PAGE (child));
+
+ if (strcmp (property_name, "position") == 0)
+ {
+ gint position = g_value_get_int (value);
+
+ if (position < 0)
+ {
+ position = glade_gnome_druid_get_page_position
+ (GNOME_DRUID (container),
+ GNOME_DRUID_PAGE (child));
+ g_value_set_int (value, position);
+ }
+
+ g_object_ref (child);
+ gtk_container_remove (GTK_CONTAINER (container), GTK_WIDGET (child));
+ glade_gnome_druid_insert_page (GNOME_DRUID (container),
+ GNOME_DRUID_PAGE (child),
+ position);
+ g_object_unref (child);
+ }
+ else
+ /* Chain Up */
+ GWA_GET_CLASS
+ (GTK_TYPE_CONTAINER)->child_set_property (adaptor,
+ container,
+ child,
+ property_name,
+ value);
+}
+
+void GLADEGNOME_API
+glade_gnome_druid_get_child_property (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child,
+ const gchar *property_name,
+ GValue *value)
+{
+ g_return_if_fail (GNOME_IS_DRUID_PAGE (child));
+
+ if (strcmp (property_name, "position") == 0)
+ g_value_set_int (value, glade_gnome_druid_get_page_position (
+ GNOME_DRUID (container),
+ GNOME_DRUID_PAGE (child)));
+ else
+ /* Chain Up */
+ GWA_GET_CLASS
+ (GTK_TYPE_CONTAINER)->child_get_property (adaptor,
+ container,
+ child,
+ property_name,
+ value);
+}
+
+/* GnomeDruidPageStandard */
+void GLADEGNOME_API
+glade_gnome_dps_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ GladeWidget *gpage, *gvbox;
+ GObject *vbox;
+
+ gpage = glade_widget_get_from_gobject (object);
+ vbox = G_OBJECT (GNOME_DRUID_PAGE_STANDARD (object)->vbox);
+ gvbox = glade_widget_adaptor_create_internal (gpage, vbox, "vbox",
+ glade_widget_get_name (gpage),
+ FALSE, GLADE_CREATE_LOAD);
+
+ if (reason == GLADE_CREATE_USER)
+ glade_widget_property_set (gvbox, "size", 1);
+}
+
+GObject * GLADEGNOME_API
+glade_gnome_dps_get_internal_child (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *name)
+{
+ GObject *child = NULL;
+
+ if (strcmp (name, "vbox") == 0)
+ child = G_OBJECT (GNOME_DRUID_PAGE_STANDARD (object)->vbox);
+
+ return child;
+}
+
+GList * GLADEGNOME_API
+glade_gnome_dps_get_children (GladeWidgetAdaptor *adaptor,
+ GObject *object)
+{
+ GnomeDruidPageStandard *page = GNOME_DRUID_PAGE_STANDARD (object);
+ GList *list = NULL;
+
+ if (page->vbox) list = g_list_append (list, G_OBJECT (page->vbox));
+
+ return list;
+}
+
+static void
+glade_gnome_dps_set_color_common (GObject *object,
+ const gchar *property_name,
+ const GValue *value)
+{
+ GladeProperty *prop;
+ const gchar *color_str;
+ GValue *color;
+
+ if ((color_str = g_value_get_string (value)) == NULL) return;
+
+ prop = glade_widget_get_property (glade_widget_get_from_gobject (object),
+ property_name);
+
+ color = glade_property_class_make_gvalue_from_string (prop->klass,
+ color_str, NULL);
+ if (color) glade_property_set_value (prop, color);
+}
+
+void GLADEGNOME_API
+glade_gnome_dps_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+
+ if (!strcmp (id, "background"))
+ glade_gnome_dps_set_color_common (object, "background-gdk", value);
+ else if (!strcmp (id, "contents-background"))
+ glade_gnome_dps_set_color_common (object, "contents-background-gdk", value);
+ else if (!strcmp (id, "logo-background"))
+ glade_gnome_dps_set_color_common (object, "logo-background-gdk", value);
+ else if (!strcmp (id, "title-foreground"))
+ glade_gnome_dps_set_color_common (object, "title-foreground-gdk", value);
+ else
+ /* Skip GNOME_TYPE_DRUID_PAGE since we didnt register an
+ * adaptor for that abstract class.
+ */
+ GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+
+/* GnomeDruidPageEdge */
+static GType
+glade_gnome_dpe_position_get_type (void)
+{
+ static GType etype = 0;
+ if (etype == 0) {
+ static const GEnumValue values[] = {
+ { GNOME_EDGE_START, "GNOME_EDGE_START", "Edge Start"},
+ { GNOME_EDGE_FINISH, "GNOME_EDGE_FINISH", "Edge Finish"},
+ { GNOME_EDGE_OTHER, "GNOME_EDGE_OTHER", "Edge Other"},
+ { 0, NULL, NULL }
+ };
+ etype = g_enum_register_static ("GladeGnomeDruidPagePosition", values);
+ }
+ return etype;
+}
+
+GParamSpec * GLADEGNOME_API
+glade_gnome_dpe_position_spec (void)
+{
+ return g_param_spec_enum ("position", _("Position"),
+ _("The position in the druid"),
+ glade_gnome_dpe_position_get_type (),
+ GNOME_EDGE_OTHER, G_PARAM_READWRITE);
+}
+
+void GLADEGNOME_API
+glade_gnome_dpe_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+
+{
+ GnomeDruidPageEdge *page = GNOME_DRUID_PAGE_EDGE (object);
+ const gchar *text = NULL;
+ GObject *pixbuf = NULL;
+ GdkColor *color = NULL;
+
+ if (G_VALUE_HOLDS (value, G_TYPE_STRING))
+ text = g_value_get_string (value);
+ else if (G_VALUE_HOLDS (value, GDK_TYPE_PIXBUF))
+ pixbuf = g_value_get_object (value);
+ else if (G_VALUE_HOLDS (value, GDK_TYPE_COLOR))
+ color = (GdkColor *) g_value_get_boxed (value);
+
+ if (!strcmp (id, "title"))
+ {
+ if (text) gnome_druid_page_edge_set_title (page, text);
+ }
+ else if (!strcmp (id, "text"))
+ {
+ if (text) gnome_druid_page_edge_set_text (page, text);
+ }
+ else if (!strcmp (id, "title-foreground"))
+ {
+ if (color) gnome_druid_page_edge_set_title_color (page, color);
+ }
+ else if (!strcmp (id, "text-foreground"))
+ {
+ if (color) gnome_druid_page_edge_set_text_color (page, color);
+ }
+ else if (!strcmp (id, "background"))
+ {
+ if (color) gnome_druid_page_edge_set_bg_color (page, color);
+ }
+ else if (!strcmp (id, "contents-background"))
+ {
+ if (color) gnome_druid_page_edge_set_textbox_color (page, color);
+ }
+ else if (!strcmp (id, "logo-background"))
+ {
+ if (color) gnome_druid_page_edge_set_logo_bg_color (page, color);
+ }
+ else if (!strcmp (id, "logo"))
+ gnome_druid_page_edge_set_logo (page, GDK_PIXBUF (pixbuf));
+ else if (!strcmp (id, "watermark"))
+ gnome_druid_page_edge_set_watermark (page, GDK_PIXBUF (pixbuf));
+ else if (!strcmp (id, "top-watermark"))
+ gnome_druid_page_edge_set_top_watermark (page, GDK_PIXBUF (pixbuf));
+ else if (!strcmp (id, "position"));
+ else
+ /* Skip GNOME_TYPE_DRUID_PAGE since we didnt register an
+ * adaptor for that abstract class.
+ */
+ GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomeIconEntry */
+void GLADEGNOME_API
+glade_gnome_icon_entry_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "max-saved"))
+ gnome_icon_entry_set_max_saved (GNOME_ICON_ENTRY (object),
+ g_value_get_uint (value));
+ else
+ GWA_GET_CLASS (GTK_TYPE_VBOX)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomeCanvas */
+typedef enum
+{
+ CANVAS_X1,
+ CANVAS_Y1,
+ CANVAS_X2,
+ CANVAS_Y2
+}GnomeCanvasCoordinate;
+
+static void
+glade_gnome_canvas_set_coordinate_common (GObject *object,
+ const GValue *value,
+ GnomeCanvasCoordinate coordinate)
+{
+ gdouble x1, y1, x2, y2;
+
+ gnome_canvas_get_scroll_region (GNOME_CANVAS (object),
+ &x1, &y1, &x2, &y2);
+
+ switch (coordinate)
+ {
+ case CANVAS_X1:
+ x1 = g_value_get_float (value);
+ break;
+ case CANVAS_Y1:
+ y1 = g_value_get_float (value);
+ break;
+ case CANVAS_X2:
+ x2 = g_value_get_float (value);
+ break;
+ case CANVAS_Y2:
+ y2 = g_value_get_float (value);
+ break;
+ }
+
+ gnome_canvas_set_scroll_region (GNOME_CANVAS (object), x1, y1, x2, y2);
+}
+
+void GLADEGNOME_API
+glade_gnome_canvas_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "pixels-per-unit"))
+ gnome_canvas_set_pixels_per_unit (GNOME_CANVAS (object),
+ g_value_get_float (value));
+ else if (!strcmp (id, "scroll-x1"))
+ glade_gnome_canvas_set_coordinate_common (object, value, CANVAS_X1);
+ else if (!strcmp (id, "scroll-x2"))
+ glade_gnome_canvas_set_coordinate_common (object, value, CANVAS_X2);
+ else if (!strcmp (id, "scroll-y1"))
+ glade_gnome_canvas_set_coordinate_common (object, value, CANVAS_Y1);
+ else if (!strcmp (id, "scroll-y2"))
+ glade_gnome_canvas_set_coordinate_common (object, value, CANVAS_Y2);
+ else
+ GWA_GET_CLASS (GTK_TYPE_LAYOUT)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomeDialog */
+static void
+glade_gnome_dialog_add_button (GladeWidget *gaction_area,
+ GObject *action_area,
+ const gchar *stock)
+{
+ GladeProject *project = glade_widget_get_project (gaction_area);
+ static GladeWidgetAdaptor *button_adaptor = NULL;
+ GladeWidget *gbutton;
+ GObject *button;
+ GEnumClass *eclass;
+ GEnumValue *eval;
+
+ if (button_adaptor == NULL)
+ button_adaptor = glade_widget_adaptor_get_by_type (GTK_TYPE_BUTTON);
+
+ gbutton = glade_widget_adaptor_create_widget (button_adaptor, FALSE,
+ "parent", gaction_area,
+ "project", project, FALSE);
+
+ eclass = g_type_class_ref (glade_standard_stock_get_type ());
+ if ((eval = g_enum_get_value_by_nick (eclass, stock)) != NULL)
+ {
+ glade_widget_property_set (gbutton, "glade-type", GLADEGTK_BUTTON_STOCK);
+ glade_widget_property_set (gbutton, "stock", eval->value);
+ }
+ g_type_class_unref (eclass);
+
+ button = glade_widget_get_object (gbutton);
+
+ glade_widget_adaptor_add (glade_widget_get_adaptor (gaction_area),
+ action_area, button);
+}
+
+void GLADEGNOME_API
+glade_gnome_dialog_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ GladeWidget *gdialog = glade_widget_get_from_gobject (object);
+ GnomeDialog *dialog = GNOME_DIALOG (object);
+ GladeWidget *gvbox, *gaction_area;
+ GtkWidget *separator;
+
+ /* Ignore close signal */
+ g_signal_connect (object, "close", G_CALLBACK (gtk_true), NULL);
+
+ if (GNOME_IS_PROPERTY_BOX (object))
+ {
+ GnomePropertyBox *pbox = GNOME_PROPERTY_BOX (object);
+
+ gaction_area = glade_widget_adaptor_create_internal
+ (gdialog, G_OBJECT (pbox->notebook), "notebook",
+ glade_widget_get_name (gdialog),
+ FALSE, GLADE_CREATE_LOAD);
+ if (reason == GLADE_CREATE_USER)
+ glade_widget_property_set (gaction_area, "pages", 3);
+ return;
+ }
+
+ /* vbox internal child */
+ gvbox = glade_widget_adaptor_create_internal
+ (gdialog, G_OBJECT (dialog->vbox), "vbox",
+ glade_widget_get_name (gdialog),
+ FALSE, GLADE_CREATE_LOAD);
+
+ glade_widget_property_set (gvbox, "size", 0);
+
+ /* action area */
+ dialog->action_area = gtk_hbutton_box_new ();
+ gtk_button_box_set_layout (GTK_BUTTON_BOX (dialog->action_area),
+ GTK_BUTTONBOX_END);
+
+ gtk_box_pack_end (GTK_BOX (dialog->vbox), dialog->action_area,
+ FALSE, TRUE, 0);
+ gtk_widget_show (dialog->action_area);
+
+ /* separator */
+ separator = gtk_hseparator_new ();
+ gtk_box_pack_end (GTK_BOX (dialog->vbox), separator,
+ FALSE, TRUE, GNOME_PAD_SMALL);
+ gtk_widget_show (separator);
+
+ /* action area internal child */
+ gaction_area =
+ glade_widget_adaptor_create_internal (gvbox,
+ G_OBJECT (dialog->action_area),
+ "action_area",
+ glade_widget_get_name (gvbox),
+ FALSE, GLADE_CREATE_LOAD);
+
+ glade_widget_property_set (gaction_area, "size", 0);
+
+ if (reason != GLADE_CREATE_USER) return;
+
+ /* Add a couple of buttons */
+ if (GNOME_IS_MESSAGE_BOX (object))
+ {
+ glade_gnome_dialog_add_button (gaction_area,
+ G_OBJECT (dialog->action_area),
+ "gtk-ok");
+ glade_widget_property_set (gaction_area, "size", 1);
+ }
+ else
+ {
+ glade_gnome_dialog_add_button (gaction_area,
+ G_OBJECT (dialog->action_area),
+ "gtk-cancel");
+ glade_gnome_dialog_add_button (gaction_area,
+ G_OBJECT (dialog->action_area),
+ "gtk-ok");
+ glade_widget_property_set (gaction_area, "size", 2);
+ glade_widget_property_set (gvbox, "size", 3);
+ }
+}
+
+GObject * GLADEGNOME_API
+glade_gnome_dialog_get_internal_child (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *name)
+{
+ GObject *child = NULL;
+
+ if (strcmp (name, "vbox") == 0)
+ child = G_OBJECT (GNOME_DIALOG (object)->vbox);
+ else if (GNOME_IS_PROPERTY_BOX (object) && strcmp (name, "notebook") == 0)
+ child = G_OBJECT (GNOME_PROPERTY_BOX (object)->notebook);
+
+ return child;
+}
+
+GList * GLADEGNOME_API
+glade_gnome_dialog_get_children (GladeWidgetAdaptor *adaptor,
+ GObject *object)
+{
+ GnomeDialog *dialog = GNOME_DIALOG (object);
+ GList *list = NULL;
+
+ if (dialog->vbox) list = g_list_append (list, G_OBJECT (dialog->vbox));
+
+ if (GNOME_IS_PROPERTY_BOX (object))
+ {
+ GnomePropertyBox *pbox = GNOME_PROPERTY_BOX (object);
+ if (pbox->notebook)
+ list = g_list_append (list, G_OBJECT (pbox->notebook));
+ }
+
+ return list;
+}
+
+/* GnomeAbout */
+void GLADEGNOME_API
+glade_gnome_about_dialog_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ gtk_dialog_set_response_sensitive (GTK_DIALOG (object), GTK_RESPONSE_CLOSE, FALSE);
+}
+
+void GLADEGNOME_API
+glade_gnome_about_dialog_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "name") ||
+ !strcmp (id, "version"))
+ {
+ if (g_value_get_string (value))
+ g_object_set_property (object, id, value);
+ }
+ else
+ GWA_GET_CLASS (GTK_TYPE_DIALOG)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomeMessageBox */
+typedef enum {
+ GLADE_GNOME_MESSAGE_BOX_INFO,
+ GLADE_GNOME_MESSAGE_BOX_WARNING,
+ GLADE_GNOME_MESSAGE_BOX_ERROR,
+ GLADE_GNOME_MESSAGE_BOX_QUESTION,
+ GLADE_GNOME_MESSAGE_BOX_GENERIC
+}GladeGnomeMessageBoxType;
+
+static GType
+glade_gnome_message_box_type_get_type (void)
+{
+ static GType etype = 0;
+ if (etype == 0) {
+ static const GEnumValue values[] = {
+ { GLADE_GNOME_MESSAGE_BOX_INFO, "GNOME_MESSAGE_BOX_INFO", "info"},
+ { GLADE_GNOME_MESSAGE_BOX_WARNING, "GNOME_MESSAGE_BOX_WARNING", "warning"},
+ { GLADE_GNOME_MESSAGE_BOX_ERROR, "GNOME_MESSAGE_BOX_ERROR", "error"},
+ { GLADE_GNOME_MESSAGE_BOX_QUESTION, "GNOME_MESSAGE_BOX_QUESTION", "question"},
+ { GLADE_GNOME_MESSAGE_BOX_GENERIC, "GNOME_MESSAGE_BOX_GENERIC", "generic"},
+ { 0, NULL, NULL }
+ };
+ etype = g_enum_register_static ("GladeGnomeMessageBoxType", values);
+ }
+ return etype;
+}
+
+GParamSpec * GLADEGNOME_API
+glade_gnome_message_box_type_spec (void)
+{
+ return g_param_spec_enum ("message_box_type", _("Message box type"),
+ _("The type of the message box"),
+ glade_gnome_message_box_type_get_type (),
+ 0, G_PARAM_READWRITE);
+}
+
+static gchar *
+glade_gnome_message_get_str (GladeGnomeMessageBoxType val)
+{
+ switch (val)
+ {
+ case GLADE_GNOME_MESSAGE_BOX_INFO:
+ return "info";
+ case GLADE_GNOME_MESSAGE_BOX_WARNING:
+ return "warning";
+ case GLADE_GNOME_MESSAGE_BOX_ERROR:
+ return "error";
+ case GLADE_GNOME_MESSAGE_BOX_QUESTION:
+ return "question";
+ case GLADE_GNOME_MESSAGE_BOX_GENERIC:
+ return "generic";
+ }
+ return "";
+}
+
+static void
+glade_gnome_message_clean (GObject *object)
+{
+ GtkContainer *container = GTK_CONTAINER (GNOME_DIALOG (object)->vbox);
+ GList *children, *l;
+
+ children = gtk_container_get_children (container);
+
+ for (l = children; l; l = l->next)
+ {
+ GtkWidget *child = (GtkWidget *) l->data;
+
+ if (GTK_IS_HBOX (child))
+ {
+ gtk_container_remove (container, child);
+ break;
+ }
+ }
+
+ g_list_free (children);
+}
+
+static void
+glade_gnome_message_box_set_type (GObject *object, const GValue *value)
+{
+ gchar *message, *type;
+
+ glade_gnome_message_clean (object);
+ glade_widget_property_get (glade_widget_get_from_gobject (object),
+ "message", &message);
+ type = glade_gnome_message_get_str (g_value_get_enum (value));
+ gnome_message_box_construct (GNOME_MESSAGE_BOX (object),
+ message, type, NULL);
+}
+
+static void
+glade_gnome_message_box_set_message (GObject *object, const GValue *value)
+{
+ GladeGnomeMessageBoxType type;
+
+ glade_gnome_message_clean (object);
+ glade_widget_property_get (glade_widget_get_from_gobject (object),
+ "message-box-type", &type);
+ gnome_message_box_construct (GNOME_MESSAGE_BOX (object),
+ g_value_get_string (value),
+ glade_gnome_message_get_str (type),
+ NULL);
+}
+
+void GLADEGNOME_API
+glade_gnome_message_box_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "message-box-type"))
+ glade_gnome_message_box_set_type (object, value);
+ else if (!strcmp (id, "message"))
+ glade_gnome_message_box_set_message (object, value);
+ else
+ GWA_GET_CLASS (GNOME_TYPE_DIALOG)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomeEntry & GnomeFileEntry */
+/* GnomeFileEntry is not derived from GnomeEntry... but hey!!! they should :) */
+GObject * GLADEGNOME_API
+glade_gnome_entry_get_internal_child (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *name)
+{
+ GObject *child = NULL;
+
+ if (strcmp (name, "entry") == 0)
+ {
+ if (GNOME_IS_ENTRY (object))
+ child = G_OBJECT (gnome_entry_gtk_entry (GNOME_ENTRY (object)));
+ else
+ child = G_OBJECT (gnome_file_entry_gtk_entry (GNOME_FILE_ENTRY (object)));
+ }
+
+ return child;
+}
+
+void GLADEGNOME_API
+glade_gnome_entry_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ GladeWidget *gentry;
+ GObject *child;
+
+ child = glade_gnome_entry_get_internal_child (adaptor, object, "entry");
+
+ gentry = glade_widget_get_from_gobject (object);
+ glade_widget_adaptor_create_internal (gentry,
+ child, "entry",
+ glade_widget_get_name (gentry),
+ FALSE, reason);
+}
+
+GList * GLADEGNOME_API
+glade_gnome_entry_get_children (GladeWidgetAdaptor *adaptor,
+ GObject *object)
+{
+ GList *list = NULL;
+ GtkWidget *entry;
+
+ if (GNOME_IS_ENTRY (object))
+ entry = gnome_entry_gtk_entry (GNOME_ENTRY (object));
+ else
+ entry = gnome_file_entry_gtk_entry (GNOME_FILE_ENTRY (object));
+
+ if (entry) list = g_list_append (list, G_OBJECT (entry));
+
+ return list;
+}
+
+void GLADEGNOME_API
+glade_gnome_entry_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "max-saved"))
+ gnome_entry_set_max_saved (GNOME_ENTRY (object), g_value_get_int (value));
+ else
+ GWA_GET_CLASS (GTK_TYPE_COMBO)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+void GLADEGNOME_API
+glade_gnome_file_entry_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ GtkWidget *entry;
+
+ if (!strcmp (id, "max-saved"))
+ {
+ entry = gnome_file_entry_gnome_entry (GNOME_FILE_ENTRY (object));
+ gnome_entry_set_max_saved (GNOME_ENTRY (entry), g_value_get_int (value));
+ }
+ else
+ GWA_GET_CLASS (GTK_TYPE_VBOX)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomePixmapEntry */
+void GLADEGNOME_API
+glade_gnome_pixmap_entry_set_do_preview (GObject *object, GValue *value)
+{
+ gnome_pixmap_entry_set_preview (GNOME_PIXMAP_ENTRY (object),
+ g_value_get_boolean (value));
+}
+
+/* GnomeFontPicker */
+static void
+glade_gnome_font_picker_set_mode (GObject *object, const GValue *value)
+{
+ GladeWidget *ggfp, *gchild;
+ GnomeFontPicker *gfp;
+ GnomeFontPickerMode mode;
+ GObject *child;
+
+ mode = g_value_get_enum (value);
+ if (mode == GNOME_FONT_PICKER_MODE_UNKNOWN) return;
+
+ gfp = GNOME_FONT_PICKER (object);
+ child = G_OBJECT (gnome_font_picker_uw_get_widget (gfp));
+ if (child && (gchild = glade_widget_get_from_gobject (child)))
+ glade_project_remove_object (glade_widget_get_project (gchild),
+ child);
+
+ gnome_font_picker_set_mode (gfp, mode);
+
+ ggfp = glade_widget_get_from_gobject (object);
+ switch (mode)
+ {
+ const gchar *reason;
+ case GNOME_FONT_PICKER_MODE_FONT_INFO:
+ glade_widget_property_set_sensitive (ggfp, "show-size", TRUE, NULL);
+ glade_widget_property_set_sensitive (ggfp, "use-font-in-label", TRUE, NULL);
+ glade_widget_property_set_sensitive (ggfp, "label-font-size", TRUE, NULL);
+ break;
+ case GNOME_FONT_PICKER_MODE_USER_WIDGET:
+ gnome_font_picker_uw_set_widget (gfp, glade_placeholder_new ());
+ case GNOME_FONT_PICKER_MODE_PIXMAP:
+ reason = _("This property is valid only in font information mode");
+ glade_widget_property_set_sensitive (ggfp, "show-size", FALSE, reason);
+ glade_widget_property_set_sensitive (ggfp, "use-font-in-label", FALSE, reason);
+ glade_widget_property_set_sensitive (ggfp, "label-font-size", FALSE, reason);
+ default: break;
+ }
+}
+
+void GLADEGNOME_API
+glade_gnome_font_picker_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "mode"))
+ glade_gnome_font_picker_set_mode (object, value);
+ else
+ GWA_GET_CLASS (GTK_TYPE_BUTTON)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+GList * GLADEGNOME_API
+glade_gnome_font_picker_get_children (GladeWidgetAdaptor *adaptor,
+ GObject *object)
+{
+ GtkWidget *child;
+
+ if ((child = gnome_font_picker_uw_get_widget (GNOME_FONT_PICKER (object))))
+ return g_list_append (NULL, G_OBJECT (child));
+ else
+ return NULL;
+}
+
+void GLADEGNOME_API
+glade_gnome_font_picker_add_child (GladeWidgetAdaptor *adaptor,
+ GtkWidget *container,
+ GtkWidget *child)
+{
+ gnome_font_picker_uw_set_widget (GNOME_FONT_PICKER (container), child);
+}
+
+void GLADEGNOME_API
+glade_gnome_font_picker_remove_child (GladeWidgetAdaptor *adaptor,
+ GtkWidget *container,
+ GtkWidget *child)
+{
+ gnome_font_picker_uw_set_widget (GNOME_FONT_PICKER (container), glade_placeholder_new ());
+}
+
+void GLADEGNOME_API
+glade_gnome_font_picker_replace_child (GladeWidgetAdaptor *adaptor,
+ GtkWidget *container,
+ GtkWidget *current,
+ GtkWidget *new_widget)
+{
+ gnome_font_picker_uw_set_widget (GNOME_FONT_PICKER (container), new_widget);
+}
+
+/* GnomeIconList */
+void GLADEGNOME_API
+glade_gnome_icon_list_post_create (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GladeCreateReason reason)
+{
+ /* Freeze the widget so we dont get the signals that cause a segfault */
+ gnome_icon_list_freeze (GNOME_ICON_LIST (object));
+}
+
+static GType
+glade_gnome_icon_list_selection_mode_get_type (void)
+{
+ static GType etype = 0;
+ if (etype == 0) {
+ static const GEnumValue values[] = {
+ { GTK_SELECTION_SINGLE, "GTK_SELECTION_SINGLE", "Single"},
+ { GTK_SELECTION_BROWSE, "GTK_SELECTION_BROWSE", "Browse"},
+ { GTK_SELECTION_MULTIPLE, "GTK_SELECTION_MULTIPLE", "Multiple"},
+ { 0, NULL, NULL }
+ };
+ etype = g_enum_register_static ("GladeGnomeIconListSelectionMode", values);
+ }
+ return etype;
+}
+
+GParamSpec * GLADEGNOME_API
+glade_gnome_icon_list_selection_mode_spec (void)
+{
+ return g_param_spec_enum ("selection_mode", _("Selection Mode"),
+ _("Choose the Selection Mode"),
+ glade_gnome_icon_list_selection_mode_get_type (),
+ GTK_SELECTION_SINGLE, G_PARAM_READWRITE);
+}
+
+void GLADEGNOME_API
+glade_gnome_icon_list_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "selection-mode"))
+ gnome_icon_list_set_selection_mode (GNOME_ICON_LIST (object),
+ g_value_get_enum (value));
+ else if (!strcmp (id, "icon-width"))
+ gnome_icon_list_set_icon_width (GNOME_ICON_LIST (object),
+ g_value_get_int (value));
+ else if (!strcmp (id, "row-spacing"))
+ gnome_icon_list_set_row_spacing (GNOME_ICON_LIST (object),
+ g_value_get_int (value));
+ else if (!strcmp (id, "column-spacing"))
+ gnome_icon_list_set_col_spacing (GNOME_ICON_LIST (object),
+ g_value_get_int (value));
+ else if (!strcmp (id, "text-spacing"))
+ gnome_icon_list_set_text_spacing (GNOME_ICON_LIST (object),
+ g_value_get_int (value));
+ else
+ GWA_GET_CLASS (GNOME_TYPE_CANVAS)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+/* GnomePixmap */
+static gint
+glade_gnome_pixmap_set_filename_common (GObject *object)
+{
+ GladeWidget *gp;
+ gint width, height;
+
+ gp = glade_widget_get_from_gobject (object);
+ glade_widget_property_get (gp, "scaled-width", &width);
+ glade_widget_property_get (gp, "scaled-height", &height);
+
+ if (width && height)
+ {
+ GladeProperty *property = glade_widget_get_property (gp, "filename");
+ gchar *file = glade_property_class_make_string_from_gvalue
+ (property->klass, property->value);
+ if (file)
+ {
+ gnome_pixmap_load_file_at_size (GNOME_PIXMAP (object),
+ file, width, height);
+ g_free (file);
+ return 0;
+ }
+ }
+
+ return -1;
+}
+
+static void
+glade_gnome_pixmap_set_scaled_common (GObject *object,
+ const GValue *value,
+ const gchar *property)
+{
+ if (glade_gnome_pixmap_set_filename_common (object))
+ {
+ GladeWidget *gp = glade_widget_get_from_gobject (object);
+ gint val2, val = g_value_get_int (value);
+ GObject *pixbuf;
+
+ glade_widget_property_get (gp, "filename", &pixbuf);
+ glade_widget_property_set (gp, "filename", pixbuf);
+
+ if (val)
+ {
+ glade_widget_property_get (gp, property, &val2);
+ if (val2 == 0)
+ glade_widget_property_set (gp, property, val);
+ }
+ else
+ glade_widget_property_set (gp, property, 0);
+ }
+}
+
+void GLADEGNOME_API
+glade_gnome_pixmap_set_scaled_width (GObject *object, GValue *value)
+{
+ glade_gnome_pixmap_set_scaled_common (object, value, "scaled-height");
+}
+
+void GLADEGNOME_API
+glade_gnome_pixmap_set_scaled_height (GObject *object, GValue *value)
+{
+ glade_gnome_pixmap_set_scaled_common (object, value, "scaled-width");
+}
+
+
+void GLADEGNOME_API
+glade_gnome_pixmap_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "filename"))
+ {
+ if (glade_gnome_pixmap_set_filename_common (object))
+ gtk_image_set_from_pixbuf (GTK_IMAGE(object),
+ GDK_PIXBUF (g_value_get_object (value)));
+ }
+ else if (!strcmp (id, "scaled-width") ||
+ !strcmp (id, "scaled-height"))
+ glade_gnome_pixmap_set_scaled_common (object, value, id);
+ else
+ GWA_GET_CLASS (GTK_TYPE_IMAGE)->set_property (adaptor,
+ object,
+ id, value);
+}
+
+
+/*
+ BBBB OOOO NN NN OOOO BBBB OOOO
+ BB B OO OO NNN NN OO OO BB B OO OO
+ BBBB OO OO NN N NN OO OO BBBB OO OO
+ BB B OO OO NN NNN OO OO BB B OO OO
+ BBBB OOOO NN NN OOOO BBBB OOOO
+*/
+
+/* GladeGnomeBonoboDockPlacement */
+static GType
+glade_gnome_bonobo_dock_placement_get_type (void)
+{
+ static GType etype = 0;
+ if (etype == 0) {
+ static const GEnumValue values[] = {
+ { BONOBO_DOCK_TOP, "BONOBO_DOCK_TOP", "Top"},
+ { BONOBO_DOCK_RIGHT, "BONOBO_DOCK_RIGHT", "Right"},
+ { BONOBO_DOCK_BOTTOM, "BONOBO_DOCK_BOTTOM", "Bottom"},
+ { BONOBO_DOCK_LEFT, "BONOBO_DOCK_LEFT", "Left"},
+ { BONOBO_DOCK_FLOATING, "BONOBO_DOCK_FLOATING", "Floating"},
+ { 0, NULL, NULL }
+ };
+ etype = g_enum_register_static ("GladeGnomeBonoboDockPlacement", values);
+ }
+ return etype;
+}
+
+GParamSpec * GLADEGNOME_API
+glade_gnome_bonobo_dock_placement_spec (void)
+{
+ return g_param_spec_enum ("placement", _("Placement"),
+ _("Choose the BonoboDockPlacement type"),
+ glade_gnome_bonobo_dock_placement_get_type (),
+ 0, G_PARAM_READWRITE);
+}
+
+/* GladeGnomeBonoboDockItemBehavior */
+static GType
+glade_gnome_bonobo_dock_item_behavior_get_type (void)
+{
+ static GType etype = 0;
+ if (etype == 0) {
+ static const GFlagsValue values[] = {
+ /*BONOBO_DOCK_ITEM_BEH_NORMAL is 0 so we do not include it. */
+ { BONOBO_DOCK_ITEM_BEH_EXCLUSIVE, "BONOBO_DOCK_ITEM_BEH_EXCLUSIVE", "Exclusive"},
+ { BONOBO_DOCK_ITEM_BEH_NEVER_FLOATING, "BONOBO_DOCK_ITEM_BEH_NEVER_FLOATING", "Never Floating"},
+ { BONOBO_DOCK_ITEM_BEH_NEVER_VERTICAL, "BONOBO_DOCK_ITEM_BEH_NEVER_VERTICAL", "Never Vertical"},
+ { BONOBO_DOCK_ITEM_BEH_NEVER_HORIZONTAL, "BONOBO_DOCK_ITEM_BEH_NEVER_HORIZONTAL", "Never Horizontal"},
+ { BONOBO_DOCK_ITEM_BEH_LOCKED, "BONOBO_DOCK_ITEM_BEH_LOCKED", "Locked"},
+ { 0, NULL, NULL }
+ };
+ etype = g_flags_register_static ("GladeGnomeBonoboDockItemBehavior", values);
+ }
+ return etype;
+}
+
+GParamSpec * GLADEGNOME_API
+glade_gnome_bonobo_dock_item_behavior_spec (void)
+{
+ return g_param_spec_flags ("behavior", _("Behavior"),
+ _("Choose the BonoboDockItemBehavior type"),
+ glade_gnome_bonobo_dock_item_behavior_get_type (),
+ 0, G_PARAM_READWRITE);
+}
+
+/* GtkPackType */
+GParamSpec * GLADEGNOME_API
+glade_gnome_gtk_pack_type_spec (void)
+{
+ return g_param_spec_enum ("pack_type", _("Pack Type"),
+ _("Choose the Pack Type"),
+ g_type_from_name ("GtkPackType"),
+ 0, G_PARAM_READWRITE);
+}
+
+/* BonoboDockBand convenience functions */
+static BonoboDockBand *
+glade_gnome_bdb_get_band (GList *bands, GtkWidget *widget)
+{
+ GList *l;
+
+ for (l = bands; l; l = l->next)
+ {
+ BonoboDockBand *band = (BonoboDockBand *) l->data;
+ GList *cl;
+ for (cl = band->children; cl; cl = cl->next)
+ {
+ BonoboDockBandChild *child = (BonoboDockBandChild *) cl->data;
+ if (child->widget == widget) return band;
+ }
+ }
+
+ return NULL;
+}
+
+static BonoboDockBand *
+glade_gnome_bd_get_band (BonoboDock *dock, GtkWidget *widget)
+{
+ BonoboDockBand *retval = NULL;
+
+ if ((retval = glade_gnome_bdb_get_band (dock->top_bands, widget)) ||
+ (retval = glade_gnome_bdb_get_band (dock->bottom_bands, widget)) ||
+ (retval = glade_gnome_bdb_get_band (dock->right_bands, widget)) ||
+ (retval = glade_gnome_bdb_get_band (dock->left_bands, widget)));
+
+ return retval;
+}
+
+/* BonoboDock */
+void GLADEGNOME_API
+glade_gnome_bonobodock_add_child (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GObject *child)
+{
+ if (BONOBO_IS_DOCK_ITEM (child))
+ bonobo_dock_add_item (BONOBO_DOCK (object), BONOBO_DOCK_ITEM (child),
+ 0,0,0,0, TRUE);
+ else if (GTK_IS_WIDGET (child))
+ bonobo_dock_set_client_area (BONOBO_DOCK (object), GTK_WIDGET (child));
+}
+
+void GLADEGNOME_API
+glade_gnome_bonobodock_remove_child (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ GObject *child)
+{
+ BonoboDockBand *band;
+
+ band = glade_gnome_bd_get_band (BONOBO_DOCK (object), GTK_WIDGET (child));
+
+ gtk_container_remove (GTK_CONTAINER (band), GTK_WIDGET (child));
+}
+
+GList * GLADEGNOME_API
+glade_gnome_bonobodock_get_children (GladeWidgetAdaptor *adaptor,
+ GObject *object)
+{
+ GList *list = NULL, *l;
+ GtkWidget *client_area;
+ BonoboDockLayout *layout;
+
+ layout = bonobo_dock_get_layout (BONOBO_DOCK (object));
+ client_area = bonobo_dock_get_client_area (BONOBO_DOCK (object));
+
+ for (l = layout->items; l; l = l->next)
+ {
+ BonoboDockLayoutItem *li = (BonoboDockLayoutItem *) l->data;
+ list = g_list_prepend (list, li->item);
+ }
+
+ if (client_area)
+ list = g_list_prepend (list, client_area);
+
+ return g_list_reverse (list);
+}
+
+void GLADEGNOME_API
+glade_gnome_bonobodock_replace_child (GladeWidgetAdaptor *adaptor,
+ GtkWidget *container,
+ GtkWidget *current,
+ GtkWidget *new_widget)
+{
+ bonobo_dock_set_client_area (BONOBO_DOCK (container), new_widget);
+}
+
+static gboolean
+glade_gnome_bonobodockitem_get_props (BonoboDock *doc,
+ BonoboDockItem *item,
+ BonoboDockPlacement *placement,
+ guint *band_num,
+ guint *band_position,
+ guint *offset)
+{
+ BonoboDockLayout *layout = bonobo_dock_get_layout (doc);
+ GList *l;
+
+ for (l = layout->items; l; l = l->next)
+ {
+ BonoboDockLayoutItem *li = (BonoboDockLayoutItem *) l->data;
+ if (li->item == item)
+ {
+ *placement = li->placement;
+ *band_num = li->position.docked.band_num;
+ *band_position = li->position.docked.band_position;
+ *offset = li->position.docked.offset;
+
+ return TRUE;
+ }
+ }
+
+ return FALSE;
+}
+
+void GLADEGNOME_API
+glade_gnome_bonobodock_set_child_property (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child,
+ const gchar *property_name,
+ GValue *value)
+{
+ BonoboDock *dock;
+ BonoboDockItem *item;
+ BonoboDockPlacement placement;
+ guint band_num, band_position, offset;
+ BonoboDockBand *band;
+ GtkWidget *wchild;
+ gboolean new_band = FALSE;
+
+ if (!BONOBO_IS_DOCK_ITEM (child))
+ /* Ignore packing properties of client area */
+ return;
+
+ dock = BONOBO_DOCK (container);
+ item = BONOBO_DOCK_ITEM (child);
+
+ if (strcmp ("behavior", property_name) == 0)
+ {
+ bonobo_dock_item_set_behavior (item, g_value_get_flags (value));
+ return;
+ }
+
+ wchild = GTK_WIDGET (child);
+ glade_gnome_bonobodockitem_get_props (dock, item, &placement, &band_num,
+ &band_position, &offset);
+
+ if (strcmp ("placement", property_name) == 0)
+ placement = g_value_get_enum (value);
+ else if (strcmp ("position", property_name) == 0)
+ band_position = g_value_get_int (value);
+ else if (strcmp ("band", property_name) == 0)
+ band_num = g_value_get_int (value);
+ else if (strcmp ("offset", property_name) == 0)
+ offset = g_value_get_int (value);
+ else
+ {
+ g_warning ("No BonoboDock set packing property support for '%s'.", property_name);
+ return;
+ }
+
+ if ((band = glade_gnome_bd_get_band (dock, wchild)))
+ {
+ g_object_ref (child);
+ gtk_container_remove (GTK_CONTAINER (band), wchild);
+
+ if (band->num_children == 0)
+ {
+ new_band = TRUE;
+ gtk_container_remove (GTK_CONTAINER (container), GTK_WIDGET(band));
+ }
+
+ bonobo_dock_add_item (dock, item, placement, band_num,
+ band_position, offset, new_band);
+ bonobo_dock_item_set_behavior (item, item->behavior);
+ g_object_unref (child);
+ }
+ else
+ g_warning ("BonoboDockItem's band not found.\n");
+}
+
+void GLADEGNOME_API
+glade_gnome_bonobodock_get_child_property (GladeWidgetAdaptor *adaptor,
+ GObject *container,
+ GObject *child,
+ const gchar *property_name,
+ GValue *value)
+{
+ BonoboDockPlacement placement;
+ guint band_num, band_position, offset;
+
+ if (!BONOBO_IS_DOCK_ITEM (child))
+ /* Ignore packing properties of client area,
+ *
+ * FIXME: packing properties should actually be removed
+ * from client area children using glade_widget_remove_property();
+ */
+ return;
+
+ if (strcmp ("behavior", property_name) == 0)
+ {
+ g_value_set_flags (value, BONOBO_DOCK_ITEM (child)->behavior);
+ return;
+ }
+
+ glade_gnome_bonobodockitem_get_props (BONOBO_DOCK (container),
+ BONOBO_DOCK_ITEM (child),
+ &placement, &band_num,
+ &band_position, &offset);
+
+ if (strcmp ("placement", property_name) == 0)
+ g_value_set_enum (value, placement);
+ else if (strcmp ("position", property_name) == 0)
+ g_value_set_int (value, band_position);
+ else if (strcmp ("band", property_name) == 0)
+ g_value_set_int (value, band_num);
+ else if (strcmp ("offset", property_name) == 0)
+ g_value_set_int (value, offset);
+}
+
+void GLADEGNOME_API
+glade_gnome_bonobodock_set_property (GladeWidgetAdaptor *adaptor,
+ GObject *object,
+ const gchar *id,
+ const GValue *value)
+{
+ if (!strcmp (id, "allow-floating"))
+ bonobo_dock_allow_floating_items (BONOBO_DOCK (object),
+ g_value_get_boolean (value));
+ else
+ GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor,
+ object,
+ id, value);
+}
diff --git a/plugins/gnome/gnome.xml.in b/plugins/gnome/gnome.xml.in
new file mode 100644
index 00000000..d08a712e
--- /dev/null
+++ b/plugins/gnome/gnome.xml.in
@@ -0,0 +1,390 @@
+<glade-catalog name="gnome" library="gladegnome" depends="gtk+" domain="glade-3" book="libgnomeui">
+ <init-function>glade_gnomeui_init</init-function>
+ <glade-widget-classes>
+ <glade-widget-class name="GnomeApp" generic-name="gnomeapp" title="Gnome App">
+ <post-create-function>glade_gnome_app_post_create</post-create-function>
+ <get-internal-child-function>glade_gnome_app_get_internal_child</get-internal-child-function>
+ <get-children-function>glade_gnome_app_get_children</get-children-function>
+ <child-set-property-function>glade_gnome_app_set_child_property</child-set-property-function>
+ <child-get-property-function>glade_gnome_app_get_child_property</child-get-property-function>
+ <set-property-function>glade_gnome_app_set_property</set-property-function>
+
+ <properties>
+ <property id="has-statusbar" _name="StatusBar" save="False">
+ <tooltip>If the window has a statusbar</tooltip>
+ <spec>glade_standard_boolean_spec</spec>
+ </property>
+ <property id="enable-layout-config" _name="Store Config">
+ <tooltip>If the layout is saved and restored automatically</tooltip>
+ <spec>glade_standard_boolean_spec</spec>
+ </property>
+ </properties>
+ <packing-properties>
+ <property id="position" _name="Position">
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="padding" _name="Padding">
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ <property id="expand" _name="Expand">
+ <spec>glade_standard_boolean_spec</spec>
+ </property>
+ <property id="fill" _name="Fill">
+ <spec>glade_standard_boolean_spec</spec>
+ </property>
+ <property id="pack-type">
+ <spec>glade_gnome_gtk_pack_type_spec</spec>
+ <displayable-values>
+ <value id="GTK_PACK_START" _name="Start"/>
+ <value id="GTK_PACK_END" _name="End"/>
+ </displayable-values>
+ </property>
+ </packing-properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeDruid" generic-name="gnomedruid" title="Gnome Druid">
+ <post-create-function>glade_gnome_druid_post_create</post-create-function>
+ <add-child-function>glade_gnome_druid_add_child</add-child-function>
+ <remove-child-function>glade_gnome_druid_remove_child</remove-child-function>
+ <child-set-property-function>glade_gnome_druid_set_child_property</child-set-property-function>
+ <child-get-property-function>glade_gnome_druid_get_child_property</child-get-property-function>
+
+ <packing-properties>
+ <property id="position" _name="Position" default="-1" save="False">
+ <spec>glade_standard_int_spec</spec>
+ </property>
+ </packing-properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeDruidPageEdge" generic-name="gnomedruidpageedge" title="Gnome Druid Page Edge">
+ <set-property-function>glade_gnome_dpe_set_property</set-property-function>
+ <properties>
+ <property id="position" _name="Position">
+ <spec>glade_gnome_dpe_position_spec</spec>
+ <_tooltip>Used to pass around information about the position of a GnomeDruidPage within the overall GnomeDruid. This enables the correct "surrounding" content for the page to be drawn</_tooltip>
+ <displayable-values>
+ <value id="GNOME_EDGE_START" _name="Start"/>
+ <value id="GNOME_EDGE_FINISH" _name="End"/>
+ <value id="GNOME_EDGE_OTHER" _name="Other"/>
+ </displayable-values>
+ </property>
+ <property id="title" _name="Title" translatable="True">
+ <spec>glade_standard_string_spec</spec>
+ <visible-lines>2</visible-lines>
+ </property>
+ <property id="text" _name="Text" translatable="True">
+ <spec>glade_standard_string_spec</spec>
+ <visible-lines>4</visible-lines>
+ </property>
+ <property id="title-foreground" _name="Title Foreground Color" default="#FFFFFF">
+ <spec>glade_standard_gdkcolor_spec</spec>
+ </property>
+ <property id="text-foreground" _name="Text Foreground Color" default="#000000">
+ <spec>glade_standard_gdkcolor_spec</spec>
+ </property>
+ <property id="background" _name="Background Color" default="#4B6983">
+ <spec>glade_standard_gdkcolor_spec</spec>
+ </property>
+ <property id="contents-background" _name="Contents Background Color" default="#DCDAD5">
+ <spec>glade_standard_gdkcolor_spec</spec>
+ </property>
+ <property id="logo-background" _name="Logo Background Color" default="#4B6983">
+ <spec>glade_standard_gdkcolor_spec</spec>
+ </property>
+ <property id="logo" _name="Logo">
+ <spec>glade_standard_pixbuf_spec</spec>
+ </property>
+ <property id="watermark" _name="Watermark">
+ <spec>glade_standard_pixbuf_spec</spec>
+ </property>
+ <property id="top-watermark" _name="Top Watermark">
+ <spec>glade_standard_pixbuf_spec</spec>
+ </property>
+ </properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeDruidPageStandard" generic-name="gnomedruidpagestandard" title="Gnome Druid Page Standard">
+ <post-create-function>glade_gnome_dps_post_create</post-create-function>
+ <get-internal-child-function>glade_gnome_dps_get_internal_child</get-internal-child-function>
+ <get-children-function>glade_gnome_dps_get_children</get-children-function>
+ <set-property-function>glade_gnome_dps_set_property</set-property-function>
+
+ <properties>
+ <property id="title" translatable="True">
+ <visible-lines>2</visible-lines>
+ </property>
+
+ <property id="background-set" disabled="True"/>
+ <property id="background" visible="False" save="False" default="#4B6983"/>
+ <property id="contents-background-set" disabled="True"/>
+ <property id="contents-background" visible="False" save="False" default="#DCDAD5"/>
+ <property id="logo-background-set" disabled="True"/>
+ <property id="logo-background" visible="False" save="False" default="#4B6983"/>
+ <property id="title-foreground-set" disabled="True"/>
+ <property id="title-foreground" visible="False" save="False" default="#FFFFFF"/>
+ </properties>
+ </glade-widget-class>
+
+
+ <glade-widget-class name="GnomeIconSelection" generic-name="gnomeiconselection" title="Gnome Icon Selection">
+ <properties>
+ <property id="size" visible="False" query="False" ignore="True"/>
+ </properties>
+ </glade-widget-class>
+ <glade-widget-class name="GnomeIconEntry" generic-name="gnomeiconentry" title="Gnome Icon Entry">
+ <set-property-function>glade_gnome_icon_entry_set_property</set-property-function>
+ <properties>
+ <property id="max-saved" _name="Max Saved">
+ <spec>glade_standard_uint_spec</spec>
+ <tooltip>The maximum number of history entries saved.</tooltip>
+ </property>
+ <property id="size" visible="False" query="False" ignore="True"/>
+ </properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeHRef" generic-name="gnomehref" title="Gnome HRef"/>
+
+ <glade-widget-class name="GnomeDateEdit" generic-name="gnomedateedit" title="Gnome Date Edit">
+ <post-create-function>glade_gnome_date_edit_post_create</post-create-function>
+ <properties>
+ <property id="time" disabled="True"/>
+ <property id="size" visible="False" query="False" ignore="True"/>
+ <property id="dateedit-flags">
+ <displayable-values>
+ <value id="GNOME_DATE_EDIT_SHOW_TIME" _name="Show Time"/>
+ <value id="GNOME_DATE_EDIT_24_HR" _name="24-Hour Format"/>
+ <value id="GNOME_DATE_EDIT_WEEK_STARTS_ON_MONDAY" _name="Monday First"/>
+ </displayable-values>
+ </property>
+ </properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeAppBar" generic-name="gnomeappbar" title="Gnome App Bar">
+ <post-create-function>glade_gnome_app_bar_post_create</post-create-function>
+ <properties>
+ <property id="has-progress" default="True" ignore="True"/>
+ <property id="has-status" default="True" ignore="True"/>
+ <property id="size" visible="False" query="False" ignore="True"/>
+ <property id="interactivity">
+ <displayable-values>
+ <value id="GNOME_PREFERENCES_NEVER" _name="Never"/>
+ <value id="GNOME_PREFERENCES_USER" _name="User"/>
+ <value id="GNOME_PREFERENCES_ALWAYS" _name="Always"/>
+ </displayable-values>
+ </property>
+ </properties>
+ </glade-widget-class>
+
+ <!-- Deprecated Widget Classes :) -->
+ <glade-widget-class name="GnomeDialog" generic-name="gnomedialog" title="Gnome Dialog">
+ <post-create-function>glade_gnome_dialog_post_create</post-create-function>
+ <get-internal-child-function>glade_gnome_dialog_get_internal_child</get-internal-child-function>
+ <get-children-function>glade_gnome_dialog_get_children</get-children-function>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeAbout" generic-name="gnomeabout" title="Gnome About">
+ <post-create-function>glade_gnome_about_dialog_post_create</post-create-function>
+ <set-property-function>glade_gnome_about_dialog_set_property</set-property-function>
+ <properties>
+ <property id="name" _name="Program Name"/>
+ <property id="version" _name="Program Version"/>
+ <property id="comments" translatable="True">
+ <visible-lines>4</visible-lines>
+ </property>
+ <property id="copyright" translatable="True">
+ <visible-lines>4</visible-lines>
+ </property>
+ <property id="translator-credits" translatable="True">
+ <visible-lines>4</visible-lines>
+ </property>
+ </properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeMessageBox" generic-name="gnomemessagebox" title="Gnome Message Box">
+ <set-property-function>glade_gnome_message_box_set_property</set-property-function>
+ <properties>
+ <property id="message-box-type">
+ <spec>glade_gnome_message_box_type_spec</spec>
+ <displayable-values>
+ <value id="GNOME_MESSAGE_BOX_INFO" _name="Information"/>
+ <value id="GNOME_MESSAGE_BOX_WARNING" _name="Warning"/>
+ <value id="GNOME_MESSAGE_BOX_ERROR" _name="Error"/>
+ <value id="GNOME_MESSAGE_BOX_QUESTION" _name="Question"/>
+ <value id="GNOME_MESSAGE_BOX_GENERIC" _name="Generic"/>
+ </displayable-values>
+ </property>
+ <property id="message" _name="Message">
+ <spec>glade_standard_string_spec</spec>
+ <tooltip>The message to display</tooltip>
+ </property>
+ </properties>
+ </glade-widget-class>
+ <glade-widget-class name="GnomePropertyBox" generic-name="gnomepropertybox" title="Gnome Property Box"/>
+
+ <glade-widget-class name="GnomeEntry" generic-name="gnomeentry" title="Gnome Entry">
+ <post-create-function>glade_gnome_entry_post_create</post-create-function>
+ <get-internal-child-function>glade_gnome_entry_get_internal_child</get-internal-child-function>
+ <get-children-function>glade_gnome_entry_get_children</get-children-function>
+ <set-property-function>glade_gnome_entry_set_property</set-property-function>
+ <properties>
+ <property id="gtk-entry" disabled="True"/>
+ <property id="max-saved" _name="Max Saved">
+ <spec>glade_standard_int_spec</spec>
+ <_tooltip>The maximum number of history entries saved</_tooltip>
+ </property>
+ <property id="size" visible="False" query="False" ignore="True"/>
+ </properties>
+
+ <packing-properties>
+ <property id="expand" disabled="True"/>
+ <property id="fill" disabled="True"/>
+ <property id="pack-type" disabled="True"/>
+ <property id="padding" disabled="True"/>
+ <property id="position" disabled="True"/>
+ </packing-properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeFileEntry" generic-name="gnomefileentry" title="Gnome File Entry">
+ <post-create-function>glade_gnome_entry_post_create</post-create-function>
+ <get-internal-child-function>glade_gnome_entry_get_internal_child</get-internal-child-function>
+ <get-children-function>glade_gnome_entry_get_children</get-children-function>
+ <set-property-function>glade_gnome_file_entry_set_property</set-property-function>
+ <properties>
+ <property id="max-saved" _name="Max Saved">
+ <spec>glade_standard_int_spec</spec>
+ <_tooltip>The maximum number of history entries saved</_tooltip>
+ </property>
+ <property id="size" visible="False" query="False" ignore="True"/>
+ <property id="filechooser-action">
+ <displayable-values>
+ <value id="GTK_FILE_CHOOSER_ACTION_OPEN" _name="Open"/>
+ <value id="GTK_FILE_CHOOSER_ACTION_SAVE" _name="Save"/>
+ <value id="GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER" _name="Select Folder"/>
+ <value id="GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER" _name="Create Folder"/>
+ </displayable-values>
+ </property>
+ </properties>
+ <packing-properties>
+ <property id="expand" disabled="True"/>
+ <property id="fill" disabled="True"/>
+ <property id="pack-type" disabled="True"/>
+ <property id="padding" disabled="True"/>
+ <property id="position" disabled="True"/>
+ </packing-properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomePixmapEntry" generic-name="gnomepixmapentry" title="Gnome Pixmap Entry">
+ <packing-properties>
+ <property id="expand" disabled="True"/>
+ <property id="fill" disabled="True"/>
+ <property id="pack-type" disabled="True"/>
+ <property id="padding" disabled="True"/>
+ <property id="position" disabled="True"/>
+ </packing-properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeColorPicker" generic-name="gnomecolorpicker" title="Gnome Color Picker">
+ <post-create-function>empty</post-create-function>
+ <properties>
+ <property id="use-underline" disabled="True"/>
+ <property id="label" disabled="True"/>
+ <property id="glade-type" disabled="True"/>
+ <property id="stock" disabled="True"/>
+ <property id="red" disabled="True"/>
+ <property id="green" disabled="True"/>
+ <property id="blue" disabled="True"/>
+ <property id="alpha" disabled="True"/>
+ <property id="dither" _name="Dither"/>
+ <property id="use-alpha" _name="Use Alpha"/>
+ <property id="title" _name="Title"/>
+ </properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomeFontPicker" generic-name="gnomefontpicker" title="Gnome Font Picker">
+ <post-create-function>empty</post-create-function>
+ <get-children-function>glade_gnome_font_picker_get_children</get-children-function>
+ <add-child-function>glade_gnome_font_picker_add_child</add-child-function>
+ <remove-child-function>glade_gnome_font_picker_remove_child</remove-child-function>
+ <replace-child-function>glade_gnome_font_picker_replace_child</replace-child-function>
+ <set-property-function>glade_gnome_font_picker_set_property</set-property-function>
+
+ <properties>
+ <property id="use-underline" disabled="True"/>
+ <property id="label" disabled="True"/>
+ <property id="glade-type" disabled="True"/>
+ <property id="stock" disabled="True"/>
+ <property id="font-name" disabled="True"/>
+ <property id="mode">
+ <displayable-values>
+ <value id="GNOME_FONT_PICKER_MODE_PIXMAP" _name="Pixmap"/>
+ <value id="GNOME_FONT_PICKER_MODE_FONT_INFO" _name="Font Information"/>
+ <value id="GNOME_FONT_PICKER_MODE_USER_WIDGET" _name="User Widget"/>
+ <value id="GNOME_FONT_PICKER_MODE_UNKNOWN" _name="Unknown"/>
+ </displayable-values>
+ </property>
+ </properties>
+ </glade-widget-class>
+
+ <glade-widget-class name="GnomePixmap" generic-name="gnomepixmap" title="Gnome Pixmap">
+ <post-create-function>empty</post-create-function>
+ <set-property-function>glade_gnome_pixmap_set_property</set-property-function>
+ <properties>
+ <property id="stock" disabled="True"/>
+ <property id="icon-name" disabled="True"/>
+ <property id="glade-stock" disabled="True"/>
+ <property id="glade-type" disabled="True"/>
+ <property id="pixbuf" disabled="True"/>
+ <property id="icon-size" disabled="True"/>
+ <property id="pixel-size" disabled="True"/>
+ <property id="filename" _name="File">
+ <spec>glade_standard_pixbuf_spec</spec>
+ <_tooltip>The pixmap file</_tooltip>
+ </property>
+ <property id="scaled-width" _name="Scaled Width">
+ <spec>glade_standard_int_spec</spec>
+ <_tooltip>The width to scale the pixmap to</_tooltip>
+ </property>
+ <property id="scaled-height" _name="Scaled Height">
+ <spec>glade_standard_int_spec</spec>
+ <_tooltip>The height to scale the pixmap to</_tooltip>
+ </property>
+ </properties>
+ </glade-widget-class>
+
+ <!-- Unsupported Classes
+ Deprecated and not suported by libglade:
+ * GnomeScores
+
+ These are not widget classes:
+ * GnomeClient
+ * GnomeMdi, GnomeMdiChild, GnomeMdiGenericChild
+ * GnomeCanvasItem, GnomeIconTextItem -->
+ </glade-widget-classes>
+
+ <glade-widget-group name="gnomeui-base" _title="GNOME User Interface">
+
+ <glade-widget-class-ref name="GnomeApp"/>
+ <glade-widget-class-ref name="GnomeDruid"/>
+ <glade-widget-class-ref name="GnomeIconSelection"/>
+ <glade-widget-class-ref name="GnomeHRef"/>
+ <glade-widget-class-ref name="GnomeDateEdit"/>
+ <glade-widget-class-ref name="GnomeIconEntry"/>
+ <glade-widget-class-ref name="GnomeAppBar"/>
+ </glade-widget-group>
+
+ <glade-widget-group name="gnomeui-obsolete" _title="GNOME UI Obsolete">
+
+ <default-palette-state expanded="False" />
+
+ <glade-widget-class-ref name="GnomeDialog"/>
+ <glade-widget-class-ref name="GnomeAbout"/>
+ <glade-widget-class-ref name="GnomeMessageBox"/>
+ <glade-widget-class-ref name="GnomePropertyBox"/>
+ <glade-widget-class-ref name="GnomeEntry"/>
+ <glade-widget-class-ref name="GnomeFileEntry"/>
+ <glade-widget-class-ref name="GnomePixmapEntry"/>
+ <glade-widget-class-ref name="GnomeColorPicker"/>
+ <glade-widget-class-ref name="GnomeFontPicker"/>
+ <glade-widget-class-ref name="GnomePixmap"/>
+ </glade-widget-group>
+</glade-catalog>
diff --git a/plugins/gnome/icons/16x16/Makefile.am b/plugins/gnome/icons/16x16/Makefile.am
new file mode 100644
index 00000000..985dd7c0
--- /dev/null
+++ b/plugins/gnome/icons/16x16/Makefile.am
@@ -0,0 +1,31 @@
+## Process this file with automake to produce Makefile.in
+
+iconsdir = $(pkgdatadir)/pixmaps/16x16
+
+icons_DATA = \
+ bonobodock.png \
+ bonobodockitem.png \
+ gnomehref.png \
+ gnomeapp.png \
+ gnomeappbar.png \
+ gnomecanvas.png \
+ gnomedateedit.png \
+ gnomeiconentry.png \
+ gnomeiconselection.png \
+ gnomedruid.png \
+ gnomedruidpageedge.png \
+ gnomedruidpagestandard.png \
+ gnomepixmap.png \
+ gnomepropertybox.png \
+ gnomecolorpicker.png \
+ gnomepixmapentry.png \
+ gnomeabout.png \
+ gnomeentry.png \
+ gnomeappbar.png \
+ gnomedialog.png \
+ gnomefileentry.png \
+ gnomefontpicker.png \
+ gnomeiconlist.png \
+ gnomemessagebox.png
+
+EXTRA_DIST = $(icons_DATA)
diff --git a/plugins/gnome/icons/16x16/bonobodock.png b/plugins/gnome/icons/16x16/bonobodock.png
new file mode 100644
index 00000000..eb8025f0
--- /dev/null
+++ b/plugins/gnome/icons/16x16/bonobodock.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/bonobodockitem.png b/plugins/gnome/icons/16x16/bonobodockitem.png
new file mode 100644
index 00000000..a56584e5
--- /dev/null
+++ b/plugins/gnome/icons/16x16/bonobodockitem.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomeabout.png b/plugins/gnome/icons/16x16/gnomeabout.png
new file mode 100644
index 00000000..2e64933e
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomeabout.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomeapp.png b/plugins/gnome/icons/16x16/gnomeapp.png
new file mode 100644
index 00000000..ee23fee5
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomeapp.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomeappbar.png b/plugins/gnome/icons/16x16/gnomeappbar.png
new file mode 100644
index 00000000..b8297ce8
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomeappbar.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomecanvas.png b/plugins/gnome/icons/16x16/gnomecanvas.png
new file mode 100644
index 00000000..5df4e274
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomecanvas.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomecolorpicker.png b/plugins/gnome/icons/16x16/gnomecolorpicker.png
new file mode 100644
index 00000000..49c077db
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomecolorpicker.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomedateedit.png b/plugins/gnome/icons/16x16/gnomedateedit.png
new file mode 100644
index 00000000..ec4e622f
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomedateedit.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomedialog.png b/plugins/gnome/icons/16x16/gnomedialog.png
new file mode 100644
index 00000000..ae70aec0
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomedialog.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomedruid.png b/plugins/gnome/icons/16x16/gnomedruid.png
new file mode 100644
index 00000000..23821b0e
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomedruid.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomedruidpageedge.png b/plugins/gnome/icons/16x16/gnomedruidpageedge.png
new file mode 100644
index 00000000..23821b0e
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomedruidpageedge.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomedruidpagestandard.png b/plugins/gnome/icons/16x16/gnomedruidpagestandard.png
new file mode 100644
index 00000000..78018d9c
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomedruidpagestandard.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomeentry.png b/plugins/gnome/icons/16x16/gnomeentry.png
new file mode 100644
index 00000000..a76ad8bf
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomeentry.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomefileentry.png b/plugins/gnome/icons/16x16/gnomefileentry.png
new file mode 100644
index 00000000..ec4e622f
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomefileentry.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomefontpicker.png b/plugins/gnome/icons/16x16/gnomefontpicker.png
new file mode 100644
index 00000000..8fa2d501
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomefontpicker.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomehref.png b/plugins/gnome/icons/16x16/gnomehref.png
new file mode 100644
index 00000000..cdc839e9
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomehref.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomeiconentry.png b/plugins/gnome/icons/16x16/gnomeiconentry.png
new file mode 100644
index 00000000..413d2b3a
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomeiconentry.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomeiconlist.png b/plugins/gnome/icons/16x16/gnomeiconlist.png
new file mode 100644
index 00000000..48439286
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomeiconlist.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomeiconselection.png b/plugins/gnome/icons/16x16/gnomeiconselection.png
new file mode 100644
index 00000000..2f7b08ad
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomeiconselection.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomemessagebox.png b/plugins/gnome/icons/16x16/gnomemessagebox.png
new file mode 100644
index 00000000..c3643f16
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomemessagebox.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomepixmap.png b/plugins/gnome/icons/16x16/gnomepixmap.png
new file mode 100644
index 00000000..7c13c07b
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomepixmap.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomepixmapentry.png b/plugins/gnome/icons/16x16/gnomepixmapentry.png
new file mode 100644
index 00000000..ec4e622f
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomepixmapentry.png
Binary files differ
diff --git a/plugins/gnome/icons/16x16/gnomepropertybox.png b/plugins/gnome/icons/16x16/gnomepropertybox.png
new file mode 100644
index 00000000..32f27900
--- /dev/null
+++ b/plugins/gnome/icons/16x16/gnomepropertybox.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/Makefile.am b/plugins/gnome/icons/22x22/Makefile.am
new file mode 100644
index 00000000..3e1629b7
--- /dev/null
+++ b/plugins/gnome/icons/22x22/Makefile.am
@@ -0,0 +1,31 @@
+## Process this file with automake to produce Makefile.in
+
+iconsdir = $(pkgdatadir)/pixmaps/22x22
+
+icons_DATA = \
+ bonobodock.png \
+ bonobodockitem.png \
+ gnomehref.png \
+ gnomeapp.png \
+ gnomeappbar.png \
+ gnomecanvas.png \
+ gnomedateedit.png \
+ gnomeiconentry.png \
+ gnomeiconselection.png \
+ gnomedruid.png \
+ gnomedruidpageedge.png \
+ gnomedruidpagestandard.png \
+ gnomepixmap.png \
+ gnomepropertybox.png \
+ gnomecolorpicker.png \
+ gnomepixmapentry.png \
+ gnomeabout.png \
+ gnomeentry.png \
+ gnomeappbar.png \
+ gnomedialog.png \
+ gnomefileentry.png \
+ gnomefontpicker.png \
+ gnomeiconlist.png \
+ gnomemessagebox.png
+
+EXTRA_DIST = $(icons_DATA)
diff --git a/plugins/gnome/icons/22x22/bonobodock.png b/plugins/gnome/icons/22x22/bonobodock.png
new file mode 100644
index 00000000..e98ed3dc
--- /dev/null
+++ b/plugins/gnome/icons/22x22/bonobodock.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/bonobodockitem.png b/plugins/gnome/icons/22x22/bonobodockitem.png
new file mode 100644
index 00000000..a66fd065
--- /dev/null
+++ b/plugins/gnome/icons/22x22/bonobodockitem.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomeabout.png b/plugins/gnome/icons/22x22/gnomeabout.png
new file mode 100644
index 00000000..00152359
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomeabout.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomeapp.png b/plugins/gnome/icons/22x22/gnomeapp.png
new file mode 100644
index 00000000..fc6acbe1
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomeapp.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomeappbar.png b/plugins/gnome/icons/22x22/gnomeappbar.png
new file mode 100644
index 00000000..85af74fc
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomeappbar.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomecanvas.png b/plugins/gnome/icons/22x22/gnomecanvas.png
new file mode 100644
index 00000000..1911b513
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomecanvas.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomecolorpicker.png b/plugins/gnome/icons/22x22/gnomecolorpicker.png
new file mode 100644
index 00000000..ff4676ac
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomecolorpicker.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomedateedit.png b/plugins/gnome/icons/22x22/gnomedateedit.png
new file mode 100644
index 00000000..7945a480
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomedateedit.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomedialog.png b/plugins/gnome/icons/22x22/gnomedialog.png
new file mode 100644
index 00000000..575ebf5d
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomedialog.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomedruid.png b/plugins/gnome/icons/22x22/gnomedruid.png
new file mode 100644
index 00000000..78daffa3
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomedruid.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomedruidpageedge.png b/plugins/gnome/icons/22x22/gnomedruidpageedge.png
new file mode 100644
index 00000000..78daffa3
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomedruidpageedge.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomedruidpagestandard.png b/plugins/gnome/icons/22x22/gnomedruidpagestandard.png
new file mode 100644
index 00000000..03010e63
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomedruidpagestandard.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomeentry.png b/plugins/gnome/icons/22x22/gnomeentry.png
new file mode 100644
index 00000000..89d0fa1f
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomeentry.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomefileentry.png b/plugins/gnome/icons/22x22/gnomefileentry.png
new file mode 100644
index 00000000..7945a480
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomefileentry.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomefontpicker.png b/plugins/gnome/icons/22x22/gnomefontpicker.png
new file mode 100644
index 00000000..79a88eb2
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomefontpicker.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomehref.png b/plugins/gnome/icons/22x22/gnomehref.png
new file mode 100644
index 00000000..58a78904
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomehref.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomeiconentry.png b/plugins/gnome/icons/22x22/gnomeiconentry.png
new file mode 100644
index 00000000..e90c5561
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomeiconentry.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomeiconlist.png b/plugins/gnome/icons/22x22/gnomeiconlist.png
new file mode 100644
index 00000000..fcf5bcb3
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomeiconlist.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomeiconselection.png b/plugins/gnome/icons/22x22/gnomeiconselection.png
new file mode 100644
index 00000000..80711e98
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomeiconselection.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomemessagebox.png b/plugins/gnome/icons/22x22/gnomemessagebox.png
new file mode 100644
index 00000000..df878d30
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomemessagebox.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomepixmap.png b/plugins/gnome/icons/22x22/gnomepixmap.png
new file mode 100644
index 00000000..414ae1c4
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomepixmap.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomepixmapentry.png b/plugins/gnome/icons/22x22/gnomepixmapentry.png
new file mode 100644
index 00000000..7945a480
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomepixmapentry.png
Binary files differ
diff --git a/plugins/gnome/icons/22x22/gnomepropertybox.png b/plugins/gnome/icons/22x22/gnomepropertybox.png
new file mode 100644
index 00000000..a36f7c3f
--- /dev/null
+++ b/plugins/gnome/icons/22x22/gnomepropertybox.png
Binary files differ
diff --git a/plugins/gnome/icons/Makefile.am b/plugins/gnome/icons/Makefile.am
new file mode 100644
index 00000000..bd39c36e
--- /dev/null
+++ b/plugins/gnome/icons/Makefile.am
@@ -0,0 +1,3 @@
+## Process this file with automake to produce Makefile.in
+
+SUBDIRS = 16x16 22x22