Differences

This shows you the differences between two versions of the page.

Link to this comparison view

en:howtos:utf8en [2009/04/17 22:49] (current)
Line 1: Line 1:
 +===== UTF-8 in PLD =====
 +
 +
 +==== Console configuration ====
 +Many of you probably heard about UTF-8 and tried to set it, but encountered a number of problems.
 +In this tutorial we will try to show you how to set your locale to use UTF-8 encoding.
 +
 +First of all, we edit **/​etc/​sysconfig/​i18n** to look like that:
 +
 +<​file>​
 +# If you feel brave, or don't ever plan to use text console
 +# you can set locale to Unicode
 +LANG=en_EN.UTF-8
 +
 +# list of supported locales
 +SUPPORTED_LOCALES="​en en_EN.UTF-8/​UTF-8 en_EN/​ISO-8859-1"​
 +</​file>​
 +
 +Next, we have to set our console. We edit **/​etc/​sysconfig/​console** we change:
 +
 +<​file>​
 +#​CONSOLEFONT=ter-v14n
 +CONSOLESCREENFONTMAP=lat2u
 +CONSOLEMAP=8859-1
 +</​file>​
 +
 +to:
 +
 +<​file>​
 +CONSOLEFONT=ter-v14n
 +CONSOLESCREENFONTMAP=
 +CONSOLEMAP=
 +</​file>​
 +
 +Now we need to install: **terminus-font-console** . We use our all-time-favourite package manager - [[ http://​linuxvideo.generatedcontent.com/​wp-content/​uploads/​2006/​11/​001-poldek.ogg|poldek ]]:
 +
 +  poldek -i terminus-font-console
 +
 +To make sure the **man** pages are correctly displayed we need to install **glibc-localedb-all** using almighty poldek:
 +
 +  poldek -i glibc-localedb-all
 +
 +Next thing would be **reboot** to make sure all locale is correctly set, after that you should have working UTF-8 encoding in your beloved PLD.
 +
 +Please note that not all programs are capable of using UTF-8 however. If you use some old program, chances are that it does not support this, fairly new, standard.
 +This tutorial was designed for Th/Ti PLD. If you are using older PLD  (for example 2.0 (Ac), which we strongly suggest to update to [[ http://​pld-linux.org/​ThInfo | Th]] or [[ http://​pld-linux.org/​Titanium | Ti]] ) you will for sure have 
 +problems with man and mc. In order to fix this, you need to update to versions from Th (download from ftp.th.pld-linux.org).
 +
 +
 +
 +==== Additional config ====
 +
 +If you use **gnu screen**, and it clearly does not want to cooperate with UTF-8, you will have to edit **~/​.screenrc** and add:
 +
 +  defutf8 on
 +
 +Unfortunately this requires **screen** restart.
 +
 +If you have working UTF-8 on your machine, but other encoding on a remote host, where you cannot change it, you need to edit  **~/​.profile** and add:
 +
 +  LANG=en_EN.UTF-8
 +  LC_ALL=en_EN.UTF-8
 +  export LANG LC_ALL
 +
 +And it should work just fine.
 +
 +
 +==== Tools ====
 +
 +* ''​convmv''​ - program which you can use to change encoding of file and directory names. Below an example showing how to change ISO-8852-2 to UTF-8:
 +  $ convmv --notest -f iso8859-2 -t utf8  żółw/
 +
 +==== Author ====
 +
 +This tutorial is a translation of [[ http://​pld-users.org/​pl/​przewodniki/​utf-8|Polish one]] made by paszczus
  
en/howtos/utf8en.txt · Last modified: 2009/04/17 22:49 (external edit)
chimeric.de = chi`s home Creative Commons License Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0 Powered by Lighttpd - fly light