latex3 / tagging-project

Issues related to the tagging project
https://latex3.github.io/tagging-project/
LaTeX Project Public License v1.3c
42 stars 15 forks source link

spacing between display math an block environments #10

Open u-fischer opened 1 year ago

u-fischer commented 1 year ago

If display math is not explicitly tagged then there is too much space before a following block environment from the EMC literal if pdflatex is used:

\DocumentMetadata{testphase={phase-III},
%testphase=math
}
\documentclass{article}
\newtheorem{rk}{Remark} 
\begin{document}\showoutput
Consider this:
\[
a=b
\]
\begin{rk}
Too much space above with pdftex!
\end{rk}

Consider this:
\[
a=b
\]
\begin{center}
Too much space above with pdftex!
\end{center}

\end{document}

image

With math tagging enabled or with lualatex, the spacing is ok, so probably it is not a real issue for now.

FrankMittelbach commented 1 year ago

it would be nevertheless good to understand what is happening there (if the math tagging is missing) but I agree it is probably not worth spending too much effort on it as math tagging has to be enabled eventually.

u-fischer commented 1 year ago

as I wrote: it is the closing literal. Basically the same problem as with all other whatsits after display math. E.g.

\documentclass{article}
\begin{document}
aaa
\[a=b\] 
\begin{center}bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb\end{center}

\showoutput 
aaa
\[a=b\] \label{blub} 
\begin{center}bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb\end{center}

\end{document}

image

When the math is tagged there is no problem, as all MC-chunks are closed when handling the math. One could perhaps avoid the problem by delaying the setting of the MC-literal to the begin of the next paragraph but I'm not sure if it is worth the trouble.

FrankMittelbach commented 8 months ago

ah ok, in that case we should most likely ignore it, ie a combination of "future" and "wontfix" since it will correct itself eventually once tagging is enabled throughout.