How can I create a custom key binding for moving the cursor to the middle of the current line using Karabiner Elements? Is there is any other way to do this? I can't find anything helpful.
Looking at the Karabiner-Elements manual, it doesn't appear that such a keyboard movement is supported. A program that accomplishes this would need to be aware of the full line of text you're typing, like a text editor is.
This answer shows how to accomplish this in Emacs with a custom function, and this answer shows how to accomplish this with a Vim mapping. Out of the box, both have a way to skip to the beginning and ends of lines (
$ in Vim,
C-e in Emacs). Both editors also support more advanced cursor movement options that can be used in context to move the cursor to arbitary positions.