Linux make return + = ctrl-

I want my return key to act like normal return when pressed alone, but act like control (ctrl) when pressed with another key.

Example: Pressing + c = ctrl-c

What tools would I use to configure this?

0

1 Answer

What you want is not practical.

(1) There is no logic in the keyboard driver to make a key dual purpose like you want.
A key is either a modifier or it generates a character.
A key cannot do both functions.

(2) The normal response of the Enter key would have to be radically changed to function as you describe.
Normally as soon as you press the Enter key, the keystroke for a return character is registered, displayed, and acted on.
All that happens before the Enter key is released, and before any other key press that you want to combine.

So in your scheme, what should the keyboard driver do when the Enter key is pressed?
Should it wait for another key to be pressed or generate the return character?
Any delay in generating the return character will probably confuse the user.

Alternate solution: Use the Ctrl key.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like