summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Günzler <r@gnzler.io>2021-05-31 16:47:01 +0200
committerRobert Günzler <r@gnzler.io>2021-05-31 16:47:01 +0200
commit20f97518530e5239963d73e7755e1861d9eee605 (patch)
tree1fee1bbe5e4d7e720a5633c19b8c9f941711f209
parent1235e437b5bc57cfa355c5b8d3e60d8f7a9d6054 (diff)
sway: use generic blocks for input configuration
-rw-r--r--.config/sway/input.conf86
1 files changed, 36 insertions, 50 deletions
diff --git a/.config/sway/input.conf b/.config/sway/input.conf
index ade53ae..1c30aaf 100644
--- a/.config/sway/input.conf
+++ b/.config/sway/input.conf
@@ -1,71 +1,57 @@
 # vim: ft=i3config fdm=marker fen
 
-input 1:1:AT_Translated_Set_2_keyboard {
-   xkb_layout us
-   xkb_variant mac
-   xkb_options 'caps:hyper,lvl3:ralt_switch_multikey,eurosign:5'
-   repeat_rate 70
-   repeat_delay 200
-}
-input 65261:25700:Input_Club_Infinity_keyboard/QMK {
-   xkb_layout us
-   xkb_variant mac
-  xkb_options 'caps:hyper,lvl3:ralt_switch_multikey,eurosign:5'
-   repeat_rate 70
-   repeat_delay 200
+input type:keyboard {
+	xkb_layout us
+	xkb_variant mac
+	xkb_options 'caps:hyper,lvl3:ralt_switch_multikey,eurosign:5'
+
+	repeat_rate 70
+	repeat_delay 200
 }
-input 12951:50895:ZSA_Technology_Labs_Planck_EZ_Glow {
-   xkb_layout us
-   xkb_variant mac
-  xkb_options 'caps:hyper,lvl3:ralt_switch_multikey,eurosign:5'
-   repeat_rate 70
-   repeat_delay 200
+
+input type:pointer {
+	accel_profile adaptive
+	pointer_accel 0
+	natural_scroll enabled
 }
 
-# internal trackpad
-input 1739:0:Synaptics_TM3289-021 {
-   tap enabled
-   natural_scroll enabled
-   accel_profile adaptive
+input type:touchpad {
+	accel_profile adaptive
+	tap enabled
+	natural_scroll enabled
 }
-input 2:10:TPPS/2_Elan_TrackPoint {
-   natural_scroll enabled
-   accel_profile adaptive
-   pointer_accel 1
+input type:tablet_tool {
+	accel_profile flat
 }
-input 1149:8264:Primax_Kensington_Eagle_Trackball {
-   accel_profile adaptive
+
+set {
+	$keyboard 1:1:AT_Translated_Set_2_keyboard
+	$trackpad 1739:0:Synaptics_TM3289-021
+	$trackpoint 2:10:TPPS/2_Elan_TrackPoint
+
+	$planck 12951:50895:ZSA_Technology_Labs_Planck_EZ_Glow
+	$slimblade 1149:8257:Kensington_Kensington_Slimblade_Trackball
+	$mouse 1133:16500:Logitech_G305
+	$pen 10429:148:XP-PEN_STAR_G640_Pen
 }
-set $slimblade 1149:8257:Kensington_Kensington_Slimblade_Trackball
-input $slimblade {
-   accel_profile adaptive
-   # pointer_accel 0.8
-   # scroll_factor 2
-   scroll_method on_button_down
-   scroll_button BTN_MIDDLE
+
+input $trackpoint {
+	pointer_accel 1
 }
+
+# $slimblade:
 # button layout:
 # ---------
 # | 2 | 8 |
 # ---------
 # | 1 | 3 |
 # ---------
+input $slimblade {
+	natural_scroll disabled
+}
 bindsym --input-device=$slimblade --whole-window button8 seat - cursor press button3, seat - cursor release button3
 bindsym --input-device=$slimblade --whole-window button3 seat - cursor press button8, seat - cursor release button8
 
-input 1133:16500:Logitech_G305 {
-   accel_profile flat
-   pointer_accel 0
-   natural_scroll enabled
-}
-
-set $pen 10429:148:XP-PEN_STAR_G640_Pen
-input $pen {
-   accel_profile flat
-   # scroll_method on_button_down
-   # BTN_STYLUS2
-   # scroll_button 332
-}
 # seat pen attach $pen
 # seat pen hide_cursor 10000
 # seat pen idle_inhibit tablet_tool