Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Here I found the statement that no special hyphenation patterns are needed with LY1 font encoding. Yet I stumbled upon different hyphenation in connection with non-letters (such as quotation marks) in utf8 input:

\documentclass[ngerman]{article}
\usepackage[utf8x]{inputenc}
\usepackage{babel}
\usepackage[LY1]{fontenc}
\def\foo{Michelsberg „Michelsberg Michelsberg“ }
\begin{document}
\LARGE
\foo\foo\foo\foo\foo\foo\foo Michelsberg!
Michelsberg, \foo Michelsberg? \foo\foo\foo Michelsberg.
\end{document}

One instance of a hyphenation Michelsber-g“ occurs in the output. With other encodings (e.g. T1), only the correct hyphenations (Mi-chels-berg) are used (or even tried as a look into the log shows). Is there a way to systematically prevent this problem with LY1?

share|improve this question
    
Is there any particular reason to use LY1? –  David Carlisle Nov 17 '13 at 22:09

1 Answer 1

up vote 4 down vote accepted

The German closing quotes (English opening quotes) are in position octal 223 in LY1, whereas T1 has an uppercase letter (Ş) with a corresponding lowercase. Thus the double quote character participates in hyphenation because it has a non zero \lccode. A hyphenation ber-g is surely acceptable mid word and, as far as TeX is concerned, the g is followed by another letter.

You solve this issue by adding

\AtBeginDocument{\lccode'223=0 }

to your preamble.

There are probably other characters that need the same treatment: all punctuation characters that are in different position in LY1 with respect to T1; also the \lccode and \uccode vectors should be updated for letters in different positions.

I've always been suspicious about LY1, to tell you the truth.

share|improve this answer
    
That sounds very plausible (though ber-g should only be acceptable midword if followed by a vowel or possibly liquida, though even these may occur in composita with berg-) –  Hagen von Eitzen Nov 18 '13 at 18:07

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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