8

I'm having some trouble with displaying UTF-8 characters correctly on bash. I was trying to extract some zipped files that contained accented characters in their names, and I was getting the invalid multibyte characters error. I created a .bash_profile with this:

export LANG=en_US.UTF-8
export LOCALE=UTF-8

This solved the extraction problem. But the console still doesn't show the accented characters correctly. Konqueror has no problem with the accented characters. What do I have to do?

  • 2
    What terminal are you running in? Do you mean the Linux console (i.e. outside X)? – Gilles 'SO- stop being evil' Jul 6 '11 at 18:12
  • I'm running it under X, with fluxbox, using tilda. – liewl Jul 8 '11 at 13:15
  • $ locale ``` LANG= LC_CTYPE="C.UTF-8" LC_NUMERIC="C.UTF-8" LC_TIME="C.UTF-8" LC_COLLATE="C.UTF-8" LC_MONETARY="C.UTF-8" LC_MESSAGES="C.UTF-8" LC_ALL= ``` – xgqfrms Mar 12 '17 at 8:55
15

Gnu Unifont has the widest unicode support. See What fonts are good for unicode glyphs.

Changing the console font (ie., outside X) can be done with the setfont command. Which takes the form: setfont /path/to/font, eg:

setfont /usr/share/kbd/consolefonts/$font

There is more information on the Arch Wiki: https://wiki.archlinux.org/index.php/Fonts#Console_fonts

Once you have selected your preferred font, setting the console font permanently will depend on your distribution. For example, in Ubuntu/Debian, it is:

sudo dpkg-reconfigure console-setup

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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