move multline code
This commit is contained in:
parent
5c8d99818b
commit
29212f284c
@ -246,12 +246,10 @@
|
||||
\global \lineht@ \z@
|
||||
\cr
|
||||
}
|
||||
}
|
||||
|
||||
% This was lost anyway, as the latex-lab code overwrites
|
||||
% the definition again.
|
||||
\IfPackageAtLeastTF{latex-lab-testphase-math}{2025-01-24}
|
||||
{}
|
||||
{ \PackageInfo{luamml}{patching~\string\maketag@@@}
|
||||
\PackageInfo{luamml}{patching~\string\maketag@@@}
|
||||
\cs_set:Npn \maketag@@@ #1
|
||||
{
|
||||
\hbox {
|
||||
@ -261,6 +259,7 @@
|
||||
\UseTaggingSocket{math/luamml/mtable/tag/save}
|
||||
}
|
||||
}
|
||||
\PackageInfo{luamml}{patching~\string\endalign}
|
||||
% this handled in latex-lab through \common@align@ending
|
||||
\cs_set:Npn \endalign {
|
||||
\math@cr
|
||||
@ -277,29 +276,34 @@
|
||||
\fi
|
||||
\ignorespacesafterend
|
||||
}
|
||||
}
|
||||
|
||||
% For a more interesting one, let's consider multline:
|
||||
\cs_new_eq:NN \__luamml_amsmath_original_multline:n \multline@
|
||||
\cs_set:Npn \multline@ #1 {
|
||||
\PackageInfo{luamml}{patching~\string\multline@}
|
||||
% For a more interesting one, let's consider multline:
|
||||
\cs_new_eq:NN \__luamml_amsmath_original_multline:n \multline@
|
||||
\cs_set:Npn \multline@ #1 {
|
||||
\__luamml_amsmath_original_multline:n {
|
||||
\ifmeasuring@ \else
|
||||
\__luamml_amsmath_set_row_columnalign:n {left}
|
||||
\UseTaggingSocket{math/luamml/mtable/aligncol} {left}
|
||||
\fi
|
||||
#1
|
||||
\ifmeasuring@ \else
|
||||
\__luamml_amsmath_set_row_columnalign:n {right}
|
||||
\UseTaggingSocket{math/luamml/mtable/aligncol} {right}
|
||||
\fi
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
\cs_new_eq:NN \__luamml_amsmath_original_mmeasure:n \mmeasure@
|
||||
\cs_set:Npn \mmeasure@ #1 {
|
||||
%this is not move to latex-lab as the luamml_ignore is inserting with
|
||||
% \measuringtrue
|
||||
\PackageInfo{luamml}{patching~\string\mmeasure@}
|
||||
\cs_new_eq:NN \__luamml_amsmath_original_mmeasure:n \mmeasure@
|
||||
\cs_set:Npn \mmeasure@ #1 {
|
||||
\exp_last_unbraced:Nno
|
||||
\use_ii_i:nn
|
||||
{ \luamml_ignore: }
|
||||
{ \__luamml_amsmath_original_mmeasure:n {#1} }
|
||||
}
|
||||
}
|
||||
} % end package test
|
||||
|
||||
|
||||
% Luckily, {multline} uses \endmultline@math in exactly
|
||||
% the spot where we have to set the flag.
|
||||
|
23
luamml.dtx
23
luamml.dtx
@ -692,7 +692,7 @@
|
||||
\AssignSocketPlug{tagsupport/math/luamml/mtable/innertable/finalize}{luamml}
|
||||
%</luatex>
|
||||
% \end{macrocode}
|
||||
|
||||
%
|
||||
%
|
||||
% This socket finalize the \texttt{mtable} in alignments like align or gather.
|
||||
% It takes an argument, the environment.
|
||||
@ -714,6 +714,27 @@
|
||||
\AssignSocketPlug{tagsupport/math/luamml/mtable/finalize}{luamml}
|
||||
%</luatex>
|
||||
% \end{macrocode}
|
||||
%
|
||||
% This socket adds attributes for the alignment in \texttt{multline}.
|
||||
% It takes an argument, the alignment.
|
||||
% \begin{macrocode}
|
||||
\str_if_exist:cF { l__socket_tagsupport/math/luamml/mtable/aligncol_plug_str }
|
||||
{
|
||||
\NewSocket{tagsupport/math/luamml/mtable/aligncol}{1}
|
||||
\AssignSocketPlug{tagsupport/math/luamml/mtable/aligncol}{noop}
|
||||
}
|
||||
% \end{macrocode}
|
||||
%
|
||||
% \begin{macrocode}
|
||||
%<*luatex>
|
||||
\NewSocketPlug{tagsupport/math/luamml/mtable/aligncol}{luamml}
|
||||
{
|
||||
\__luamml_amsmath_set_row_columnalign:n {#1}
|
||||
}
|
||||
\AssignSocketPlug{tagsupport/math/luamml/mtable/aligncol}{luamml}
|
||||
%</luatex>
|
||||
% \end{macrocode}
|
||||
|
||||
%
|
||||
% \subsubsection{Tags and labels}
|
||||
% These sockets save and set tags and labels in alignments.
|
||||
|
Loading…
x
Reference in New Issue
Block a user