
UTF-8 ENCODING

Attention: this document includes the excerpts encoded in UTF-8.  If your
system does not use that encoding you can customize it in the following way.

First you have to configure LILO or GRUB.

If you use LILO then modify append entry in /etc/lilo.conf as follows:

   append="vt.default_utf8=1"

and run lilo command.

If you use GRUB then edit /boot/grub/grub.cfg to load gettext module just
below setting the lang entry:

   set lang=en_US
   insmod gettext

and run grub-install /dev/sda command or the other appropriate in your case.

Next add to /etc/profile.d/lang.sh or /etc/default/locale file the following
line:

   export LANG=en_US.UTF-8

(Instead of en_US above you can use the other locale setting according to
the expected system language.)

Finally restart the system and run the terminal using the font in iso10646-1
encoding, for example:

   xterm +sb -bg black -fg white -geometry 99x49+64+0 -fn -misc-fixed-medium-r-normal--15-140-75-75-c-90-iso10646-1

After the switching to UTF-8 you may want to convert directories and files
names to UTF-8.  To convert directories nad files names in Linux to and from
UTF-8 use convmv program, for example:

   convmv -f iso-8859-1 -t utf-8 filename

                                      *
                                    *   *

If your system is customized to use UTF-8 it displays properly filenames
that use that encoding.  Unfortunately not all programs understand it.  The
same with the audio tags.  The following tables sum up the tests performed
in different systems and on different devices using audio files in MP3, OGG,
and FLAC formats that use directories and files names as well as audio tags
in Polish and Russian.

   Linux *       | UTF-8
   --------------+----------------------------------------------
   console       | partial support -- depending on the used font
   xterm **      | yes
   Amarok        | yes
   Audacious     | yes in OGGs and FLACs; no in MP3s
   Banshee       | yes
   JuK           | yes
   MOC           | yes
   XMMS          | no
   --------------+----------------------------------------------
    * Used with LANG=en_US.UTF-8 or similar locale setting.
    ** Used with the font that offers iso10646-1 encoding.

   Windows       | UTF-8
   --------------+----------------------------------------------
   Explorer      | Both Windows Vista and Windows 7 displayed
   Media Player  | UTF-8 encoded filenames and Media Player
                 | displayed UTF-8 encoded tags properly (Media
                 | Player does not recognize FLAC audio files).
                 |
                 | On the other hand the tests performed on
                 | Windows 7 Professional failed because it was
                 | unable to display filenames in UTF-8.  Since
                 | there is a lot of versions of Windows the
                 | rule of thumb is you should test filenames
                 | and tags encoded in UTF-8 with your version
                 | of Windows yourself.
                 |
                 | Windows XP installed in VirtualBox using
                 | VBoxGuestAdditions displayed UTF-8 encoded
                 | filenames stored in shared folders properly.
                 | The same with these folders copied to Windows
                 | XP "My Documents" folder.  Media Player
                 | provided with Windows XP recognizes only MP3
                 | files and displays UTF-8 encoded tags
                 | properly.  Unfortunately the embedded Windows
                 | XP unzip tool does not interpret file names
                 | encoded in UTF-8 properly.
                 |
                 | If you encounter any problems you can try to
                 | use mounted shares.  The following
                 | information is taken from JinzoraWiki:
                 |
                 | Modern windows versions support UTF-8 on
                 | mounted shares.  Make a share of your
                 | mediafolder and mount it as a network drive.
   --------------+----------------------------------------------

   Android       | UTF-8
   --------------+----------------------------------------------
                 | yes
   --------------+----------------------------------------------

   devices       | UTF-8
   --------------+----------------------------------------------
   iPod Touch 2  | yes (iTunes recognizes only MP3 audio files)
   Nokia 6300    | yes (it recognizes only MP3 audio files)
   Nokia C2-01   | yes (it recognizes only MP3 audio files)
   Kindle Touch  | no (it recognizes only MP3 audio files)
   --------------+----------------------------------------------

The bottom line is that some Windows versions have problems with the
directories and files names using UTF-8 encoding and that the only universal
audio format is MP3.

                                      *
                                    *   *

In order to test UTF-8 encoding in directories and files names as well as in
audio tags you can download the following archive:

   http://linux-bsd-unix.strefa.pl/UTF-8.zip

It includes one second long audio sample taken from John Fahey's song
``Voice Of The Turtle'' from ``America'' album, converted to MP3, OGG, and
FLAC formats, renamed to English, Polish, and Russian, and tagged with
settags script from cdwrite package.

The archive includes three directories and each directory includes three
files:

   Różni artyści - Składanka [Polish, 2012]
   01 Żółw I.mp3
   01 Żółw II.ogg
   01 Żółw III.flac

   Various Artists - Medley [English, 2012]
   01 Turtle I.mp3
   01 Turtle II.ogg
   01 Turtle III.flac

   Разные артисты - Попурри [Russian, 2012]
   01 Черепаха I.mp3
   01 Черепаха II.ogg
   01 Черепаха III.flac

The directories and the files names do not correspond to the actual contents
of the archive because they are matched to use different diacritics and
alphabets.

Before you decide to use UTF-8 encoding for your audio files you can rename
one of these directories as well as included files using diacritics or
alphabet specific for your language, set tags using settags script from
cdwrite package, and test your system, programs, and devices to assure that
all of them work with UTF-8 encoding.


Copyright (C) 2012 Cezary M. Kruk <c.kruk@bigfoot.com>

