2
* Copyright (C) 1999 Craig Knudsen, cknudsen@cknudsen.com
4
* This program is free software; you can redistribute it and/or
5
* modify it under the terms of the GNU General Public License
6
* as published by the Free Software Foundation; either version 2
7
* of the License, or (at your option) any later version.
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
19
* Helps you keep track of time spent on different tasks.
22
* Craig Knudsen, cknudsen@cknudsen.com, http://www.cknudsen.com
25
* http://www.cknudsen.com/gtimer/
28
* 17-Apr-2005 Added configurability of the browser. (Russ Allbery)
30
* (Code stolen from another project/program I wrote.)
32
****************************************************************************/
38
/* config file parameters */
40
#define CONFIG_DEFAULT_FILE ".gtimerrc"
42
#define CONFIG_VERSION "version"
43
#define CONFIG_SORT "sort"
44
#define CONFIG_SORT_FORWARD "sort-dir"
45
#define CONFIG_PRINT "print"
46
#define CONFIG_IDLE "idle"
47
#define CONFIG_IDLE_ON "idle-on"
48
#define CONFIG_TOOLBAR_STATUS "toolbar-status"
49
#define CONFIG_AUTOSAVE "autosave"
50
#define CONFIG_ANIMATE "animate"
51
#define CONFIG_USE_PROJECTS "use-projects"
52
#define CONFIG_MAIN_WINDOW_WIDTH "win_width"
53
#define CONFIG_MAIN_WINDOW_HEIGHT "win_height"
54
#define CONFIG_MAIN_WINDOW_PROJECT_WIDTH "list_project_width"
55
#define CONFIG_MAIN_WINDOW_TASK_WIDTH "list_task_width"
56
#define CONFIG_MAIN_WINDOW_TODAY_WIDTH "list_today_width"
57
#define CONFIG_MAIN_WINDOW_TOTAL_WIDTH "list_total_width"
58
#define CONFIG_NEXT_VERSION_CHECK "next_version_check"
59
#define CONFIG_LAST_TIMED_TASKS "timed_tasks"
60
#define CONFIG_BROWSER "browser"
63
#ifdef CONFIG_DEFAULTS
64
static char *default_config[] = {
66
CONFIG_SORT_FORWARD, "1",
72
CONFIG_USE_PROJECTS, "1",
73
CONFIG_TOOLBAR_STATUS, "1",
74
CONFIG_MAIN_WINDOW_WIDTH, "500",
75
CONFIG_MAIN_WINDOW_HEIGHT, "400",
76
CONFIG_NEXT_VERSION_CHECK, "0",
78
/* rra 2005-07-15: Changed to sensible-browser for Debian. */
79
CONFIG_BROWSER, "sensible-browser",
84
int configReadAttributes (
89
int configGetAttribute (
91
char *attribute, char **value
94
int configGetAttributeInt (
96
char *attribute, int *value
99
int configSetAttribute (
101
char *attribute, char *value
104
int configSetAttributeInt (
106
char *attribute, int value
109
int configSaveAttributes (
114
int configModified ();
117
#endif /* _CONFIG_H */