Make disable-while-typing work when the touchpad still fires during typing
keyd README (gh api) contains the quirk verbatim: /etc/libinput/local-overrides.quirks, [Serial Keyboards], MatchUdevType=keyboard, MatchName=keyd*keyboard, AttrKeyboardIntegration=internal. omacom/omarchy#5071 confirms makima's virtual keyboard broke disable-while-typing (closed because Quattro dropped makima, which is not installed on 4.0.4-1, so this now applies only to a user-installed remapper, as the record says). #10815 is still open and its comments confirm the T2 cause (ID_INTEGRATION and ID_INPUT_TOUCHPAD_INTEGRATION external, DWT unavailable in libinput), the exact udev rule for 05ac:0340 on MacBookPro16,1, 027b on MacBookPro15,2, a fix on MacBookAir9,1, and the 'palm: dwt activated with' log line. The quattro tree's install/hardware/apple/fix-t2.sh adds no trackpad hwdb or udev rule, so the workaround is still needed. Hyprland wiki config-options.md lists disable_while_typing default true, and /usr/share/omarchy/default/hypr/input.lua sets no such key. libinput palm-detection docs confirm touchpad and keyboard pairing for DWT. Not exercised on hardware.
Symptom
The cursor jumps or the touchpad registers clicks while you type, even though hyprctl getoption input:touchpad:disable_while_typing reports bool: true. Typically starts after installing a key remapper (keyd, makima, kanata) or is there from day one on a T2 MacBook (MacBookPro15,2, MacBookPro16,1, MacBookAir9,1).
Cause
libinput does not disable the touchpad for any key press. It pairs touchpads with keyboards, and in the common case the internal touchpad is paired only with the internal keyboard. Two setups break that pairing. (1) A remapper grabs the real keyboard and re-emits keys from a virtual uinput device. libinput does not consider that device internal, so typing never triggers disable-while-typing. keyd's README documents this and the quirk that fixes it. (2) On T2 Macs the built-in trackpad sits behind the t2bce_vhci virtual USB bridge and udev classifies it as external (ID_INPUT_TOUCHPAD_INTEGRATION=external), so libinput reports disable-while-typing as unavailable for it. Hyprland's disable_while_typing defaults to true and Omarchy 4 does not change it (it is absent from /usr/share/omarchy/default/hypr/input.lua), so the Hyprland setting is not the problem in either case.
Fix
**1. Find the devices and how udev classified them.**
grep -E 'Name=|Handlers=' /proc/bus/input/devices
udevadm info -q property -n /dev/input/eventN | grep -E 'NAME|INTEGRATION|ID_VENDOR_ID|ID_MODEL_ID'
Replace eventN with the touchpad's and the keyboard's event nodes from the first command.
**Case 1: a remapper's virtual keyboard.** Mark it internal for libinput. This is the snippet from keyd's README, adjust MatchName to the virtual device name shown in /proc/bus/input/devices for other tools:
# /etc/libinput/local-overrides.quirks
[Serial Keyboards]
MatchUdevType=keyboard
MatchName=keyd*keyboard
AttrKeyboardIntegration=internal
**Case 2: a T2 MacBook trackpad classified as external.** Mark it internal with a udev rule. Use your own ID_MODEL_ID from step 1: reports so far are 027b (MacBookPro15,2) and 0340 (MacBookPro16,1).
# /etc/udev/rules.d/99-apple-t2-internal-touchpad.rules
ACTION!="remove", SUBSYSTEM=="input", KERNEL=="event*", \
ENV{ID_INPUT_TOUCHPAD}=="1", ENV{ID_VENDOR_ID}=="05ac", ENV{ID_MODEL_ID}=="0340", \
DEVPATH=="*/t2bce_vhci/*", \
ENV{ID_INTEGRATION}="internal", ENV{ID_INPUT_TOUCHPAD_INTEGRATION}="internal"
sudo udevadm control --reload
Then reboot so libinput opens the devices again with the new classification. Both files are the same on Omarchy 4 and plain Arch.
Verify
udevadm info -q property -n /dev/input/eventN | grep INTEGRATION on the touchpad shows internal (case 2). Type continuously in a terminal while resting a palm on the pad: the cursor does not move. A Hyprland debug log, where enabled, shows palm: dwt activated with ... naming the keyboard and touchpad pair.
Sources
- https://github.com/omacom/omarchy/issues/10815
- https://github.com/omacom/omarchy/issues/5071
- https://wayland.freedesktop.org/libinput/doc/latest/palm-detection.html
- https://github.com/rvaiya/keyd/blob/master/README.md
- https://github.com/hyprwm/hyprland-wiki/blob/main/content/configuring/core/config-options.md