2010-08-26 00:02:35 +02:00
|
|
|
#ifndef CONFIG_H_
|
2010-11-04 12:27:10 +01:00
|
|
|
#define CONFIG_H_
|
|
|
|
|
|
|
|
#include "common.h"
|
2010-08-26 00:02:35 +02:00
|
|
|
|
2011-02-21 15:47:58 +01:00
|
|
|
typedef enum {
|
2011-10-21 20:59:25 +02:00
|
|
|
POS_NONE = 0,
|
|
|
|
POS_TOP,
|
|
|
|
POS_BOT
|
|
|
|
} position_t;
|
2011-02-21 15:47:58 +01:00
|
|
|
|
2010-08-26 00:02:35 +02:00
|
|
|
typedef struct config_t {
|
2010-11-04 12:27:10 +01:00
|
|
|
int hide_on_modifier;
|
2011-10-21 20:59:25 +02:00
|
|
|
position_t position;
|
2010-11-04 12:27:10 +01:00
|
|
|
int verbose;
|
2011-10-19 23:58:19 +02:00
|
|
|
struct xcb_color_strings_t colors;
|
2011-04-21 20:24:02 +02:00
|
|
|
int disable_ws;
|
2011-10-19 23:58:19 +02:00
|
|
|
char *bar_id;
|
|
|
|
char *command;
|
|
|
|
char *fontname;
|
2011-10-21 20:47:56 +02:00
|
|
|
char *tray_output;
|
2011-10-21 23:17:41 +02:00
|
|
|
int num_outputs;
|
|
|
|
char **outputs;
|
2010-08-26 00:02:35 +02:00
|
|
|
} config_t;
|
|
|
|
|
|
|
|
config_t config;
|
|
|
|
|
2011-10-19 23:58:19 +02:00
|
|
|
/**
|
|
|
|
* Start parsing the received bar configuration json-string
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
void parse_config_json(char *json);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* free()s the color strings as soon as they are not needed anymore.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
void free_colors(struct xcb_color_strings_t *colors);
|
|
|
|
|
2010-08-26 00:02:35 +02:00
|
|
|
#endif
|