Dear list, I have the following MWE: \showframe\showgrid \setupindenting[yes, always, big] \starttext \noindentation a a \stoptext Using LMTX (2020.11.19 11:28), I get indentation with \noindentation. Could anyone confirm this? Many thanks for your help, Pablo -- http://www.ousia.tk
Hi Pablo, I can confirm that with LMTX version 2020.11.19 11:28, the behaviour is as the one you report (the behaviour is correct with mkiv version 2020.06.25 10:55). Best regards: Otared
On 20 Nov 2020, at 17:41, Pablo Rodriguez
wrote: Dear list,
I have the following MWE:
\showframe\showgrid \setupindenting[yes, always, big] \starttext \noindentation a
a \stoptext
Using LMTX (2020.11.19 11:28), I get indentation with \noindentation.
Could anyone confirm this?
Many thanks for your help,
Pablo -- http://www.ousia.tk ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________
Pablo Rodriguez schrieb am 20.11.2020 um 17:41:
Dear list,
I have the following MWE:
\showframe\showgrid \setupindenting[yes, always, big] \starttext \noindentation a
a \stoptext
Using LMTX (2020.11.19 11:28), I get indentation with \noindentation.
Could anyone confirm this?
Yes, something is wrong. %%%% begin example \showgrid \starttext \parindent\emwidth a \everypar{\setbox\scratchbox\lastbox} a \stoptext %%%% end example Wolfgang
On 11/20/2020 6:27 PM, Wolfgang Schuster wrote:
Pablo Rodriguez schrieb am 20.11.2020 um 17:41:
Dear list,
I have the following MWE:
\showframe\showgrid \setupindenting[yes, always, big] \starttext \noindentation a
a \stoptext
Using LMTX (2020.11.19 11:28), I get indentation with \noindentation.
Could anyone confirm this?
Yes, something is wrong.
%%%% begin example \showgrid
\starttext
\parindent\emwidth
a
\everypar{\setbox\scratchbox\lastbox} a
\stoptext %%%% end example
Ah, okay. We have normalization enabled now. That means two things: - instead if a hbox being used for indentation (with >= 0 width) we now have a skip (with no stretch but that might become an option some day); the tex engine uses a hbox because it is easier on the par builder (less checking, as glue, being a valid breakpoint, involves quite a bit) - after breaking a paragraph into lines the result is normalized, that is: we have left/right hang, left/right skip. left/right parfilskip instead of a mix of either or not present left/right skip, and shifted boxes in case of some hang features (again, the original approach is easier for the engine, but machines are fast enough and have plenty of memory so we can stop worrying about it) The ideas is that this way we can make some lua nodelist hackery more elegant (but I need to catch up with that: most tex files are now split in mkiv and lmtx and next comes the lua files after which we can start some more drastic upgrading ... keep in mind that quite some code is from more than a decase ago, evolved a bit but seldom changed conceptually). Here's a fix: \unprotect \def\spac_indentation_remove {\ifzeropt\parindent \else \begingroup \unskip % we also need to check for the subtype \setbox\scratchbox\lastbox % we also need to check for the \endgroup \fi} \protect (we might need adapt some more code); actually more correct would be: \def\spac_indentation_remove {\ifzeropt\parindent \else \begingroup \ifnum\lastnodetype=\gluenodecode \unskip % we also need to check for the subtype \orelse\ifnum\lastnodetype=\hlistnodecode \setbox\scratchbox\lastbox % we also need to check for the subtype \else % forget about it \fi \endgroup \fi} (it actually makes sense to have a native \unindent primitive but we can simulate that in lua) 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 -----------------------------------------------------------------
On 11/20/20 8:07 PM, Hans Hagen wrote:
[...] Here's a fix: [...] (we might need adapt some more code); actually more correct would be:
\def\spac_indentation_remove {\ifzeropt\parindent \else \begingroup \ifnum\lastnodetype=\gluenodecode \unskip % we also need to check for the subtype \orelse\ifnum\lastnodetype=\hlistnodecode \setbox\scratchbox\lastbox % we also need to check for the subtype \else % forget about it \fi \endgroup \fi}
Many thanks for the fix, Hans. I placed it in cont-new.mkiv (I thought there was a cont-new.mkxl, but I couldn’t find it. Many thanks for your help, Pablo -- http://www.ousia.tk
On 11/20/20 9:07 PM, Joseph wrote:
Thanks. Does the fix apply for similar issue I raised with below where all paragraphs are indented (expected is that first par is not indented) ?
\setupindenting[yes, next, 1em] \starttext \input knuth \stoptext
Yes, the fix solves your issue. Pablo -- http://www.ousia.tk
participants (5)
-
Hans Hagen
-
Joseph
-
Otared Kavian
-
Pablo Rodriguez
-
Wolfgang Schuster