[OS X TeX] non-english hyphenation in PlainTeX

Tom Koornwinder thk at science.uva.nl
Tue Nov 2 07:37:43 EST 2004


On 21 Oct 2004 17:36:23 +0200, Gianluca Gorni wrote:
> I have tried to migrate some old Textures PlainTeX documents
> to TeXShop &co., and I have run into a couple of prolems.
> 
> ...
> 
> More important: I have not been able to activate the Italian
> hyphenation. When I iInstalled gwTeX, I configured for Italian,
> and in fact Italian *LaTeX* is fine. Perhaps PlainTeX was not
> configured? Or was it? What shall I do?

I had similar problems with Dutch hyphenation in TeXShop.
With a lot of effort, and with the help of Gianluca Gorni, Bruno Voisin
and a script posted by Ros Moore (quoted in
http://www.tug.org/pipermail/xetex/2004-April/000030.html )
I managed to solve this problem.
In order that other people can fix it in less time, I report my solution here.

Step 1.
In /usr/local/teTeX/share/texmf.local/etex/plain/config/language.def
replace the line

%%% \addlanguage {German}{ghyph31}{}{2}{2}  %%% further such lines may be used;

by the line

\addlanguage {dutch}{nehyph.tex}{}{2}{2}

where {dutch}{nehyph.tex} can be replaced by analogues
for other languages, see
/usr/local/teTeX/share/texmf.tetex/tex/generic
for all available hyphenation files.

For this replacing you may need to login as superuser or use the sudo command.

By the way, there is also a language.def file in directory
/usr/local/teTeX/share/texmf.tetex/tex/plain/config
but changing anything in that file seems to be without impact.

Step 2.
Configure the TeX package in Gerben Wierda's I-Installer.
Use expert mode and let pdfetex be included in the configuring.
Check in the file
/usr/local/teTeX/share/texmf.local/web2c/pdfetex.log
that the correct hyphneation patterns with \language 1 (and possibly 2, ...)
have been configured.
The resulting format file is
/usr/local/teTeX/share/texmf.local/web2c/pdfetex.fmt

Step 3.
Make an executable file
~/Library/TeXShop/Engines//pdfetex.engine
with the lines

#!/bin/sh
test -f "`kpsewhich pdfetex.fmt`" || fmtutil --byfmt pdfetex
exec pdfetex -fmt=pdfetex -progname=pdfetex "$@"

Step 4.
In TeXShop Preferences go to Engine and there
put under pdfTeX as your TeX Program pdfetex (default is pdftex)
and under TeX+dvips+distiller as your TeX Progran altpdfetex
(default is altpdftex).

Now, under Plain TeX typesetting, any plain TeX file should produce its
hyphenation in the suitable non-English language after a line with
\language 1 (or 2, ...).


The reason that this does work for pdfetex but not for pdftex, is
that
/usr/local/teTeX/share/texmf.tetex/tex/plain/config/pdfetex.ini
calls
/usr/local/teTeX/share/texmf.tetex/tex/plain/etex/etex.src
which calls in its turn
/usr/local/teTeX/share/texmf.local/etex/plain/config/language.def

but
/usr/local/teTeX/share/texmf.tetex/tex/plain/config/pdftex.ini
calls
/usr/local/teTeX/share/texmf.tetex/tex/plain/base/plain.tex
which does not call language.def

Probably you can fix this by adding at the end of plain.tex the lines

\def\english{0}
\def\dutch{1}
\language\dutch
\input nehyph
\language\english

But I did not try and test this.


Anyhow, it would be helpful if the TeX package in I-Installer would take care
of one or more of the above steps, as it is now done for latex, after the
user has specified which languages he wants to see included.


                                  Tom Koornwinder
--------------------- Info ---------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
           & FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Post: <mailto:MacOSX-TeX at email.esm.psu.edu>





More information about the MacOSX-TeX mailing list