X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=include%2Fx.h;h=afc1645cd2044683991502d5bbc541da3bcd7e8b;hb=08986a17983c45781e59515b528710413b953984;hp=15d37420adfb7b1cdcde8822ad201f3432d310d7;hpb=c130cefa93a048323586963b7ffce928d848fbb0;p=i3%2Fi3 diff --git a/include/x.h b/include/x.h index 15d37420..afc1645c 100644 --- a/include/x.h +++ b/include/x.h @@ -1,7 +1,13 @@ /* * vim:ts=4:sw=4:expandtab + * + * i3 - an improved dynamic tiling window manager + * © 2009-2011 Michael Stapelberg and contributors (see also: LICENSE) + * + * x.c: Interface to X11, transfers our in-memory state to X11 (see also + * render.c). Basically a big state machine. + * */ - #ifndef _X_H #define _X_H @@ -52,7 +58,7 @@ bool window_supports_protocol(xcb_window_t window, xcb_atom_t atom); * Kills the given X11 window using WM_DELETE_WINDOW (if supported). * */ -void x_window_kill(xcb_window_t window); +void x_window_kill(xcb_window_t window, kill_window_t kill_window); /** * Draws the decoration of the given container onto its parent. @@ -60,6 +66,22 @@ void x_window_kill(xcb_window_t window); */ void x_draw_decoration(Con *con); +/** + * Recursively calls x_draw_decoration. This cannot be done in x_push_node + * because x_push_node uses focus order to recurse (see the comment above) + * while drawing the decoration needs to happen in the actual order. + * + */ +void x_deco_recurse(Con *con); + +/** + * This function pushes the properties of each node of the layout tree to + * X11 if they have changed (like the map state, position of the window, …). + * It recursively traverses all children of the given node. + * + */ +void x_push_node(Con *con); + /** * Pushes all changes (state of each node, see x_push_node() and the window * stack) to X11. @@ -88,4 +110,19 @@ void x_set_name(Con *con, const char *name); */ void x_set_i3_atoms(); +/** + * Set warp_to coordinates. This will trigger on the next call to + * x_push_changes(). + * + */ +void x_set_warp_to(Rect *rect); + +/** + * Applies the given mask to the event mask of every i3 window decoration X11 + * window. This is useful to disable EnterNotify while resizing so that focus + * is untouched. + * + */ +void x_mask_event_mask(uint32_t mask); + #endif