-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
invalid character input after ctrl+g input #74
Comments
Normal invalid commands do display nothing. Your bug won't be seen during normal usage because it doesn't happen with any of the normal keys, only special keys like the arrow keys and the F keys. The reason this is happening is that the terminal representation for the arrow keys is longer than just one character. You can figure this out by doing
where To mtm, |
This annoyed me as well. Any keys you type that don't have I propose a three-part fix. I already wrote it in my fork of the repo, and tested it a little bit. But I'd like other people's opinions.
|
Proposed fix: 1. When you have not typed the command character, and you type any unhandled special key, such as F20 or clear all tabs or help, mtm ignores it. 2. When you have typed the command character, and you type any unhandled key (special or not), mtm cancels the command. 3. Then the BAILOUT key becomes unnecessary because all unknown keys bail out. (So the code and the configuration files should not define it.) And the manual should say explicitly that all unknown keys bail out. Cleanup: Added blank lines, removed extra semicolons, changed comma operator to two separate statements.
if you enter ctrl+g and press by mistake, for example, F1, then ĉ will be entered into the terminal. The bug was discovered when i replaced default navigation keys with wasd in the config. The characters A/B/C/D were entered into the console when i pressed the arrows by mistake. I would like that when entering an invalid command, nothing would be printed.
The text was updated successfully, but these errors were encountered: