3 ## 14.5 Localizing DragonFly to Specific Languages
\r
5 ### 14.5.1 Russian Language (KOI8-R Encoding)
\r
7 ***Originally contributed by Andrey A. Chernov. ***
\r
9 For more information about KOI8-R encoding, see the [KOI8-R References (Russian Net Character Set)](http://koi8.pp.ru/).
\r
11 #### 14.5.1.1 Locale Setup
\r
13 Put the following lines into your `~/.login_conf` file:
\r
21 See earlier in this chapter for examples of setting up the [locale](using-localization.html#SETTING-LOCALE).
\r
23 #### 14.5.1.2 Console Setup
\r
26 * Add the following line to your kernel configuration file:
\r
28 options SC_MOUSE_CHAR=0x03
\r
30 Insert the following line into `/etc/rc.conf`:
\r
35 * Use following settings in `/etc/rc.conf`:
\r
38 scrnmap="koi8-r2cp866"
\r
39 font8x16="cp866b-8x16"
\r
40 font8x14="cp866-8x14"
\r
44 * For each `ttyv*` entry in `/etc/ttys`, use `cons25r` as the terminal type.
\r
46 See earlier in this chapter for examples of setting up the [console](using-localization.html#SETTING-CONSOLE).
\r
48 #### 14.5.1.3 Printer Setup
\r
50 Since most printers with Russian characters come with hardware code page CP866, a special output filter is needed to convert from KOI8-R to CP866. Such a filter is installed by default as `/usr/libexec/lpr/ru/koi2alt`. A Russian printer `/etc/printcap` entry should look like:
\r
53 lp|Russian local line printer:\
\r
54 :sh:of=/usr/libexec/lpr/ru/koi2alt:\
\r
55 :lp#/dev/lpt0:sd/var/spool/output/lpd:lf=/var/log/lpd-errs:
\r
58 See [printcap(5)](http://leaf.dragonflybsd.org/cgi/web-man?command#printcap§ion5) for a detailed description.
\r
60 #### 14.5.1.4 MS-DOS® FS and Russian Filenames
\r
62 The following example [fstab(5)](http://leaf.dragonflybsd.org/cgi/web-man?command#fstab§ion5) entry enables support for Russian filenames in mounted MS-DOS® filesystems:
\r
65 /dev/ad0s2 /dos/c msdos rw,-Wkoi2dos,-Lru_RU.KOI8-R 0 0
\r
68 The option `-L` selects the locale name used, and `-W` sets the character conversion table. To use the `-W` option, be sure to mount `/usr` before the MS-DOS partition because the conversion tables are located in `/usr/libdata/msdosfs`. For more informations, see the [mount_msdos(8)](http://leaf.dragonflybsd.org/cgi/web-man?command#mount_msdos&section8) manual page.
\r
70 #### 14.5.1.5 X11 Setup
\r
72 1. Do [using-localization.html#SETTING-LOCALE non-X locale setup] first as described.
\r
73 **Note:** The Russian KOI8-R locale may not work with old **XFree86™** releases (lower than 3.3). **XFree86 4.X** is now the default version of the X Window System on DragonFly. This should not be an issue unless you explicitly install an older version of **XFree86** .
\r
74 1. Go to the [russian/X.language](http://pkgsrc.se/russian/X.language) directory and issue the following command:
\r
78 The above port installs the latest version of the KOI8-R fonts. ***'XFree86 3.3***' already has some KOI8-R fonts, but these are scaled better.
\r
79 Check the `"Files"` section in your `/etc/XF86Config` file. The following lines must be added ***before*** any other `FontPath` entries:
\r
81 FontPath "/usr/X11R6/lib/X11/fonts/cyrillic/misc"
\r
82 FontPath "/usr/X11R6/lib/X11/fonts/cyrillic/75dpi"
\r
83 FontPath "/usr/X11R6/lib/X11/fonts/cyrillic/100dpi"
\r
85 If you use a high resolution video mode, swap the 75 dpi and 100 dpi lines.
\r
86 1. To activate a Russian keyboard, add the following to the `"Keyboard"` section of your `XF86Config` file.
\r
87 For ***'XFree86 3.X***':
\r
90 XkbOptions "grp:caps_toggle"
\r
92 For **XFree86 4.X** :
\r
94 Option "XkbLayout" "ru"
\r
95 Option "XkbOptions" "grp:caps_toggle"
\r
97 Also make sure that `XkbDisable` is turned off (commented out) there.
\r
98 The RUS/LAT switch will be **CapsLock** . The old **CapsLock** function is still available via **Shift** + **CapsLock** (in LAT mode only).
\r
99 If you have ***Windows®*** keys on your keyboard, and notice that some non-alphabetical keys are mapped incorrectly in RUS mode, add the following line in your `XF86Config` file.
\r
100 For ***'XFree86 3.X***':
\r
102 XkbVariant "winkeys"
\r
104 For **XFree86 4.X** :
\r
106 Option "XkbVariant" "winkeys"
\r
108 **Note:** The Russian XKB keyboard may not work with old **XFree86** versions, see the [lang-setup.html#RUSSIAN-NOTE above note] for more information. The Russian XKB keyboard may also not work with non-localized applications as well. Minimally localized applications should call a `XtSetLanguageProc (NULL, NULL, NULL);` function early in the program. See [KOI8-R for X Window](http://koi8.pp.ru/xwin.html) for more instructions on localizing X11 applications.
\r
110 ### 14.5.2 Traditional Chinese Localization for Taiwan
\r
112 The FreeBSD-Taiwan Project has an I18N/L10N tutorial for FreeBSD at http://freebsd.sinica.edu.tw/~ncvs/zh-l10n-tut/ using many Chinese ports. Much of that project can apply to DragonFly. The editor for the `zh-L10N-tut` is Clive Lin. You can also cvsup the following collections at `freebsd.sinica.edu.tw`:
\r
115 | Collection | Description
116 outta-port tag=. | Beta-quality ports collection for Chinese
117 zh-L10N-tut tag=. | Localizing FreeBSD Tutorial in BIG-5 Traditional Chinese
118 zh-doc tag=. | FreeBSD Documentation Translation to BIG-5 Traditional Chinese |
\r
120 Chuan-Hsing Shen has created the [Chinese FreeBSD Collection (CFC)](http://cnpa.yzu.edu.tw/~cfc/) using FreeBSD-Taiwan's `zh-L10N-tut`. The packages and the script files are available at ftp://ftp.csie.ncu.edu.tw/OS/FreeBSD/taiwan/CFC/.
\r
122 ### 14.5.3 German Language Localization (for All ISO 8859-1 Languages)
\r
124 Slaven Rezic `<[mailto:eserte@cs.tu-berlin.de eserte@cs.tu-berlin.de]>` wrote a tutorial how to use umlauts on a FreeBSD machine. The tutorial is written in German and available at http://www.de.FreeBSD.org/de/umlaute/.
\r
126 ### 14.5.4 Japanese and Korean Language Localization
\r
128 For Japanese, refer to http://www.jp.FreeBSD.org/, and for Korean, refer to http://www.kr.FreeBSD.org/.
\r
130 ### 14.5.5 Non-English DragonFly Documentation
\r
132 Non-English documentation will be made available as it is created, at the [main site](../../../../index.html) or in `/usr/share/doc`.
\r
137 CategoryHandbook-localization
\r