diff options
author | arg@10ksloc.org <unknown> | 2006-07-20 19:09:11 +0200 |
---|---|---|
committer | arg@10ksloc.org <unknown> | 2006-07-20 19:09:11 +0200 |
commit | 04eb016e782743ec88f150ec6f5389703bed3ce2 (patch) | |
tree | d814ad02b5c0182210c6d34e12673fa6a04d909c /client.c | |
parent | 0a4342098b6d01367c69782c643cb685f1cd3c3d (diff) | |
download | dwm-04eb016e782743ec88f150ec6f5389703bed3ce2.tar.gz |
applied sanders no_sizehints for tiled mode patch (thx!)
Diffstat (limited to 'client.c')
-rw-r--r-- | client.c | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -293,30 +293,30 @@ pop(Client *c) } void -resize(Client *c, Bool inc, Corner sticky) +resize(Client *c, Bool sizehints, Corner sticky) { int bottom = c->y + c->h; int right = c->x + c->w; XConfigureEvent e; - if(inc) { + if(sizehints) { if(c->incw) c->w -= (c->w - c->basew) % c->incw; if(c->inch) c->h -= (c->h - c->baseh) % c->inch; + if(c->minw && c->w < c->minw) + c->w = c->minw; + if(c->minh && c->h < c->minh) + c->h = c->minh; + if(c->maxw && c->w > c->maxw) + c->w = c->maxw; + if(c->maxh && c->h > c->maxh) + c->h = c->maxh; } if(c->x > sw) /* might happen on restart */ c->x = sw - c->w; if(c->y > sh) c->y = sh - c->h; - if(c->minw && c->w < c->minw) - c->w = c->minw; - if(c->minh && c->h < c->minh) - c->h = c->minh; - if(c->maxw && c->w > c->maxw) - c->w = c->maxw; - if(c->maxh && c->h > c->maxh) - c->h = c->maxh; if(sticky == TopRight || sticky == BotRight) c->x = right - c->w; if(sticky == BotLeft || sticky == BotRight) |