Custom Keybinds with Better Touch Tool on MacOS

Create Global or App Specific Hotkeys with Better Touch Tool

Posted on:

I've used Better Touch Tool for a few years now, but only for a few basic functions. I had one problem to solve, creating global shortcuts to launch apps like I have setup in my tiling window managers. I set that up to my liking and never explored any further into its capabilities. Now my Mac workflow is the same way as my computer running Fedora. The Option(⌥) key on the Mac keyboard is where the Super key would be on a standard keyboard.

I recently took my BTT usage a step further and added a few key sequence shortcuts to make caps lock an Esc/Ctrl key, which gives me even more mileage out of the app. What never occurred to me though (but probably should have) is BTT can also create key binds for actions while focused on a specific app. I occasionally use Ivory to browse Mastodon. It's always annoyed me that the developers added j and k binds for moving up and down between toots, but didn't go the extra step to add h and l to go back and forward or g and G (shift+g) for scroll to top and scroll to bottom. Today, I finally put two and two together; I can now stop waiting for a day that may never come and just make my own key binds.

Better Touch Tool Key Binds for Ivory

While I know this isn't revolutionary and probably not even news to anyone who's used BTT before, it's a function I never thought to tap into and has made my day a little better. Now that I have the idea in the back of my head, I'm confident I'll find other places to use this feature... and vim keys all the things.

Update

After using these new keybindings for a few weeks, today was the first time I tried to write a new toot. When I opened the text box, I noticed that my u key wasn't working and I realized the keybinds I had created were interfering with regular typing. I came up with another somewhat hacky solution, which is to only enable those binds on windows not titled Compose using the advanced conditions option. But I also had to take it one step further as it appears that excluding the Compose window from the keybind doesn't just disable the shortcut and pass the key through, it disables the key altogether. That means I had to create another keybind for each key that only activates on the Compose window and sends the key that was pressed. My BTT configuration window now looks more like this:

Better Touch Tool Keybinds to Pass Keys to Compose Window


Tagged with:

More posts: