Control- U, H, J, K
Closed this issue · 3 comments
The GNU-style Emacs keybindings, default in Bash, are deeply ingrained into my mind. Control- K: cut to end of line, U: cut to start of line, H: delete backwards,
I have faint memories of using those keys on my //c as shortcuts to arrow keys. Control- H: left, J: down, K: right, and U: up. I turned on the printf debug lines and watched xev, and it appears that the arrow keycodes are being sent. The translation might be happening in the ROM, but I wouldn't know. Could it be in the a2pi.s assembly code? Could provision be made to turn off the arrow keys on h, j, k, and u: sending the Control-L keycodes and letters instead?
Is it possible to make things act more raw, so GNU/Bash and Emacs will work properly?
I think I got it. They're actually mapped to arrows in kbmap.h. Changing them back to control scancodes did the trick. Here's a patch of what I did:
file-kbmap-revert-control-keys-patch
Please consider making this change in the master branch.
Oh, sigh. That change ended up changing the arrow keys themselves, too. Do the arrow keys not have their own scancodes? It'd be sad if that is truly the case.
Sorry, the arrow keys are mapped to control codes in HW. Such is life with a 35 year old ASCII keyboard.
left arrow: ctrl-H
right arrow: ctrl-U (oh, why couldn't it be ctrl-L?)
up arrow: ctrl-K
down arrow: ctrl-J
Dave...