Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hyphenation of the Estonian word "näidislahendused" incorrect #60

Open
piiskop opened this issue Jan 28, 2024 · 2 comments
Open

Hyphenation of the Estonian word "näidislahendused" incorrect #60

piiskop opened this issue Jan 28, 2024 · 2 comments

Comments

@piiskop
Copy link

piiskop commented Jan 28, 2024

I was looking for how to show the hyphenation locations and found a program:

The input:

\documentclass{report}
\usepackage[estonian]{babel}
\def\rehbox{\unskip\unpenalty\setbox2\lastbox\ifhbox2
	\setbox0\hbox{\hbox{\unhbox2} \unhbox0}\expandafter\rehbox\fi}
\newcommand\printhyphens[1]{%
	\setbox0\vbox{{\setbox0\hbox{}%
			\pretolerance-1\hsize=0pt\hfuzz=\maxdimen
			\noindent\hspace*{0pt}#1\par\rehbox\unhbox0}\par}%
	\unvbox 0
}

\begin{document}
	\printhyphens{näidislahendused} 
\end{document}

The output:

näi- dis- la- hen- dus- ed

The expected output:

näi- dis- la- hen- du- sed

Please follow the rule:

  1. Üksik kaashäälik täishäälikute vahel kuulub järgmisse silpi: ko-ju, du-ši, Lii-na.
@mnater
Copy link

mnater commented Jan 30, 2024

I'm not sure, but this seems to be an issue with babel:
The estonian patterns are computed with righthyphenmin = 3

but babel uses righthyphenmin = 2
https://github.com/latex3/babel/blob/b488d60c6b12eefc664077666b4e207f90b63889/locale/et/babel-et.ini#L152 .

If righthyphenmin was set to 3 (as requested by the patterns) the word would hyphenate to näi•dis•la•hen•dused missing the last hyphenation opportunity but being correct.

@jbezos
Copy link
Contributor

jbezos commented Jan 31, 2024

@mnater The ‘hyphenmins’ in the hyphenation files doesn’t necessarily reflect the values set in patgen to generate them. This is particularly true in rule-based patterns (ie, created without patgen), like those for spanish, which sets the hyphenmins to 2/2, the ‘typographical’ limit, as opposed to the ‘technical’ limit (which is 1/1). Please, also note the original babel style and the patterns are the work of one person, so it’s doubtful there is a mistake here (btw, polyglossia also sets 2/2).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants