i3
i3.h
Go to the documentation of this file.
1 /*
2  * vim:ts=4:sw=4:expandtab
3  *
4  * i3 - an improved dynamic tiling window manager
5  * © 2009 Michael Stapelberg and contributors (see also: LICENSE)
6  *
7  * i3.h: global variables that are used all over i3.
8  *
9  */
10 #pragma once
11 
12 #include <config.h>
13 
14 #include <sys/time.h>
15 #include <sys/resource.h>
16 
17 #include <xcb/shape.h>
18 #include <xcb/xcb_keysyms.h>
19 #include <xcb/xkb.h>
20 
21 #include <X11/XKBlib.h>
22 
23 #define SN_API_NOT_YET_FROZEN 1
24 #include <libsn/sn-launcher.h>
25 
26 #include "queue.h"
27 #include "data.h"
28 #include "xcb.h"
29 
31 extern const char *i3_version;
32 
36 extern struct rlimit original_rlimit_core;
38 extern bool debug_build;
40 extern int listen_fds;
41 extern int conn_screen;
42 extern xcb_atom_t wm_sn;
51 extern xcb_window_t ewmh_window;
55 extern xcb_timestamp_t last_timestamp;
56 extern SnDisplay *sndisplay;
57 extern xcb_key_symbols_t *keysyms;
58 extern char **start_argv;
59 extern Display *xlibdpy, *xkbdpy;
60 extern int xkb_current_group;
61 extern TAILQ_HEAD(bindings_head, Binding) *bindings;
62 extern const char *current_binding_mode;
63 extern TAILQ_HEAD(autostarts_head, Autostart) autostarts;
64 extern TAILQ_HEAD(autostarts_always_head, Autostart) autostarts_always;
65 extern TAILQ_HEAD(ws_assignments_head, Workspace_Assignment) ws_assignments;
66 extern TAILQ_HEAD(assignments_head, Assignment) assignments;
67 extern SLIST_HEAD(stack_wins_head, Stack_Window) stack_wins;
68 
69 /* Color depth, visual id and colormap to use when creating windows and
70  * pixmaps. Will use 32 bit depth and an appropriate visual, if available,
71  * otherwise the root window’s default (usually 24 bit TrueColor). */
72 extern uint8_t root_depth;
73 extern xcb_visualid_t visual_id;
74 extern xcb_colormap_t colormap;
75 
77 extern xcb_window_t root;
78 extern struct ev_loop *main_loop;
79 extern bool only_check_config;
80 extern bool force_xinerama;
struct autostarts_always_head autostarts_always
Definition: main.c:94
struct autostarts_head autostarts
Definition: main.c:91
struct assignments_head assignments
Definition: main.c:97
struct ws_assignments_head ws_assignments
Definition: main.c:101
struct bindings_head * bindings
Definition: main.c:87
xcb_timestamp_t last_timestamp
The last timestamp we got from X11 (timestamps are included in some events and are used for some thin...
Definition: main.c:64
xcb_atom_t wm_sn
Definition: main.c:70
const char * i3_version
Git commit identifier, from version.c.
Definition: version.c:13
Display * xkbdpy
Definition: i3.h:59
bool xkb_supported
Definition: main.c:104
int xkb_current_group
Definition: handlers.c:22
int conn_screen
Definition: main.c:56
xcb_colormap_t colormap
Definition: main.c:77
int listen_fds
The number of file descriptors passed via socket activation.
Definition: main.c:46
bool force_xinerama
Definition: main.c:107
xcb_key_symbols_t * keysyms
Definition: main.c:81
uint8_t root_depth
Definition: main.c:75
TAILQ_HEAD(bindings_head, Binding) *bindings
SLIST_HEAD(stack_wins_head, Stack_Window) stack_wins
SnDisplay * sndisplay
Definition: main.c:59
Display * xlibdpy
xcb_window_t root
Definition: main.c:67
struct rlimit original_rlimit_core
The original value of RLIMIT_CORE when i3 was started.
Definition: main.c:43
bool debug_build
Whether this version of i3 is a debug build or a release build.
xcb_window_t ewmh_window
The EWMH support window that is used to indicate that an EWMH-compliant window manager is present.
Definition: ewmh.c:14
const char * current_binding_mode
Definition: main.c:88
bool only_check_config
xcb_visualid_t visual_id
char ** start_argv
Definition: main.c:52
bool shape_supported
Definition: i3.h:76
struct ev_loop * main_loop
Definition: main.c:79
Stores which workspace (by name or number) goes to which output.
Definition: data.h:206
Holds a keybinding, consisting of a keycode combined with modifiers and the command which is executed...
Definition: data.h:276
Holds a command specified by either an:
Definition: data.h:339
An Assignment makes specific windows go to a specific workspace/output or run a command for that wind...
Definition: data.h:564