+ /* position/size and map/unmap all the windows */
+
+ /* they all default off, they're turned on in layout_title */
+ self->icon_x = -1;
+ self->desk_x = -1;
+ self->icon_x = -1;
+ self->label_x = -1;
+ self->max_x = -1;
+ self->close_x = -1;
+
+ if (self->frame.client->decorations & Decor_Titlebar) {
+ XMoveResizeWindow(ob_display, self->title,
+ -self->bwidth, -self->bwidth,
+ self->width, TITLE_HEIGHT);
+ self->innersize.top += TITLE_HEIGHT + self->bwidth;
+ XMapWindow(ob_display, self->title);
+
+ /* layout the title bar elements */
+ layout_title(self);
+ } else {
+ XUnmapWindow(ob_display, self->title);
+ /* make all the titlebar stuff not render */
+ self->frame.client->decorations &= ~(Decor_Icon | Decor_Iconify |
+ Decor_Maximize | Decor_Close |
+ Decor_AllDesktops);
+ }
+
+ if (self->frame.client->decorations & Decor_Handle) {
+ XMoveResizeWindow(ob_display, self->handle,
+ -self->bwidth, HANDLE_Y(self),
+ self->width, s_handle_height);
+ XMoveWindow(ob_display, self->lgrip,
+ -self->bwidth, -self->bwidth);
+ XMoveWindow(ob_display, self->rgrip,
+ -self->bwidth + self->width -
+ GRIP_WIDTH, -self->bwidth);
+ self->innersize.bottom += s_handle_height +
+ self->bwidth;
+ XMapWindow(ob_display, self->handle);
+ } else
+ XUnmapWindow(ob_display, self->handle);
+ }