dwl-patches overhaul

Eliminated wiki.
Individual patches have a README.md explanation in their own subdirectory.
Simplified submission of new patches and maintenance of existing patches.
Instructions page (README.md autodisplayed) is now at https://codeberg.org/dwl/dwl-patches/
This commit is contained in:
A Frederick Christensen
2024-04-24 20:20:07 -05:00
parent d6b051f5b8
commit 9c5d5d85f3
183 changed files with 1434 additions and 4 deletions
+9
View File
@@ -0,0 +1,9 @@
### Description
Limits nmaster to within the range of currently-opened windows (nmaster will not change past the full horizontal split layout)
### Download
- [git branch](https://codeberg.org/dev-gm/dwl/src/branch/limitnmaster)
- [2024-03-15](https://codeberg.org/dwl/dwl-patches/raw/branch/main/patches/limitnmaster/limitnmaster.patch)
### Authors
- [dev-gm](https://codeberg.org/dev-gm)
+33
View File
@@ -0,0 +1,33 @@
From 20c948398af900564a59007fc08d15eaa0b65da3 Mon Sep 17 00:00:00 2001
From: Gavin M <github@gavinm.us>
Date: Fri, 15 Mar 2024 17:33:27 -0500
Subject: [PATCH] Added limitnmaster
---
dwl.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/dwl.c b/dwl.c
index 5867b0c..210c41d 100644
--- a/dwl.c
+++ b/dwl.c
@@ -1391,9 +1391,15 @@ handlesig(int signo)
void
incnmaster(const Arg *arg)
{
+ unsigned int n = 0;
+ Client *c;
+
if (!arg || !selmon)
return;
- selmon->nmaster = MAX(selmon->nmaster + arg->i, 0);
+ wl_list_for_each(c, &clients, link)
+ if (VISIBLEON(c, selmon) && !c->isfloating && !c->isfullscreen)
+ n++;
+ selmon->nmaster = MIN(MAX(selmon->nmaster + arg->i, 0), n);
arrange(selmon);
}
--
2.44.0