X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=include%2Frender.h;h=750b7d310317901155a626656517db9102afedde;hb=f354f534357798eb3ba497b7143132f41ff090f6;hp=1794b513894ea0c8583ff15400e1a66f679f39db;hpb=00cf2b21daa5bd5973f52cb1ac7a3852bf69f7cc;p=i3%2Fi3 diff --git a/include/render.h b/include/render.h index 1794b513..750b7d31 100644 --- a/include/render.h +++ b/include/render.h @@ -2,7 +2,7 @@ * vim:ts=4:sw=4:expandtab * * i3 - an improved dynamic tiling window manager - * © 2009-2011 Michael Stapelberg and contributors (see also: LICENSE) + * © 2009 Michael Stapelberg and contributors (see also: LICENSE) * * render.c: Renders (determines position/sizes) the layout tree, updating the * various rects. Needs to be pushed to X11 (see x.c) to be visible. @@ -10,6 +10,25 @@ */ #pragma once +#include + +/* This is used to keep a state to pass around when rendering a con in render_con(). */ +typedef struct render_params { + /* A copy of the coordinates of the container which is being rendered. */ + int x; + int y; + + /* The computed height for decorations. */ + int deco_height; + /* Container rect, subtract container border. This is the actually usable space + * inside this container for clients. */ + Rect rect; + /* The number of children of the container which is being rendered. */ + int children; + /* A precalculated list of sizes of each child. */ + int *sizes; +} render_params; + /** * "Renders" the given container (and its children), meaning that all rects are * updated correctly. Note that this function does not call any xcb_*