Store sensor properties into $HOME/.psensor/psensor.cfg instead of using GConf
[psensor.git] / src / cfg.h
index f4392ef..d56f18b 100644 (file)
--- a/src/cfg.h
+++ b/src/cfg.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2010-2012 jeanfi@gmail.com
+ * Copyright (C) 2010-2014 jeanfi@gmail.com
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License as
@@ -25,7 +25,7 @@
 #include "color.h"
 
 enum temperature_unit {
-       CELCIUS,
+       CELSIUS,
        FAHRENHEIT
 };
 
@@ -109,9 +109,29 @@ void config_set_sensor_name(const char *, const char *);
 bool config_is_appindicator_enabled(const char *);
 void config_set_appindicator_enabled(const char *, bool);
 
+bool config_is_appindicator_label_enabled(const char *);
+void config_set_appindicator_label_enabled(const char *, bool);
+
 void config_slog_enabled_notify_add(GConfClientNotifyFunc cbk, void *data);
 bool is_slog_enabled();
 
 int config_get_slog_interval();
 
+int config_get_sensor_position(const char *);
+void config_set_sensor_position(const char *, int);
+
+char *config_get_notif_script();
+void config_set_notif_script(const char *);
+
+/*
+ * Returns the user directory containing psensor data (configuration
+ * and log).
+ * Corresponds to $HOME/.psensor/
+ * Creates the directory if it does not exist;
+ * Returns NULL if it cannot be determined.
+ */
+const char *get_psensor_user_dir();
+
+void config_sync();
+
 #endif