summaryrefslogtreecommitdiff
path: root/common/achordion.h
diff options
context:
space:
mode:
authorChristoph Cullmann <cullmann@kde.org>2023-12-28 19:41:29 +0100
committerChristoph Cullmann <cullmann@kde.org>2023-12-28 19:41:29 +0100
commit29daa02b02408ff1712b26f9d0da30ae3b794875 (patch)
tree1303cf3de084fd2682e8d652ea9b3cb0f78a35f1 /common/achordion.h
parent49f72da230d9595b72ad5fc7270b212205dc1cd2 (diff)
update to current state
https://getreuer.info/posts/keyboards/achordion/ https://sunaku.github.io/home-row-mods.html#typing-streaks
Diffstat (limited to 'common/achordion.h')
-rw-r--r--common/achordion.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/common/achordion.h b/common/achordion.h
index e6bb534..dfa8dc2 100644
--- a/common/achordion.h
+++ b/common/achordion.h
@@ -53,6 +53,27 @@
#include "quantum.h"
+/**
+ * Suppress tap-hold mods within a *typing streak* by defining
+ * ACHORDION_STREAK. This can help preventing accidental mod
+ * activation when performing a fast tapping sequence.
+ * This is inspired by https://sunaku.github.io/home-row-mods.html#typing-streaks
+ *
+ * Enable with:
+ *
+ * #define ACHORDION_STREAK
+ *
+ * Adjust the maximum time between key events before modifiers can be enabled
+ * by defining the following callback in your keymap.c:
+ *
+ * uint16_t achordion_streak_timeout(uint16_t tap_hold_keycode) {
+ * return 100; // Default of 100 ms.
+ * }
+ */
+#ifdef ACHORDION_STREAK
+uint16_t achordion_streak_timeout(uint16_t tap_hold_keycode);
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif