Quickly Position Text Cursor Behind Typed Character

(This macro was inspired by this macro)

Purpose of this macro:

Provide a way to quickly position the text cursor behind a typed character for all multi-line input fields and editors that don't have a feature to do so.

MacVim and Emacs have a keyboard shortcut to quickly position the text cursor behind a typed character. This macro mimics this feature.

First you have to create a macro group Keypress Identifier and disable it. In this macro group you place exactly one macro, Set variable targetCharacter:

And the macro Set variable targetCharacter to read the hotkey pressed:

In any other macro group you create the macro Position cursor behind entered character that enables and disables the macro group Keypress Identifier and processes the variable targetCharacter:


Position cursor behind entered character.kmmacros (8.6 KB)
Set variable targetCharacter.kmmacros (9.4 KB)

Operation:
Press the backtick key at the left of the space bar to trigger the macro, and then press a letter, 9, 0, comma, forward slash, dash or the single straight quote key to navigate to the first occurrence of this character. (9 and 0 stand for “(“ and “)” respectively.)

Demo:
1

1 Like