13 extern struct w *Qnil;
16 set_size (struct w *w, int new_size, int nodelete, int set_height)
18 int old_size = set_height? w->height : w->width;
20 if (nodelete || w->parent == Qnil)
22 int last_pos, last_old_pos, pos, old_pos, first;
23 int div_val = old_size << 1;
26 last_pos = first = set_height? w->top : w->left;
29 for (c = w->child; c != Qnil; c = c->next)
32 old_pos = last_old_pos + c->height;
34 old_pos = last_old_pos + c->width;
36 pos = (((old_pos * new_size) << 1) + old_size) / div_val;
37 set_size (c, pos + first - last_pos, 1, set_height);
38 last_pos = pos + first;
39 last_old_pos = old_pos;
43 for (c = w->child; c != Qnil; c = c->next)