]> icculus.org git repositories - manmower/openbox.git/blob - openbox/config.c
start the config system, add the config file parser
[manmower/openbox.git] / openbox / config.c
1 #include "config.h"
2
3 #ifdef HAVE_STDIO_H
4 #  include <stdio.h>
5 #endif
6
7 static GSList *config = NULL;
8
9 /* provided by cparse.l */
10 void cparse_go(FILE *);
11
12
13 void config_startup()
14 {
15 }
16
17 void config_shutdown()
18 {
19 }
20
21 void config_parse()
22 {
23     FILE *file;
24     char *path;
25
26     path = g_build_filename(g_get_home_dir(), ".openbox", "rc3", NULL);
27     if ((file = fopen(path, "r")) != NULL) {
28         cparse_go(file);
29         fclose(file);
30     }
31 }
32
33 gboolean config_set(char *name, ConfigValueType type, ConfigValue value)
34 {
35     g_message("Setting %s\n", name);
36     return TRUE;
37 }