+ val = g_settings_get_value (settings, GSETTINGS_TOOL_BAR_STYLE);
+ if (val)
+ {
+ g_variant_ref_sink (val);
+ if (g_variant_is_of_type (val, G_VARIANT_TYPE_STRING))
+ {
+ const gchar *newstyle = g_variant_get_string (val, NULL);
+ store_tool_bar_style_changed (newstyle, first_dpyinfo);
+ }
+ g_variant_unref (val);
+ }
+ }
+#ifdef HAVE_XFT
+ else if (strcmp (key, GSETTINGS_MONO_FONT) == 0)
+ {
+ val = g_settings_get_value (settings, GSETTINGS_MONO_FONT);
+ if (val)
+ {
+ g_variant_ref_sink (val);
+ if (g_variant_is_of_type (val, G_VARIANT_TYPE_STRING))
+ {
+ const gchar *newfont = g_variant_get_string (val, NULL);
+ store_monospaced_changed (newfont);
+ }
+ g_variant_unref (val);
+ }
+ }
+ else if (strcmp (key, GSETTINGS_FONT_NAME) == 0)
+ {
+ val = g_settings_get_value (settings, GSETTINGS_FONT_NAME);
+ if (val)
+ {
+ g_variant_ref_sink (val);
+ if (g_variant_is_of_type (val, G_VARIANT_TYPE_STRING))
+ {
+ const gchar *newfont = g_variant_get_string (val, NULL);
+ store_font_name_changed (newfont);
+ }
+ g_variant_unref (val);
+ }
+ }
+#endif /* HAVE_XFT */
+}
+
+#endif /* HAVE_GSETTINGS */
+
+#ifdef HAVE_GCONF
+#define GCONF_TOOL_BAR_STYLE "/desktop/gnome/interface/toolbar_style"
+#ifdef HAVE_XFT
+#define GCONF_MONO_FONT "/desktop/gnome/interface/monospace_font_name"
+#define GCONF_FONT_NAME "/desktop/gnome/interface/font_name"
+#endif
+
+/* The single GConf instance, or NULL if not connected to GConf. */
+
+static GConfClient *gconf_client;
+
+/* Callback called when something changed in GConf that we care about. */
+
+static void
+something_changed_gconfCB (GConfClient *client,
+ guint cnxn_id,
+ GConfEntry *entry,
+ gpointer user_data)
+{
+ GConfValue *v = gconf_entry_get_value (entry);
+ const char *key = gconf_entry_get_key (entry);
+
+ if (!v || v->type != GCONF_VALUE_STRING || ! key) return;
+ if (strcmp (key, GCONF_TOOL_BAR_STYLE) == 0)
+ {
+ const char *value = gconf_value_get_string (v);
+ store_tool_bar_style_changed (value, first_dpyinfo);
+ }
+#ifdef HAVE_XFT
+ else if (strcmp (key, GCONF_MONO_FONT) == 0)
+ {
+ const char *value = gconf_value_get_string (v);
+ store_monospaced_changed (value);
+ }
+ else if (strcmp (key, GCONF_FONT_NAME) == 0)
+ {
+ const char *value = gconf_value_get_string (v);
+ store_font_name_changed (value);