You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
patches/dwm/dwm-renamedscratchpads-nosc...

34 lines
1.1 KiB
Diff

From 5c5a096d1b07d1840d5f6f5e14af459705e195f1 Mon Sep 17 00:00:00 2001
From: Bakkeby <bakkeby@gmail.com>
Date: Mon, 10 Jan 2022 13:26:37 +0100
Subject: [PATCH 2/2] Named scratchpad variant (without scratch color scheme)
---
dwm.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dwm.c b/dwm.c
index c58c6ed..67e5079 100644
--- a/dwm.c
+++ b/dwm.c
@@ -1820,6 +1820,8 @@ togglescratch(const Arg *arg)
if (!found || (mon == selmon && found->mon != selmon))
found = c;
+ unfocus(c, 0); // unfocus to avoid client border discrepancies
+
/* If scratchpad clients reside on another monitor and we are moving them across then
as we are looping through monitors we could be moving a client to a monitor that has
not been processed yet, hence we could be processing a scratchpad twice. To avoid
@@ -1838,7 +1840,6 @@ togglescratch(const Arg *arg)
} else if (scratchvisible == numscratchpads) {
c->tags = 0;
} else {
- XSetWindowBorder(dpy, c->win, scheme[SchemeScratchNorm][ColBorder].pixel);
c->tags = c->mon->tagset[c->mon->seltags];
if (c->isfloating)
XRaiseWindow(dpy, c->win);
--
2.19.1