Previous Next Contents

3. Display and application setup

Most applications need to be compiled as ``8-bit-clean'' to work well with European characters. Some need a few extra hints to get it right.

3.1 Loading the Latin-1 character set on the console

Execute the following commands under the bash shell:

setfont lat1-16.psf
mapscrn trivial
echo -ne '\033(K'
You could also choose to load the font as unicode to ensure that lines are displayed correctly in programs such as mc and workbone. Execute the following commands to do that:
setfont lat1-16.psf
loadunimap lat1.uni
echo -ne '\033(K'

If you use Linux kernels v1.3.1 or higher, you do not need the echo command when you load the font as unicode.

Note: This only has effect under plain Linux.

3.2 Characters you can display under Linux

Type dumpkeys -l | less at the prompt to find out which characters that are readily available. You can map them to your keyboard via the keymap files mentioned in section Loading a keytable.

3.3 International character sets in specific applications

A number of applications demand special attention. This section describes how to set up configuration files for them.


Put the following in your ~/.inputrc file:

set meta-flag on
set convert-meta off
set output-meta on


Put the following definitions in your ~/.elm/elmrc file:

charset = iso-8859-1
displaycharset = iso-8859-1
textencoding = 8bit
This may not work on some versions of elm.


Put the following in your ~/.emacs or the the system-wide initialization file (probably /usr/lib/emacs/site-lisp/default.el or /usr/share/emacs/site-lisp/default.el):

(standard-display-european t)
(require 'iso-syntax)
(set-input-mode (car (current-input-mode))
        (nth 1 (current-input-mode))
You can leave out the first two of the lines above if you have installed locale support, and your LC_CTYPE environment variable includes one of the strings 8859-1 or 88591. See section Locale support in libc 5.4.x for some information on locales.

Dead keys should work under GNU emacs provided you use GNU emacs v19.30 or higher and XFree86 v3.1.2 or higher (it works for me anyway,) so do not start researching available elisp packages implementing ``electric keys'' or anything like that. If you want to implement European keyboard conventions in emacs without upgrading, the best choice is probably the remap package available from the SunSite DK server (see section FTP and Web sites.) There are also two packages called iso-acc.elc and iso-trans.elc included with emacs that has similar functionality, but they are not nearly as powerful.


Issue the command as

groff -Tlatin1 <your_groff_input_file>
Remember to change this in /etc/man.config to get latin1 characters working in man (don't remove the -mandoc switch.)

ispell --- Spell checking in Danish:

First make sure that you install version 3.1 instead of version 4.0 of ispell. The latter is obsolete and multiple brain-damaged. You can download the sources for ispell at the GNU archive at, and you can get a Danish dictionary via FTP from Aalborg University Center. Follow the compilation instructions and you should have no trouble (One caveat: When defining the variables necessary for compilation you must tell ispell that Linux is a SysV type OS by defining the variable USG.)

When you have installed the Danish dictionary for ispell you can check the spelling of a Danish language file by executing the command:

ispell -d danish -T latin1 -w "æøåÆØÅ" <your_danish_text_file>

(Note for non-Danish readers: You can find dictionaries for most Western languages by reading the file Where included with the sources for ispell.)


Issue the command as

joe -asis
or put the following in your ~/.joerc file:
The hyphen character must be in the first column.


This is as close as I can get, but not completely satisfying yet. Put the following in your ~/.kermrc file:

set terminal bytesize 8
set command bytesize 8
set file bytesize 8
set language danish
set file character-set latin1-iso
set transfer character-set latin1-iso
set terminal character-set latin1-iso
I think there are more variables to set, but they are hiding. You would have to modify these settings if the remote system is DOS or OS/2 based.


Set the following environment variable:



Issue the command as

ls -N
or possibly
ls --8bit


Put the following definition in your ~/.lynxrc file:

character_set=ISO Latin 1
This can also be set via the Options menu in lynx. Type `o' and set the relevant option.


See entry for groff in this section.


Set the following environment variable:



Put the following in your ~/.nn/init file:

set data-bits 8


Put the following definition in your ~/.pinerc file:

This can also be set via the Setup, Config menu option in pine.


Issue the command as

rlogin -8


Put the following in your /etc/csh.login or ~/.tcshrc file:

setenv LANG C
Actually you just have to define one of the environment variables LANG or LC_CTYPE. The value does not matter. Read the tcsh man page for more information.


Put one line of the following type in your ~/.telnetrc file for each host you want to log on to using telnet:

<hostname> set outbinary true
localhost set outbinary true set outbinary true


There are several problems with TeX/LaTeX: You want LaTeX to understand the special characters and you do not want LaTeX to put in English words like ``Chapter'' at the beginning of every chapter or use English typesetting conventions.

Under LaTeX2e the header of your input file should look something like this:



The first usepackage statement ensures that LaTeX will interpret European characters correctly, so you do not have to use escape codes for European characters. The second is not strictly necessary; but it is recommended to include it to use the DC fonts (which of course must be installed.) The DC fonts should soon be replaced by the newer EC fonts. These two packages are most likely included in your LaTeX distribution. The last usepackage statement defines a range of standards for typesetting Danish texts.

If you use the Debian distribution (or older Slackware) you will have to install Danish hyphenation tables yourself (dansk: ``hyphenation''=``orddeling''.) These are available from Aalborg University Center. The files you need are dkhyphen.tex, dkcommon.tex and dkspecial.tex. If you use the teTeX distribution (distributed with e.g. Red Hat and S.u.S.E.) you already have the relevant files. Essentially you need to put these into the directory containing international hyphenation tables, edit the appropriate language dependency file (usually called language.dat) and finally rebuild LaTeX with initex. Before you do anything, please make sure you know what files you are changing and back them up in advance.

If you use NTeX (distributed with the Slackware distribution) you will have a configuration script called ntm-ltx.cfg located in /usr/lib/texmf/tools/. In that case put the hyphenation tables in the the relevant directory (most likely called /usr/lib/texmf/tex/hyphenation/) and run the script. It will guide you through the various steps described below. If you use teTeX there is a somewhat more advanced program called texconfig to help you.

Below is a description for enabling Danish hyphenation by hand. If it looks vague it is because TeX/LaTeX installations differ very much in their choice of path-names.

  1. Find out where you have the hyphenation tables. Under NTeX they are in /usr/lib/texmf/tex/hyphenation/, under teTeX in /usr/lib/texmf/texmf/tex/generic/hyphen/. Try issuing the command find /usr/lib/ -iname '*hyph*' -print if you cannot find the directory.
  2. Check if the hyphenation tables are already there. If not put the hyphenation tables mentioned above in this directory.
  3. Edit the file (probably) called language.dat. In the teTeX distribution you can just uncomment the appropriate line. Otherwise insert a line reading
    danish dkhyphen.tex
    If you have difficulty finding language.dat try issuing the command find /usr/lib/ -name language.dat -print
  4. Find and back up the file latex.fmt. It could be in a variety of places. Use find /usr/lib/ -name latex.fmt -print to find it.
  5. Go to the directory where you found latex.fmt. Issue the command initex latex.ltx. Pray. If everything went well you now have a new version of latex.fmt.
  6. You can now use
    in your LaTeX headers. Hyphenation should be reasonably correct, quotation marks follow Danish conventions, chapters are now called ``Kapitel'' instead of ``Chapter'' etc.

All new Linux distributions now includes LaTeX2e.

(Note for non-Danish readers: The process is similar for other Western European languages, and the necessary files are normally included in the Linux distributions.)

In LaTeX 2.09, use

to include support for ISO-8859-1 characters and European paper sizes.

isolatin.sty is available from all DANTE servers (see section FTP and Web sites) and from Michael Gschwind's FTP site. It should also be included in the standard Linux distributions.

Note: Some people prefer using emacs in a special mode which translates ``special'' letters into TeX escape codes, but this method should be obsolete by now.


Put the following definitions in your ~/.tin/headers file:

Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
Now you can post messages with the proper Danish characters in the message body.

Previous Next Contents