Introduction
Introduction Statistics Contact Development Disclaimer Help
[dwm][patch][colorschemes] Edit patch - sites - public wiki contents of suckles…
git clone git://git.suckless.org/sites
Log
Files
Refs
---
commit d6331f8b0eae114fcd436f13d8291b9f8bac6fe0
parent 7e306a5bd9ea94d9525f772d338784242e8987a3
Author: Listeria monocytogenes <[email protected]>
Date: Mon, 23 Dec 2024 17:59:39 -0300
[dwm][patch][colorschemes] Edit patch
fix window border colors not updating
Diffstat:
M dwm.suckless.org/patches/colorsche… | 28 ++++++++++++++++++++--------
M dwm.suckless.org/patches/colorsche… | 3 ++-
2 files changed, 22 insertions(+), 9 deletions(-)
---
diff --git a/dwm.suckless.org/patches/colorschemes/dwm-colorschemes-6.5.diff b/…
@@ -1,12 +1,12 @@
-From a9dc99543fe07801587ed1b412cd97b5da01474f Mon Sep 17 00:00:00 2001
+From d067cd3815e35c8c5b804893a551d24fa7505e4b Mon Sep 17 00:00:00 2001
From: Listeria monocytogenes <[email protected]>
Date: Wed, 26 Jun 2024 11:49:20 -0300
Subject: [PATCH] add setscheme() to cycle between colorschemes
---
config.def.h | 15 +++++++++++----
- dwm.c | 37 ++++++++++++++++++++++++++++---------
- 2 files changed, 39 insertions(+), 13 deletions(-)
+ dwm.c | 49 ++++++++++++++++++++++++++++++++++++++++---------
+ 2 files changed, 51 insertions(+), 13 deletions(-)
diff --git a/config.def.h b/config.def.h
index 9efa774..f87f707 100644
@@ -42,7 +42,7 @@ index 9efa774..f87f707 100644
TAGKEYS( XK_2, 1)
TAGKEYS( XK_3, 2)
diff --git a/dwm.c b/dwm.c
-index f1d86b2..1ac8e05 100644
+index f1d86b2..9c00a09 100644
--- a/dwm.c
+++ b/dwm.c
@@ -59,7 +59,7 @@
@@ -84,14 +84,22 @@ index f1d86b2..1ac8e05 100644
XDestroyWindow(dpy, wmcheckwin);
drw_free(drw);
XSync(dpy, False);
-@@ -1536,10 +1537,25 @@ setmfact(const Arg *arg)
+@@ -1536,10 +1537,37 @@ setmfact(const Arg *arg)
arrange(selmon);
}
+void
+setscheme(const Arg *arg)
+{
-+ ptrdiff_t si = (scheme - schemes) + arg->i * SchemeN;
++ ptrdiff_t si;
++ Monitor *m;
++ Client *c;
++
++ /* select default color scheme */
++ if (!arg || arg->i == 0)
++ si = 0;
++ else
++ si = (scheme - schemes) + arg->i * SchemeN;
+
+ /* wrap around, won't work if (abs(arg->i) > LENGTH(colors)) */
+ if (si < 0)
@@ -100,7 +108,11 @@ index f1d86b2..1ac8e05 100644
+ si -= LENGTH(colors) * SchemeN;
+
+ scheme = &schemes[si];
++
+ drawbars();
++ for (m = mons; m; m = m->next)
++ for (c = m->clients; c; c = c->next)
++ XSetWindowBorder(dpy, c->win, scheme[c == selmon->sel…
+}
+
void
@@ -111,7 +123,7 @@ index f1d86b2..1ac8e05 100644
XSetWindowAttributes wa;
Atom utf8string;
struct sigaction sa;
-@@ -1584,9 +1600,12 @@ setup(void)
+@@ -1584,9 +1612,12 @@ setup(void)
cursor[CurResize] = drw_cur_create(drw, XC_sizing);
cursor[CurMove] = drw_cur_create(drw, XC_fleur);
/* init appearance */
@@ -128,5 +140,5 @@ index f1d86b2..1ac8e05 100644
updatebars();
updatestatus();
--
-2.45.2
+2.47.1
diff --git a/dwm.suckless.org/patches/colorschemes/index.md b/dwm.suckless.org/…
@@ -16,8 +16,9 @@ Default keybindings
Download
--------
-* [dwm-colorschemes-6.5.diff](dwm-colorschemes-6.5.diff) (2024-06-26)
+* [dwm-colorschemes-6.5.diff](dwm-colorschemes-6.5.diff) (2024-12-23)
Authors
-------
* Listeria monocytogenes <[email protected]>
+* Dhruv Trivedi
You are viewing proxied material from suckless.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.