Hotkey with Keystroke Causing Chain of Macros

I am trying to use Keyboard Maestro to set up a Programmer-Dvorak layout, which I used to do in Karabiner until Sierra, but am running into a really weird issue with chaining.

I basically just have a ton of macros with Hotkey triggers and “Type the _ Keystroke” actions. An example would be: Pressing = should actually press Shift+1 (Exclamation mark). Once I fully setup my macros, if I keep tapping =, the output is pretty random. Here’s example output of me pressing = a bunch of times: “%!&%!&1%1!!0!%1!!%%%%%1

I looked in the log, and it seems to be chaining my events and randomly firing one. For example, I am getting the percent sign a bunch of times because it is firing the hotkey I have for Shift+1, which is where the percent sign should be. So, it’s firing the first hotkey, which triggers the action of Shift+1, then it’s triggering that hotkey sometimes, which triggers Shift+5.

Is there any way for me to remap all my keys without this chain reaction? I am trying to get it so that the keys convert to Programmer Dvorak for normal types, but stay in QWERTY when Cmd, Ctrl, or Alt are down.

Keyboard Maestro is not a tool for remapping keyboards.

You can map = to !, but if you are also mapping ! to something else, that may or may not happen, and so on.


If you simulate a key that is the hot key of a macro, that macro may or may not fire.

There is a build in keyboard for DVORAK with QWERTY Command keys.

I suggest you figure out how to create a new keyboard layout or alternatively investigate application:Karabiner or some other tool - this is not something Keyboard Maestro can do for you.

Ukelele — a Unicode keyboard layout editor

I haven’t used this, but it’s been around quite a while now.


I had a feeling that was going to be the answer. I was using Programmer Dvorak on Mac forever until Sierra broke Karabiner, and I had to update to get the latest Xcode.

Thanks for your help,

I tried Ukelele and thought I finally had a solution, but both of the IDEs I prefer (IntelliJ and Visual Studio Code) fail to handle the fact that the buttons return to QWERTY when holding command. I don’t know what they’re trying to do, but they undo all the work of mapping that and return keyboard shortcuts to Dvorak. Same thing with the built-in Dvorak-QWERTY layout.

For future reference, I just want to say I managed to accomplish what I needed to with a combination of Keyboard Maestro and Ukelele. I created the Programmer DVORAK layout in Ukelele, but didn’t bother making the Control/Command keys return the layout to QWERTY. I then used the “This Device Key” released and down triggers to toggle to the US keyboard layout while Control and Command are down.