mirror of
https://github.com/0intro/wmii
synced 2025-02-12 04:14:47 +03:00
fixed some ugly stacking issues
This commit is contained in:
parent
c855a6dad0
commit
0d3b8a0b10
@ -508,16 +508,18 @@ resize_client(Client *c, XRectangle *r, XPoint *pt)
|
||||
XMoveResizeWindow(dpy, c->frame.win, px - (pi * rect.width) + c->frame.rect.x, c->frame.rect.y,
|
||||
c->frame.rect.width, c->frame.rect.height);
|
||||
|
||||
c->rect.x = bw;
|
||||
c->rect.y = bh ? bh : bw;
|
||||
c->rect.width = c->frame.rect.width - 2 * bw;
|
||||
c->rect.height = c->frame.rect.height - bw - (bh ? bh : bw);
|
||||
if((c->area->mode != COL_STACK) || (c->area->sel == client2index(c))) {
|
||||
c->rect.x = bw;
|
||||
c->rect.y = bh ? bh : bw;
|
||||
c->rect.width = c->frame.rect.width - 2 * bw;
|
||||
c->rect.height = c->frame.rect.height - bw - (bh ? bh : bw);
|
||||
|
||||
/* resize if client requests special size */
|
||||
check_dimensions(c, bh, bw);
|
||||
/* resize if client requests special size */
|
||||
check_dimensions(c, bh, bw);
|
||||
|
||||
XMoveResizeWindow(dpy, c->win, c->rect.x, c->rect.y, c->rect.width, c->rect.height);
|
||||
configure_client(c);
|
||||
XMoveResizeWindow(dpy, c->win, c->rect.x, c->rect.y, c->rect.width, c->rect.height);
|
||||
configure_client(c);
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
|
@ -93,8 +93,7 @@ draw_pager()
|
||||
unsigned int i, ic, ir, tw, th, rows, cols;
|
||||
int dx;
|
||||
|
||||
for(i = 0; (i < pagesz) && page[i]; i++);
|
||||
blitz_getbasegeometry(i, &cols, &rows);
|
||||
blitz_getbasegeometry(npage - 1, &cols, &rows);
|
||||
dx = (cols - 1) * DEF_PAGER_GAP; /* DEF_PAGER_GAPpx space */
|
||||
tw = (rect.width - dx) / cols;
|
||||
th = ((double) tw / rect.width) * rect.height;
|
||||
@ -102,7 +101,7 @@ draw_pager()
|
||||
d.gc = gc_transient;
|
||||
d.font = xfont;
|
||||
d.align = CENTER;
|
||||
i = 0;
|
||||
i = 1;
|
||||
for(ir = 0; ir < rows; ir++) {
|
||||
for(ic = 0; ic < cols; ic++) {
|
||||
d.rect.x = ic * tw + (ic * DEF_PAGER_GAP);
|
||||
@ -113,7 +112,7 @@ draw_pager()
|
||||
d.rect.y = ir * (rect.height - th) / (rows - 1);
|
||||
d.rect.height = th;
|
||||
draw_pager_page(i++, &d);
|
||||
if(!page[i])
|
||||
if(i == npage)
|
||||
return;
|
||||
}
|
||||
}
|
||||
@ -174,7 +173,7 @@ pager()
|
||||
int i;
|
||||
Client *c;
|
||||
|
||||
if(!npage)
|
||||
if(npage < 2)
|
||||
return;
|
||||
|
||||
XClearWindow(dpy, transient);
|
||||
|
Loading…
x
Reference in New Issue
Block a user