Make Apple Magic Trackpad pointer feel closer to macOS - #9276
Open
barmstrong wants to merge 1 commit into
Open
Conversation
hid-magicmouse treats a resting thumb as a second finger, so a light edge contact becomes two-finger scroll or a right-click. Stock libinput also disables size-based palm/thumb filtering on these pads (TouchSizeRange 20:10). Skip kernel gesture emulation when a Magic Trackpad is present, re-enable libinput thumb/palm thresholds, and keep Hyprland's default sensitivity and adaptive accel on the pad even if the user raises the global pointer speed. The same kernel module drives Magic Mouse, whose surface-scroll still needs emulate_scroll_wheel, so those options are skipped when a Magic Mouse is connected.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On Linux, a Magic Trackpad treats a light resting thumb as a second finger. That becomes two-finger scroll or a right-click, and small pointer moves feel jumpy compared with macOS.
Two layers cause it:
hid-magicmousekernel two-finger scroll and 3-button emulation fire as soon as a second contact exists, before libinput can classify it as a thumb.50-system-apple.quirkssetsAttrTouchSizeRange=20:10on these pads, which turns size-based palm/thumb filtering off.This change:
/etc/libinput/omarchy-magic-trackpad.quirksso a light edge rest is ignored. Harmless on machines without the pad (match is by device name)./etc/modprobe.d/omarchy-magic-trackpad.conf(emulate_scroll_wheel=0,emulate_3button=0) when a Magic Trackpad is present, so libinput owns two-finger scroll and click. Two-finger right-click still works throughclickfinger_behavior.0on the common Magic Trackpad device names, so raising the global pointer speed does not make this large pad jumpy.Tested on a USB Magic Trackpad 2 (05AC:0265) on Omarchy 4.0.1. Resting-thumb scroll/right-click stopped, and fine text selection became usable.
test/shell.d/magic-trackpad-test.shcovers install and migration for trackpad-only, mouse-present, no-device, and Bluetooth USB-C IDs.