Press and Hold Modifier not working

I’m trying to map a button on my mouse to hold down shift. The Macro triggers and the KM menubar icon continues to spin until I release the button. But the system doesn’t behave as if Shift is held down, for example if I type while the macro is running, just appears in lowercase.

Any ideas?

The Press and Hold Shift Modifier action is intended, I think, to press Shift for any key that Keyboard maestro simulates, not any real key that you physically press.

I think that is briefly explained in the following message. But I agree, it's not obvious what that action does, and it's not really mentioned on the Help page for this action.

Thanks. That make sense. I achieved this using AppleScript instead.

In case anyone is interested, I trigger F4 using a side-button on my mouse which triggers KM to hold down shift so that I can scroll horizontally using the scroll wheel (something I often need to do in digital audio workstation software.)

Cool idea. That works? I never would have thought of that.

Works great. I’ve mapped the other side button to Command in the same way so that I can zoom using the mouse wheel one-handed.

That's a great idea too. I use CMD-scroll dozens of times per day. But pressing CMD isn't much worse than pressing a mouse button, so I'm not sure if I will try it out myself.

First, simulated events and real events are independent.

So for example, if Keyboard Maestro is simulating holding the shift key down, then you press “a” on the keyboard, you will get “a” not “A”. If you click, you will get a click, not a shift-click.

Second, keys that Keyboard Maestro type have their own modifiers, so they would release and held shift if necessary to type them.

I'm surprised your AppleScript works - but Apple works in mysterious ways.

1 Like

Indeed, this is quite a niche use-case where I’m holding a guitar in one hand and need to navigate a timeline with the other.

1 Like