konsole/gnome-terminal/xterm, UTF-8 and backspace

Doncho N. Gunchev mr700 at globalnet.bg
Wed Dec 8 13:51:19 UTC 2004


    Hello,
    when a shell/python script reads input from the user in konsole and
gnome-terminal it I enter non-ascii characters (ex: "Проба", "Test" in
English) backspace does not work correct. For example:
--- cut ---
$ echo -n "Test: "; read a; echo "[$a]"
Test: Проба
[ You can paste this, then hit backspace 4 times to get the next line ]
Test: П
[ Press Enter here and you get ]
[Про]
$ _
--- cut ---
    If I erase one character I get '[Проб�'
    Text editing in bash and mc works, but in python 'starts to erase'
the '>>> ' prompt. In xterm instead of cyrilic letters I get spaces.
I wanted to enter a bug, but I don't know against what to. Looks like
backspace erases single bytes, while these letters consist of 2. Can
someone direct me and confirm it?

-- 
Regards,
  Doncho N. Gunchev    Registered Linux User #291323 at counter.li.org
  GPG-Key-ID: 1024D/DA454F79                        http://pgp.mit.edu
  Key fingerprint = 684F 688B C508 C609 0371  5E0F A089 CB15 DA45 4F79




More information about the devel mailing list