-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-
/*
- * (GLABELS) Label and Business Card Creation program for GNOME
- *
- * prefs-model.c: Application preferences model module
+ * prefs-model.h
+ * Copyright (C) 2001-2009 Jim Evins <evins@snaught.com>.
*
- * Copyright (C) 2001-2003 Jim Evins <evins@snaught.com>.
+ * This file is part of gLabels.
*
- * This program is free software; you can redistribute it and/or modify
+ * gLabels is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
+ * the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
- * This program is distributed in the hope that it will be useful,
+ * gLabels is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * along with gLabels. If not, see <http://www.gnu.org/licenses/>.
*/
+
#include <config.h>
#include "prefs-model.h"
-#include <libglabels/db.h>
-#include <libglabels/xml.h>
-#include <gtk/gtkpapersize.h>
+#include <glib.h>
+#include <gtk/gtk.h>
#include <string.h>
-#include <glib/gstrfuncs.h>
+#include <libglabels/libglabels.h>
#include "marshal.h"
#include "util.h"
#include "color.h"
#include "debug.h"
+
/*========================================================*/
/* Private macros and constants. */
/*========================================================*/
#define DEFAULT_FILL_COLOR GL_COLOR_A (0, 255, 0, 255)
+
/*========================================================*/
/* Private types. */
/*========================================================*/
};
-
/*========================================================*/
/* Private globals. */
/*========================================================*/
static guint signals[LAST_SIGNAL] = {0};
+
/*========================================================*/
/* Private function prototypes. */
/*========================================================*/
static const gchar *units_to_string (lglUnitsType units);
-\f
/*****************************************************************************/
/* Boilerplate object stuff. */
/*****************************************************************************/
G_DEFINE_TYPE (glPrefsModel, gl_prefs_model, G_TYPE_OBJECT);
+
static void
gl_prefs_model_class_init (glPrefsModelClass *class)
{
gl_debug (DEBUG_PREFS, "END");
}
+
static void
gl_prefs_model_init (glPrefsModel *prefs_model)
{
gl_debug (DEBUG_PREFS, "END");
}
+
static void
gl_prefs_model_finalize (GObject *object)
{
gl_debug (DEBUG_PREFS, "END");
}
+
/*****************************************************************************/
/* New prefs_model object. */
/*****************************************************************************/
}
-
/*****************************************************************************/
/* Save all settings. */
/*****************************************************************************/
gl_debug (DEBUG_PREFS, "END");
}
+
/*****************************************************************************/
/* Load all settings. */
/*****************************************************************************/
gl_debug (DEBUG_PREFS, "END");
}
+
/*---------------------------------------------------------------------------*/
/* PRIVATE. Key changed callback. */
/*---------------------------------------------------------------------------*/
gl_prefs_model_load_settings (prefs_model);
}
+
/*---------------------------------------------------------------------------*/
/* PRIVATE. Utilities to get values with defaults. */
/*---------------------------------------------------------------------------*/
}
}
+
static gboolean
get_bool (GConfClient *client,
const gchar *key,
}
}
+
static gint
get_int (GConfClient *client,
const gchar *key,
}
}
+
static gdouble
get_float (GConfClient *client,
const gchar *key,
}
}
+
/*---------------------------------------------------------------------------*/
/* PRIVATE. Utilities to deal with units. */
/*---------------------------------------------------------------------------*/
return units;
}
+
static const
gchar *units_to_string (lglUnitsType units)
{
}
+
+
+
+/*
+ * Local Variables: -- emacs
+ * mode: C -- emacs
+ * c-basic-offset: 8 -- emacs
+ * tab-width: 8 -- emacs
+ * indent-tabs-mode: nil -- emacs
+ * End: -- emacs
+ */