Re: step by step HOWTO switch debian installation into utf-8
On Fri, Aug 31, 2001 at 11:15:03PM +0200, Radovan Garabik wrote:
> So I decided to write this small HOWTO describing how
> I changed my encoding to UTF-8 and the problems I encountered
> and solved (or not solved).
>
> The document is at:
> http://melkor.dnp.fmph.uniba.sk/~garabik/debian-utf8/HOWTO
Nice work! Some comments:
>Preparing correct locale:
>Pick a locale you would use. I decided to use en_GB,
>you may use something else, the important part is the
>UTF-8 encoding.
>1) generate the locale:
># localedef -v -c -i en_GB -f UTF-8 /usr/lib/locale/en_GB.UTF-8
Isn't the "correct" approach to define
en_AU UTF-8
in /etc/locale.gen, and run locale-gen?
>mutt:
>mutt should be able to figure out you are using utf-8 from your
>locale, you can force it by putting
>set charset="utf-8"
>into /etc/Muttrc, and if incoming mails have correct headers,
>they will be displayed correctly
mutt is cool that way! No I can see your accents properly :) And some
chinese characters too sometimes! I just hope ncurses gets released
soon with proper utf-8 support!
>(unfortunately, many mails (especially
>those originating in Russia) claim to be in incorrect encoding,
>mostly in iso-8859-1 - there is nothing to be done, except of
>saving the message and converting it with konwert or iconv)
I use recode for this :)
>Prepare locale:
>create directory /usr/X11R6/lib/X11/locale/en_GB.UTF-8
>copy XLC_LOCALE from /usr/X11R6/lib/X11/locale/en_US.UTF-8 into
>this directory.
Is this a typo? You're referring to the same directory twice.
(my system seems to work fine without this step, by the way)
>If you want to input non-ascii characters, you need compose map.
>Unfortunately, compose maps provided with xfree86 are somewhat insufficient.
An alternative approach is to have something like
Option "XkbLayout" "ru"
Option "XkbOptions" "grp:menu_toggle"
in /etc/X11/XF86Config-4. (ru can be replaced with the non-qwerty keyboard
of choice, I gather). grp:menu_toggle here means the Windows key can be
used to switch between, for example, qwerty and йцукен (russian) key layouts.
Other keys can be used instead for the toggle key, I forget the exact syntax.
This also works for switching to a greek keyboard, for example, or thai,
or whatever, and can be used to access special symbols when using a western
european keyboard, e.g. de qwerty when toggles gives @ł€¶ŧ←. So it's
like a kind of compose key.
>In theory, xterm should recognize utf-8 locale by itself, but
>it does not work for me, so you have to use -u8 option:
It works for me without the -u8 option (X 4.1.0).
>KDE (and all KDE applications) does not display unicode characters.
They can display at least partially in Gnome, at least I can see russian in
irssi, though only in the display window, not the input window.
Gnome also offers gkb, a keyboard switcher which is able to toggle
between a large number of different keyboard layouts. Here's a sample
(prepared via vim 6. It rules!):
qwer english (alternate european latin keyboards are available)
йцук russian
タテイス japanese (only one qwerty keyboard's worth, not very useful I
guess)
ๆไำพ thai
;ςερ greek
/'קר hebrew
Is it worth mentioning in the HOW-TO that the fixed font for UTF-8 is
-Misc-Fixed-Medium-R-SemiCondensed--13-120-75-75-C-60-ISO10646-1 ?
(although you don't need to specify it for xterm to work). But other X
terminals probably don't support it yet. Eterm doesn't.
This was prepared from mutt with vim 6 as editor, running in an xterm.
Drew Parsons
--
PGP public key available at http://dparsons.webjump.com/drewskey.txt
Fingerprint: A110 EAE1 D7D2 8076 5FE0 EC0A B6CE 7041 6412 4E4A
Reply to: