X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=i3bar%2Finclude%2Fconfig.h;h=4f6e8858f2f8798809fb17e3198d22e4f59cef56;hb=659e06a1709e6376c60ffd7b1401c471dce8a02e;hp=d6abb45c250e1254e3b8d16c488cea230f9ddc11;hpb=64f2a7561d885ab64905851626268d72051fe59f;p=i3%2Fi3 diff --git a/i3bar/include/config.h b/i3bar/include/config.h index d6abb45c..4f6e8858 100644 --- a/i3bar/include/config.h +++ b/i3bar/include/config.h @@ -1,21 +1,50 @@ +/* + * vim:ts=4:sw=4:expandtab + * + * i3bar - an xcb-based status- and ws-bar for i3 + * © 2010-2011 Axel Wagner and contributors (see also: LICENSE) + * + * config.c: Parses the configuration (received from i3). + * + */ #ifndef CONFIG_H_ #define CONFIG_H_ #include "common.h" typedef enum { - DOCKPOS_NONE = 0, - DOCKPOS_TOP, - DOCKPOS_BOT -} dockpos_t; + POS_NONE = 0, + POS_TOP, + POS_BOT +} position_t; typedef struct config_t { int hide_on_modifier; - dockpos_t dockpos; + int modifier; + position_t position; int verbose; - xcb_colors_t *colors; + struct xcb_color_strings_t colors; + int disable_ws; + char *bar_id; + char *command; + char *fontname; + char *tray_output; + int num_outputs; + char **outputs; } config_t; config_t config; +/** + * 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); + #endif