Home

Awesome

MacGesture

logo

Configurable global mouse gestures for macOS.

You can read this README file in About section in App Preferences.

Installation

Automatic Update

MacGesture will regularly check for updates and prompt you when new version is available. 👍

Manually

Download the latese release bundle from GitHub releases page.

Homebrew

Simply use brew install --cask macgesture. 🙌

Features

Gestures Format

GestureAcronym
Move LeftL
Move UpU
Move RightR
Move DownD
Left ButtonZ
Wheel Upu
Wheel Dpd

Gestures can contain wildcard matching (? and *).

The first rule matching will take effect.

Z is the acronym of pinyin of which means “left” in English. So to distinguish clicking the left mouse button from dragging your mouse to the left, we chose letter Z.

Wheel directions may vary according to system configuration (Natural scroll direction setting) or some system tweaks (Karabiner's Reverse Vertical Scrolling, for example).

Known Issues

Right click does not work in some Java applications

An imperfect fix: Take WebStorm for example, open Preferences, then KeyMap, set the shortcut of “Show Context Menu” to Button3 Click.

Cannot assign some system-wide shortcuts to rules

Reason: macOS respond to system-wide shortcuts before MacGesture.

Fix: Disable the shortcut first (for example in System Preferences → Keyboard → Shortcuts), then assign the shortcut in MacGesture, and re-enable the shortcut.

Caveats: Some shortcuts still don't work with the fix above. When you are encountering this, here are two possible solutions:

Tips

Basic gestures

The following table covers probably the most basic scenario of usage:

GestureFilterActionNote⚡️
D*safari|*chrome⌘TNew Tab
DR*safari|*chrome⌘WClose

By setting these rules, you can empower mouse gestures to open new and close currently focused tabs in Sarari and Chrome Browsers. Simply:

How neat! 🙌

Mouse scroll gesture example

Now, to quickly cycle between the selected tabs even without releasing the right mouse button, you can set the gesture to be triggered on every match using the “⚡️” checkbox at the end of the Rule line.

So by defining the following rules:

GestureFilterActionNote⚡️
U*u*safari|*chrome⇧⌘[Prev Tab☑️
U*d*safari|*chrome⇧⌘]Next Tab☑️

you can simply:

Switching between multiple tabs in the browser is now a piece of cake! 😎

Exporting and importing MacGesture preferences

Recommended way

Use “Import” and “Export” buttons in the General Panel.

Geek-ish way

Open the Terminal app, Do this in your old computer:

defaults read com.codefalling.MacGesture backup.plist

And then copy that file to your new computer, then:

defaults import com.codefalling.MacGesture backup.plist

All settings should be successfully brought over. If that's not the case please file an issue.

Excluding an app in a certain rule

You can prepend !, then the app you want to exclude (still wildcard).

For example, the original one:

GestureFilterActionNote⚡️
U*d*⇧⌘]Next Tab☑️

Then, in order to exclude Safari, change this to:

GestureFilterActionNote⚡️
U*d*|!*safari⇧⌘]Next Tab☑️

Then you will experience the expected behaviour.

Found a Bug?

Feel free to open an issue on GitHub! 👍

Contributors

License

This project is made under GNU General Public License.

App icon & other icons designed by username0x0a.