shorten patch filename to 7-digit

This commit is contained in:
pi66 2026-04-08 21:55:38 +01:00
parent f8147d53d8
commit 221554021f
3 changed files with 25 additions and 24 deletions

View File

@ -1,14 +1,15 @@
### Description
implements wlr-tablet-v2 for drawing tablets and supports cursor emulation
inspired by @guyuming76's [branch](https://codeberg.org/guyuming76/dwl/commits/branch/graphic_tablet), with coding help from @Palanix and testing by @Thanatos
Implements wlr-tablet-v2 for drawing tablets with cursor emulation.
Inspired by @guyuming76's [branch](https://codeberg.org/guyuming76/dwl/commits/branch/graphic_tablet), with coding help from @Palanix and testing by @Thanatos.
extended with:
- specify the active drawing zone on the physical tablet
- pad and tool button bindings to compositor actions
- **Tablet area**: define the active drawing zone using the `tablet_pad` array
`{x, y, width, height}`, values range from 0.0 to 1.0 (as a fraction of the
tablet's full surface). Only input within this area is mapped to the screen.
- **Button bindings**: bind tablet pad and stylus buttons to compositor actions.
### Download
- [git branch](https://codeberg.org/pi66/dwl/src/branch/tablet-input)
- [tablet-input-main-a2d03cf618.patch](https://codeberg.org/dwl/dwl-patches/raw/branch/main/patches/tablet-input/tablet-input-main-a2d03cf618.patch)
- [tablet-input-main-a2d03cf.patch](https://codeberg.org/dwl/dwl-patches/raw/branch/main/patches/tablet-input/tablet-input-main-a2d03cf.patch)
- [tablet-input-0.8.patch](https://codeberg.org/dwl/dwl-patches/raw/branch/main/patches/tablet-input/tablet-input-0.8.patch)
### Authors

View File

@ -1,6 +1,6 @@
From 27a9f5b7a0446f212785e7e8d6413f2a8e6af1ff Mon Sep 17 00:00:00 2001
From a14dff19f38fffa498f3de4679952b39b4323502 Mon Sep 17 00:00:00 2001
From: pi66 <pixel2176@proton.me>
Date: Sat, 4 Apr 2026 01:38:16 +0100
Date: Wed, 8 Apr 2026 21:47:41 +0100
Subject: [PATCH] feat: add pad/tool bindings and pen region
---
@ -34,7 +34,7 @@ index 578194f..e0d1835 100644
config.h:
cp config.def.h $@
diff --git a/config.def.h b/config.def.h
index 8a6eda0..1286eeb 100644
index 8a6eda0..288494e 100644
--- a/config.def.h
+++ b/config.def.h
@@ -4,6 +4,7 @@
@ -61,17 +61,17 @@ index 8a6eda0..1286eeb 100644
+
+static const TabletButton tabletbuttons[] = {
+ /* button state function argument */
+// { BTN_STYLUS, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} },
+// { BTN_STYLUS2, WLR_BUTTON_PRESSED, killclient, {0} },
+/* { BTN_STYLUS, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} }, */
+/* { BTN_STYLUS2, WLR_BUTTON_PRESSED, killclient, {0} }, */
+ { 0, 0, NULL, {0} }
+};
+
+static const TabletPadButton tabletpadbuttons[] = {
+ /* button state function argument */
+// { 0, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} },
+// { 1, WLR_BUTTON_PRESSED, killclient, {0} },
+// { 2, WLR_BUTTON_PRESSED, togglefloating, {0} },
+// { 3, WLR_BUTTON_PRESSED, zoom, {0} },
+/* { 0, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} }, */
+/* { 1, WLR_BUTTON_PRESSED, killclient, {0} },*/
+/* { 2, WLR_BUTTON_PRESSED, togglefloating, {0} },*/
+/* { 3, WLR_BUTTON_PRESSED, zoom, {0} },*/
+ { 0, 0, NULL, {0} }
+};
diff --git a/dwl.c b/dwl.c

View File

@ -1,6 +1,6 @@
From 27a9f5b7a0446f212785e7e8d6413f2a8e6af1ff Mon Sep 17 00:00:00 2001
From a14dff19f38fffa498f3de4679952b39b4323502 Mon Sep 17 00:00:00 2001
From: pi66 <pixel2176@proton.me>
Date: Sat, 4 Apr 2026 01:38:16 +0100
Date: Wed, 8 Apr 2026 21:47:41 +0100
Subject: [PATCH] feat: add pad/tool bindings and pen region
---
@ -34,7 +34,7 @@ index 578194f..e0d1835 100644
config.h:
cp config.def.h $@
diff --git a/config.def.h b/config.def.h
index 8a6eda0..1286eeb 100644
index 8a6eda0..288494e 100644
--- a/config.def.h
+++ b/config.def.h
@@ -4,6 +4,7 @@
@ -61,17 +61,17 @@ index 8a6eda0..1286eeb 100644
+
+static const TabletButton tabletbuttons[] = {
+ /* button state function argument */
+// { BTN_STYLUS, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} },
+// { BTN_STYLUS2, WLR_BUTTON_PRESSED, killclient, {0} },
+/* { BTN_STYLUS, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} }, */
+/* { BTN_STYLUS2, WLR_BUTTON_PRESSED, killclient, {0} }, */
+ { 0, 0, NULL, {0} }
+};
+
+static const TabletPadButton tabletpadbuttons[] = {
+ /* button state function argument */
+// { 0, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} },
+// { 1, WLR_BUTTON_PRESSED, killclient, {0} },
+// { 2, WLR_BUTTON_PRESSED, togglefloating, {0} },
+// { 3, WLR_BUTTON_PRESSED, zoom, {0} },
+/* { 0, WLR_BUTTON_PRESSED, spawn, {.v = termcmd} }, */
+/* { 1, WLR_BUTTON_PRESSED, killclient, {0} },*/
+/* { 2, WLR_BUTTON_PRESSED, togglefloating, {0} },*/
+/* { 3, WLR_BUTTON_PRESSED, zoom, {0} },*/
+ { 0, 0, NULL, {0} }
+};
diff --git a/dwl.c b/dwl.c