If we use ruhyphal.tex from distribution, generation of format is OK:

tex -ini '\input plain \count255=128 \loop \lccode\count255=\count255 \advance\count255 by 1 \ifnum \count255<256 \repeat \input ruhyphal \dump'

But if we use hyph-ru.tex from distribution, it fails:

iconv -f utf8 -t koi8-r hyph-ru.tex > ruhyph.tex
tex -ini '\input plain \count255=128 \loop \lccode\count255=\count255 \advance\count255 by 1 \ifnum \count255<256 \repeat \input ruhyph \dump'
This is TeX, Version 3.14159265 (TeX Live 2016/Debian) (INITEX)
Preloading the plain format: codes, registers, parameters, fonts, more fonts,
macros, math definitions, output routines, hyphenation
! Nonletter.
l.4834 8-

It is less probable that hyphenation file from distribution is broken. So why TeX fails?


What each of the files in the following list is for?


The error message you've got is pretty clear: dash (-) is not a letter, and only letters are allowed in the hyphenation patterns.

So, what is a letter? When loading hyphenation patterns, TeX treats as letters those characters which have \lccode set. Actually, you already have to assign \lccodes to all the second half of the 8-bit encoding (otherwise all the cyrillic letters would fail to be recognized), so do the final step and add


somewhere in your command line. For example,

tex -ini '\input plain \lccode`\-=`\- \count255=128 \loop \lccode\count255=\count255 \advance\count255 by 1 \ifnum \count255<256 \repeat \input ruhyph \dump'
| improve this answer | |
  • It was totally unexpected for me that dash can be used in hyphenation pattern! Which list of words leads to generation of such hyphenation pattern? I would like to remove this hyphenation pattern from hyph-ru.tex and as such would like to know hyphenation of which words I will be missing. – Igor Liferenko Feb 16 '17 at 5:41
  • There are many of patterns that include dash. Just look into the hyphenation definition file. They actually forbid hyphenation of a word with dash in it (if I read them correctly). – Sergei Golovan Feb 16 '17 at 6:01
  • If they forbid hyphenation of word with dash, why use them in hyphenation pattern in the first place? Do you know where to find the list of words from which hyph-ru.tex is produced? Please say which "hyphenation definition file" exactly you are talking about. – Igor Liferenko Feb 16 '17 at 6:26
  • @IgorLiferenko hyph-ru.tex isn't meant for 8bit-pdftex, see the wrapper loadhyph-ru.tex (which also shows you how to setup the lccode). You can look in the file for some information regarding the sources, more information can be found here hyphenation.org – Ulrike Fischer Feb 16 '17 at 9:33
  • @UlrikeFischer interesting... But what exactly are the peculiarities of non-8bit TeX vs. 8bit TeX that require totally different hyphenation patterns? And with which program patterns for non-8bit TeX are generated? (hyphenation patterns for 8bit TeX are generated with patgen program). Maybe this should be asked as a separate question? – Igor Liferenko Feb 16 '17 at 9:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.