Description: Migrate to GSettings
Author: Marc Deslauriers <marc.deslauriers@canonical.com>
Origin: based in part on original patches by Debarshi Ray <debarshir@src.gnome.org>
 and Robert Ancell <robert.ancell@gmail.com>
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=625893

Index: xchat-gnome-0.30.0~git20141005.816798/configure.ac
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/configure.ac	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/configure.ac	2014-11-12 18:57:53.796332771 -0500
@@ -21,7 +21,6 @@
 
 GLIB_REQUIRED=2.32.0
 GTK_REQUIRED=3.4.2
-GCONF_REQUIRED=2.8.0
 DBUS_REQUIRED=1.4
 DBUS_GLIB_REQUIRED=0.98
 LIBNOTIFY_REQUIRED=0.7
@@ -64,7 +63,6 @@
                   gio-2.0 >= $GLIB_REQUIRED \
                   gmodule-2.0  >= $GLIB_REQUIRED \
                   gtk+-3.0 >= $GTK_REQUIRED \
-                  gconf-2.0 >= $GCONF_REQUIRED \
                   ])
 
 #D-Bus
@@ -134,9 +132,8 @@
 
 AM_CONDITIONAL([ENABLE_LIBCANBERRA],[test "x$enable_canberra" = "xyes"])
 
-# GConf
-AM_GCONF_SOURCE_2
-AC_PATH_PROG(GCONFTOOL, gconftool-2, no)
+# GSettings
+GLIB_GSETTINGS
 
 # SOCKS5
 AC_CHECK_LIB(socks5, SOCKSconnect, have_socks=yes, have_socks=no)
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/notification/Makefile.am
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/notification/Makefile.am	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/notification/Makefile.am	2014-11-12 18:57:53.796332771 -0500
@@ -1,9 +1,6 @@
 plugindir = $(pkglibdir)/plugins
 plugin_LTLIBRARIES = notification.la
 
-BUILT_SOURCES = notification.schemas
-DISTCLEANFILES = $(BUILT_SOURCES)
-
 notification_la_SOURCES =	\
 	notification.c		\
 	preferences-page-plugin-notification.h \
@@ -29,18 +26,8 @@
 
 xchat_gnomedir = $(datadir)/xchat-gnome
 
-schemadir	= $(GCONF_SCHEMA_FILE_DIR)
-schema_in_files	= notification.schemas.in
-schema_DATA	= $(schema_in_files:.schemas.in=.schemas)
-@INTLTOOL_SCHEMAS_RULE@
-
-EXTRA_DIST = notification.schemas.in preferences-notification.glade
-
-if GCONF_SCHEMAS_INSTALL
-install-data-local:
-	if test -z "$(DESTDIR)" ; then \
-		for p in $(schema_DATA) ; do \
-			GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) $(GCONFTOOL) --makefile-install-rule $$p; \
-		done \
-	fi
-endif
+@GSETTINGS_RULES@
+gsettings_SCHEMAS = org.gnome.Xchat.notification.gschema.xml
+
+EXTRA_DIST = preferences-notification.glade	\
+	org.gnome.Xchat.notification.gschema.xml
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/notification/notification.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/notification/notification.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/notification/notification.c	2014-11-12 18:57:53.800332799 -0500
@@ -24,7 +24,6 @@
 #include <config.h>
 #include <gtk/gtk.h>
 #include <gdk/gdk.h>
-#include <gconf/gconf-client.h>
 #include <dlfcn.h>
 
 #include "navigation-tree.h"
@@ -52,6 +51,7 @@
 	N_NOTIF
 } NotifStatus;
 
+static GSettings          *settings;            /* Settings */
 static GtkStatusIcon*      status_icon;         /* Notification area icon. */
 static gboolean            focused = TRUE;      /* GTK_WIDGET_HAS_FOCUS doesn't seem to be working... */
 static gint		   level = 0;		/* Level of messages that we want to notify */
@@ -60,7 +60,6 @@
 static NotifStatus         status = NOTIF_NONE; /* Current status level. */
 static xchat_gnome_plugin* xgph;                /* xchat gnome plugin handle. */
 static xchat_plugin*       ph;                  /* Plugin handle. */
-static guint		   gconf_notify_id;
 
 static const char *images[N_NOTIF] = {
 	"xchat-gnome",
@@ -166,9 +165,9 @@
 }
 
 static void
-level_changed (GConfClient *client, guint cnxn_id,  GConfEntry *entry, gpointer data)
+level_changed (GSettings *settings, const gchar *key)
 {
-	level = gconf_value_get_int (gconf_entry_get_value (entry));
+	level = g_settings_get_int (settings, key);
 	update_tray ();
 }
 
@@ -176,18 +175,19 @@
 int
 xchat_plugin_init (xchat_plugin * plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
 {
-	GConfClient *client = gconf_client_get_default ();
-
 	ph = plugin_handle;
 
+	settings = g_settings_new ("org.gnome.Xchat.plugins.notification");
+	g_signal_connect (G_OBJECT (settings), "changed::level", G_CALLBACK (level_changed), NULL);
+
 	/* Set context on ph*/
 	xchat_find_set_context (ph);
 
 	/* Set the plugin info. */
 	xchat_plugin_get_info (plugin_name, plugin_desc, plugin_version, NULL);
 
-	/* Get our preferences from gconf. */
-	level = gconf_client_get_int (client, "/apps/xchat/plugins/notification/level", NULL);
+	/* Get our preferences from gsettings. */
+	level = g_settings_get_int (settings, "level");
 
 	focused = TRUE;
 	hidden = FALSE;
@@ -205,8 +205,6 @@
 	xchat_hook_print (ph, "Channel Msg Hilight",		XCHAT_PRI_NORM, new_msg_cb, GUINT_TO_POINTER (NOTIF_NICK));
 	xchat_hook_print (ph, "Channel Action Hilight",		XCHAT_PRI_NORM, new_msg_cb, GUINT_TO_POINTER (NOTIF_NICK));
 	xchat_hook_print (ph, "Private Message to Dialog",	XCHAT_PRI_NORM, new_msg_cb, GUINT_TO_POINTER (NOTIF_NICK));
-	gconf_notify_id = gconf_client_notify_add (client, "/apps/xchat/plugins/notification/level", (GConfClientNotifyFunc) level_changed, NULL, NULL, NULL);
-	g_object_unref (client);
 
 	xchat_print (ph, _("Notification plugin loaded.\n"));
 
@@ -216,18 +214,15 @@
 int
 xchat_plugin_deinit (void)
 {
-	GConfClient *client = gconf_client_get_default ();
-
 	/* Disconnect the signal handlers. */
 	g_signal_handlers_disconnect_by_func (main_window, G_CALLBACK (got_focus_cb), NULL);
 	g_signal_handlers_disconnect_by_func (main_window, G_CALLBACK (lost_focus_cb), NULL);
+	g_signal_handlers_disconnect_by_func (settings, G_CALLBACK (level_changed), NULL);
 
 	g_object_unref (status_icon);
 	status_icon = NULL;
 
-	gconf_client_notify_remove (client, gconf_notify_id);
-	g_object_unref (client);
-	gconf_notify_id = 0;
+	g_object_unref (settings);
 
 	xchat_print (ph, _("Notification plugin unloaded.\n"));
 
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/notification/preferences-page-plugin-notification.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/notification/preferences-page-plugin-notification.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/notification/preferences-page-plugin-notification.c	2014-11-12 18:57:53.800332799 -0500
@@ -24,7 +24,7 @@
 #include "preferences-page-plugin-notification.h"
 #include "util.h"
 
-#define NOTIFICATION_KEY "/apps/xchat/plugins/notification/level"
+#define NOTIFICATION_KEY "level"
 
 G_DEFINE_TYPE(PreferencesPagePluginNotification, preferences_page_plugin_notification, PREFERENCES_PAGE_TYPE)
 
@@ -35,8 +35,7 @@
 	/* The vbox is already destroyed when the page is removed from the
 	 * gtk_notebook */
 
-	gconf_client_notify_remove (page->gconf, page->notify);
-	g_object_unref (page->gconf);
+	g_object_unref (page->settings);
 
 	G_OBJECT_CLASS (preferences_page_plugin_notification_parent_class)->finalize (object);
 }
@@ -69,7 +68,7 @@
 	else
 		level = 0;
 
-	gconf_client_set_int (page->gconf, NOTIFICATION_KEY, level, NULL);
+	g_settings_set_int (page->settings, NOTIFICATION_KEY, level);
 }
 
 static void
@@ -92,7 +91,7 @@
 }
 
 static void
-gconf_notif_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, PreferencesPagePluginNotification *page)
+settings_notif_changed (GSettings *settings, const gchar *key, PreferencesPagePluginNotification *page)
 {
 	gint level;
 
@@ -101,7 +100,7 @@
 	g_signal_handlers_block_by_func (G_OBJECT (page->notif_level_1), G_CALLBACK (notif_changed), page);
 	g_signal_handlers_block_by_func (G_OBJECT (page->notif_level_0), G_CALLBACK (notif_changed), page);
 
-	level = gconf_client_get_int (client, entry->key, NULL);
+	level = g_settings_get_int (settings, NOTIFICATION_KEY);
 	preferences_page_plugin_notification_set_notif_level (page, level);
 
 	g_signal_handlers_unblock_by_func (G_OBJECT (page->notif_level_3), G_CALLBACK (notif_changed), page);
@@ -126,9 +125,8 @@
 
 	PREFERENCES_PAGE (page)->title = g_strdup (_("Notification"));
 
-	page->gconf = gconf_client_get_default ();
-	page->notify = gconf_client_notify_add (page->gconf, NOTIFICATION_KEY,
-				(GConfClientNotifyFunc) gconf_notif_changed, page, NULL, NULL);
+	page->settings = g_settings_new ("org.gnome.Xchat.plugins.notification");
+	g_signal_connect (G_OBJECT (page->settings), "changed::level", G_CALLBACK (settings_notif_changed), page);
 
 #define GW(name) ((page->name) = GTK_WIDGET (gtk_builder_get_object (xml, #name)))
 	GW(notif_level_3);
@@ -137,7 +135,7 @@
 	GW(notif_level_0);
 #undef GW
 
-	gint level = gconf_client_get_int (page->gconf, NOTIFICATION_KEY, NULL);
+	gint level = g_settings_get_int (page->settings, NOTIFICATION_KEY);
 	preferences_page_plugin_notification_set_notif_level (page, level);
 
 	g_signal_connect (G_OBJECT (page->notif_level_3), "clicked", G_CALLBACK (notif_changed), page);
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/notification/preferences-page-plugin-notification.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/notification/preferences-page-plugin-notification.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/notification/preferences-page-plugin-notification.h	2014-11-12 18:57:53.800332799 -0500
@@ -23,8 +23,6 @@
 #ifndef XCHAT_GNOME_PREFERENCES_PAGE_PLUGIN_NOTIFICATION_H
 #define XCHAT_GNOME_PREFERENCES_PAGE_PLUGIN_NOTIFICATION_H
 
-#include <gconf/gconf-client.h>
-
 #include "preferences-page.h"
 
 G_BEGIN_DECLS
@@ -41,8 +39,7 @@
 {
 	PreferencesPage parent;
 
-	GConfClient *gconf;
-	guint notify;
+	GSettings *settings;
 
 	GtkWidget *notif_level_3;
 	GtkWidget *notif_level_2;
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/url_scraper/Makefile.am
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/url_scraper/Makefile.am	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/url_scraper/Makefile.am	2014-11-12 18:57:53.800332799 -0500
@@ -16,21 +16,8 @@
 	-module		\
 	$(AM_LDFLAGS)
 
-schemadir	= $(GCONF_SCHEMA_FILE_DIR)
-schema_in_files	= urlscraper.schemas.in
-schema_DATA	= $(schema_in_files:.schemas.in=.schemas)
-@INTLTOOL_SCHEMAS_RULE@
+@GSETTINGS_RULES@
+gsettings_SCHEMAS = org.gnome.Xchat.urlscraper.gschema.xml
 
-EXTRA_DIST = urlscraper.schemas.in
-
-BUILT_SOURCES = urlscraper.schemas
-DISTCLEANFILES = $(BUILT_SOURCES)
-
-if GCONF_SCHEMAS_INSTALL
-install-data-local:
-	if test -z "$(DESTDIR)" ; then \
-		for p in $(schema_DATA) ; do \
-			GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) $(GCONFTOOL) --makefile-install-rule $$p; \
-		done \
-	fi
-endif
+EXTRA_DIST =					\
+	org.gnome.Xchat.urlscraper.gschema.xml
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/url_scraper/urlscraper.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/url_scraper/urlscraper.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/url_scraper/urlscraper.c	2014-11-12 18:57:53.800332799 -0500
@@ -5,7 +5,6 @@
 #include <gtk/gtk.h>
 #include <stdlib.h>
 #include <string.h>
-#include <gconf/gconf-client.h>
 #include <time.h>
 
 #include "xchat-plugin.h"
@@ -15,6 +14,7 @@
 #define URLREGEX "((ht|f)tps?://[~a-z0-9./_=#%&?,-]+[a-z0-9]+)|(apt:(//)?[a-z0-9][-+.a-z0-9]+)"
 #define EMAILREGEX "[a-z0-9.+_-]+@([0-9a-z-]+\\.)+[a-z]+"
 
+static GSettings *settings; // Settings
 static xchat_plugin *ph;	// Plugin handle.
 static regex_t *email;		// Regex that matches e-mail addresses.
 static regex_t *url;		// Regex that matches urls.
@@ -189,10 +189,10 @@
 		char **plugin_version,
 		char *arg)
 {
-	GConfClient *client = gconf_client_get_default ();
-
 	ph = plugin_handle;
 
+	settings = g_settings_new ("org.gnome.Xchat.plugins.urlscraper");
+
 	xchat_plugin_get_info (plugin_name, plugin_desc, plugin_version, NULL);
 
 	url = malloc (sizeof (regex_t));
@@ -210,8 +210,8 @@
 	urls = 0;
 
 	/* Set our prefs from GConf. */
-	history = gconf_client_get_int (client, "/apps/xchat/plugins/urlscraper/history", NULL);
-	timestamps = gconf_client_get_bool (client, "/apps/xchat/plugins/urlscraper/timestamps", NULL);
+	history = g_settings_get_int (settings, "history");
+	timestamps = g_settings_get_boolean (settings, "timestamps");
 
 	make_window ();
 
Index: xchat-gnome-0.30.0~git20141005.816798/src/common/dbus/Makefile.am
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/common/dbus/Makefile.am	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/common/dbus/Makefile.am	2014-11-12 18:57:53.800332799 -0500
@@ -41,22 +41,7 @@
 $(service_DATA): $(service_in_files) Makefile
 	@sed -e "s|\@bindir\@|$(bindir)|" $< > $@
 
-schemadir = $(GCONF_SCHEMA_FILE_DIR)
-schema_in_files = url_handler.schemas.in
-schema_DATA = $(schema_in_files:.schemas.in=.schemas)
-@INTLTOOL_SCHEMAS_RULE@
-
-install-data-local: $(schema_DATA)
-if GCONF_SCHEMAS_INSTALL
-	if test -z "$(DESTDIR)" ; then \
-		for p in $^ ; do \
-		GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) $(GCONFTOOL) --makefile-install-rule $$p >&1 > /dev/null; \
-		done \
-	fi
-endif
-
 EXTRA_DIST =				\
-	url_handler.schemas.in		\
 	remote-object.xml		\
 	marshallers.list		\
 	example.py			\
@@ -69,5 +54,4 @@
 
 CLEANFILES = \
  	$(BUILT_SOURCES)	\
-	$(schema_DATA)		\
 	$(service_DATA)
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/Makefile.am
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/Makefile.am	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/Makefile.am	2014-11-12 19:07:43.436468972 -0500
@@ -1,16 +1,8 @@
-schemadir	= $(GCONF_SCHEMA_FILE_DIR)
-schema_in_files	= apps_xchat.schemas.in
-schema_DATA	= $(schema_in_files:.schemas.in=.schemas)
-@INTLTOOL_SCHEMAS_RULE@
-
-if GCONF_SCHEMAS_INSTALL
-install-data-local:
-	if test -z "$(DESTDIR)" ; then \
-		for p in $(schema_DATA) ; do \
-			GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) $(GCONFTOOL) --makefile-install-rule $$p; \
-		done \
-	fi
-endif
+@GSETTINGS_RULES@
+gsettings_SCHEMAS = org.gnome.Xchat.gschema.xml
+
+convertdir = $(datadir)/GConf/gsettings
+convert_DATA = org.gnome.Xchat.convert
 
 bin_PROGRAMS = xchat-gnome
 
@@ -126,7 +118,7 @@
 	sexy-marshal.c
 
 CLEANFILES = $(stamp_files) $(BUILT_SOURCES)
-DISTCLEANFILES = $(stamp_files) apps_xchat.schemas $(BUILT_SOURCES)
+DISTCLEANFILES = $(stamp_files) $(BUILT_SOURCES)
 MAINTAINERCLEANFILES = $(stamp_files) $(BUILT_SOURCES)
 
 stamp_files = \
@@ -163,4 +155,4 @@
 	$(xchat_gnome_SOURCES)			\
 	xg-marshal.list				\
 	sexy-marshal.list			\
-	apps_xchat.schemas.in
+	org.gnome.Xchat.gschema.xml
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/channel-list-window.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/channel-list-window.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/channel-list-window.c	2014-11-12 18:57:53.800332799 -0500
@@ -24,7 +24,6 @@
 #include <string.h>
 #include <gtk/gtk.h>
 #include <gdk/gdkkeysyms.h>
-#include <gconf/gconf-client.h>
 #include "channel-list-window.h"
 #include "util.h"
 #include "gui.h"
@@ -178,12 +177,8 @@
 static gboolean
 channel_list_window_resize (GtkWidget *widget, GdkEventConfigure *event, ChannelListWindow *win)
 {
-	GConfClient *client;
-
-	client = gconf_client_get_default ();
-	gconf_client_set_int (client, "/apps/xchat/channel_list/width",  event->width,  NULL);
-	gconf_client_set_int (client, "/apps/xchat/channel_list/height", event->height, NULL);
-	g_object_unref (client);
+	g_settings_set_int (gui.settings_channel_list, "width",  event->width);
+	g_settings_set_int (gui.settings_channel_list, "height", event->height);
 
 	return FALSE;
 }
@@ -191,7 +186,6 @@
 static void
 channel_list_window_list_showed (ChannelListWindow *win)
 {
-	GConfClient *client;
 	gint width, height;
 
 	gtk_window_set_resizable (GTK_WINDOW (win->window), TRUE);
@@ -204,10 +198,8 @@
 	gtk_widget_show (win->refresh_button);
 
 	/* Set the size of the window */
-	client = gconf_client_get_default ();
-	width  = gconf_client_get_int (client, "/apps/xchat/channel_list/width",  NULL);
-	height = gconf_client_get_int (client, "/apps/xchat/channel_list/height", NULL);
-	g_object_unref (client);
+	width  = g_settings_get_int (gui.settings_channel_list, "width");
+	height = g_settings_get_int (gui.settings_channel_list, "height");
 
 	if (width == 0 || height == 0) {
 		gtk_window_resize (GTK_WINDOW (win->window), 640, 480);
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/conversation-panel.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/conversation-panel.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/conversation-panel.c	2014-11-12 18:57:53.800332799 -0500
@@ -22,8 +22,6 @@
 #include <string.h>
 #include <gtk/gtk.h>
 #include <gdk/gdkx.h>
-#include <gconf/gconf.h>
-#include <gconf/gconf-client.h>
 
 #include "conversation-panel.h"
 #include "gui.h"
@@ -63,14 +61,12 @@
                                               GdkEventFocus *event,
                                               ConversationPanel *panel);
 static void conversation_panel_set_font(ConversationPanel *panel);
-static void conversation_panel_font_changed(GConfClient *client,
-                                            guint cnxn_id,
-                                            GConfEntry *entry,
+static void conversation_panel_font_changed(GSettings         *settings,
+                                            const gchar       *key,
                                             ConversationPanel *panel);
 static void     conversation_panel_set_background     (ConversationPanel      *panel);
-static void     conversation_panel_background_changed (GConfClient            *client,
-                                                       guint                   cnxn_id,
-                                                       GConfEntry             *entry,
+static void     conversation_panel_background_changed (GSettings              *settings,
+                                                       const gchar            *key,
                                                        ConversationPanel      *panel);
 static gboolean conversation_panel_query_tooltip      (GtkWidget  *widget,
                                                        gint        x,
@@ -78,14 +74,12 @@
                                                        gboolean    keyboard_tooltip,
                                                        GtkTooltip *tooltip);
 
-static void     timestamps_changed                    (GConfClient  *client,
-                                                       guint         cnxn_id,
-                                                       GConfEntry   *entry,
+static void     timestamps_changed                    (GSettings    *settings,
+                                                       const gchar  *key,
                                                        xtext_buffer *buffer);
 
-static void     redundant_nickstamp_changed           (GConfClient       *client,
-                                                       guint              cnxn_id,
-                                                       GConfEntry        *entry,
+static void     redundant_nickstamp_changed           (GSettings         *settings,
+                                                       const gchar       *key,
                                                        ConversationPanel *panel);
 static void     conversation_panel_print_line         (ConversationPanel      *panel,
                                                        xtext_buffer           *buffer,
@@ -208,7 +202,6 @@
 {
 	GtkWidget *frame;
 	GtkActionGroup *action_group;
-	GConfClient       *client;
 
 	panel->priv = g_new0 (ConversationPanelPriv, 1);
 	panel->priv->xtext     = gtk_xtext_new (colors, prefs.indent_nicks);
@@ -242,10 +235,8 @@
 	panel->priv->tooltip_nick = NULL;
 	gtk_widget_set_has_tooltip(GTK_WIDGET(panel), TRUE);
 
-	client = gconf_client_get_default ();
 	panel->priv->redundant_nickstamps =
-		gconf_client_get_bool (client, "/apps/xchat/main_window/redundant_nickstamps", NULL);
-	g_object_unref (client);
+		g_settings_get_boolean (gui.settings_main_window, "redundant-nickstamps");
 
 	g_signal_connect (G_OBJECT (panel), "style-set", G_CALLBACK (style_set_callback), panel);
 	g_signal_connect (G_OBJECT (panel->priv->xtext), "drag_data_received", G_CALLBACK (drag_data_received), panel);
@@ -277,14 +268,12 @@
 conversation_panel_realize (GtkWidget *widget)
 {
 	ConversationPanel *panel;
-	GConfClient       *client;
 
 	if (GTK_WIDGET_CLASS (parent_class)->realize) {
 		GTK_WIDGET_CLASS (parent_class)->realize (widget);
 	}
 
 	panel  = CONVERSATION_PANEL (widget);
-	client = gconf_client_get_default ();
 
 	gtk_xtext_set_palette(GTK_XTEXT(panel->priv->xtext), colors);
 	gtk_xtext_set_max_lines(GTK_XTEXT(panel->priv->xtext), 3000);
@@ -300,21 +289,12 @@
 	g_signal_connect (G_OBJECT (panel->priv->xtext), "word_leave",      G_CALLBACK (conversation_panel_leave_word),   panel);
 	g_signal_connect (G_OBJECT (gui.main_window),    "focus-out-event", G_CALLBACK (conversation_panel_lost_focus),   panel);
 	g_signal_connect (G_OBJECT (gui.main_window),    "leave-notify-event", G_CALLBACK (conversation_panel_lost_focus),   panel);
-	gconf_client_notify_add (client, "/apps/xchat/main_window/use_sys_fonts",
-	                         (GConfClientNotifyFunc) conversation_panel_font_changed,       panel, NULL, NULL);
-	gconf_client_notify_add (client, "/apps/xchat/main_window/font",
-	                         (GConfClientNotifyFunc) conversation_panel_font_changed,       panel, NULL, NULL);
-	gconf_client_notify_add (client, "/apps/xchat/main_window/background_type",
-	                         (GConfClientNotifyFunc) conversation_panel_background_changed, panel, NULL, NULL);
-	gconf_client_notify_add (client, "/apps/xchat/main_window/background_image",
-	                         (GConfClientNotifyFunc) conversation_panel_background_changed, panel, NULL, NULL);
-	gconf_client_notify_add (client, "/apps/xchat/main_window/background_transparency",
-	                         (GConfClientNotifyFunc) conversation_panel_background_changed, panel, NULL, NULL);
-	gconf_client_notify_add (client, "/apps/xchat/main_window/redundant_nickstamps",
-	                         (GConfClientNotifyFunc) redundant_nickstamp_changed, panel, NULL, NULL);
-
-
-	g_object_unref (client);
+	g_signal_connect (G_OBJECT (gui.settings_main_window), "changed::use-sys-fonts", G_CALLBACK (conversation_panel_font_changed), panel);
+	g_signal_connect (G_OBJECT (gui.settings_main_window), "changed::font", G_CALLBACK (conversation_panel_font_changed), panel);
+	g_signal_connect (G_OBJECT (gui.settings_main_window), "changed::background-type", G_CALLBACK (conversation_panel_background_changed), panel);
+	g_signal_connect (G_OBJECT (gui.settings_main_window), "changed::background-image", G_CALLBACK (conversation_panel_background_changed), panel);
+	g_signal_connect (G_OBJECT (gui.settings_main_window), "changed::background-transparency", G_CALLBACK (conversation_panel_background_changed), panel);
+	g_signal_connect (G_OBJECT (gui.settings_main_window), "changed::redundant-nickstamps", G_CALLBACK (redundant_nickstamp_changed), panel);
 }
 
 static int
@@ -515,22 +495,18 @@
 static void
 conversation_panel_set_font (ConversationPanel *panel)
 {
-	GConfClient *client;
 	gchar       *font = NULL;
 
-	client = gconf_client_get_default ();
-	if (!gconf_client_get_bool(client, "/apps/xchat/main_window/use_sys_fonts", NULL)) {
-		font = gconf_client_get_string (client, "/apps/xchat/main_window/font", NULL);
+	if (!g_settings_get_boolean(gui.settings_main_window, "use-sys-fonts")) {
+		font = g_settings_get_string (gui.settings_main_window, "font");
 	}
 
 	/* Either use_sys_fonts==TRUE, or there is no current font preference.
 	 * In both cases we try the GNOME monospace font. */
 	if (font == NULL) {
-		font = gconf_client_get_string (client, "/desktop/gnome/interface/monospace_font_name", NULL);
+		font = g_settings_get_string (gui.settings_interface, "monospace-font-name");
 	}
 
-	g_object_unref (client);
-
 	if (font == NULL)
 		font = g_strdup ("fixed 11");
 
@@ -540,7 +516,7 @@
 }
 
 static void
-conversation_panel_font_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, ConversationPanel *panel)
+conversation_panel_font_changed (GSettings *settings, const gchar *key, ConversationPanel *panel)
 {
 	GtkAdjustment *adj;
 
@@ -558,7 +534,7 @@
 }
 
 static void
-conversation_panel_background_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, ConversationPanel *panel)
+conversation_panel_background_changed (GSettings *settings, const gchar *key, ConversationPanel *panel)
 {
 	conversation_panel_set_background (panel);
 	gtk_xtext_refresh (GTK_XTEXT (panel->priv->xtext), TRUE);
@@ -589,15 +565,15 @@
 
 
 static void
-timestamps_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, xtext_buffer *buffer)
+timestamps_changed (GSettings *settings, const gchar *key, xtext_buffer *buffer)
 {
-	gtk_xtext_set_time_stamp (buffer, gconf_client_get_bool (client, entry->key, NULL));
+	gtk_xtext_set_time_stamp (buffer, g_settings_get_boolean (settings, key));
 }
 
 static void
-redundant_nickstamp_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, ConversationPanel *panel)
+redundant_nickstamp_changed (GSettings *settings, const gchar *key, ConversationPanel *panel)
 {
-	panel->priv->redundant_nickstamps = gconf_value_get_bool (entry->value);
+	panel->priv->redundant_nickstamps = g_settings_get_boolean (settings, key);
 }
 
 static void
@@ -894,11 +870,8 @@
 static void
 style_set_callback (GtkWidget *widget, GtkStyle  *previous_style, void *data)
 {
-	GConfClient *client;
 	gint color_scheme;
-	client = gconf_client_get_default ();
-	color_scheme = gconf_client_get_int (client, "/apps/xchat/irc/color_scheme", NULL);
-	g_object_unref (client);
+	color_scheme = g_settings_get_int (gui.settings_irc, "color-scheme");
 	if (color_scheme == 3) {
 		load_colors (color_scheme);
 		load_palette (color_scheme);
@@ -922,17 +895,13 @@
 void
 conversation_panel_add_session (ConversationPanel *panel, struct session *sess, gboolean focus)
 {
-	GConfClient  *client;
 	xtext_buffer *buffer;
 	gint          notify;
 
 	buffer = gtk_xtext_buffer_new (GTK_XTEXT (panel->priv->xtext));
 
-	client = gconf_client_get_default ();
-	gtk_xtext_set_time_stamp (buffer, gconf_client_get_bool (client, "/apps/xchat/irc/showtimestamps", NULL));
-	notify = gconf_client_notify_add (client, "/apps/xchat/irc/showtimestamps",
-	                                  (GConfClientNotifyFunc) timestamps_changed, buffer, NULL, NULL);
-	g_object_unref (client);
+	gtk_xtext_set_time_stamp (buffer, g_settings_get_boolean (gui.settings_irc, "showtimestamps"));
+	notify = g_signal_connect (gui.settings_irc, "changed::showtimestamps", G_CALLBACK (timestamps_changed), buffer);
 
 	g_hash_table_insert (panel->priv->buffers,            sess, buffer);
 	g_hash_table_insert (panel->priv->timestamp_notifies, sess, GINT_TO_POINTER (notify));
@@ -1118,14 +1087,11 @@
 void
 conversation_panel_remove_session (ConversationPanel *panel, struct session *sess)
 {
-	GConfClient *client;
 	gint         notify;
 
-	client = gconf_client_get_default ();
 	notify = GPOINTER_TO_INT (g_hash_table_lookup (panel->priv->timestamp_notifies, sess));
 	g_hash_table_remove (panel->priv->timestamp_notifies, sess);
-	gconf_client_notify_remove (client, notify);
-	g_object_unref (client);
+	g_signal_handler_disconnect (gui.settings_irc, notify);
 
 	g_hash_table_remove (panel->priv->buffers, sess);
 }
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/fe-gnome.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/fe-gnome.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/fe-gnome.c	2014-11-12 18:57:53.800332799 -0500
@@ -25,7 +25,6 @@
 #include <string.h>
 #include <unistd.h>
 #include <glib.h>
-#include <gconf/gconf-client.h>
 #include "gui.h"
 #include "navigation-tree.h"
 #include "main-window.h"
@@ -158,17 +157,11 @@
 void
 fe_init (void)
 {
-	GConfClient *client;
-
-	client = gconf_client_get_default ();
-	gconf_client_add_dir (client, "/apps/xchat", GCONF_CLIENT_PRELOAD_NONE, NULL);
-	g_object_unref (client);
-
 	u = userlist_new ();
 	gui.quit = FALSE;
 	palette_init ();
-	run_migrations ();
 	initialize_gui_1 ();
+	run_migrations ();
 	if (!preferences_exist ()) {
 		run_setup_dialog ();
 	} else {
@@ -1020,14 +1013,9 @@
 			case FE_SE_LOGGEDIN:
 				if (arg == 0) {
 					/* No auto-join channels */
-					GConfClient *client;
 					gboolean popup_channel_list;
 
-					client = gconf_client_get_default ();
-					popup_channel_list = gconf_client_get_bool (client,
-							"/apps/xchat/channel_list/auto_popup",  NULL);
-					g_object_unref (client);
-
+					popup_channel_list = g_settings_get_boolean (gui.settings_channel_list, "auto-popup");
 					if (popup_channel_list)
 						create_channel_list_window (sess, FALSE);
 				}
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/gui.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/gui.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/gui.c	2014-11-12 18:57:53.800332799 -0500
@@ -44,6 +44,14 @@
 
 	gui.manager = gtk_ui_manager_new ();
 
+	gui.settings = g_settings_new ("org.gnome.Xchat");
+	gui.settings_interface = g_settings_new ("org.gnome.desktop.interface");
+	gui.settings_channel_list = g_settings_new ("org.gnome.Xchat.channel-list");
+	gui.settings_irc = g_settings_new ("org.gnome.Xchat.irc");
+	gui.settings_main_window = g_settings_new ("org.gnome.Xchat.main-window");
+	gui.settings_plugins = g_settings_new ("org.gnome.Xchat.plugins");
+	gui.settings_spellcheck = g_settings_new ("org.gnome.Xchat.spellcheck");
+
 	gchar *path = locate_data_file ("xchat-gnome.glade");
 	g_assert (path != NULL);
 
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/gui.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/gui.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/gui.h	2014-11-12 18:57:53.800332799 -0500
@@ -34,6 +34,13 @@
 typedef struct
 {
 	GtkBuilder *xml;
+	GSettings *settings;
+	GSettings *settings_interface;
+	GSettings *settings_channel_list;
+	GSettings *settings_irc;
+	GSettings *settings_main_window;
+	GSettings *settings_plugins;
+	GSettings *settings_spellcheck;
 	GtkActionGroup *action_group;
 	GtkUIManager *manager;
 	PreferencesDialog *prefs_dialog;
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/irc-network-editor.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/irc-network-editor.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/irc-network-editor.c	2014-11-12 18:57:53.800332799 -0500
@@ -37,9 +37,9 @@
 {
 	IrcNetworkEditor *e = (IrcNetworkEditor *) object;
 
-	if (e->gconf) {
-		g_object_unref (e->gconf);
-		e->gconf = NULL;
+	if (e->settings_irc) {
+		g_object_unref (e->settings_irc);
+		e->settings_irc = NULL;
 	}
 	if (e->network) {
 		g_object_unref (e->network);
@@ -81,11 +81,11 @@
 {
 	gchar *text;
 
-	text = gconf_client_get_string (e->gconf, "/apps/xchat/irc/nickname", NULL);
+	text = g_settings_get_string (e->settings_irc, "nickname");
 	gtk_entry_set_text (GTK_ENTRY (e->nickname), text);
 	g_free (text);
 
-	text = gconf_client_get_string (e->gconf, "/apps/xchat/irc/realname", NULL);
+	text = g_settings_get_string (e->settings_irc, "realname");
 	gtk_entry_set_text (GTK_ENTRY (e->realname), text);
 	g_free (text);
 
@@ -257,7 +257,7 @@
 	gchar **enc;
 	GtkTreeSelection *server_selection, *autojoin_selection;
 
-	dialog->gconf = NULL;
+	dialog->settings_irc = NULL;
 	dialog->network = NULL;
 	dialog->toplevel = NULL;
 
@@ -451,7 +451,7 @@
 {
 	gchar *title;
 
-	e->gconf = gconf_client_get_default ();
+	e->settings_irc = g_settings_new ("org.gnome.Xchat.irc");
 
 	if (!e->network->net) {
 		/* We're creating a new network. Don't populate things from the structure */
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/irc-network-editor.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/irc-network-editor.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/irc-network-editor.h	2014-11-12 18:57:53.800332799 -0500
@@ -20,7 +20,6 @@
  */
 
 #include <gtk/gtk.h>
-#include <gconf/gconf-client.h>
 #include "irc-network.h"
 
 #ifndef __XCHAT_GNOME_IRC_NETWORK_EDITOR_H__
@@ -41,7 +40,7 @@
 	GtkDialog parent;
 
 	IrcNetwork *network;
-	GConfClient *gconf;
+	GSettings  *settings_irc;
 
 	GtkWidget *network_settings_table;
 
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/main-window.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/main-window.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/main-window.c	2014-11-12 18:57:53.800332799 -0500
@@ -22,7 +22,6 @@
 #include <config.h>
 #include <glib/gi18n.h>
 #include <string.h>
-#include <gconf/gconf-client.h>
 #include <gtk/gtk.h>
 #include <gdk/gdkkeysyms.h>
 #include <sys/types.h>
@@ -93,7 +92,7 @@
 
 static void nickname_style_set (GtkWidget *button, GtkStyle *previous_style, gpointer data);
 
-static void main_window_userlist_location_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, gpointer user_data);
+static void main_window_userlist_location_changed (GSettings *settings, gchar *key, gpointer user_data);
 
 static GtkActionEntry action_entries [] = {
 
@@ -152,7 +151,6 @@
 	GtkWidget *close, *menu_vbox, *widget;
 	GtkSizeGroup *group;
 	GtkAction *action;
-	GConfClient *client;
 	GdkVisual *visual;
 
 	gui.main_window = GTK_WIDGET (gtk_builder_get_object (gui.xml, "xchat-gnome"));
@@ -240,48 +238,37 @@
 	gtk_button_set_use_underline (GTK_BUTTON (gui.nick_button), FALSE);
 	g_signal_connect (G_OBJECT (gui.nick_button), "clicked",   G_CALLBACK (on_nickname_clicked), NULL);
 	g_signal_connect (G_OBJECT (gtk_bin_get_child (GTK_BIN (gui.nick_button))), "style-set", G_CALLBACK (nickname_style_set),  NULL);
-    
-    client = gconf_client_get_default ();
-    
-    /* move userlist to main window if applicable */
-    main_window_set_show_userlist (gconf_client_get_bool (client, "/apps/xchat/main_window/userlist_in_main_window", NULL));
-    
-	gconf_client_notify_add (client, "/apps/xchat/main_window/userlist_in_main_window", (GConfClientNotifyFunc) main_window_userlist_location_changed, NULL, NULL, NULL);
 
-    g_object_unref (client);
+	/* move userlist to main window if applicable */
+	main_window_set_show_userlist (g_settings_get_boolean (gui.settings_main_window, "userlist-in-main-window"));
+	g_signal_connect (G_OBJECT (gui.settings_main_window), "changed::userlist-in-main-window", G_CALLBACK (main_window_userlist_location_changed), NULL);
 }
 
 void
 run_main_window (gboolean fullscreen)
 {
-	GConfClient *client = gconf_client_get_default();
+	int width, height;
+	int x, y;
+	int h;
 
-	int width = gconf_client_get_int(client,
-	                                 "/apps/xchat/main_window/width",
-	                                 NULL);
-	int height = gconf_client_get_int(client,
-	                                  "/apps/xchat/main_window/height",
-	                                  NULL);
+	width = g_settings_get_int(gui.settings_main_window, "width");
+	height = g_settings_get_int(gui.settings_main_window, "height");
 	if (width == 0 || height == 0) {
 		width = 800;
 		height = 550;
 	}
-	gboolean maximized = gconf_client_get_bool(client,
-	                                           "/apps/xchat/main_window/maximized",
-	                                           NULL);
+	gboolean maximized = g_settings_get_boolean (gui.settings_main_window, "maximized");
 	gtk_window_set_default_size(GTK_WINDOW(gui.main_window), width, height);
    	if (maximized)
 		gtk_window_maximize(GTK_WINDOW(gui.main_window));
 
-	int x = gconf_client_get_int (client, "/apps/xchat/main_window/x", NULL);
-	int y = gconf_client_get_int (client, "/apps/xchat/main_window/y", NULL);
+	x = g_settings_get_int (gui.settings_main_window, "x");
+	y = g_settings_get_int (gui.settings_main_window, "y");
 	if (!(x == 0 || y == 0)) {
 		gtk_window_move (GTK_WINDOW(gui.main_window), x, y);
 	}
 
-	int h = gconf_client_get_int(client,
-	                             "/apps/xchat/main_window/hpane",
-	                             NULL);
+	h = g_settings_get_int(gui.settings_main_window, "hpane");
 	if (h != 0) {
 		GtkWidget *hpane = GTK_WIDGET (gtk_builder_get_object (gui.xml, "HPane"));
 		gtk_paned_set_position(GTK_PANED(hpane), h);
@@ -299,15 +286,13 @@
 	GtkAction *action;
 
 	action = gtk_action_group_get_action(gui.action_group, "ViewShowSidebar");
-	val = gconf_client_get_bool(client, "/apps/xchat/main_window/show_hpane", NULL);
+	val = g_settings_get_boolean (gui.settings_main_window, "show-hpane");
 	gtk_toggle_action_set_active(GTK_TOGGLE_ACTION(action), val);
 
 	action = gtk_action_group_get_action(gui.action_group, "ViewStatusbar");        
-	val = gconf_client_get_bool(client, "/apps/xchat/main_window/show_statusbar",NULL);
+	val = g_settings_get_boolean (gui.settings_main_window, "show-statusbar");
 	gtk_toggle_action_set_active(GTK_TOGGLE_ACTION(action), val);
 
-	g_object_unref (client);
-
 	gtk_widget_show (gui.main_window);
 
 	action = gtk_action_group_get_action(gui.action_group,
@@ -349,13 +334,10 @@
 save_main_window ()
 {
 	gint x, y;
-	GConfClient *client;
 
 	gtk_window_get_position (GTK_WINDOW (gui.main_window), &x, &y);
-	client = gconf_client_get_default ();
-	gconf_client_set_int (client, "/apps/xchat/main_window/x", x, NULL);
-	gconf_client_set_int (client, "/apps/xchat/main_window/y", y, NULL);
-	g_object_unref (client);
+	g_settings_set_int (gui.settings_main_window, "x", x);
+	g_settings_set_int (gui.settings_main_window, "y", y);
 }
 
 static gboolean
@@ -367,6 +349,13 @@
 	  return TRUE;
 	}
 	save_main_window ();
+	g_object_unref (gui.settings);
+	g_object_unref (gui.settings_interface);
+	g_object_unref (gui.settings_channel_list);
+	g_object_unref (gui.settings_irc);
+	g_object_unref (gui.settings_main_window);
+	g_object_unref (gui.settings_plugins);
+	g_object_unref (gui.settings_spellcheck);
 	gui.quit = TRUE;
 
 	gtk_widget_hide (GTK_WIDGET (gui.dcc));
@@ -382,6 +371,13 @@
 	gtk_widget_hide (GTK_WIDGET (gui.main_window));
 	gtk_widget_hide (GTK_WIDGET (gui.dcc));
 	userlist_gui_hide ();
+	g_object_unref (gui.settings);
+	g_object_unref (gui.settings_interface);
+	g_object_unref (gui.settings_channel_list);
+	g_object_unref (gui.settings_irc);
+	g_object_unref (gui.settings_main_window);
+	g_object_unref (gui.settings_plugins);
+	g_object_unref (gui.settings_spellcheck);
 	gui.quit = TRUE;
 	xchat_exit ();
 }
@@ -467,15 +463,12 @@
 	session *s = gui.current_session;
 	if ((s != NULL) && (s->type == SESS_CHANNEL) && (s->channel[0] != '\0')) {
 		gchar *text;
-		GConfClient *client;
 
-		client = gconf_client_get_default ();
-		text = gconf_client_get_string (client, "/apps/xchat/irc/partmsg", NULL);
+		text = g_settings_get_string (gui.settings_irc, "partmsg");
 		if (text == NULL) {
 			text = g_strdup (_("Ex-Chat"));
 		}
 		s->server->p_part (s->server, s->channel, text);
-		g_object_unref (client);
 		g_free (text);
 	}
 }
@@ -491,15 +484,13 @@
 	switch (s->type) {
 	case SESS_CHANNEL:
 	{
-		GConfClient *client = gconf_client_get_default ();
-		gchar *text = gconf_client_get_string (client, "/apps/xchat/irc/partmsg", NULL);
+		gchar *text = g_settings_get_string (gui.settings_irc, "partmsg");
 		if (text == NULL) {
 			text = g_strdup (_("Ex-Chat"));
 		}
 
 		s->server->p_part (s->server, s->channel, text);
 
-		g_object_unref (client);
 		g_free (text);
 
 		break;
@@ -560,15 +551,9 @@
 static void
 on_sidebar_toggled (GtkToggleAction *action, gpointer data)
 {
-	GConfClient *client;
 	GtkWidget *paned, *child;
 
-	client = gconf_client_get_default();
-	gconf_client_set_bool(client,
-	                      "/apps/xchat/main_window/show_hpane",
-	                      gtk_toggle_action_get_active(action),
-	                      NULL);
-	g_object_unref(client);
+	g_settings_set_boolean (gui.settings_main_window, "show-hpane", gtk_toggle_action_get_active(action));
 
 	paned = GTK_WIDGET (gtk_builder_get_object (gui.xml, "HPane"));
 	child = gtk_paned_get_child1(GTK_PANED(paned));
@@ -583,13 +568,7 @@
 static void
 on_statusbar_toggled (GtkToggleAction *action, gpointer data)
 {
-        GConfClient *client;
-        client = gconf_client_get_default();
-        gconf_client_set_bool(client,
-                              "/apps/xchat/main_window/show_statusbar",
-                              gtk_toggle_action_get_active(action),
-                              NULL);
-        g_object_unref(client);
+	g_settings_set_boolean (gui.settings_main_window, "show-statusbar", gtk_toggle_action_get_active(action));
 
         if (gtk_toggle_action_get_active(action)) {
                 gtk_widget_show(gui.status_bar);
@@ -673,13 +652,9 @@
 static gboolean
 on_resize (GtkWidget *widget, GdkEventConfigure *event, gpointer data)
 {
-	GConfClient *client;
-
-	if (!gui.maximized) {  
-		client = gconf_client_get_default ();
-		gconf_client_set_int (client, "/apps/xchat/main_window/width",  event->width,  NULL);
-		gconf_client_set_int (client, "/apps/xchat/main_window/height", event->height, NULL);
-		g_object_unref (client);
+	if (!gui.maximized) {
+		g_settings_set_int (gui.settings_main_window, "width",  event->width);
+		g_settings_set_int (gui.settings_main_window, "height", event->height);
 	}
 
 	return FALSE;
@@ -688,12 +663,8 @@
 static gboolean
 on_state_change (GtkWidget *widget, GdkEventWindowState *event, gpointer data)
 {
-	GConfClient *client;
-
-	client = gconf_client_get_default ();
 	gui.maximized = (event->new_window_state & GDK_WINDOW_STATE_MAXIMIZED) != 0;
-	gconf_client_set_bool (client, "/apps/xchat/main_window/maximized", gui.maximized, NULL);
-	g_object_unref (client);
+	g_settings_set_boolean (gui.settings_main_window, "maximized", gui.maximized);
 
 	return FALSE;
 }
@@ -701,13 +672,10 @@
 static gboolean
 on_hpane_move (GtkPaned *widget, GParamSpec *param_spec, gpointer data)
 {
-	GConfClient *client;
 	int pos;
 
-	client = gconf_client_get_default ();
 	pos = gtk_paned_get_position (widget);
-	gconf_client_set_int (client, "/apps/xchat/main_window/hpane", pos, NULL);
-	g_object_unref (client);
+	g_settings_set_int (gui.settings_main_window, "hpane", pos);
 	return FALSE;
 }
 
@@ -825,10 +793,9 @@
 }
 
 static void
-main_window_userlist_location_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, gpointer user_data)
+main_window_userlist_location_changed (GSettings *settings, gchar *key, gpointer user_data)
 {
-	GConfValue *value = gconf_entry_get_value (entry);
-	main_window_set_show_userlist (gconf_value_get_bool (value));
+	main_window_set_show_userlist (g_settings_get_boolean (settings, "userlist-in-main-window"));
 }
 
 void
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/migration.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/migration.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/migration.c	2014-11-12 18:57:53.800332799 -0500
@@ -21,8 +21,9 @@
 
 #include <config.h>
 #include <stdlib.h>
+#include <string.h>
 #include <glib/gi18n.h>
-#include <gconf/gconf-client.h>
+#include "gui.h"
 #include "migration.h"
 #include "util.h"
 
@@ -41,10 +42,7 @@
 static gint
 check_version (guint major, guint minor, guint micro)
 {
-
-	GConfClient *client = gconf_client_get_default ();
-	gchar *version = gconf_client_get_string (client, "/apps/xchat/version", NULL);
-	g_object_unref (client);
+	gchar *version = g_settings_get_string (gui.settings, "version");
 
 	if (version == NULL) {
 		return 0;
@@ -85,11 +83,9 @@
 static void
 dbus_migration_remove_autoload (void)
 {
-	GConfClient *client;
 	GSList *enabled_plugins, *l;
 
-	client = gconf_client_get_default ();
-	enabled_plugins = gconf_client_get_list (client, "/apps/xchat/plugins/loaded", GCONF_VALUE_STRING, NULL);
+	enabled_plugins = xchat_settings_get_list (gui.settings_plugins, "loaded");
 
 	l = enabled_plugins;
 	while (l != NULL) {
@@ -102,9 +98,7 @@
 			l = l->next;
 		}
 	}
-	gconf_client_set_list (client, "/apps/xchat/plugins/loaded", GCONF_VALUE_STRING, enabled_plugins, NULL);
-
-	g_object_unref (client);
+	xchat_settings_set_list (gui.settings_plugins, "loaded", enabled_plugins);
 }
 
 static void
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/org.gnome.Xchat.gschema.xml
===================================================================
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/org.gnome.Xchat.gschema.xml	2014-11-12 18:57:53.800332799 -0500
@@ -0,0 +1,144 @@
+<schemalist>
+  <schema id="org.gnome.Xchat" path="/org/gnome/Xchat/">
+    <key name="version" type="s">
+      <default>''</default>
+      <summary>xchat configuration version</summary>
+    </key>
+    <child name="irc" schema="org.gnome.Xchat.irc"/>
+    <child name="main-window" schema="org.gnome.Xchat.main-window"/>
+    <child name="channel-list" schema="org.gnome.Xchat.channel-list"/>
+    <child name="plugins" schema="org.gnome.Xchat.plugins"/>
+    <child name="spellcheck" schema="org.gnome.Xchat.spellcheck"/>
+  </schema>
+  <schema id="org.gnome.Xchat.irc" path="/org/gnome/Xchat/irc/">
+    <key name="nickname" type="s">
+      <default>''</default>
+      <summary>Default nickname used by servers without special options set</summary>
+    </key>
+    <key name="realname" type="s">
+      <default>''</default>
+      <summary>Default real name used by servers without special options set</summary>
+    </key>
+    <key name="quitmsg" type="s">
+      <default>'Ex-Chat'</default>
+      <summary>Message sent on quit</summary>
+    </key>
+    <key name="partmsg" type="s">
+      <default>'Ex-Chat'</default>
+      <summary>Message sent on channel part</summary>
+    </key>
+    <key name="awaymsg" type="s">
+      <default>'Away'</default>
+      <summary>Message sent on away</summary>
+    </key>
+    <key name="showcolors" type="b">
+      <default>true</default>
+      <summary>Show colors in the main window</summary>
+    </key>
+    <key name="colorize-nicknames" type="b">
+      <default>false</default>
+      <summary>Colorize nicknames in the main window</summary>
+    </key>
+    <key name="showtimestamps" type="b">
+      <default>true</default>
+      <summary>Show timestamps in the main window</summary>
+    </key>
+    <key name="color-scheme" type="i">
+      <default>3</default>
+      <summary>Selected color scheme</summary>
+    </key>
+  </schema>
+  <schema id="org.gnome.Xchat.main-window" path="/org/gnome/Xchat/main-window/">
+    <key name="background-type" type="i">
+      <default>0</default>
+      <summary>Selected background type</summary>
+    </key>
+    <key name="background-image" type="s">
+      <default>''</default>
+      <summary>Background image filename</summary>
+    </key>
+    <key name="background-transparency" type="d">
+      <default>0.5</default>
+      <summary>Background transparency</summary>
+    </key>
+    <key name="use-sys-fonts" type="b">
+      <default>true</default>
+      <summary>Use system fonts</summary>
+    </key>
+    <key name="font" type="s">
+      <default>'Bitstream Vera Sans Mono 10'</default>
+      <summary>Font for the main window</summary>
+    </key>
+    <key name="width" type="i">
+      <default>800</default>
+      <summary>Width of the main window</summary>
+    </key>
+    <key name="height" type="i">
+      <default>600</default>
+      <summary>Height of the main window</summary>
+    </key>
+    <key name="x" type="i">
+      <default>0</default>
+      <summary>X position of the main window on the screen</summary>
+    </key>
+    <key name="y" type="i">
+      <default>0</default>
+      <summary>Y position of the main window on the screen</summary>
+    </key>
+    <key name="maximized" type="b">
+      <default>false</default>
+      <summary>Whether the main window is maximized</summary>
+    </key>
+    <key name="show-hpane" type="b">
+      <default>true</default>
+      <summary>Whether the horizontal pane in the main window is shown</summary>
+    </key>
+    <key name="show-statusbar" type="b">
+      <default>true</default>
+      <summary>Whether the statusbar in the main window is shown</summary>
+    </key>
+    <key name="hpane" type="i">
+      <default>0</default>
+      <summary>Position of the horizontal pane in the main window</summary>
+    </key>
+    <key name="redundant-nickstamps" type="b">
+      <default>false</default>
+      <summary>Display redundant nickstamps</summary>
+    </key>
+    <key name="userlist-in-main-window" type="b">
+      <default>false</default>
+      <summary>Show user list in main window</summary>
+    </key>
+  </schema>
+  <schema id="org.gnome.Xchat.channel-list" path="/org/gnome/Xchat/channel-list/">
+    <key name="width" type="i">
+      <default>640</default>
+      <summary>Width of the channel list</summary>
+    </key>
+    <key name="height" type="i">
+      <default>480</default>
+      <summary>Height of the channel list</summary>
+    </key>
+    <key name="auto-popup" type="b">
+      <default>true</default>
+      <summary>Automatically display the channel list dialog</summary>
+      <description>If set to true, when you join a server without automatically joining a channel, the channel list dialog will be displayed</description>
+    </key>
+  </schema>
+  <schema id="org.gnome.Xchat.plugins" path="/org/gnome/Xchat/plugins/">
+    <key name="loaded" type="as">
+      <default>[]</default>
+      <summary>List of enabled plugins</summary>
+    </key>
+  </schema>
+  <schema id="org.gnome.Xchat.spellcheck" path="/org/gnome/Xchat/spellcheck/">
+    <key name="enabled" type="b">
+      <default>true</default>
+      <summary>Enable spellchecking</summary>
+    </key>
+    <key name="languages" type="as">
+      <default>[]</default>
+      <summary>Languages to use for spellchecking</summary>
+    </key>
+  </schema>
+</schemalist>
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/plugins.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/plugins.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/plugins.c	2014-11-12 18:57:53.800332799 -0500
@@ -21,10 +21,10 @@
 
 #include <config.h>
 #include <glib/gi18n.h>
-#include <gconf/gconf-client.h>
 #include <gmodule.h>
 #include <string.h>
 #include "gui.h"
+#include "util.h"
 #include "../common/util.h"
 #include "../common/xchat-plugin.h"
 #include "../common/plugin.h"
@@ -50,18 +50,13 @@
 static void
 autoload_plugin_cb (gchar * filename, gpointer data)
 {
-	GConfClient *client;
-
 	gchar *err;
 
 	gboolean script = GPOINTER_TO_INT (data);
 	err = load_plugin (gui.current_session, filename, NULL, script, TRUE);
 	if (err != NULL) {
-		client = gconf_client_get_default ();
 		enabled_plugins = g_slist_remove (enabled_plugins, filename);
-		gconf_client_set_list (client, "/apps/xchat/plugins/loaded", GCONF_VALUE_STRING,
-				enabled_plugins, NULL);
-		g_object_unref (client);
+		xchat_settings_set_list (gui.settings_plugins, "loaded", enabled_plugins);
 	}
 }
 
@@ -79,11 +74,7 @@
 void
 plugins_initialize (void)
 {
-	GConfClient *client;
-
-	client = gconf_client_get_default ();
-	enabled_plugins = gconf_client_get_list (client, "/apps/xchat/plugins/loaded", GCONF_VALUE_STRING, NULL);
-	g_object_unref (client);
+	enabled_plugins = xchat_settings_get_list (gui.settings_plugins, "loaded");
 }
 
 int
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-dialog.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-dialog.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-dialog.c	2014-11-12 18:57:53.800332799 -0500
@@ -79,9 +79,19 @@
 		p->spellcheck_page = NULL;
 	}
 
-	if (p->gconf) {
-		g_object_unref (p->gconf);
-		p->gconf = NULL;
+	if (p->settings_irc) {
+		g_object_unref (p->settings_irc);
+		p->settings_irc = NULL;
+	}
+
+	if (p->settings_main_window) {
+		g_object_unref (p->settings_main_window);
+		p->settings_main_window = NULL;
+	}
+
+	if (p->settings_spellcheck) {
+		g_object_unref (p->settings_spellcheck);
+		p->settings_spellcheck = NULL;
 	}
 
 	if (p->dialog) {
@@ -189,7 +199,6 @@
 	GtkTreeViewColumn *column;
 	GtkTreeSelection *select;
 
-	p->gconf = NULL;
 	p->dialog = NULL;
 
 	gchar *path = locate_data_file ("preferences-dialog.glade");
@@ -206,7 +215,9 @@
 	GW(settings_notebook);
 #undef GW
 
-	p->gconf = gconf_client_get_default ();
+	p->settings_irc = g_settings_new ("org.gnome.Xchat.irc");
+	p->settings_main_window = g_settings_new ("org.gnome.Xchat.main-window");
+	p->settings_spellcheck = g_settings_new ("org.gnome.Xchat.spellcheck");
 
 	g_assert (p->dialog);
 
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-dialog.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-dialog.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-dialog.h	2014-11-12 18:57:53.800332799 -0500
@@ -19,7 +19,6 @@
  *
  */
 
-#include <gconf/gconf-client.h>
 #include "gui.h"
 #include "preferences-page-irc.h"
 #include "preferences-page-colors.h"
@@ -45,7 +44,9 @@
 {
 	GObject parent;
 
-	GConfClient *gconf;
+	GSettings *settings_irc;
+	GSettings *settings_main_window;
+	GSettings *settings_spellcheck;
 
 	GtkWidget *dialog;
 	GtkWidget *settings_page_list;
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-colors.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-colors.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-colors.c	2014-11-12 18:57:53.800332799 -0500
@@ -21,7 +21,6 @@
 
 #include <config.h>
 #include <glib/gi18n.h>
-#include <gconf/gconf-client.h>
 #include "conversation-panel.h"
 #include "gui.h"
 #include "palette.h"
@@ -35,18 +34,6 @@
 static int scheme;
 
 static void
-toggle_pref_changed (GtkToggleButton *button, const gchar *key)
-{
-	GConfClient *client;
-	gboolean value;
-
-	client = gconf_client_get_default ();
-	value = gtk_toggle_button_get_active (button);
-	gconf_client_set_bool (client, key, value, NULL);
-	g_object_unref (client);
-}
-
-static void
 color_button_changed (GtkColorButton *button, gpointer data)
 {
 	int index = GPOINTER_TO_INT (data);
@@ -115,11 +102,8 @@
 colors_changed (GtkComboBox *combo_box, PreferencesPageColors *page)
 {
 	int i, selection;
-	GConfClient *client;
 	gboolean sensitive;
 
-	client = gconf_client_get_default ();
-
 	selection = gtk_combo_box_get_active (combo_box);
 	scheme = selection;
 
@@ -136,32 +120,6 @@
 	gtk_widget_set_sensitive (page->mirc_colors_box, sensitive);
 	gtk_widget_set_sensitive (page->extra_colors_box, sensitive);
 
-	gconf_client_set_int (client, "/apps/xchat/irc/color_scheme", selection, NULL);
-	set_color_buttons (selection, page->color_buttons);
-	set_palette_buttons (selection, page->palette_buttons);
-
-	g_object_unref (client);
-}
-
-static void
-gconf_toggle_pref_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, GtkToggleButton *button)
-{
-	gboolean toggle;
-
-	g_signal_handlers_block_by_func (button, "toggled", toggle_pref_changed);
-	toggle = gconf_client_get_bool (client, entry->key, NULL);
-	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), toggle);
-	g_signal_handlers_unblock_by_func (button, "toggled", toggle_pref_changed);
-}
-
-static void
-gconf_color_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, PreferencesPageColors *page)
-{
-	int selection;
-	selection = gconf_client_get_int (client, entry->key, NULL);
-	scheme = selection;
-
-	gtk_combo_box_set_active (GTK_COMBO_BOX (page->combo), selection);
 	set_color_buttons (selection, page->color_buttons);
 	set_palette_buttons (selection, page->palette_buttons);
 }
@@ -174,7 +132,6 @@
 	GtkSizeGroup *group;
 	GtkTreeIter iter;
 	gint i, j;
-	gboolean toggle;
 
 	palette_init ();
 
@@ -242,8 +199,6 @@
 	gtk_label_set_mnemonic_widget (GTK_LABEL (page->color_label_4), page->color_buttons[2]);
 	gtk_label_set_mnemonic_widget (GTK_LABEL (page->color_label_5), page->color_buttons[3]);
 
-	g_signal_connect (G_OBJECT (page->show_colors),        "toggled", G_CALLBACK (toggle_pref_changed), "/apps/xchat/irc/showcolors");
-	g_signal_connect (G_OBJECT (page->colorize_nicknames), "toggled", G_CALLBACK (toggle_pref_changed), "/apps/xchat/irc/colorize_nicknames");
 	g_signal_connect (G_OBJECT (page->color_buttons[0]), "color-set", G_CALLBACK (color_button_changed), GINT_TO_POINTER (32));
 	g_signal_connect (G_OBJECT (page->color_buttons[1]), "color-set", G_CALLBACK (color_button_changed), GINT_TO_POINTER (33));
 	g_signal_connect (G_OBJECT (page->color_buttons[2]), "color-set", G_CALLBACK (color_button_changed), GINT_TO_POINTER (34));
@@ -263,22 +218,13 @@
 	gtk_widget_show (page->combo);
 	gtk_label_set_mnemonic_widget (GTK_LABEL (page->color_label_1), page->combo);
 	gtk_box_pack_start (GTK_BOX (page->foreground_background_hbox), page->combo, FALSE, TRUE, 0);
-	scheme = gconf_client_get_int (p->gconf, "/apps/xchat/irc/color_scheme", NULL);
 
-	page->nh[0] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/showcolors",
-	                                       (GConfClientNotifyFunc) gconf_toggle_pref_changed, page->show_colors, NULL, NULL);
-	page->nh[1] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/colorize_nicknames",
-					       (GConfClientNotifyFunc) gconf_toggle_pref_changed, page->colorize_nicknames, NULL, NULL);			       
-	page->nh[2] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/color_scheme",
-	                                       (GConfClientNotifyFunc) gconf_color_changed, page, NULL, NULL);
-
-	toggle = gconf_client_get_bool (p->gconf, "/apps/xchat/irc/showcolors", NULL);
-	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->show_colors), toggle);
-	toggle = gconf_client_get_bool (p->gconf, "/apps/xchat/irc/colorize_nicknames", NULL);
-	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->colorize_nicknames), toggle);
+	g_settings_bind (p->settings_irc, "showcolors", G_OBJECT (page->show_colors), "active", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_irc, "colorize-nicknames", G_OBJECT (page->colorize_nicknames), "active", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_irc, "color-scheme", G_OBJECT (page->combo), "active", G_SETTINGS_BIND_DEFAULT);
 
+	scheme = g_settings_get_int (p->settings_irc, "color-scheme");
 	g_signal_connect (G_OBJECT (page->combo), "changed", G_CALLBACK (colors_changed), page);
-	gtk_combo_box_set_active (GTK_COMBO_BOX (page->combo), scheme);
 
 	return page;
 }
@@ -291,16 +237,6 @@
 static void
 preferences_page_colors_finalize (GObject *object)
 {
-	PreferencesPageColors *page = (PreferencesPageColors *) object;
-	gint i;
-	GConfClient *client;
-
-	client = gconf_client_get_default ();
-	for (i = 0; i < 3; i++) {
-		gconf_client_notify_remove (client, page->nh[i]);
-	}
-	g_object_unref (client);
-
 	G_OBJECT_CLASS (preferences_page_colors_parent_class)->finalize (object);
 }
 
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-colors.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-colors.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-colors.h	2014-11-12 18:57:53.800332799 -0500
@@ -62,8 +62,6 @@
 	GtkWidget *mirc_palette_table;
 	GtkWidget *extra_colors_box;
 	GtkWidget *extra_palette_table;
-
-	guint      nh[3];
 };
 
 struct _PreferencesPageColorsClass
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-effects.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-effects.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-effects.c	2014-11-12 18:57:53.800332799 -0500
@@ -21,7 +21,6 @@
 
 #include <config.h>
 #include <glib/gi18n.h>
-#include <gconf/gconf-client.h>
 
 #include "preferences-page-effects.h"
 #include "preferences-dialog.h"
@@ -32,7 +31,6 @@
 static void
 type_changed (GtkToggleButton *button, PreferencesPageEffects *page)
 {
-	GConfClient *client;
 	gint type;
 
 	if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (page->background_none))) {
@@ -49,23 +47,18 @@
 		gtk_widget_set_sensitive (GTK_WIDGET (page->background_transparency), TRUE);
 	}
 
-	client = gconf_client_get_default ();
-	gconf_client_set_int (client, "/apps/xchat/main_window/background_type", type, NULL);
-	g_object_unref (client);
+	g_settings_set_int (page->settings_main_window, "background-type", type);
 }
 
 static void
 image_changed (GtkFileChooser *chooser, PreferencesPageEffects *page)
 {
-	GConfClient *client;
 	gchar *filename;
 
 	filename = gtk_file_chooser_get_filename (chooser);
 
 	if (filename) {
-		client = gconf_client_get_default ();
-		gconf_client_set_string (client, "/apps/xchat/main_window/background_image", filename, NULL);
-		g_object_unref (client);
+		g_settings_set_string (page->settings_main_window, "background-image", filename);
 		g_free (filename);
 	}
 }
@@ -73,25 +66,22 @@
 static void
 transparency_changed (GtkRange *range, PreferencesPageEffects *page)
 {
-	GConfClient *client;
 	gdouble value;
 
 	value = gtk_range_get_value (range);
-
-	client = gconf_client_get_default ();
-	gconf_client_set_float (client, "/apps/xchat/main_window/background_transparency", (float) value, NULL);
-	g_object_unref (client);
+	g_settings_set_double (page->settings_main_window, "background-transparency", value);
 }
 
 static void
-gconf_type_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, PreferencesPageEffects *page)
+settings_type_changed (GSettings *settings, gchar *key, gpointer *user_data)
 {
+	PreferencesPageEffects *page = (PreferencesPageEffects *) user_data;
 	gint type;
 
 	g_signal_handlers_block_by_func (G_OBJECT (page->background_none),        G_CALLBACK (type_changed), page);
 	g_signal_handlers_block_by_func (G_OBJECT (page->background_image),       G_CALLBACK (type_changed), page);
 	g_signal_handlers_block_by_func (G_OBJECT (page->background_transparent), G_CALLBACK (type_changed), page);
-	type = gconf_client_get_int (client, entry->key, NULL);
+	type = g_settings_get_int (settings, key);
 	if (type == 0) {
 		gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->background_none), TRUE);
 		gtk_widget_set_sensitive (GTK_WIDGET (page->background_image_file),   FALSE);
@@ -111,10 +101,13 @@
 }
 
 static void
-gconf_image_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, PreferencesPageEffects *page)
+settings_image_changed (GSettings *settings, gchar *key, gpointer user_data)
 {
+	PreferencesPageEffects *page = (PreferencesPageEffects *) user_data;
+	gchar *filename;
+
 	g_signal_handlers_block_by_func (G_OBJECT (page->background_image_file), G_CALLBACK (image_changed), page);
-	gchar *filename = gconf_client_get_string (client, entry->key, NULL);
+	filename = g_settings_get_string (settings, key);
 	if (filename) {
 		gtk_file_chooser_set_filename (GTK_FILE_CHOOSER (page->background_image_file), filename);
 		g_free (filename);
@@ -123,10 +116,13 @@
 }
 
 static void
-gconf_transparency_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, PreferencesPageEffects *page)
+settings_transparency_changed (GSettings *settings, gchar *key, gpointer user_data)
 {
+	PreferencesPageEffects *page = (PreferencesPageEffects *) user_data;
+	double value;
+
 	g_signal_handlers_block_by_func (G_OBJECT (page->background_transparency), G_CALLBACK (transparency_changed), page);
-	float value = gconf_client_get_float (client, entry->key, NULL);
+	value = g_settings_get_double (settings, key);
 	gtk_range_set_value (GTK_RANGE (page->background_transparency), (double) value);
 	g_signal_handlers_unblock_by_func (G_OBJECT (page->background_transparency), G_CALLBACK (transparency_changed), page);
 }
@@ -162,7 +158,7 @@
 	GtkTreeIter iter;
 	int type;
 	gchar *filename;
-	float transparency;
+	double transparency;
 
 #define GW(name) ((page->name) = GTK_WIDGET (gtk_builder_get_object (xml, #name)))
 	GW(background_none);
@@ -183,17 +179,10 @@
 	gtk_file_chooser_set_preview_widget (GTK_FILE_CHOOSER (page->background_image_file), page->image_preview);
 	g_signal_connect (G_OBJECT (page->background_image_file),   "update-preview",    G_CALLBACK (update_preview),       page);
 
-	g_signal_connect (G_OBJECT (page->background_none),         "toggled",           G_CALLBACK (type_changed),         page);
-	g_signal_connect (G_OBJECT (page->background_image),        "toggled",           G_CALLBACK (type_changed),         page);
-	g_signal_connect (G_OBJECT (page->background_transparent),  "toggled",           G_CALLBACK (type_changed),         page);
-	g_signal_connect (G_OBJECT (page->background_image_file),   "file-set",          G_CALLBACK (image_changed),        page);
-	g_signal_connect (G_OBJECT (page->background_transparency), "value-changed",     G_CALLBACK (transparency_changed), page);
+	page->settings_main_window = p->settings_main_window;
+	g_object_ref (page->settings_main_window);
 
-	page->nh[0] = gconf_client_notify_add (p->gconf, "/apps/xchat/main_window/background_type",         (GConfClientNotifyFunc) gconf_type_changed,         page, NULL, NULL);
-	page->nh[1] = gconf_client_notify_add (p->gconf, "/apps/xchat/main_window/background_image",        (GConfClientNotifyFunc) gconf_image_changed,        page, NULL, NULL);
-	page->nh[2] = gconf_client_notify_add (p->gconf, "/apps/xchat/main_window/background_transparency", (GConfClientNotifyFunc) gconf_transparency_changed, page, NULL, NULL);
-
-	type = gconf_client_get_int (p->gconf, "/apps/xchat/main_window/background_type", NULL);
+	type = g_settings_get_int (page->settings_main_window, "background-type");
 	if (type == 0) {
 		gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->background_none), TRUE);
 		gtk_widget_set_sensitive (GTK_WIDGET (page->background_image_file),   FALSE);
@@ -208,15 +197,25 @@
 		gtk_widget_set_sensitive (GTK_WIDGET (page->background_transparency), TRUE);
 	}
 
-	filename = gconf_client_get_string (p->gconf, "/apps/xchat/main_window/background_image", NULL);
+	filename = g_settings_get_string (page->settings_main_window, "background-image");
 	if (filename) {
 		gtk_file_chooser_set_filename (GTK_FILE_CHOOSER (page->background_image_file), filename);
 		g_free (filename);
 	}
 
-	transparency = gconf_client_get_float (p->gconf, "/apps/xchat/main_window/background_transparency", NULL);
+	transparency = g_settings_get_double (page->settings_main_window, "background-transparency");
 	gtk_range_set_value (GTK_RANGE (page->background_transparency), (gdouble) transparency);
 
+	g_signal_connect (G_OBJECT (page->background_none),         "toggled",           G_CALLBACK (type_changed),         page);
+	g_signal_connect (G_OBJECT (page->background_image),        "toggled",           G_CALLBACK (type_changed),         page);
+	g_signal_connect (G_OBJECT (page->background_transparent),  "toggled",           G_CALLBACK (type_changed),         page);
+	g_signal_connect (G_OBJECT (page->background_image_file),   "file-set",          G_CALLBACK (image_changed),        page);
+	g_signal_connect (G_OBJECT (page->background_transparency), "value-changed",     G_CALLBACK (transparency_changed), page);
+
+	g_signal_connect (page->settings_main_window, "changed::background-type",         G_CALLBACK (settings_type_changed),  page);
+	g_signal_connect (page->settings_main_window, "changed::background-image",        G_CALLBACK (settings_image_changed), page);
+	g_signal_connect (page->settings_main_window, "changed::background-transparency", G_CALLBACK (settings_transparency_changed), page);
+
 	return page;
 }
 
@@ -226,19 +225,16 @@
 }
 
 static void
-preferences_page_effects_finalize (GObject *object)
+preferences_page_effects_dispose (GObject *object)
 {
 	PreferencesPageEffects *page = (PreferencesPageEffects *) object;
-	GConfClient *client;
-	gint i;
 
-	client = gconf_client_get_default ();
-	for (i = 0; i < 3; i++) {
-		gconf_client_notify_remove (client, page->nh[i]);
+	if (page->settings_main_window) {
+		g_object_unref (page->settings_main_window);
+		page->settings_main_window = NULL;
 	}
-	g_object_unref (client);
 
-	G_OBJECT_CLASS (preferences_page_effects_parent_class)->finalize (object);
+	G_OBJECT_CLASS (preferences_page_effects_parent_class)->dispose (object);
 }
 
 static void
@@ -246,5 +242,5 @@
 {
 	GObjectClass *object_class = (GObjectClass *) klass;
 
-	object_class->finalize = preferences_page_effects_finalize;
+	object_class->dispose = preferences_page_effects_dispose;
 }
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-effects.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-effects.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-effects.h	2014-11-12 18:57:53.800332799 -0500
@@ -46,8 +46,7 @@
 	GtkWidget *background_transparency;
 	GtkWidget *image_preview;
 
-	/* gconf notification handlers */
-	guint nh[3];
+	GSettings *settings_main_window;
 };
 
 struct _PreferencesPageEffectsClass
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-irc.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-irc.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-irc.c	2014-11-12 18:57:53.800332799 -0500
@@ -22,7 +22,6 @@
 #include <config.h>
 #include <glib/gi18n.h>
 #include <string.h>
-#include <gconf/gconf-client.h>
 #include "../common/xchat.h"
 #include "../common/text.h"
 #include "../common/xchatc.h"
@@ -37,78 +36,6 @@
 extern struct xchatprefs prefs;
 
 static void
-entry_changed (GtkEntry *entry, const gchar *key)
-{
-	GConfClient *client;
-	const gchar *text;
-
-	client = gconf_client_get_default ();
-	text = gtk_entry_get_text (entry);
-	if (text)
-		gconf_client_set_string (client, key, text, NULL);
-	g_object_unref (client);
-}
-
-static void
-bool_changed (GtkToggleButton *button, const gchar *key)
-{
-	GConfClient *client;
-	gboolean value;
-
-	client = gconf_client_get_default ();
-	value = gtk_toggle_button_get_active (button);
-	gconf_client_set_bool (client, key, value, NULL);
-	g_object_unref (client);
-}
-
-static void
-font_changed (GtkFontButton *button, const gchar *key)
-{
-	GConfClient *client;
-	const gchar *text;
-
-	client = gconf_client_get_default ();
-	text = gtk_font_button_get_font_name (button);
-	gconf_client_set_string (client, key, text, NULL);
-	g_object_unref (client);
-}
-
-static void
-gconf_entry_changed (GConfClient *client, guint cnxn_id,  GConfEntry *entry, GtkEntry *gtkentry)
-{
-	gchar *text;
-
-	g_signal_handlers_block_by_func (gtkentry, "changed", entry_changed);
-	text = gconf_client_get_string (client, entry->key, NULL);
-	gtk_entry_set_text (gtkentry, text);
-	g_free (text);
-	g_signal_handlers_unblock_by_func (gtkentry, "changed", entry_changed);
-}
-
-static void
-gconf_bool_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, GtkToggleButton *button)
-{
-	gboolean toggle;
-
-	g_signal_handlers_block_by_func (button, "toggled", bool_changed);
-	toggle = gconf_client_get_bool (client, entry->key, NULL);
-	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), toggle);
-	g_signal_handlers_unblock_by_func (button, "toggled", bool_changed);
-}
-
-static void
-gconf_font_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, GtkFontButton *button)
-{
-	gchar *text;
-
-	g_signal_handlers_block_by_func (button, "font-set", font_changed);
-	text = gconf_client_get_string (client, entry->key, NULL);
-	gtk_font_button_set_font_name (button, text);
-	g_free (text);
-	g_signal_handlers_unblock_by_func (button, "font-set", font_changed);
-}
-
-static void
 sysfonts_changed (GtkToggleButton *toggle, PreferencesPageIrc *page)
 {
 	gtk_widget_set_sensitive (page->font_selection, !gtk_toggle_button_get_active (toggle));
@@ -270,13 +197,9 @@
 userlist_main_changed (GtkToggleButton *button, gpointer data)
 {
 	gboolean active;
-    GConfClient *client = gconf_client_get_default ();
 
 	active = gtk_toggle_button_get_active (button);
 	main_window_set_show_userlist (active);
-
-	gconf_client_set_bool (client, "/apps/xchat/main_window/userlist_in_main_window", active, NULL);
-    g_object_unref (client);
 }
 
 PreferencesPageIrc*
@@ -286,8 +209,6 @@
 	PreferencesDialog *p = (PreferencesDialog *) prefs_dialog;
 	GtkTreeIter iter;
 	GtkCellRenderer *renderer;
-	gchar *text;
-	gboolean toggle;
 	GtkTreeSelection *select;
 	gchar **highlight_entries;
 	gint i;
@@ -320,15 +241,18 @@
 	gtk_list_store_append (p->page_store, &iter);
 	gtk_list_store_set (p->page_store, &iter, 0, PREFERENCES_PAGE (page)->icon, 1, _("IRC Preferences"), 2, 0, -1);
 
-	g_signal_connect (G_OBJECT (page->nick_name),        "changed",  G_CALLBACK (entry_changed),    "/apps/xchat/irc/nickname");
-	g_signal_connect (G_OBJECT (page->real_name),        "changed",  G_CALLBACK (entry_changed),    "/apps/xchat/irc/realname");
-	g_signal_connect (G_OBJECT (page->quit_message),     "changed",  G_CALLBACK (entry_changed),    "/apps/xchat/irc/quitmsg");
-	g_signal_connect (G_OBJECT (page->part_message),     "changed",  G_CALLBACK (entry_changed),    "/apps/xchat/irc/partmsg");
-	g_signal_connect (G_OBJECT (page->away_message),     "changed",  G_CALLBACK (entry_changed),    "/apps/xchat/irc/awaymsg");
-	g_signal_connect (G_OBJECT (page->usesysfonts),      "toggled",  G_CALLBACK (bool_changed),     "/apps/xchat/main_window/use_sys_fonts");
+	g_settings_bind (p->settings_irc, "nickname", G_OBJECT (page->nick_name), "text", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_irc, "realname", G_OBJECT (page->real_name), "text", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_irc, "quitmsg", G_OBJECT (page->quit_message), "text", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_irc, "partmsg", G_OBJECT (page->part_message), "text", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_irc, "awaymsg", G_OBJECT (page->away_message), "text", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_irc, "showtimestamps", G_OBJECT (page->show_timestamps), "active", G_SETTINGS_BIND_DEFAULT);
+
+	g_settings_bind (p->settings_main_window, "use-sys-fonts", G_OBJECT (page->usesysfonts), "active", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_main_window, "font", G_OBJECT (page->font_selection), "font-name", G_SETTINGS_BIND_DEFAULT);
+	g_settings_bind (p->settings_main_window, "userlist-in-main-window", G_OBJECT (page->userlist_main), "active", G_SETTINGS_BIND_DEFAULT);
+
 	g_signal_connect (G_OBJECT (page->usesysfonts),      "toggled",  G_CALLBACK (sysfonts_changed), page);
-	g_signal_connect (G_OBJECT (page->font_selection),   "font-set", G_CALLBACK (font_changed),     "/apps/xchat/main_window/font");
-	g_signal_connect (G_OBJECT (page->show_timestamps),  "toggled",  G_CALLBACK (bool_changed),     "/apps/xchat/irc/showtimestamps");
 	g_signal_connect (G_OBJECT (page->auto_logging),     "toggled",  G_CALLBACK (auto_logging_changed), NULL);
 	g_signal_connect (G_OBJECT (page->show_marker),      "toggled",  G_CALLBACK (show_marker_changed), NULL);
 	g_signal_connect (G_OBJECT (page->userlist_main),    "toggled",  G_CALLBACK (userlist_main_changed), NULL);
@@ -336,74 +260,6 @@
 	g_signal_connect (G_OBJECT (page->highlight_edit),   "clicked",  G_CALLBACK (highlight_edit),   page);
 	g_signal_connect (G_OBJECT (page->highlight_remove), "clicked",  G_CALLBACK (highlight_remove), page);
 
-	page->nh[0] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/nickname",              (GConfClientNotifyFunc) gconf_entry_changed, page->nick_name,       NULL, NULL);
-	page->nh[1] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/realname",              (GConfClientNotifyFunc) gconf_entry_changed, page->real_name,       NULL, NULL);
-	page->nh[2] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/quitmsg",               (GConfClientNotifyFunc) gconf_entry_changed, page->quit_message,    NULL, NULL);
-	page->nh[3] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/partmsg",               (GConfClientNotifyFunc) gconf_entry_changed, page->part_message,    NULL, NULL);
-	page->nh[4] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/awaymsg",               (GConfClientNotifyFunc) gconf_entry_changed, page->away_message,    NULL, NULL);
-	page->nh[5] = gconf_client_notify_add (p->gconf, "/apps/xchat/main_window/use_sys_fonts", (GConfClientNotifyFunc) gconf_bool_changed,  page->usesysfonts,     NULL, NULL);
-	page->nh[6] = gconf_client_notify_add (p->gconf, "/apps/xchat/main-window/font",          (GConfClientNotifyFunc) gconf_font_changed,  page->font_selection,  NULL, NULL);
-	page->nh[7] = gconf_client_notify_add (p->gconf, "/apps/xchat/irc/showtimestamps",        (GConfClientNotifyFunc) gconf_bool_changed,  page->show_timestamps, NULL, NULL);
-
-	text = gconf_client_get_string (p->gconf, "/apps/xchat/irc/nickname", NULL);
-	if (text) {
-		gtk_entry_set_text (GTK_ENTRY (page->nick_name), text);
-		g_free (text);
-	} else {
-		gtk_entry_set_text (GTK_ENTRY (page->nick_name), "");
-	}
-
-	text = gconf_client_get_string (p->gconf, "/apps/xchat/irc/realname", NULL);
-	if (text) {
-		gtk_entry_set_text (GTK_ENTRY (page->real_name), text);
-		g_free (text);
-	} else {
-		gtk_entry_set_text (GTK_ENTRY (page->real_name), "");
-	}
-
-	text = gconf_client_get_string (p->gconf, "/apps/xchat/irc/quitmsg", NULL);
-	if (text) {
-		gtk_entry_set_text (GTK_ENTRY (page->quit_message), text);
-		g_free (text);
-	} else {
-		gtk_entry_set_text (GTK_ENTRY (page->quit_message), "");
-	}
-
-	text = gconf_client_get_string (p->gconf, "/apps/xchat/irc/partmsg", NULL);
-	if (text) {
-		gtk_entry_set_text (GTK_ENTRY (page->part_message), text);
-		g_free (text);
-	} else {
-		gtk_entry_set_text (GTK_ENTRY (page->part_message), "");
-	}
-
-	text = gconf_client_get_string (p->gconf, "/apps/xchat/irc/awaymsg", NULL);
-	if (text) {
-		gtk_entry_set_text (GTK_ENTRY (page->away_message), text);
-		g_free (text);
-	} else {
-		gtk_entry_set_text (GTK_ENTRY (page->away_message), "");
-	}
-
-	toggle = gconf_client_get_bool (p->gconf, "/apps/xchat/main_window/use_sys_fonts", NULL);
-	if (toggle)
-		gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->usesysfonts), TRUE);
-	else
-		gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->usethisfont), TRUE);
-	gtk_widget_set_sensitive (page->font_selection, !toggle);
-
-	text = gconf_client_get_string (p->gconf, "/apps/xchat/main_window/font", NULL);
-	if (text) {
-		gtk_font_button_set_font_name (GTK_FONT_BUTTON (page->font_selection), text);
-		g_free (text);
-	}
-
-	toggle = gconf_client_get_bool (p->gconf, "/apps/xchat/irc/showtimestamps", NULL);
-	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->show_timestamps), toggle);
-
-	toggle = gconf_client_get_bool (p->gconf, "/apps/xchat/main_window/userlist_in_main_window", NULL);
-	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->userlist_main), toggle);
-
     gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->auto_logging), prefs.logging);
 	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->show_marker), prefs.show_marker);
 	/* highlight list */
@@ -452,17 +308,6 @@
 static void
 preferences_page_irc_finalize (GObject *object)
 {
-	PreferencesPageIrc *page = (PreferencesPageIrc *) object;
-	gint i;
-	GConfClient *client;
-
-	client = gconf_client_get_default ();
-	for (i = 0; i < 8; i++) {
-		gconf_client_notify_remove (client, page->nh[i]);
-	}
-
-	g_object_unref (client);
-
 	G_OBJECT_CLASS (preferences_page_irc_parent_class)->finalize (object);
 }
 
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-irc.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-irc.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-irc.h	2014-11-12 18:57:53.800332799 -0500
@@ -61,9 +61,6 @@
 
 	GtkListStore *highlight_store;
 	GtkTreeViewColumn *highlight_column;
-
-	/* gconf notification handlers */
-	guint nh[8];
 };
 
 struct _PreferencesPageIrcClass
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-networks.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-networks.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-networks.c	2014-11-12 18:57:53.804332827 -0500
@@ -21,7 +21,6 @@
 
 #include <config.h>
 #include <glib/gi18n.h>
-#include <gconf/gconf-client.h>
 #include "preferences-page-networks.h"
 #include "preferences-dialog.h"
 #include "irc-network.h"
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-plugins.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-plugins.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-plugins.c	2014-11-12 18:57:53.804332827 -0500
@@ -21,7 +21,6 @@
 
 #include <config.h>
 #include <glib/gi18n.h>
-#include <gconf/gconf-client.h>
 #include <string.h>
 
 #include "preferences-page.h"
@@ -169,8 +168,6 @@
 static void
 load_unload (char *filename, gboolean loaded, PreferencesPagePlugins *page, GtkTreeIter iter)
 {
-	GConfClient *client;
-
 	/* FIXME: Now that we're handling these things in such a way that
 	 * we check for successful a load/unload we should maybe do something
 	 * with any errors we receive.
@@ -205,10 +202,8 @@
 		}
 	}
 
-	/* Update the enabled gconf key. */
-	client = gconf_client_get_default ();
-	gconf_client_set_list (client, "/apps/xchat/plugins/loaded", GCONF_VALUE_STRING, enabled_plugins, NULL);
-	g_object_unref (client);
+	/* Update the enabled gsetting. */
+	xchat_settings_set_list (gui.settings_plugins, "loaded", enabled_plugins);
 }
 
 static void
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-spellcheck.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-spellcheck.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-spellcheck.c	2014-11-12 18:57:53.804332827 -0500
@@ -22,7 +22,6 @@
 #include <config.h>
 #include <glib/gi18n.h>
 #include <string.h>
-#include <gconf/gconf-client.h>
 #include "preferences-page-spellcheck.h"
 #include "preferences-dialog.h"
 #include "util.h"
@@ -46,16 +45,12 @@
 static void
 enabled_changed (GtkToggleButton *button, PreferencesPageSpellcheck *page)
 {
-	GConfClient *client;
 	gboolean enabled;
 
-	client = gconf_client_get_default ();
 	enabled = gtk_toggle_button_get_active (button);
-	gconf_client_set_bool (client, "/apps/xchat/spellcheck/enabled", enabled, NULL);
+	g_settings_set_boolean (gui.settings_spellcheck, "enabled", enabled);
 
 	gtk_widget_set_sensitive (page->spellcheck_list, enabled);
-
-	g_object_unref (client);
 }
 
 static void
@@ -66,7 +61,6 @@
 	gchar *lang;
 	gboolean activated, result;
 	GSList *languages;
-	GConfClient *client;
 	GError *err = NULL;
 
 	result = TRUE;
@@ -86,10 +80,8 @@
 
 		if (result) {
 			/* ok we can update the configuration */
-			client = gconf_client_get_default ();
 			languages = sexy_spell_entry_get_active_languages (SEXY_SPELL_ENTRY (gui.text_entry));
-			gconf_client_set_list (client, "/apps/xchat/spellcheck/languages",
-			                       GCONF_VALUE_STRING, languages, NULL);
+			xchat_settings_set_list (gui.settings_spellcheck, "languages", languages);
 
 			if (languages == NULL) {
 				/* No more languages selected: deactivate spellchecking */
@@ -98,7 +90,6 @@
 
 			g_slist_foreach (languages, (GFunc) g_free, NULL);
 			g_slist_free (languages);
-			g_object_unref (client);
 		} else {
 			g_printerr (_("Error in language %s activation: %s\n"), lang, err->message);
 			g_error_free (err);
@@ -109,18 +100,18 @@
 }
 
 static void
-gconf_enabled_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, GtkToggleButton *enabled_spellcheck)
+settings_enabled_changed (GSettings *settings, const gchar *key, GtkToggleButton *enabled_spellcheck)
 {
 	gboolean enabled;
 
 	g_signal_handlers_block_by_func (enabled_spellcheck, "toggled", enabled_changed);
-	enabled = gconf_client_get_bool (client, "/apps/xchat/spellcheck/enabled", NULL);
+	enabled = g_settings_get_boolean (gui.settings_spellcheck, "enabled");
 	gtk_toggle_button_set_active (enabled_spellcheck, enabled);
 	g_signal_handlers_unblock_by_func (enabled_spellcheck, "toggled", enabled_changed);
 }
 
 static void
-gconf_languages_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry, GtkListStore *store)
+settings_languages_changed (GSettings *settings, const gchar *key, GtkListStore *store)
 {
 	GtkTreeIter iter;
 	gchar *lang;
@@ -133,7 +124,7 @@
 	 * FIXME: This suck because it should be done in text-entry.c
 	 * see FIXME in that file for information about this problem.
 	 * */
-	new_languages = gconf_client_get_list (client, "/apps/xchat/spellcheck/languages", GCONF_VALUE_STRING, NULL);
+	new_languages = xchat_settings_get_list (gui.settings_spellcheck, "languages");
 
 	if (new_languages != NULL) {
 		sexy_spell_entry_set_active_languages (SEXY_SPELL_ENTRY (gui.text_entry), new_languages, &err);
@@ -145,8 +136,7 @@
 
 		old_languages = sexy_spell_entry_get_active_languages (SEXY_SPELL_ENTRY (gui.text_entry));
 		if (old_languages != NULL) {
-			gconf_client_set_list (client, "/apps/xchat/spellcheck/languages",
-			                       GCONF_VALUE_STRING, old_languages, NULL);
+			xchat_settings_set_list (gui.settings_spellcheck, "languages", old_languages);
 			g_slist_foreach (old_languages, (GFunc) g_free, NULL);
 			g_slist_free (old_languages);
 		}
@@ -232,8 +222,8 @@
 	g_signal_connect (G_OBJECT (page->enable_spellcheck),   "toggled", G_CALLBACK (enabled_changed), page);
 	g_signal_connect (G_OBJECT (page->activated_renderer),  "toggled", G_CALLBACK (language_changed),page);
 
-	page->nh[0] = gconf_client_notify_add (p->gconf, "/apps/xchat/spellcheck/enabled", (GConfClientNotifyFunc) gconf_enabled_changed, page->enable_spellcheck, NULL, NULL);
-	page->nh[1] = gconf_client_notify_add (p->gconf, "/apps/xchat/spellcheck/languages", (GConfClientNotifyFunc) gconf_languages_changed, page->spellcheck_store, NULL, NULL);
+	page->sh[0] = g_signal_connect (G_OBJECT (gui.settings_spellcheck), "changed::enabled", G_CALLBACK (settings_enabled_changed), page->enable_spellcheck);
+	page->sh[1] = g_signal_connect (G_OBJECT (gui.settings_spellcheck), "changed::languages", G_CALLBACK (settings_languages_changed), page->spellcheck_store);
 
 	/* Populate the model */
 	for (l = languages; l != NULL; l = l->next) {
@@ -260,7 +250,7 @@
 	}
 	g_slist_free (languages);
 
-	enabled = gconf_client_get_bool (p->gconf, "/apps/xchat/spellcheck/enabled", NULL);
+	enabled = g_settings_get_boolean (gui.settings_spellcheck, "enabled");
 	gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (page->enable_spellcheck), enabled);
 	gtk_widget_set_sensitive (page->spellcheck_list, enabled);
 
@@ -290,13 +280,10 @@
 {
 	PreferencesPageSpellcheck *page = (PreferencesPageSpellcheck *) object;
 	gint i;
-	GConfClient *client;
 
-	client = gconf_client_get_default ();
 	for (i = 0; i < 2; i++) {
-		gconf_client_notify_remove (client, page->nh[i]);
+		g_signal_handler_disconnect (gui.settings_spellcheck, page->sh[i]);
 	}
-	g_object_unref (client);
 
 	G_OBJECT_CLASS (preferences_page_spellcheck_parent_class)->finalize (object);
 }
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-spellcheck.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences-page-spellcheck.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences-page-spellcheck.h	2014-11-12 18:57:53.804332827 -0500
@@ -46,8 +46,9 @@
 	GtkListStore *spellcheck_store;
 	GtkTreeViewColumn *spellcheck_column;
 
-	/* gconf notification handlers */
-	guint nh[2];
+
+	/* gsettings signal handlers */
+	guint sh[2];
 };
 
 struct _PreferencesPageSpellcheckClass
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/preferences.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/preferences.c	2014-11-12 18:57:53.804332827 -0500
@@ -22,7 +22,6 @@
 #include <config.h>
 #include <glib/gi18n.h>
 #include <string.h>
-#include <gconf/gconf-client.h>
 #include "preferences.h"
 #include "palette.h"
 #include "../common/xchat.h"
@@ -30,40 +29,32 @@
 #include "../common/util.h"
 #include "gui.h"
 
-static void nickname_changed           (GConfClient *client, guint cnxn_id,
-                                        GConfEntry *entry, gpointer data);
-static void showcolors_changed         (GConfClient *client, guint cnxn_id,
-                                        GConfEntry *entry, gpointer data);
-static void colorize_nicknames_changed (GConfClient *client, guint cnxn_id,
-                                        GConfEntry *entry, gpointer data);
-static void colors_changed             (GConfClient *client, guint cnxn_id,
-                                        GConfEntry *entry, gpointer data);
+typedef void (*PreferenceChangedFunc) (GSettings *settings, const gchar *key, gpointer preference);
+
+static void nickname_changed           (GSettings *settings, const gchar *key, gpointer data);
+static void showcolors_changed         (GSettings *settings, const gchar *key, gpointer data);
+static void colorize_nicknames_changed (GSettings *settings, const gchar *key, gpointer data);
+static void colors_changed             (GSettings *settings, const gchar *key, gpointer data);
 
 gboolean
 preferences_exist (void)
 {
-	GConfClient *client;
-	char *text;
-
-	client = gconf_client_get_default ();
+	gchar *text;
 
-	text = gconf_client_get_string (client, "/apps/xchat/version", NULL);
-	if (text == NULL) {
-		return FALSE;
-	} else {
+	text = g_settings_get_string (gui.settings, "version");
+	if (*text == '\0') {
 		g_free (text);
+		return FALSE;
 	}
 
-	g_object_unref (client);
-
+	g_free (text);
 	return TRUE;
 }
 
 static void
-string_preference_changed (GConfClient *client, guint cnxn_id,
-                           GConfEntry *entry, gpointer user_data)
+string_preference_changed (GSettings *settings, const gchar *key, gpointer user_data)
 {
-	gchar *text = gconf_client_get_string (client, entry->key, NULL);
+	gchar *text = g_settings_get_string (settings, key);
 	if (text) {
 		strcpy (user_data, text);
 		g_free (text);
@@ -71,45 +62,36 @@
 }
 
 /*
- * This goes through the mechanics of hooking up a gconf notify for
+ * This goes through the mechanics of hooking up a gsettings signal for
  * the given key, and also calls the callback once to populate the
  * initial value.
  */
-static void hook_preference (GConfClient *client, GConfEntry entry, gchar *path,
-			     GConfClientNotifyFunc callback, gpointer preference)
+static void hook_preference (GSettings *settings, const gchar *key, PreferenceChangedFunc callback, gpointer preference)
 {
-	entry.key = path;
-	callback (client, 0, &entry, preference);
-	gconf_client_notify_add (client, entry.key, callback,
-	                         preference, NULL, NULL);
+	gchar *name;
+
+	callback (settings, key, preference);
+
+	name = g_strdup_printf ("changed::%s", key);
+	g_signal_connect (settings, name, G_CALLBACK (callback), preference);
+
+	g_free (name);
+
 }
 
 void
 load_preferences (void)
 {
 	gchar *ddir;
-	GConfClient *client = gconf_client_get_default ();
-	GConfEntry entry;
-
-	gconf_client_notify_add (client, "/apps/xchat/irc/nickname",
-	                         nickname_changed, NULL, NULL, NULL);
-
-	hook_preference(client, entry, "/apps/xchat/irc/realname",
-	                string_preference_changed, prefs.realname);
-	hook_preference(client, entry, "/apps/xchat/irc/awaymsg",
-	                string_preference_changed, prefs.awayreason);
-	hook_preference(client, entry, "/apps/xchat/irc/quitmsg",
-	                string_preference_changed, prefs.quitreason);
-	hook_preference(client, entry, "/apps/xchat/irc/partmsg",
-	                string_preference_changed, prefs.partreason);
-	hook_preference(client, entry, "/apps/xchat/irc/showcolors",
-	                showcolors_changed, NULL);
-	hook_preference(client, entry, "/apps/xchat/irc/colorize_nicknames",
-			colorize_nicknames_changed, NULL);
-	hook_preference(client, entry, "/apps/xchat/irc/color_scheme",
-	                colors_changed, NULL);
 
-	g_object_unref (client);
+	hook_preference(gui.settings_irc, "nickname", nickname_changed, NULL);
+	hook_preference(gui.settings_irc, "realname", string_preference_changed, prefs.realname);
+	hook_preference(gui.settings_irc, "awaymsg", string_preference_changed, prefs.awayreason);
+	hook_preference(gui.settings_irc, "quitmsg", string_preference_changed, prefs.quitreason);
+	hook_preference(gui.settings_irc, "partmsg", string_preference_changed, prefs.partreason);
+	hook_preference(gui.settings_irc, "showcolors", showcolors_changed, NULL);
+	hook_preference(gui.settings_irc, "colorize-nicknames",	colorize_nicknames_changed, NULL);
+	hook_preference(gui.settings_irc, "color-scheme", colors_changed, NULL);
 
 	ddir = get_save_directory ();
 	g_utf8_strncpy (prefs.dccdir, ddir, sizeof (prefs.dccdir));
@@ -118,10 +100,7 @@
 
 void set_version (void)
 {
-	GConfClient *client = gconf_client_get_default ();
-	gconf_client_set_string (client, "/apps/xchat/version",
-	                         PACKAGE_VERSION, NULL);
-	g_object_unref (client);
+	g_settings_set_string (gui.settings, "version", PACKAGE_VERSION);
 }
 
 void
@@ -144,35 +123,29 @@
 }
 
 static void
-nickname_changed (GConfClient *client, guint cnxn_id,
-                  GConfEntry *entry, gpointer data)
+nickname_changed (GSettings *settings, const gchar *key, gpointer data)
 {
-	gchar *text = gconf_client_get_string (client, entry->key, NULL);
+	gchar *text = g_settings_get_string (settings, "nickname");
 	set_nickname (text);
 	g_free (text);
 }
 
 static void
-showcolors_changed (GConfClient *client, guint cnxn_id,
-                    GConfEntry *entry, gpointer data)
+showcolors_changed (GSettings *settings, const gchar *key, gpointer data)
 {
-	prefs.stripcolor = (unsigned int)
-		(!gconf_client_get_bool (client, entry->key, NULL));
+	prefs.stripcolor = (unsigned int) (!g_settings_get_boolean (settings, key));
 }
 
 static void
-colorize_nicknames_changed (GConfClient *client, guint cnxn_id,
-			    GConfEntry *entry, gpointer data)
+colorize_nicknames_changed (GSettings *settings, const gchar *key, gpointer data)
 {
-	prefs.colorednicks = (unsigned int)
-		gconf_client_get_bool (client, entry->key, NULL);
+	prefs.colorednicks = (unsigned int) g_settings_get_boolean (settings, key);
 }
 
 static void
-colors_changed (GConfClient *client, guint cnxn_id,
-                GConfEntry *entry, gpointer data)
+colors_changed (GSettings *settings, const gchar *key, gpointer data)
 {
-	gint color_scheme = gconf_client_get_int (client, entry->key, NULL);
+	gint color_scheme = g_settings_get_int (settings, key);
 	load_colors (color_scheme);
 	load_palette (color_scheme);
 	gtk_widget_queue_draw (gui.conversation_panel);
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/setup-dialog.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/setup-dialog.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/setup-dialog.c	2014-11-12 18:57:53.804332827 -0500
@@ -21,9 +21,9 @@
 
 #include <config.h>
 #include <glib/gi18n.h>
-#include <gconf/gconf-client.h>
 #include <gtk/gtk.h>
 #include <string.h>
+#include "gui.h"
 #include "setup-dialog.h"
 #include "util.h"
 #include "preferences.h"
@@ -80,14 +80,10 @@
 	const gchar *nick = gtk_entry_get_text (GTK_ENTRY (nick_entry));
 	const gchar *real = gtk_entry_get_text (GTK_ENTRY (real_entry));
 
-	GConfClient *client = gconf_client_get_default ();
+	g_settings_set_string (gui.settings_irc, "nickname", nick);
+	g_settings_set_string (gui.settings_irc, "realname", real);
 
-	gconf_client_set_string (client, "/apps/xchat/irc/nickname", nick, NULL);
-	gconf_client_set_string (client, "/apps/xchat/irc/realname", real, NULL);
-
-	gconf_client_set_string (client, "/apps/xchat/version", PACKAGE_VERSION, NULL);
-
-	g_object_unref (client);
+	set_version();
 
 	/*
 	 * We set the alternative nicknames here, so that people editing the
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/text-entry.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/text-entry.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/text-entry.c	2014-11-12 18:57:53.804332827 -0500
@@ -22,13 +22,13 @@
 #include <string.h>
 #include <gtk/gtk.h>
 #include <gdk/gdkkeysyms.h>
-#include <gconf/gconf-client.h>
 #include "conversation-panel.h"
 #include "gui.h"
 #include "palette.h"
 #include "text-entry.h"
 #include "userlist.h"
 #include "sexy-spell-entry.h"
+#include "util.h"
 #include "../common/outbound.h"
 #include "../common/xchatc.h"
 
@@ -41,9 +41,8 @@
 static gboolean   text_entry_spell_check       (TextEntry      *entry,
                                                 gchar          *text,
                                                 gpointer        data);
-static void       enable_spellcheck_changed    (GConfClient    *client,
-		                                guint           cnxn_id,
-					        GConfEntry     *gconf_entry,
+static void       enable_spellcheck_changed    (GSettings      *settings,
+					        const gchar    *key,
 					        TextEntry      *entry);
 static void       text_entry_activate          (GtkWidget      *widget,
                                                 gpointer        data);
@@ -104,9 +103,8 @@
 {
 	GList *items = NULL;
 	int i;
-	GConfClient *client;
 	gboolean enable_spellcheck;
-	GSList *languages;
+	GSList *languages = NULL;
 	GError *err  = NULL;
 	GList *real_command_list;
 
@@ -130,10 +128,9 @@
 	g_list_free (items);
 
 	/* Setup spellchecking */
-	client = gconf_client_get_default ();
 
-	enable_spellcheck = gconf_client_get_bool (client, "/apps/xchat/spellcheck/enabled", NULL);
-	languages = gconf_client_get_list (client, "/apps/xchat/spellcheck/languages", GCONF_VALUE_STRING, NULL);
+	enable_spellcheck = g_settings_get_boolean (gui.settings_spellcheck, "enabled");
+	languages = xchat_settings_get_list (gui.settings_spellcheck, "languages");
 
 	if (languages != NULL) {
 		sexy_spell_entry_set_active_languages (SEXY_SPELL_ENTRY (entry), languages, &err);
@@ -147,10 +144,9 @@
 		g_slist_free (languages);
 	} else {
 		if (enable_spellcheck) {
-			/* We use libsexy default languages and set it in gconf */
+			/* We use libsexy default languages and set it in gsettings */
 			languages = sexy_spell_entry_get_active_languages (SEXY_SPELL_ENTRY (entry));
-			gconf_client_set_list (client, "/apps/xchat/spellcheck/languages",
-					       GCONF_VALUE_STRING, languages, NULL);
+			xchat_settings_set_list (gui.settings_spellcheck, "languages", languages);
 
 			g_slist_foreach (languages, (GFunc) g_free, NULL);
 			g_slist_free (languages);
@@ -159,10 +155,7 @@
 
 	sexy_spell_entry_set_checked (SEXY_SPELL_ENTRY (entry), enable_spellcheck);
 
-	gconf_client_notify_add (client, "/apps/xchat/spellcheck/enabled",
-	                         (GConfClientNotifyFunc) enable_spellcheck_changed, entry, NULL, NULL);
-
-	g_object_unref (client);
+	g_signal_connect (G_OBJECT (gui.settings_spellcheck), "changed::enabled", G_CALLBACK (enable_spellcheck_changed), entry);
 
 	/* Save the current input for each session */
 	entry->priv->current_text = g_hash_table_new (NULL, NULL);
@@ -701,12 +694,12 @@
 }
 
 static void
-enable_spellcheck_changed (GConfClient *client, guint cnxn_id, GConfEntry *gconf_entry, TextEntry *entry)
+enable_spellcheck_changed (GSettings *settings, const gchar *key, TextEntry *entry)
 {
 	GSList *langs;
 	gboolean enabled;
 
-	enabled = gconf_value_get_bool (gconf_entry->value);
+	enabled = g_settings_get_boolean (gui.settings_spellcheck, "enabled");
 	sexy_spell_entry_set_checked (SEXY_SPELL_ENTRY (entry), enabled);
 
 	if (enabled) {
@@ -715,8 +708,7 @@
 			/* No langs activated: we use the defaults */
 			sexy_spell_entry_activate_default_languages (SEXY_SPELL_ENTRY (entry));
 			langs = sexy_spell_entry_get_active_languages (SEXY_SPELL_ENTRY (entry));
-			gconf_client_set_list (client, "/apps/xchat/spellcheck/languages",
-					       GCONF_VALUE_STRING, langs, NULL);
+			xchat_settings_set_list (gui.settings_spellcheck, "languages", langs);
 		}
 
 		g_slist_foreach (langs, (GFunc) g_free, NULL);
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/util.c
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/util.c	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/util.c	2014-11-12 18:57:53.804332827 -0500
@@ -160,3 +160,58 @@
 	}
 	return NULL;
 }
+
+/* Code taken from gedit (gedit/gedit-settings.c) */
+GSList *
+xchat_settings_get_list (GSettings   *settings,
+			 const gchar *key)
+{
+	GSList *list = NULL;
+	gchar **values;
+	gsize i;
+
+	g_return_val_if_fail (G_IS_SETTINGS (settings), NULL);
+	g_return_val_if_fail (key != NULL, NULL);
+
+	values = g_settings_get_strv (settings, key);
+	i = 0;
+
+	while (values[i] != NULL)
+	{
+		list = g_slist_prepend (list, values[i]);
+		i++;
+	}
+
+	g_free (values);
+
+	return g_slist_reverse (list);
+}
+
+void
+xchat_settings_set_list (GSettings    *settings,
+			 const gchar  *key,
+			 const GSList *list)
+{
+	gchar **values = NULL;
+	const GSList *l;
+
+	g_return_if_fail (G_IS_SETTINGS (settings));
+	g_return_if_fail (key != NULL);
+
+	if (list != NULL)
+	{
+		gint i, len;
+
+		len = g_slist_length ((GSList *)list);
+		values = g_new (gchar *, len + 1);
+
+		for (l = list, i = 0; l != NULL; l = g_slist_next (l), i++)
+		{
+			values[i] = l->data;
+		}
+		values[i] = NULL;
+	}
+
+	g_settings_set_strv (settings, key, (const gchar * const *)values);
+	g_free (values);
+}
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/util.h
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/util.h	2014-11-12 18:57:53.808332855 -0500
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/util.h	2014-11-12 18:57:53.804332827 -0500
@@ -52,4 +52,10 @@
 
 server *find_connected_server (ircnet *network);
 
+GSList *xchat_settings_get_list	(GSettings     *settings,
+                                 const gchar   *key);
+
+void xchat_settings_set_list (GSettings     *settings,
+                              const gchar   *key,
+                              const GSList  *list);
 #endif
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/notification/notification.schemas.in
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/notification/notification.schemas.in	2014-11-12 18:57:53.808332855 -0500
+++ /dev/null	1970-01-01 00:00:00.000000000 +0000
@@ -1,19 +0,0 @@
-<gconfschemafile>
-	<schemalist>
-		<schema>
-			<key>/schemas/apps/xchat/plugins/notification/level</key>
-			<applyto>/apps/xchat/plugins/notification/level</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>3</default>
-			<locale name="C">
-				<short>Level of the messages that require a notification</short>
-				<long>Messages are classified according to their importance. 
-				Select level of messages above which the notification icon will be displayed.
-				Valid values are: "0" (always displayed), "1" (all messages including information),
-				"2" (all channel messages), "3" (only private or highlighted messages).
-				</long>
-			</locale>
-		</schema>
-	</schemalist>
-</gconfschemafile>
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/url_scraper/urlscraper.schemas.in
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/plugins/url_scraper/urlscraper.schemas.in	2014-11-12 18:57:53.808332855 -0500
+++ /dev/null	1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-<gconfschemafile>
-	<schemalist>
-
-		<schema>
-			<key>/schemas/apps/xchat/plugins/urlscraper/history</key>
-			<applyto>/apps/xchat/plugins/urlscraper/history</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>10</default>
-			<locale name="C">
-				<short>URL Scraper history length</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/plugins/urlscraper/timestamps</key>
-			<applyto>/apps/xchat/plugins/urlscraper/timestamps</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>URL Scraper show timestamps</short>
-			</locale>
-		</schema>
-
-	</schemalist>
-</gconfschemafile>
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/apps_xchat.schemas.in
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/fe-gnome/apps_xchat.schemas.in	2014-11-12 18:57:53.808332855 -0500
+++ /dev/null	1970-01-01 00:00:00.000000000 +0000
@@ -1,362 +0,0 @@
-<gconfschemafile>
-	<schemalist>
-
-		<!-- xchat-gnome config version -->
-		<schema>
-			<key>/schemas/apps/xchat/version</key>
-			<applyto>/apps/xchat/version</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<locale name="C">
-				<short>xchat configuration version</short>
-			</locale>
-		</schema>
-
-		<!-- nickname -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/nickname</key>
-			<applyto>/apps/xchat/irc/nickname</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default></default>
-			<locale name="C">
-				<short>Default nickname used by servers without special options set</short>
-			</locale>
-		</schema>
-
-		<!-- real name -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/realname</key>
-			<applyto>/apps/xchat/irc/realname</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default></default>
-			<locale name="C">
-				<short>Default real name used by servers without special options set</short>
-			</locale>
-		</schema>
-
-		<!-- quit message -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/quitmsg</key>
-			<applyto>/apps/xchat/irc/quitmsg</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default>Ex-Chat</default>
-			<locale name="C">
-				<short>Message sent on quit</short>
-			</locale>
-		</schema>
-
-		<!-- part message -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/partmsg</key>
-			<applyto>/apps/xchat/irc/partmsg</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default>Ex-Chat</default>
-			<locale name="C">
-				<short>Message sent on channel part</short>
-			</locale>
-		</schema>
-
-		<!-- away message -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/awaymsg</key>
-			<applyto>/apps/xchat/irc/awaymsg</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default>Away</default>
-			<locale name="C">
-				<short>Message sent on away</short>
-			</locale>
-		</schema>
-
-		<!-- show colors -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/showcolors</key>
-			<applyto>/apps/xchat/irc/showcolors</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>Show colors in the main window</short>
-			</locale>
-		</schema>
-
-		<!-- colorize nicknames -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/colorize_nicknames</key>
-			<applyto>/apps/xchat/irc/colorize_nicknames</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>false</default>
-			<locale name="C">
-				<short>Colorize nicknames in the main window</short>
-			</locale>
-		</schema>
-
-		<!-- show timestamps -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/showtimestamps</key>
-			<applyto>/apps/xchat/irc/showtimestamps</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>Show timestamps in the main window</short>
-			</locale>
-		</schema>
-
-		<!-- colors -->
-		<schema>
-			<key>/schemas/apps/xchat/irc/color_scheme</key>
-			<applyto>/apps/xchat/irc/color_scheme</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>3</default>
-			<locale name="C">
-				<short>Selected color scheme</short>
-			</locale>
-		</schema>
-
-		<!-- background -->
-		<schema>
-			<key>/schemas/apps/xchat/main_window/background_type</key>
-			<applyto>/apps/xchat/main_window/background_type</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>0</default>
-			<locale name="C">
-				<short>Selected background type</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/background_image</key>
-			<applyto>/apps/xchat/main_window/background_image</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default></default>
-			<locale name="C">
-				<short>Background image filename</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/background_transparency</key>
-			<applyto>/apps/xchat/main_window/background_transparency</applyto>
-			<owner>xchat</owner>
-			<type>float</type>
-			<default>0.5</default>
-			<locale name="C">
-				<short>Background transparency</short>
-			</locale>
-		</schema>
-
-		<!-- fonts -->
-		<schema>
-			<key>/schemas/apps/xchat/main_window/use_sys_fonts</key>
-			<applyto>/apps/xchat/main_window/use_sys_fonts</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>Use system fonts</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/font</key>
-			<applyto>/apps/xchat/main_window/font</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default>Bitstream Vera Sans Mono 10</default>
-			<locale name="C">
-				<short>Font for the main window</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/width</key>
-			<applyto>/apps/xchat/main_window/width</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>800</default>
-			<locale name="C">
-				<short>Width of the main window</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/height</key>
-			<applyto>/apps/xchat/main_window/height</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>600</default>
-			<locale name="C">
-				<short>Height of the main window</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/maximized</key>
-			<applyto>/apps/xchat/main_window/maximized</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>false</default>
-			<locale name="C">
-				<short>Whether the main window is maximized</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/x</key>
-			<applyto>/apps/xchat/main_window/x</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>0</default>
-			<locale name="C">
-				<short>X position of the main window on the screen</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/y</key>
-			<applyto>/apps/xchat/main_window/y</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>0</default>
-			<locale name="C">
-				<short>Y position of the main window on the screen</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/show_hpane</key>
-			<applyto>/apps/xchat/main_window/show_hpane</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>Whether the horizontal pane in the main window is shown</short>
-			</locale>
-		</schema>
-
-                <schema>
-                        <key>/schemas/apps/xchat/main_window/show_statusbar</key>
-                        <applyto>/apps/xchat/main_window/show_statusbar</applyto>
-                        <owner>xchat</owner>
-                        <type>bool</type>
-                        <default>true</default>
-                        <locale name="C">
-                                <short>Whether the statusbar in the main window is shown</short>
-                        </locale>
-                </schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/hpane</key>
-			<applyto>/apps/xchat/main_window/hpane</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>0</default>
-			<locale name="C">
-				<short>Position of the horizontal pane in the main window</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/redundant_nickstamps</key>
-			<applyto>/apps/xchat/main_window/redundant_nickstamps</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>false</default>
-			<locale name="C">
-				<short>Display redundant nickstamps</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/main_window/userlist_in_main_window</key>
-			<applyto>/apps/xchat/main_window/userlist_in_main_window</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>false</default>
-			<locale name="C">
-				<short>Show user list in main window</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/channel_list/width</key>
-			<applyto>/apps/xchat/channel_list/width</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>640</default>
-			<locale name="C">
-				<short>Width of the channel list</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/channel_list/height</key>
-			<applyto>/apps/xchat/channel_list/height</applyto>
-			<owner>xchat</owner>
-			<type>int</type>
-			<default>480</default>
-			<locale name="C">
-				<short>Height of the channel list</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/channel_list/auto_popup</key>
-			<applyto>/apps/xchat/channel_list/auto_popup</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>Automatically display the channel list dialog</short>
-				<long>If set to true, when you join a server without automatically
-				joining a channel, the channel list dialog will be displayed</long>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/apps/xchat/plugins/loaded</key>
-			<applyto>/apps/xchat/plugins/loaded</applyto>
-			<owner>xchat</owner>
-			<type>list</type>
-			<list_type>string</list_type>
-			<default>[]</default>
-			<locale name="C">
-				<short>List of enabled plugins</short>
-			</locale>
-		</schema>
-
-		<!-- spellchecking enabled -->
-		<schema>
-			<key>/schemas/apps/xchat/spellcheck/enabled</key>
-			<applyto>/apps/xchat/spellcheck/enabled</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>Enable spellchecking</short>
-			</locale>
-		</schema>
-
-		<!-- languages for spellchecking -->
-		<schema>
-			<key>/schemas/apps/xchat/spellcheck/languages</key>
-			<applyto>/apps/xchat/spellcheck/languages</applyto>
-			<owner>xchat</owner>
-			<type>list</type>
-			<list_type>string</list_type>
-			<default>[]</default>
-			<locale name="C">
-				<short>Languages to use for spellchecking</short>
-			</locale>
-		</schema>
-	</schemalist>
-</gconfschemafile>
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/notification/org.gnome.Xchat.notification.gschema.xml
===================================================================
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/notification/org.gnome.Xchat.notification.gschema.xml	2014-11-12 18:57:53.804332827 -0500
@@ -0,0 +1,8 @@
+<schemalist>
+  <schema id="org.gnome.Xchat.plugins.notification" path="/org/gnome/Xchat/plugins/notification/">
+    <key name="level" type="i">
+      <default>3</default>
+      <summary>Level of the messages that require a notification</summary>
+    </key>
+  </schema>
+</schemalist>
Index: xchat-gnome-0.30.0~git20141005.816798/plugins/url_scraper/org.gnome.Xchat.urlscraper.gschema.xml
===================================================================
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ xchat-gnome-0.30.0~git20141005.816798/plugins/url_scraper/org.gnome.Xchat.urlscraper.gschema.xml	2014-11-12 18:57:53.804332827 -0500
@@ -0,0 +1,12 @@
+<schemalist>
+  <schema id="org.gnome.Xchat.plugins.urlscraper" path="/org/gnome/Xchat/plugins/urlscraper/">
+    <key name="history" type="i">
+      <default>10</default>
+      <summary>URL Scraper history length</summary>
+    </key>
+    <key name="timestamps" type="b">
+      <default>true</default>
+      <summary>URL Scraper show timestamps</summary>
+    </key>
+  </schema>
+</schemalist>
Index: xchat-gnome-0.30.0~git20141005.816798/src/common/dbus/url_handler.schemas.in
===================================================================
--- xchat-gnome-0.30.0~git20141005.816798.orig/src/common/dbus/url_handler.schemas.in	2014-11-12 18:57:53.808332855 -0500
+++ /dev/null	1970-01-01 00:00:00.000000000 +0000
@@ -1,37 +0,0 @@
-<gconfschemafile>
-	<schemalist>
-		<schema>
-			<key>/schemas/desktop/gnome/url-handlers/irc/command</key>
-			<applyto>/desktop/gnome/url-handlers/irc/command</applyto>
-			<owner>xchat</owner>
-			<type>string</type>
-			<default>xchat-gnome --existing --url=%s</default>
-			<locale name="C">
-				<short>The handler for "irc://" URLs</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/desktop/gnome/url-handlers/irc/enabled</key>
-			<applyto>/desktop/gnome/url-handlers/irc/enabled</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>true</default>
-			<locale name="C">
-				<short>Set it at TRUE if you want it activated</short>
-			</locale>
-		</schema>
-
-		<schema>
-			<key>/schemas/desktop/gnome/url-handlers/irc/needs_terminal</key>
-			<applyto>/desktop/gnome/url-handlers/irc/needs_terminal</applyto>
-			<owner>xchat</owner>
-			<type>bool</type>
-			<default>false</default>
-			<locale name="C">
-				<short>Run XChat-GNOME in a terminal?</short>
-			</locale>
-		</schema>
-
-	</schemalist>
-</gconfschemafile>
Index: xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/org.gnome.Xchat.convert
===================================================================
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ xchat-gnome-0.30.0~git20141005.816798/src/fe-gnome/org.gnome.Xchat.convert	2014-11-12 18:57:53.804332827 -0500
@@ -0,0 +1,50 @@
+[org.gnome.Xchat]
+version = /apps/xchat/version
+
+[org.gnome.Xchat.irc]
+nickname = /apps/xchat/irc/nickname
+realname = /apps/xchat/irc/realname
+quitmsg = /apps/xchat/irc/quitmsg
+partmsg = /apps/xchat/irc/partmsg
+awaymsg = /apps/xchat/irc/awaymsg
+showcolors = /apps/xchat/irc/showcolors
+colorize-nicknames = /apps/xchat/irc/colorize_nicknames
+showtimestamps = /apps/xchat/irc/showtimestamps
+color-scheme = /apps/xchat/irc/color_scheme
+
+[org.gnome.Xchat.main-window]
+background-type = /apps/xchat/main_window/background_type
+background-image = /apps/xchat/main_window/background_image
+background-transparency = /apps/xchat/main_window/background_transparency
+use-sys-fonts = /apps/xchat/main_window/use_sys_fonts
+font = /apps/xchat/main_window/font
+width = /apps/xchat/main_window/width
+height = /apps/xchat/main_window/height
+x = /apps/xchat/main_window/x
+y = /apps/xchat/main_window/y
+maximized = /apps/xchat/main_window/maximized
+show-hpane = /apps/xchat/main_window/show_hpane
+show-statusbar = /apps/xchat/main_window/show_statusbar
+hpane = /apps/xchat/main_window/hpane
+redundant-nickstamps = /apps/xchat/main_window/redundant_nickstamps
+userlist-in-main-window = /apps/xchat/main_window/userlist_in_main_window
+
+[org.gnome.Xchat.channel-list]
+width = /apps/xchat/channel_list/width
+height = /apps/xchat/channel_list/height
+auto-popup = /apps/xchat/channel_list/auto_popup
+
+[org.gnome.Xchat.plugins]
+loaded = /apps/xchat/plugins/loaded
+
+[org.gnome.Xchat.spellcheck]
+enabled = /apps/xchat/spellcheck/enabled
+languages = /apps/xchat/spellcheck/languages
+
+[org.gnome.Xchat.plugins.notification]
+level = /apps/xchat/plugins/notification/level
+
+[org.gnome.Xchat.plugins.urlscraper]
+history = /apps/xchat/plugins/urlscraper/history
+timestamps = /apps/xchat/plugins/urlscraper/timestamps
+
