Trackpad gesture
Runs the macro on a multi-finger trackpad swipe, tap or pinch.
A fingers-finger kind
Keyboard Maestro: Gesture
Details #
Fires when you make a gesture on the trackpad that matches fingers, kind and, if you give one, direction.
fingers: 2 to 5.
kind:
swipe,taporpinch. If left out,swipe.direction: for a swipe
left,right,upordown. For a pinchinorout. A tap has none. Leave it out to match every direction.app: a bundle id. The gesture then only counts while that app is in front. A gesture tied to the front app wins over one for every app.
Two-finger swipes must be quick flicks, because two fingers also scroll. Switchboard watches the gesture, it does not stop it: macOS still sees it too.
Gestures are read from the trackpad through a macOS framework that Apple does not document. If that framework cannot be read after a macOS update, gestures switch themselves off and the engine says why. There is also a switch for the whole gestures module, on by default.
The kinds rotate, click and doubleTap can be stored, and BetterTouchTool presets use them, but nothing recognizes them, so they never fire.
Parameters #
| Parameter | Type | Required | Values | What it does |
|---|---|---|---|---|
fingers | whole number | Yes | Number of fingers, 2 to 5. | |
kind | text | Yes | swipe, tap or pinch. | |
app | text | Bundle id to limit the gesture to one app. | ||
direction | text | Direction for swipes and pinches. |
Every trigger also takes Limits: a cooldown, the first time each day, every nth time, twice within seconds, a chance, only while you are at the Mac, on one Mac, or in a State. See Limits on any trigger.
Examples #
- 3-finger swipe left
- Show “Swiped”
Gotchas #
Switchboard does not stop macOS from acting on the same gesture. If the system also uses it, turn the system gesture off in System Settings.
BetterTouchTool presets can import
rotate,clickanddoubleTapgestures, and one-finger Magic Mouse gestures. They are stored but never fire.