dwm-custom/patches/tagmon_floatrules.diff
2024-02-28 01:33:38 +01:00

25 lines
578 B
Diff

--- a/dwm.c
+++ b/dwm.c
@@ -1937,7 +1937,8 @@ sendmon(Client *c, Monitor *m)
c->tags = m->tagset[m->seltags]; /* assign tags of target monitor */
attachx(c);
attachstack(c);
- arrange(m);
+ if (!c->isfloating)
+ arrange(m);
if (hadfocus) {
focus(c);
restack(m);
@@ -2303,8 +2304,11 @@ tagmon(const Arg *arg)
c->isfullscreen = 1;
resizeclient(c, c->mon->mx, c->mon->my, c->mon->mw, c->mon->mh);
XRaiseWindow(dpy, c->win);
- } else
+ } else {
sendmon(c, dest);
+ applyrules(c);
+ XMoveResizeWindow(dpy, c->win, c->x, c->y, c->w, c->h);
+ }
}
void