Forums

Polish letter in bash

I can't write polish letters in bash, when I choice letter and right ALT I heard sound and don't write any polish letter :/

Hi there,

I think this may something to do with hterm's alt-key configuration (see this faq, under "How do I send accented characters?").

Let's try an experiment. If you open a console, and then add /frame/ to the end of the url (eg https://www.pythonanywhere.com/user/username/consoles/bash/1234567/frame/). Then, open up the javascript debug console (tools->developer->browser console in ff, similar in chrome), and try a couple of the alternatives:

Anywhere.terminal.prefs_.set('alt-sends-what', '8-bit')

then try typing an alt-key combination into the console. if that doesn't work, try:

Anywhere.terminal.prefs_.set('alt-sends-what', 'browser-key')

Let us know if either of them work? we may be able to reset the default, or allow it to be user-configurable...

I do this but when I am on (tools->developer->browser console)

I try it like below and it's nothing better :/

"Bold characters disabled: Size of bold weight differs from normal. Font family is: "DejaVu Sans Mono","Everson Mono","FreeMono","Menlo","Lucida Console","Terminal","monospace"" hterm_all.js:10048 Anywhere.terminal.prefs_.set('alt-sends-what', '8-bit')

undefined Anywhere.terminal.prefs_.set('alt-l', '8-bit')

Error: Unknown preference: alt-l Anywhere.terminal.prefs_.set('alt-sends-l', '8-bit')

Error: Unknown preference: alt-sends-l term_.prefs_.set('alt-is-meta', true)

OK, so after you do the

Anywhere.terminal.prefs_.set('alt-sends-what', '8-bit')

You should go back to the pythonanywhere console, and try and type your character?

Whta I must write on console, I use UTF-8 for Polish charset

type whichever alt-key combination wasn't working before?

to summarise:

  1. open a pythonanywhere Bash console
  2. add /frame/ to the URL
  3. try and type a letter using right-alt key.
  4. if it doesn't work, open up the developer tools, and run Anywhere.terminal.prefs_.set('alt-sends-what', '8-bit')
  5. click back into the pythonanywhere Bash console, and try your right-alt-key combination again
  6. does this now work? does it do something different?
  7. if not, go back to the developer tools, and run Anywhere.terminal.prefs_.set('alt-sends-what', 'browser-key')
  8. Now click back in the bash console, and try the right-alt-key combination again
  9. Now, does this change anything?

I do this like You said in points but it not work.

If anybody do this I am wonder how...

OK, I'll experiment with switching my keyboard to the polish layout. Can you tell me an example of alt-key combination (which letter i have to press), and which letter you expect to see?

Ok

Try with this

alt+l = ł alt+o = ó alt+n = ń

Interesting. So for me, those just work, out of the box, without having to change anything in the developer tools, in both Firefox and Chrome....

screenshot

Which OS are you on? And which browser are you using?

[1]:

I dont't know why, below is my print screen when I try alt+l a cursor is flashes and in www console of browser is message like in print screen link

Can you try a different web browser, or another operating system? Which ones are you using?

I try now on Win XP with Mozilla and in my Win 8 on Mozilla and Opera and nothing changed :/

If I give You my login and password could You check it in Your computer?

No need, we administrators can see everyone's consoles if we need to. If you look in your bash console you'll see I was able to type some ł's...

I will start a windows VM and see if it's a windows problem. I'm on linux.

OK, I can confirm I can reproduce the bug on windows. We'll see if it's something we can fix, otherwise we will raise a ticket against the upstream chromium project.

Thanks very much for reporting it, and thanks for persisting with your bug report :)

I sow Your text, ok...

I am glad to help, and good to know that It's not my defect od knowladge :)

Hello guys, I experience similar problems with my German and Portuguese keyboards. Alt key does not work. I tried the suggestion of Harry and setting 'alt-sends-what' to 'browser-key' improves the situation. The only keys not working where the compose keys. This is consistent for both keyboards. Reading through the docs of hterm i also found that this solves my foreground- and background-color problem (see vim thread). It seems the change is permanent. However a new problem is introduced: Next time I am unable to connect to my console anymore, because the browser rejects the connection for cross domain manipulation. I have to kill the console which kind of defeats part of the purpose of PA :-x. So as a quick fix I would suggest a config file in the home directory (.anywhererc) where the user can enter his settings (JSON format would be natural). Then you could work on a tab to make it easier to change things for less experienced users. I would also suggest someway of beta access for these kind of things. You will get additional user manpower in testing. What do you think?

That's a great idea! I'll add it to our tracker.

Hi there, anyone struggling with Polish, German, Portugese or other non-English keyboard layouts, we just released an experimental fix. Let us know if you would like us to switch it on for your account?