Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a problem with text encoding in konsole (I also tried xterm, things are the same) (Kubuntu 13.04, KDE). Here is the sample output:

oleg@PrizoffN:~$ gg
gg: \u043a\u043e\u043c\u0430\u043d\u0434\u0430 \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d\u0430

(Here gg is just random characters, so the answer should be command not supported or something like this)

oleg@PrizoffN:~$ sudo apt-get install krusader
[sudo] password for oleg: 
?????? ??????? ???????... ??????
?????????? ?????? ????????????       
?????? ?????????? ? ?????????... ??????
??? ??????????? ????? ????? ?????? krusader.
????????? 0, ??????????? 0 ????? ???????, ??? ???????? ???????? 0 ???????, ? 0 ??????? ?? ?????????.

oleg@PrizoffN:~$ uname -a
Linux PrizoffN 3.8.0-19-generic #29-Ubuntu SMP Wed Apr 17 18:16:28 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

Not sure why it is so... What can be done here?

In the same time, all is working well in pure console mode (If I press CTRL+ALT+F1)

Update: here is useful data:

oleg@PrizoffN:~$ locale
LANG=en_US.ISO-8859-1
LANGUAGE=en_US:ru:en
LC_CTYPE="en_US.ISO-8859-1"
LC_NUMERIC="en_US.ISO-8859-1"
LC_TIME="en_US.ISO-8859-1"
LC_COLLATE="en_US.ISO-8859-1"
LC_MONETARY="en_US.ISO-8859-1"
LC_MESSAGES="en_US.ISO-8859-1"
LC_PAPER="en_US.ISO-8859-1"
LC_NAME="en_US.ISO-8859-1"
LC_ADDRESS="en_US.ISO-8859-1"
LC_TELEPHONE="en_US.ISO-8859-1"
LC_MEASUREMENT="en_US.ISO-8859-1"
LC_IDENTIFICATION="en_US.ISO-8859-1"
LC_ALL=

Update 2:

I was able to restore locale to its normal state by executing

LANG=en_US.utf8

But this was only temporary result. On konsole restarting locale is set back to its ISO-8859-1 value. How can I store this permanently?

I also found this file:

oleg@PrizoffN:~$ cat .kde/env/setlocale.sh 
export LANG=en_US.utf8
export LANGUAGE=en_US:ru:en

where LANG was originally set to ISO-8859-1. I changed it to utf8 without any effect.

UPDATE 3:

After rebooting, locale returned to its normal state. So, no more problems.

share|improve this question
    
on ubuntu 12.x or 13.04 ? what did you to facing local problem did you change system fonts ? –  Hany Alsamman Apr 28 '13 at 19:58
    
13.04; What did I do before facing problem... Can't say for sure... Definitely it were not any new fonts, just played with locales.. it seems while installing packages with apt-get they report warning about absence LC_ALL value... Can't say for sure now –  Prizoff Apr 28 '13 at 20:50

1 Answer 1

up vote 2 down vote accepted

I am using a fresh installation of Kubuntu 13.04.

After installing the Russian locale and rebooting, I had the same problem. It was indeed due to the mismatch of the locale name in .kde/env/setlocale.sh.

So repeating the workaround:

LANG=en_US.ISO-8859-1 =>>>
export LANG=en_US.utf8

and then rebooting fixed the problem totally!

Funny enough I've understood that there is a problem in the first place not in the konsole (this symptom is well present), but while browsing the data with Dolphin and seeing that all Russian-encoded files were abracadabra-named.

share|improve this answer
    
Let it be the accepted answer :) –  Prizoff Jun 12 '13 at 20:05

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.