As my endless quest for automation continues, I've found myself running out of memorable keyboard shortcuts, and so I've been seeing if it's possible to create a Hotstring macro in KM. The basic idea is that the macro would:
Be able to trigger other macros using a short alphanumeric sequence (or hotstring) in a safe environment where they wouldn't accidentally be triggered by normal typing
Display a list of all possible hotstrings and details of what they trigger (so i don't forget them)
Filter the list as i type to only show the remaining matches
Automatically trigger the associated macro when the typed string exactly matches the hotstring (so that partial matches don't trigger too soon)
After far too much messing around with entirely overcomplicated solutions, I have come up with this.
The only thing that it is missing is the ability for the associated macro to trigger when the typed string exactly matches the hotstring. Granted, it only takes an extra half a second to hit enter, so this is by no means an essential feature - but it would be pretty cool...
Does anyone have thoughts on this - is it even possible?
As in showing a conflict palette? Can you control that with your keyboard?
EDIT: just tried this, this is what I need! Thanks for bringing it up!
EDIT: actually thinking about it, the thing that's still missing is a safe place to enter the hotstring so that it won't be triggered in normal typing. I'd previously been using Alfred for this but it was clunky getting the two to talk to each other, maybe this will ease it though
Because you don't use a hotstring. Use a Hot Key trigger that's the same for all the macros you want to conflict, like ⌃⌥C. That brings up the Conflict Palette which will start to filter as you type in further letters. It's a different approach to using a different, fixed, typed string for each macro but it's a lot easier to set up and a lot less likely to have unintended consequences.
If you do want to use typed string triggers, take a look at @Frankb's post (he's keen on, and experienced with, typed string triggers), consider a hot key triggered macro that makes a new, sacrificial, TextEdit doc or similar to type into, or @ccstone's idea of an AppleScript prompt to swallow the string.
Also have a look at the Trigger Macro by Name action which, conveniently, shows the macro names and hot key combos without any extra work from you...
That is very kind of you. But the only thing I am experienced in is asking questions in this forum.
And to be honest, I have given up my string trigger idea.... in favor of a new one. I call it "magic 4".
It's easy to create and expand. I can keep all my palettes, they always open in the right app and work like a shortcut/modifier. If I can't remember the tigger, I look it up in the palette or click the mouse, which always moves to the open palette and then back.
The function "4" remains if I only tap briefly (but is also a "modifier"). I reach the "4" key blindly with my left index finger. By simply swiping from 4 to 3 or from 4 to 5, to e, to r I blindly trigger more shortcuts and I'm sure I'll think of other things to do soon.
I think the AppleScript dialog to swallow the string is what I'll end up going with, activating the hotstring macros at the same time and deactivating them once the dialog is gone. But thanks for your detailed answer!