aewl

diff client.c @ 502:9aa3d06199cb

applied Jukkas patch
author Anselm R. Garbe <arg@10kloc.org>
date Thu, 28 Sep 2006 14:03:39 +0200
parents d5ad819f2a66
children 2b4bd49fc155
line diff
     1.1 --- a/client.c	Wed Sep 27 17:21:25 2006 +0200
     1.2 +++ b/client.c	Thu Sep 28 14:03:39 2006 +0200
     1.3 @@ -214,11 +214,11 @@
     1.4  	c->border = 0;
     1.5  	updatesize(c);
     1.6  
     1.7 -	if(c->x + c->w + 2 > sw)
     1.8 -		c->x = sw - c->w - 2;
     1.9 +	if(c->x + c->w + 2 * BORDERPX > sw)
    1.10 +		c->x = sw - c->w - 2 * BORDERPX;
    1.11  	if(c->x < 0)
    1.12  		c->x = 0;
    1.13 -	if(c->y + c->h + 2 > sh)
    1.14 +	if(c->y + c->h + 2 * BORDERPX > sh)
    1.15  		c->y = sh - c->h - 2;
    1.16  	if(c->h != sh && c->y < bh)
    1.17  		c->y = bh;
    1.18 @@ -302,7 +302,7 @@
    1.19  	if(c->w == sw && c->h == sh)
    1.20  		wc.border_width = 0;
    1.21  	else
    1.22 -		wc.border_width = 1;
    1.23 +		wc.border_width = BORDERPX;
    1.24  	XConfigureWindow(dpy, c->win, CWX | CWY | CWWidth | CWHeight | CWBorderWidth, &wc);
    1.25  	configure(c);
    1.26  	XSync(dpy, False);
    1.27 @@ -312,8 +312,8 @@
    1.28  resizetitle(Client *c) {
    1.29  	c->tw = textw(c->name);
    1.30  	if(c->tw > c->w)
    1.31 -		c->tw = c->w + 2;
    1.32 -	c->tx = c->x + c->w - c->tw + 2;
    1.33 +		c->tw = c->w + 2 * BORDERPX;
    1.34 +	c->tx = c->x + c->w - c->tw + 2 * BORDERPX;
    1.35  	c->ty = c->y;
    1.36  	if(isvisible(c))
    1.37  		XMoveResizeWindow(dpy, c->twin, c->tx, c->ty, c->tw, c->th);