-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Prompt / Newline Bug in Firefox #6
Comments
I just noticed the following:
|
xterm.js is just an xterm clone in JavaScript. That means that there is no underlying logic, like a Bash or Zsh interpreter — it just receives and prints characters with some additional functionalities (like cursor displaying, column and rows resizing etc.). It's demo page just showcases some of its basic functionalities.
No this is not the expected behavior, despite the fundamental nature of the demo page, so this will be fixed ASAP.
The ` character works fine in USA and UK layout in ISO keyboard. I will investigate this further for the german layout, but I do not own a German keyboard to test this out.
This would introduce additional logic, that is relevant to the underlying interpreter. There is no reason such logic should exist in the demo page.
The same thing applies here as well. |
Hey, thanks. Can I help somehow with the german keyboard layout? |
Output of xev when pressing ´ once. To appear in Linux I have to press the key twice. Does that help? KeyPress event, serial 37, synthetic NO, window 0x3200001, KeyRelease event, serial 37, synthetic NO, window 0x3200001, |
ah sorry, and the inverse (which is the key that i need - I have to press shift+´ (so hold shift and press ´ twice. that's in xev: KeyPress event, serial 37, synthetic NO, window 0x3200001, KeyPress event, serial 37, synthetic NO, window 0x3200001, |
Can you run the following line of JavaScript in the console of your browser (when viewing the demo page) and tell me the number printed, when entering the "`" character? term.on('key', function (key, e) {console.log(e.keyCode)}) P.S. Operating System, browser and browser version would be extremely helpful as well. |
Hey, Linux Mint, Firefox 32.0 as stated above. You might consider changing the following line in your demo
to
keyIdentifier is empty/does not exist there (at least not in firefox). See: https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent hence that if is never used. You might as well, consider to use ev.which instead of ev.keyCode because for some keys keyCode will be 0 and charCode would return something (that is the case if I for example type in qwertz - e.keyCode is 0, while e.which shows the correct number). However, back to the problem: That returns nothing. As if it was never reached; that might be related to something else (I tried using which, keyCode, charCode - I also tried without xterm.js in an input field. It seems that key is not identifiable using javascript) - I'll investigate further and will let you know. |
Adding support for emoji input
Only apply the selection hack for the WebGL renderer
If you open up the demo page in Firefox (32.0 in Linux Mint) and you hit the enter key there is no newline, instead everything is written on the same line. In Chrome it does work as expected, though.
The text was updated successfully, but these errors were encountered: