fixed north attaching policy in float layout

This commit is contained in:
garbeam 2005-12-13 15:55:48 +02:00
parent 8e868a64e4
commit 8856b230b8
4 changed files with 11 additions and 2 deletions

View File

@ -120,6 +120,7 @@ static void iter_after_write_area(void *item, void *aux)
a->layout->deinit(a);
a->layout = l;
a->layout->init(a);
invoke_wm_event(def[WM_EVENT_PAGE_UPDATE]);
}
draw_page(a->page);
return;

View File

@ -153,7 +153,11 @@ static void handle_configurerequest(XEvent * e)
wc.y = tabh ? tabh : bw;
}
wc.width = ev->width;
if (!wc.width)
wc.width = 1; /* borken app fix */
wc.height = ev->height;
if (!wc.height)
wc.height = 1; /* borken app fix */
wc.border_width = 0;
wc.sibling = None;
wc.stack_mode = Above;

View File

@ -72,6 +72,11 @@ static Bool attach_float(Area *a, Client *c)
if (f && (((char *) f->file[F_LOCKED]->content)[0] == '1'))
f = 0;
if (!f) {
if (c->rect.y < area_rect.y)
c->rect.y = area_rect.y;
if (c->rect.x < area_rect.x)
c->rect.x = area_rect.x;
f = alloc_frame(&c->rect);
attach_frame_to_area(a, f);
cext_attach_item((Container *)a->aux, f);

View File

@ -710,8 +710,7 @@ static void clean_client_up(void *item, void *aux)
if (f) {
XWindowChanges wc;
gravitate(c, tab_height(f), border_width(f), 1);
XReparentWindow(dpy, c->win, root, f->rect.x + c->rect.x,
f->rect.y + c->rect.y);
XReparentWindow(dpy, c->win, root, f->rect.x + c->rect.x, f->rect.y + c->rect.y);
wc.border_width = c->border;
XConfigureWindow(dpy, c->win, CWBorderWidth, &wc);
}