[NTG-context] Missing parinitskips in \normalizelinemode=0
Hans Hagen
j.hagen at freedom.nl
Wed Oct 19 11:59:44 CEST 2022
On 10/19/2022 3:01 AM, Max Chernoff via ntg-context wrote:
> Hi Hans,
>
> When running in \normalizelinemode=0, the \parinitleftskip and
> \parinitrightskip nodes are either nonexistant or invisible from Lua,
> causing tex.linebreak to not work correctly.
>
> This sample file:
>
> \enabledirectives[system.callbacks.permitoverloads]
>
> \normalizelinemode=0
>
> \directlua{
> callback.register("pre_linebreak_filter", function(head)
> tex.preparelinebreak(head)
> local list, info = tex.linebreak(head)
> print(info)
>
> return head
> end)
> }
>
> \starttext
> \input knuth
> \stoptext
>
> Produces this output:
>
> luatex warning > linebreak: list seems already prepared
> luatex warning > linebreak: [ leftinit | rightinit | leftfill | rigthfill ] expected
> nil
i'll bypass that warnign when the mode is zero
btw, you need to work with a copy of the list
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
More information about the ntg-context
mailing list