* workspace at all. However, just calling render_con() on the
* workspace isn’t enough either — it needs the rect. */
ws->rect = ws->parent->rect;
- render_con(ws, true);
+ render_con(ws);
/* Disable setting focus, otherwise we’d move focus to an invisible
* workspace, which we generally prevent (e.g. in
* con_move_to_workspace). */
set_focus = false;
}
- render_con(croot, false);
+ render_con(croot);
/* Send an event about window creation */
ipc_send_window_event("new", nc);
* updated in X11.
*
*/
-void render_con(Con *con, bool render_fullscreen) {
+void render_con(Con *con) {
render_params params = {
.rect = con->rect,
.x = con->rect.x,
.y = con->rect.y,
.children = con_num_children(con)};
- DLOG("Rendering %snode %p / %s / layout %d / children %d\n",
- (render_fullscreen ? "fullscreen " : ""), con, con->name, con->layout,
- params.children);
+ DLOG("Rendering node %p / %s / layout %d / children %d\n", con, con->name,
+ con->layout, params.children);
int i = 0;
con->mapped = true;
* needs to be smaller */
Rect *inset = &(con->window_rect);
*inset = (Rect){0, 0, con->rect.width, con->rect.height};
- if (!render_fullscreen)
+ if (con->fullscreen_mode == CF_NONE) {
*inset = rect_add(*inset, con_border_style_rect(con));
+ }
/* Obey x11 border */
inset->width -= (2 * con->border_width);
if (fullscreen) {
fullscreen->rect = params.rect;
x_raise_con(fullscreen);
- render_con(fullscreen, true);
+ render_con(fullscreen);
/* Fullscreen containers are either global (underneath the CT_ROOT
* container) or per-output (underneath the CT_CONTENT container). For
* global fullscreen containers, we cannot abort rendering here yet,
DLOG("child at (%d, %d) with (%d x %d)\n",
child->rect.x, child->rect.y, child->rect.width, child->rect.height);
x_raise_con(child);
- render_con(child, false);
+ render_con(child);
i++;
}
* that we have a non-leaf-container inside the stack. In that
* case, the children of the non-leaf-container need to be raised
* as well. */
- render_con(child, false);
+ render_con(child);
}
if (params.children != 1)
Con *output;
if (!fullscreen) {
TAILQ_FOREACH(output, &(con->nodes_head), nodes) {
- render_con(output, false);
+ render_con(output);
}
}
DLOG("floating child at (%d,%d) with %d x %d\n",
child->rect.x, child->rect.y, child->rect.width, child->rect.height);
x_raise_con(child);
- render_con(child, false);
+ render_con(child);
}
}
}
if (fullscreen) {
fullscreen->rect = con->rect;
x_raise_con(fullscreen);
- render_con(fullscreen, true);
+ render_con(fullscreen);
return;
}
DLOG("child at (%d, %d) with (%d x %d)\n",
child->rect.x, child->rect.y, child->rect.width, child->rect.height);
x_raise_con(child);
- render_con(child, false);
+ render_con(child);
}
}