comparison tag.c @ 115:329fd7dae530

removed c->f{x,y,w,h} and c->t{x,y,w,h} in favor for the new rule handling remembering two kinds of geometries is unnecessary, removed the randomized (x,y) setting on dofloat startup, was kind too random und unpredictable
author arg@10ksloc.org
date Thu, 20 Jul 2006 07:26:23 +0200
parents dfa5cd0969a6
children 61490330e90a
comparison
equal deleted inserted replaced
114:dfa5cd0969a6 115:329fd7dae530
51 { 51 {
52 Client *c; 52 Client *c;
53 53
54 arrange = dofloat; 54 arrange = dofloat;
55 for(c = clients; c; c = c->next) { 55 for(c = clients; c; c = c->next) {
56 setgeom(c);
57 if(c->tags[tsel]) { 56 if(c->tags[tsel]) {
58 resize(c, True, TopLeft); 57 resize(c, True, TopLeft);
59 } 58 }
60 else 59 else
61 ban(c); 60 ban(c);
85 h = (sh - bh) / (n - 1); 84 h = (sh - bh) / (n - 1);
86 else 85 else
87 h = sh - bh; 86 h = sh - bh;
88 87
89 for(i = 0, c = clients; c; c = c->next) { 88 for(i = 0, c = clients; c; c = c->next) {
90 setgeom(c);
91 if(c->tags[tsel]) { 89 if(c->tags[tsel]) {
92 if(c->isfloat) { 90 if(c->isfloat) {
93 higher(c); 91 higher(c);
94 resize(c, True, TopLeft); 92 resize(c, True, TopLeft);
95 continue; 93 continue;
96 } 94 }
97 if(n == 1) { 95 if(n == 1) {
98 *c->x = sx; 96 c->x = sx;
99 *c->y = sy + bh; 97 c->y = sy + bh;
100 *c->w = sw - 2 * c->border; 98 c->w = sw - 2 * c->border;
101 *c->h = sh - 2 * c->border - bh; 99 c->h = sh - 2 * c->border - bh;
102 } 100 }
103 else if(i == 0) { 101 else if(i == 0) {
104 *c->x = sx; 102 c->x = sx;
105 *c->y = sy + bh; 103 c->y = sy + bh;
106 *c->w = mw - 2 * c->border; 104 c->w = mw - 2 * c->border;
107 *c->h = sh - 2 * c->border - bh; 105 c->h = sh - 2 * c->border - bh;
108 } 106 }
109 else if(h > bh) { 107 else if(h > bh) {
110 *c->x = sx + mw; 108 c->x = sx + mw;
111 *c->y = sy + (i - 1) * h + bh; 109 c->y = sy + (i - 1) * h + bh;
112 *c->w = w - 2 * c->border; 110 c->w = w - 2 * c->border;
113 *c->h = h - 2 * c->border; 111 c->h = h - 2 * c->border;
114 } 112 }
115 else { /* fallback if h < bh */ 113 else { /* fallback if h < bh */
116 *c->x = sx + mw; 114 c->x = sx + mw;
117 *c->y = sy + bh; 115 c->y = sy + bh;
118 *c->w = w - 2 * c->border; 116 c->w = w - 2 * c->border;
119 *c->h = sh - 2 * c->border - bh; 117 c->h = sh - 2 * c->border - bh;
120 } 118 }
121 resize(c, False, TopLeft); 119 resize(c, False, TopLeft);
122 i++; 120 i++;
123 } 121 }
124 else 122 else