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 <sys/time.h>
13 #include <sys/resource.h>
14 
15 #include <xcb/xcb_keysyms.h>
16 #include <xcb/xkb.h>
17 
18 #include <X11/XKBlib.h>
19 
20 #define SN_API_NOT_YET_FROZEN 1
21 #include <libsn/sn-launcher.h>
22 
23 #include "queue.h"
24 #include "data.h"
25 #include "xcb.h"
26 
28 extern const char *i3_version;
29 
33 extern struct rlimit original_rlimit_core;
35 extern bool debug_build;
37 extern int listen_fds;
38 extern int conn_screen;
47 extern xcb_window_t ewmh_window;
51 extern xcb_timestamp_t last_timestamp;
52 extern SnDisplay *sndisplay;
53 extern xcb_key_symbols_t *keysyms;
54 extern char **start_argv;
55 extern Display *xlibdpy, *xkbdpy;
56 extern int xkb_current_group;
57 extern TAILQ_HEAD(bindings_head, Binding) * bindings;
58 extern TAILQ_HEAD(autostarts_head, Autostart) autostarts;
59 extern TAILQ_HEAD(autostarts_always_head, Autostart) autostarts_always;
60 extern TAILQ_HEAD(ws_assignments_head, Workspace_Assignment) ws_assignments;
61 extern TAILQ_HEAD(assignments_head, Assignment) assignments;
62 extern SLIST_HEAD(stack_wins_head, Stack_Window) stack_wins;
63 
64 /* Color depth, visual id and colormap to use when creating windows and
65  * pixmaps. Will use 32 bit depth and an appropriate visual, if available,
66  * otherwise the root window’s default (usually 24 bit TrueColor). */
67 extern uint8_t root_depth;
68 extern xcb_visualid_t visual_id;
69 extern xcb_colormap_t colormap;
70 
71 extern bool xcursor_supported, xkb_supported;
72 extern xcb_window_t root;
73 extern struct ev_loop *main_loop;
74 extern bool only_check_config;
#define SLIST_HEAD(name, type)
Definition: queue.h:93
Display * xkbdpy
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:53
An Assignment makes specific windows go to a specific workspace/output or run a command for that wind...
Definition: data.h:498
xcb_window_t root
Definition: main.c:56
int conn_screen
Definition: main.c:45
struct bindings_head * bindings
Definition: main.c:73
struct autostarts_always_head autostarts_always
Definition: main.c:79
uint8_t root_depth
Definition: main.c:61
Stores which workspace (by name or number) goes to which output.
Definition: data.h:191
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
int xkb_current_group
Definition: handlers.c:24
bool xkb_supported
Definition: main.c:90
struct assignments_head assignments
Definition: main.c:82
struct ws_assignments_head ws_assignments
Definition: main.c:86
#define TAILQ_HEAD(name, type)
Definition: queue.h:318
xcb_key_symbols_t * keysyms
Definition: main.c:67
int listen_fds
The number of file descriptors passed via socket activation.
Definition: main.c:33
bool xcursor_supported
Definition: main.c:89
struct ev_loop * main_loop
Definition: main.c:65
SnDisplay * sndisplay
Definition: main.c:48
bool only_check_config
struct autostarts_head autostarts
Definition: main.c:76
Display * xlibdpy
struct rlimit original_rlimit_core
The original value of RLIMIT_CORE when i3 was started.
Definition: main.c:30
xcb_visualid_t visual_id
char ** start_argv
Definition: main.c:41
xcb_colormap_t colormap
Definition: main.c:63
const char * i3_version
Git commit identifier, from version.c.
Definition: version.c:11
bool debug_build
Whether this version of i3 is a debug build or a release build.
Holds a command specified by either an:
Definition: data.h:313
Holds a keybinding, consisting of a keycode combined with modifiers and the command which is executed...
Definition: data.h:250