[luatex] \hyphenpenalty not working

Paul Isambert zappathustra at free.fr
Tue Jul 9 00:52:41 CEST 2013


Taco Hoekwater <taco at elvenkind.com> a écrit:
> On 07/08/2013 04:24 PM, Élie Roux wrote:
> > Dear all,
> >
> > It seems that \hyphenpenalty is not working at all in LuaTeX. See the
> > difference between the outputs of LuaTeX and pdfTeX on the following
> > example:
> >
> > \hyphenpenalty=-10000
> > ab\discretionary{-}{-}{-}cd
> > \bye
> 
> I think that bug is only for negative values? I tested some positive 
> ones, and these seemed ok.

Hasty remarks:

There seems to be some interaction with \pretolerance.

If you add \pretolerance=-10000, LuaTeX does break at the penalty.

Also, there is some interaction with one-liners:

  \hyphenpenalty=-10000
  \pretolerance=0
  Lorem ipsum dolor sit amet, consectetur adipiscing elit.
  \bye

does not break at hyphens (in PDFTeX and LuaTeX), whereas (note the explicit
disc)

  \hyphenpenalty=-10000
  % \pretolerance=0
  Lorem ip\-sum dolor sit amet, consectetur adipiscing elit.
  \bye

breaks at all hyphens in PDFTeX but not LuaTeX unless you uncomment the second
line, and finally

  \hyphenpenalty=-10000
  \pretolerance=0
  Lorem ipsum dolor sit amet, consectetur adipiscing elit.
  Lorem ipsum dolor sit amet, consectetur adipiscing elit.
  \bye

breaks for all engines.

There might be some interaction with normal behavior, but I’ll admit
I’m too incompetent here to do more than those remarks, hoping they’ll
be helpful.

Best,
Paul



More information about the luatex mailing list