mirror of
https://github.com/0intro/wmii
synced 2025-01-06 02:22:01 +03:00
fixed column layout obscuring on running wmiirc again
This commit is contained in:
parent
e5ea2fb4fd
commit
c0cf389d84
@ -15,20 +15,14 @@ alloc_area(Tag *t)
|
||||
Area *a = cext_emallocz(sizeof(Area));
|
||||
a->tag = t;
|
||||
a->id = id++;
|
||||
update_area_geometry(a);
|
||||
a->rect = rect;
|
||||
a->rect.height = rect.height - brect.height;
|
||||
t->area = (Area **)cext_array_attach((void **)t->area, a, sizeof(Area *), &t->areasz);
|
||||
t->sel = t->narea;
|
||||
t->narea++;
|
||||
return a;
|
||||
}
|
||||
|
||||
void
|
||||
update_area_geometry(Area *a)
|
||||
{
|
||||
a->rect = rect;
|
||||
a->rect.height -= brect.height;
|
||||
}
|
||||
|
||||
void
|
||||
destroy_area(Area *a)
|
||||
{
|
||||
@ -332,7 +326,7 @@ arrange_tag(Tag *t, Bool updategeometry)
|
||||
for(i = 1; i < t->narea; i++) {
|
||||
Area *a = t->area[i];
|
||||
if(updategeometry) {
|
||||
update_area_geometry(a);
|
||||
a->rect.height = rect.height - brect.height;
|
||||
a->rect.x = (i - 1) * width;
|
||||
a->rect.width = width;
|
||||
}
|
||||
|
12
cmd/wm/bar.c
12
cmd/wm/bar.c
@ -62,11 +62,17 @@ update_bar_geometry()
|
||||
barpmap = XCreatePixmap(dpy, barwin, brect.width, brect.height, DefaultDepth(dpy, screen));
|
||||
XSync(dpy, False);
|
||||
draw_bar();
|
||||
for(i = 0; i < ntag; i++)
|
||||
for(i = 0; i < ntag; i++) {
|
||||
for(j = 1; j < tag[i]->narea; j++) {
|
||||
update_area_geometry(tag[i]->area[j]);
|
||||
arrange_area(tag[i]->area[j]);
|
||||
Area *a = tag[i]->area[j];
|
||||
a->rect.height = rect.height - brect.height;
|
||||
arrange_area(a);
|
||||
}
|
||||
for(j = 0; j < tag[i]->area[0]->nframe; j++) {
|
||||
Frame *f = tag[i]->area[0]->frame[j];
|
||||
resize_client(f->client, &f->rect, nil, False);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -432,7 +432,7 @@ resize_client(Client *c, XRectangle *r, XPoint *pt, Bool ignore_xcall)
|
||||
{
|
||||
Frame *f = c->frame[c->sel];
|
||||
|
||||
if((area2index(f->area) > 0) && pt)
|
||||
if(area2index(f->area))
|
||||
resize_area(c, r, pt);
|
||||
else
|
||||
f->rect = *r;
|
||||
|
@ -1357,7 +1357,6 @@ xwrite(IXPConn *c, Fcall *fcall)
|
||||
XFreeFont(dpy, xfont);
|
||||
xfont = blitz_getfont(dpy, def.font);
|
||||
update_bar_geometry();
|
||||
resize_all_clients();
|
||||
break;
|
||||
case FsFmode:
|
||||
if(!i2)
|
||||
|
@ -122,11 +122,9 @@ match_tags(Client *c)
|
||||
rules = parse(def.rules, &n);
|
||||
c->tags[0] = 0;
|
||||
tags = match(rules, n, c->name);
|
||||
fprintf(stderr, "match_tags tags=%s c->name=%s\n", tags, c->name);
|
||||
if(strlen(tags))
|
||||
cext_strlcat(c->tags, tags, sizeof(c->tags));
|
||||
tags = match(rules, n, c->classinst);
|
||||
fprintf(stderr, "match_tags tags=%s c->name=%s\n", tags, c->name);
|
||||
if(strlen(tags))
|
||||
cext_strlcat(c->tags, tags, sizeof(c->tags));
|
||||
|
||||
|
@ -213,7 +213,6 @@ Area *alloc_area(Tag *t);
|
||||
void destroy_area(Area *a);
|
||||
int area2index(Area *a);
|
||||
int aid2index(Tag *t, unsigned short id);
|
||||
void update_area_geometry(Area *a);
|
||||
void select_area(Area *a, char *arg);
|
||||
void send2area(Area *to, Area *from, Client *c);
|
||||
void attach_toarea(Area *a, Client *c);
|
||||
|
Loading…
Reference in New Issue
Block a user