{
client_resize(c, ev->x_root - X.start_x, ev->y_root - X.start_y);
}
+ XSync(X.disp, False);
}
}
}
* O columns per workspace
* Windows can tile in a column or float on workspaces
* Columns can have different layouts: manual, stacked, monocle
+
+ TODO: window border is wrong width on right and bottom for some reason...
+ TODO: warp mouse pointer to title bars on new windows
+ TODO: account for frame size in client x,y,w,h fields
+ TODO: implement mouse handling for tiling methods
+
*/
enum {
XAddToSaveSet(X.disp, c->win);
mons_addclient(c);
client_show(c, 1);
+ XSync(X.disp, False);
client_draw(c);
return c;
{
if (c->frame)
{
- XSetWindowBackground(X.disp, c->frame, (Focused == c) ? X.black : X.gray);
+ XSetWindowBackground(X.disp, c->frame, (Focused == c) ? X.black : X.white);
+ XSetWindowBorderWidth(X.disp, c->frame, 1);
+ XSetWindowBorder(X.disp, c->frame, (Focused == c) ? X.white : X.black);
+ XSetWindowBorderWidth(X.disp, c->win, 1);
+ XSetWindowBorder(X.disp, c->win, (Focused == c) ? X.white : X.black);
XClearWindow(X.disp, c->frame);
XDefineCursor(X.disp, c->frame, X.csr_point);
if (c->name) {
int ignore_error = (
(ev->error_code == BadWindow)
|| (ev->request_code == X_SetInputFocus && ev->error_code == BadMatch)
+ || (ev->request_code == X_ConfigureWindow && ev->error_code == BadMatch)
+ || (ev->request_code == X_ChangeWindowAttributes && ev->error_code == BadMatch)
);
if (ignore_error)
{
int ch = c->h + 2*BORDER_WIDTH + TITLE_HEIGHT;
c->x = mon->midx - cw/2;
c->y = mon->midy - ch/2;
- client_move(c, 0, 0);
- client_resize(c, 0, 0);
+ client_adjust(c);
}
else
{
}
}
mons_layer(mon);
+ XSync(X.disp, False);
}
void mons_delclient(Client* c)