]> git.sur5r.net Git - i3/i3/blob - include/x.h
Handle saved_configpath in get_config_path, fix memleak in current_configpath handlin...
[i3/i3] / include / x.h
1 /*
2  * vim:ts=4:sw=4:expandtab
3  */
4
5 #ifndef _X_H
6 #define _X_H
7
8 /**
9  * Initializes the X11 part for the given container. Called exactly once for
10  * every container from con_new().
11  *
12  */
13 void x_con_init(Con *con);
14
15 /**
16  * Moves a child window from Container src to Container dest.
17  *
18  */
19 void x_move_win(Con *src, Con *dest);
20
21 /**
22  * Reparents the child window of the given container (necessary for sticky
23  * containers). The reparenting happens in the next call of x_push_changes().
24  *
25  */
26 void x_reparent_child(Con *con, Con *old);
27
28 /**
29  * Re-initializes the associated X window state for this container. You have
30  * to call this when you assign a client to an empty container to ensure that
31  * its state gets updated correctly.
32  *
33  */
34 void x_reinit(Con *con);
35
36 /**
37  * Kills the window decoration associated with the given container.
38  *
39  */
40 void x_con_kill(Con *con);
41
42 /**
43  * Returns true if the client supports the given protocol atom (like WM_DELETE_WINDOW)
44  *
45  */
46 bool window_supports_protocol(xcb_window_t window, xcb_atom_t atom);
47
48 /**
49  * Kills the given X11 window using WM_DELETE_WINDOW (if supported).
50  *
51  */
52 void x_window_kill(xcb_window_t window);
53
54 /**
55  * Draws the decoration of the given container onto its parent.
56  *
57  */
58 void x_draw_decoration(Con *con);
59
60 /**
61  * Pushes all changes (state of each node, see x_push_node() and the window
62  * stack) to X11.
63  *
64  */
65 void x_push_changes(Con *con);
66
67 /**
68  * Raises the specified container in the internal stack of X windows. The
69  * next call to x_push_changes() will make the change visible in X11.
70  *
71  */
72 void x_raise_con(Con *con);
73
74 /**
75  * Sets the WM_NAME property (so, no UTF8, but used only for debugging anyways)
76  * of the given name. Used for properly tagging the windows for easily spotting
77  * i3 windows in xwininfo -root -all.
78  *
79  */
80 void x_set_name(Con *con, const char *name);
81
82 /**
83  * Sets up i3 specific atoms (I3_SOCKET_PATH and I3_CONFIG_PATH)
84  *
85  */
86 void x_set_i3_atoms();
87
88 #endif