Go to the documentation of this file.
16 #include <xkbcommon/xkbcommon.h>
20 struct modes_head
modes;
30 DLOG(
"Ungrabbing all keys\n");
31 xcb_ungrab_key(
conn, XCB_GRAB_ANY,
root, XCB_BUTTON_MASK_ANY);
101 TAILQ_REMOVE(&(barconfig->tray_outputs), tray_output, tray_outputs);
186 #define INIT_COLOR(x, cborder, cbackground, ctext, cindicator) \
188 x.border = draw_util_hex_to_color(cborder); \
189 x.background = draw_util_hex_to_color(cbackground); \
190 x.text = draw_util_hex_to_color(ctext); \
191 x.indicator = draw_util_hex_to_color(cindicator); \
192 x.child_border = draw_util_hex_to_color(cbackground); \
198 "#f7f7f7",
"#f5f5f5",
"#000000",
"#0a0a0a");
200 "#f7f7f7",
"#dcdcdc",
"#191919",
"#232323");
202 "#f7f7f7",
"#c4c4c4",
"#323232",
"#3b3b3b");
204 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
208 "#d06767",
"#bd2727",
"#ffffff",
"#27bdbd");
210 "#d06767",
"#971f1f",
"#e5e5e5",
"#1f9797");
212 "#d06767",
"#841b1b",
"#cccccc",
"#1b8484");
214 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
218 "#eebb67",
"#e79e27",
"#000000",
"#2770e7");
220 "#eebb67",
"#b87e1f",
"#191919",
"#1f59b8");
222 "#eebb67",
"#a16e1b",
"#323232",
"#1b4ea1");
224 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
228 "#eeec6f",
"#e7e532",
"#000000",
"#3234e7");
230 "#eeec6f",
"#b8b728",
"#191919",
"#2829b8");
232 "#eeec6f",
"#a1a023",
"#323232",
"#2324a1");
234 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
238 "#8be379",
"#5ad840",
"#000000",
"#be40d8");
240 "#8be379",
"#48ac33",
"#191919",
"#9833ac");
242 "#8be379",
"#3e972c",
"#323232",
"#852c97");
244 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
248 "#afafb4",
"#8e8e95",
"#ffffff",
"#95958e");
250 "#afafb4",
"#717177",
"#e5e5e5",
"#777771");
252 "#afafb4",
"#636368",
"#cccccc",
"#686863");
254 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
258 "#739de3",
"#3874d8",
"#ffffff",
"#d89c38");
260 "#739de3",
"#2c5cac",
"#e5e5e5",
"#ac7c2c");
262 "#739de3",
"#275197",
"#cccccc",
"#976d27");
264 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
268 "#bb73bb",
"#9f389f",
"#ffffff",
"#389f38");
270 "#bb73bb",
"#7f2c7f",
"#e5e5e5",
"#2c7f2c");
272 "#bb73bb",
"#6f276f",
"#cccccc",
"#276f27");
274 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
278 "#5b5b5b",
"#333333",
"#ffffff",
"#cccccc");
280 "#5b5b5b",
"#1e1e1e",
"#e5e5e5",
"#e1e1e1");
282 "#5b5b5b",
"#141414",
"#cccccc",
"#ebebeb");
284 "#bd2727",
"#e79e27",
"#333333",
"#27bdbd");
312 die(
"Unable to find the configuration file (looked at "
313 "$XDG_CONFIG_HOME/i3/config, ~/.i3/config, $XDG_CONFIG_DIRS/i3/config "
314 "and " SYSCONFDIR
"/i3/config)");
327 char resolved_path[PATH_MAX] = {
'\0'};
336 LOG(
"Parsing configfile %s\n", resolved_path);
348 die(
"Could not open configuration file: %s\n", strerror(errno));
355 ELOG(
"You did not specify required configuration option \"font\"\n");
369 if (current->
font != NULL) {
struct bindings_head * bindings
#define TAILQ_FIRST(head)
char * status_command
Command that should be run to get a statusline, for example 'i3status'.
char * restart_state_path
char * binding_mode_border
char * urgent_workspace_text
struct Colortriple focused_inactive
bool show_marks
Specifies whether or not marks should be displayed in the window decoration.
char * command
The command which is to be executed for this button.
struct includedfiles_head included_files
parse_file_result_t parse_file(struct parser_ctx *ctx, const char *f, IncludedFile *included_file)
Parses the given file by first replacing the variables, then calling parse_config and launching i3-na...
struct Colortriple unfocused
char * sstrdup(const char *str)
Safe-wrapper around strdup which exits if malloc returns NULL (meaning that there is no more memory a...
const char * current_binding_mode
char * current_configpath
void x_deco_recurse(Con *con)
Recursively calls x_draw_decoration.
The configuration file can contain multiple sets of bindings.
struct Colortriple unfocused
char * focused_background
struct ws_assignments_head ws_assignments
Holds the status bar configuration (i3bar).
void free_font(void)
Frees the resources taken by the current font.
char * focused_workspace_text
char * active_workspace_border
char * urgent_workspace_border
An Assignment makes specific windows go to a specific workspace/output or run a command for that wind...
char * inactive_workspace_bg
void free_variables(struct parser_ctx *ctx)
Releases the memory of all variables in ctx.
#define TAILQ_EMPTY(head)
#define SLIST_FIRST(head)
List entry struct for an included file.
struct deco_render_params * deco_render_params
Cache for the decoration rendering.
char * focused_statusline
int num_outputs
Number of outputs in the outputs array.
char * focused_workspace_bg
char * id
Automatically generated ID for this bar config.
focus_wrapping_t focus_wrapping
When focus wrapping is enabled (the default), attempting to move focus past the edge of the screen (i...
char * focused_workspace_border
#define TAILQ_INSERT_TAIL(head, elm, field)
struct Colortriple urgent
void * scalloc(size_t num, size_t size)
Safe-wrapper around calloc which exits if malloc returns NULL (meaning that there is no more memory a...
void translate_keysyms(void)
Translates keysymbols to keycodes for all bindings which use keysyms.
struct all_cons_head all_cons
void binding_free(Binding *bind)
Frees the binding.
#define SLIST_INSERT_HEAD(head, elm, field)
#define SLIST_REMOVE(head, elm, type, field)
char * font
Font specification for all text rendered on the bar.
char * active_workspace_text
#define TAILQ_HEAD_INITIALIZER(head)
border_style_t default_border
The default border style for new windows.
struct Colortriple focused
struct Barconfig::bar_colors colors
void match_free(Match *match)
Frees the given match.
char * inactive_workspace_border
static void free_configuration(void)
enum Assignment::@16 type
type of this assignment:
struct Colortriple urgent
struct Config::config_bar bar
char * active_workspace_bg
char * urgent_workspace_bg
Match match
the criteria to check if a window matches
struct Config::config_client client[QUBE_NUM_LABELS]
int default_floating_border_width
#define SLIST_EMPTY(head)
int logical_px(const int logical)
Convert a logical amount of pixels (e.g.
color_t draw_util_hex_to_color(const char *color)
Parses the given color in hex format to an internal color representation.
char * socket_path
Path to the i3 IPC socket.
struct bindings_head * bindings
struct Colortriple placeholder
char * pattern
The pattern/name used to load the font.
void regrab_all_buttons(xcb_connection_t *conn)
Release the button grabs on all managed windows and regrab them, reevaluating which buttons need to b...
char * i3bar_command
Command that should be run to execute i3bar, give a full path if i3bar is not in your $PATH.
#define INIT_COLOR(x, cborder, cbackground, ctext, cindicator)
union Assignment::@17 dest
destination workspace/command/output, depending on the type
void switch_mode(const char *new_mode)
Switches the key bindings to the given mode, if the mode exists.
char * fake_outputs
Overwrites output detection (for testing), see src/fake_outputs.c.
void extract_workspace_names_from_bindings(void)
Extracts workspace names from keybindings (e.g.
void ungrab_all_keys(xcb_connection_t *conn)
Ungrabs all keys, to be called before re-grabbing the keys because of a mapping_notify event or a con...
char * variable_replaced_contents
float workspace_urgency_timer
By default, urgency is cleared immediately when switching to another workspace leads to focusing the ...
int default_orientation
Default orientation for new containers.
struct assignments_head assignments
Assignment ** ran_assignments
Holds a keybinding, consisting of a keycode combined with modifiers and the command which is executed...
struct barconfig_head barconfigs
Defines a mouse command to be executed instead of the default behavior when clicking on the non-statu...
i3Font load_font(const char *pattern, const bool fallback)
Loads a font for usage, also getting its height.
bool load_configuration(const char *override_configpath, config_load_t load_type)
(Re-)loads the configuration file (sets useful defaults before).
char ** outputs
Outputs on which this bar should show up on.
void set_font(i3Font *font)
Defines the font to be used for the forthcoming calls.
void grab_all_keys(xcb_connection_t *conn)
Grab the bound keys (tell X to send us keypress events for those keycodes)
static xcb_cursor_context_t * ctx
xcb_connection_t * conn
XCB connection and root screen.
#define TAILQ_FOREACH(var, head, field)
Stores which workspace (by name or number) goes to which output.
border_style_t default_floating_border
The default border style for new floating windows.
Holds part of the configuration (the part which is not already in dedicated structures in include/dat...
enum Font::@21 type
The type of font.
A 'Con' represents everything from the X11 root window down to a single X11 window.
uint32_t nr_assignments
Pointers to the Assignments which were already ran for this Window (assignments run only once)
struct Colortriple focused
char * inactive_workspace_text
void reorder_bindings(void)
Reorders bindings by event_state_mask descendingly so that get_binding() correctly matches more speci...
char * get_config_path(const char *override_configpath, bool use_system_paths)
Get the path of the first configuration file found.
#define TAILQ_REMOVE(head, elm, field)