Suboptimal German hyphenation
Hi,
I was typesetting some German text on a narrow page when I discovered
the justification wasn't as good as expected. I think I tracked this
down to differences in hyphenation points, namely, ConTeXt has fewer:
\starttext
\language[de]
\showhyphens{Zusammenhang}
\showhyphens{anderswo}
\showhyphens{anderswoher}
\stoptext
This shows
languages > hyphenation > show: Zusam[-||]men[-||]hang
languages > hyphenation > show: anderswo
languages > hyphenation > show: anders[-||]wo[-||]her
Now with LaTeX and Babel:
\documentclass{article}
\usepackage[ngerman]{babel}
\begin{document}
\showhyphens{Zusammenhang}
\showhyphens{anderswo}
\showhyphens{anderswoher}
\end{document}
This shows
[] \TU/lmr/m/n/10 Zu-sam-men-hang
[] \TU/lmr/m/n/10 an-ders-wo
[] \TU/lmr/m/n/10 an-ders-wo-her
The LaTeX hyphenation points agree with the German Duden dictionary.
As none of the words use more than 7-bit ASCII, I think newer pattern
changes are not related.
Curiously, the same effect already appears with MKII and MKIV from
TeXLive 2014, the oldest I had around.
I'm also surprised 'anders-wo-her' gets hyphenated but 'anderswo' is
not hyphenated at all.
I could not reproduce a difference with English words so far.
Any ideas? As far as I understand, MKIV/LMTX should use the
de-hyph-1996 patterns which LuaLaTeX uses these days too, via
hyph-utf8.
Thanks,
--
Leah Neukirchen
Hi Leah,
I was typesetting some German text on a narrow page when I discovered the justification wasn't as good as expected. I think I tracked this down to differences in hyphenation points, namely, ConTeXt has fewer:
\starttext \language[de] \showhyphens{Zusammenhang} \showhyphens{anderswo} \showhyphens{anderswoher} \stoptext
This shows languages > hyphenation > show: Zusam[-||]men[-||]hang languages > hyphenation > show: anderswo languages > hyphenation > show: anders[-||]wo[-||]her
Babel/ngerman sets left/righthyphenmin to 2/2, but ConTeXt sets those to 3/3 for German. (The English default is 2/3). I don't speak German so I have no idea which is correct, but you can get the same behaviour in ConTeXt with: \mainlanguage[de] \lefthyphenmin=2 \righthyphenmin=2 \starttext \showhyphens{Zusammenhang} \showhyphens{anderswo} \showhyphens{anderswoher} \stoptext which gives: languages > hyphenation > show: Zu[-||]sam[-||]men[-||]hang languages > hyphenation > show: an[-||]ders[-||]wo languages > hyphenation > show: an[-||]ders[-||]wo[-||]her -- Max
Max Chernoff via ntg-context
Hi Leah,
I was typesetting some German text on a narrow page when I discovered the justification wasn't as good as expected. I think I tracked this down to differences in hyphenation points, namely, ConTeXt has fewer:
\starttext \language[de] \showhyphens{Zusammenhang} \showhyphens{anderswo} \showhyphens{anderswoher} \stoptext
This shows languages > hyphenation > show: Zusam[-||]men[-||]hang languages > hyphenation > show: anderswo languages > hyphenation > show: anders[-||]wo[-||]her
Babel/ngerman sets left/righthyphenmin to 2/2, but ConTeXt sets those to 3/3 for German. (The English default is 2/3). I don't speak German so I have no idea which is correct, but you can get the same behaviour in ConTeXt with:
Perfect, thanks!
Many prefixes have two letters, so changing the default may be
reasonable. But there are more experienced German typographers on
this list who can chime in.
--
Leah Neukirchen
Leah Neukirchen via ntg-context
Max Chernoff via ntg-context
writes: Hi Leah,
I was typesetting some German text on a narrow page when I discovered the justification wasn't as good as expected. I think I tracked this down to differences in hyphenation points, namely, ConTeXt has fewer:
\starttext \language[de] \showhyphens{Zusammenhang} \showhyphens{anderswo} \showhyphens{anderswoher} \stoptext
This shows languages > hyphenation > show: Zusam[-||]men[-||]hang languages > hyphenation > show: anderswo languages > hyphenation > show: anders[-||]wo[-||]her
Babel/ngerman sets left/righthyphenmin to 2/2, but ConTeXt sets those to 3/3 for German. (The English default is 2/3). I don't speak German so I have no idea which is correct, but you can get the same behaviour in ConTeXt with:
Perfect, thanks!
Many prefixes have two letters, so changing the default may be reasonable. But there are more experienced German typographers on this list who can chime in.
After some research, I found the recommendation in
Forssman, de Jong: Detailtypografie (4. Aufl, 2008, S. 124f.) to
use 2/3 for German justified texts, and 3/4 to 5/5 for ragged text.
They also recommend to never hyphenate words with 5 letters, not sure
that can be encoded.
--
Leah Neukirchen
On 10/19/22 16:47, Leah Neukirchen via ntg-context wrote:
[...] Many prefixes have two letters, so changing the default may be reasonable. But there are more experienced German typographers on this list who can chime in.
After some research, I found the recommendation in Forssman, de Jong: Detailtypografie (4. Aufl, 2008, S. 124f.) to use 2/3 for German justified texts, and 3/4 to 5/5 for ragged text. They also recommend to never hyphenate words with 5 letters, not sure that can be encoded.
Hi Leah, Hans added hyphenmin some time ago: \setuplanguage[de][lefthyphenmin=2, righthyphenmin=3, hyphenmin=6] \setuplanguage[deo][lefthyphenmin=2, righthyphenmin=3, hyphenmin=5] \mainlanguage[de] \starttext \startTEXpage[offset=1em] \hyphenatedword{davon} \deo\hyphenatedword{davon} \stopTEXpage \stoptext It is technically on the wiki, but it lacks proper “wikification”. I hope it helps, Pablo
-----Ursprüngliche Nachricht----- Von: ntg-context
Im Auftrag von Pablo Rodriguez via ntg-context Gesendet: Mittwoch, 19. Oktober 2022 20:02 An: Leah Neukirchen via ntg-context Cc: Pablo Rodriguez Betreff: Re: [NTG-context] Suboptimal German hyphenation Hans added hyphenmin some time ago:
\setuplanguage[de][lefthyphenmin=2, righthyphenmin=3, hyphenmin=6] \setuplanguage[deo][lefthyphenmin=2, righthyphenmin=3, hyphenmin=5] \mainlanguage[de] \starttext \startTEXpage[offset=1em] \hyphenatedword{davon} \deo\hyphenatedword{davon} \stopTEXpage \stoptext
It is technically on the wiki, but it lacks proper “wikification”.
I just wanted to add it to the hyphenation page on the wiki, but I've seen that you have just added it a couple of days ago. Thanks! Denis
Max Chernoff via ntg-context schrieb am 29.09.2022 um 02:17:
Hi Leah,
I was typesetting some German text on a narrow page when I discovered the justification wasn't as good as expected. I think I tracked this down to differences in hyphenation points, namely, ConTeXt has fewer:
\starttext \language[de] \showhyphens{Zusammenhang} \showhyphens{anderswo} \showhyphens{anderswoher} \stoptext
This shows languages > hyphenation > show: Zusam[-||]men[-||]hang languages > hyphenation > show: anderswo languages > hyphenation > show: anders[-||]wo[-||]her Babel/ngerman sets left/righthyphenmin to 2/2, but ConTeXt sets those to 3/3 for German. (The English default is 2/3). I don't speak German so I have no idea which is correct, but you can get the same behaviour in ConTeXt with:
\mainlanguage[de] \lefthyphenmin=2 \righthyphenmin=2
You can use \setuplanguage to change the values. \setuplanguage [de] [ lefthyphenmin=2, righthyphenmin=2] Wolfgang
Am 29.09.22 um 06:10 schrieb Wolfgang Schuster via ntg-context:
Max Chernoff via ntg-context schrieb am 29.09.2022 um 02:17:
Babel/ngerman sets left/righthyphenmin to 2/2, but ConTeXt sets those to 3/3 for German. (The English default is 2/3). I don't speak German so I have no idea which is correct, but you can get the same behaviour in ConTeXt with:
\mainlanguage[de] \lefthyphenmin=2 \righthyphenmin=2
You can use \setuplanguage to change the values.
\setuplanguage [de] [ lefthyphenmin=2, righthyphenmin=2]
Thank you, Leah, Max and Wolfgang! I changed that immediately in all of my ongoing projects, but I don’t think we should change the default after all these years. published: https://literatur.social/@fiee/109079837141552277 Hraban
On Thu, Sep 29, 2022 at 06:49:23AM +0200, Henning Hraban Ramm via ntg-context wrote:
Thank you, Leah, Max and Wolfgang! I changed that immediately in all of my ongoing projects, but I don’t think we should change the default after all these years.
Are you sure that the default in ConTeXt has *not* changed in all these years? :-) Arthur
Am 29.09.22 um 08:27 schrieb Arthur Rosendahl:
On Thu, Sep 29, 2022 at 06:49:23AM +0200, Henning Hraban Ramm via ntg-context wrote:
Thank you, Leah, Max and Wolfgang! I changed that immediately in all of my ongoing projects, but I don’t think we should change the default after all these years.
Are you sure that the default in ConTeXt has *not* changed in all these years? :-)
jag vet inte Hraban
participants (7)
-
Arthur Rosendahl
-
denis.maier@unibe.ch
-
Henning Hraban Ramm
-
Leah Neukirchen
-
Max Chernoff
-
Pablo Rodriguez
-
Wolfgang Schuster