[latex3-commits] [git/LaTeX3-latex3-latex2e] everymath: Collect all amsmath redefs in one place (618db5d5)

Joseph Wright joseph.wright at morningstar2.co.uk
Fri Jan 6 14:21:59 CET 2023


Repository : https://github.com/latex3/latex2e
On branch  : everymath
Link       : https://github.com/latex3/latex2e/commit/618db5d5dbcf21f435c7d041fa7885d58b9e6456

>---------------------------------------------------------------

commit 618db5d5dbcf21f435c7d041fa7885d58b9e6456
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Fri Jan 6 13:20:36 2023 +0000

    Collect all amsmath redefs in one place
    
    These are then trivial to move out later. For the present I've not moved equation(*) as it's going to be handled like other non-amsmath things: upcoming commit.


>---------------------------------------------------------------

618db5d5dbcf21f435c7d041fa7885d58b9e6456
 required/latex-lab/latex-lab-mathcapture.dtx | 91 ++++++++++++++--------------
 1 file changed, 47 insertions(+), 44 deletions(-)

diff --git a/required/latex-lab/latex-lab-mathcapture.dtx b/required/latex-lab/latex-lab-mathcapture.dtx
index a56a97c2..697496b7 100644
--- a/required/latex-lab/latex-lab-mathcapture.dtx
+++ b/required/latex-lab/latex-lab-mathcapture.dtx
@@ -83,7 +83,7 @@
 % \subsection{File declaration}
 %    \begin{macrocode}
 \ProvidesFile{latex-lab-mathcapture.ltx}
-        [2023-01-05 v0.1a Grab all the math(s)]
+        [2023-01-06 v0.1a Grab all the math(s)]
 %    \end{macrocode}
 %
 %    \begin{macrocode}
@@ -313,49 +313,7 @@
   }
 %    \end{macrocode}
 %
-% \subsection{Modifying environments and \pkg{amsmath}}
-%
-% Mark up all of the display environments as the content is captured anyway.
-%    \begin{macrocode}
-\clist_map_inline:nn
-  { align , gather , multline }
-  {
-    \AddToHook{ env / #1 / begin }
-      { \bool_set_true:N \l_@@_collected_bool }
-    \AddToHook{ env / #1* / begin }
-      { \bool_set_true:N \l_@@_collected_bool }
-  }
-%    \end{macrocode}
-%
-% \begin{macro}{\@@_measure@:n, \@@_gmeasure@:n, \@@_mmeasure@:n}
-% \begin{macro}{\measure@, \gmeasure@, \mmeasure@}
-%   The \pkg{amsmath} environments use a few common internal commands that are
-%   useful places to pick up the content.
-%    \begin{macrocode}
-\tl_gput_right:Nn \@kernel at before@begindocument
-  {
-    \cs_new_eq:NN \@@_measure@:n \measure@
-    \cs_gset_protected:Npn \measure@ #1
-      {
-        \@@_process:n {#1}
-        \@@_measure@:n {#1}
-      }
-    \cs_new_eq:NN \@@_gmeasure@:n \gmeasure@
-    \cs_gset_protected:Npn \gmeasure@ #1
-      {
-        \@@_process:n {#1}
-        \@@_gmeasure@:n {#1}
-      }
-    \cs_new_eq:NN \@@_mmeasure@:n \mmeasure@
-    \cs_gset_protected:Npn \mmeasure@ #1
-      {
-        \@@_process:n {#1}
-        \@@_mmeasure@:n {#1}
-      }
-  }
-%    \end{macrocode}
-% \end{macro}
-% \end{macro}
+% \subsection{Modifying kernel environments}
 %
 % \begin{macro}{\eqnarray, \@@_eqnarray_begin:}
 % \begin{macro}{\endeqnarray, \@@_eqnarray_end:}
@@ -403,6 +361,51 @@
 %    \end{macrocode}
 % \end{macro}
 %
+% \subsection{Modifying \pkg{amsmath}}
+%
+% Mark up all of the display environments as the content is captured anyway.
+%    \begin{macrocode}
+\clist_map_inline:nn
+  { align , gather , multline }
+  {
+    \AddToHook{ env / #1 / begin }
+      { \bool_set_true:N \l_@@_collected_bool }
+    \AddToHook{ env / #1* / begin }
+      { \bool_set_true:N \l_@@_collected_bool }
+  }
+%    \end{macrocode}
+%
+%
+% \begin{macro}{\@@_measure@:n, \@@_gmeasure@:n, \@@_mmeasure@:n}
+% \begin{macro}{\measure@, \gmeasure@, \mmeasure@}
+%   The \pkg{amsmath} environments use a few common internal commands that are
+%   useful places to pick up the content.
+%    \begin{macrocode}
+\tl_gput_right:Nn \@kernel at before@begindocument
+  {
+    \cs_new_eq:NN \@@_measure@:n \measure@
+    \cs_gset_protected:Npn \measure@ #1
+      {
+        \@@_process:n {#1}
+        \@@_measure@:n {#1}
+      }
+    \cs_new_eq:NN \@@_gmeasure@:n \gmeasure@
+    \cs_gset_protected:Npn \gmeasure@ #1
+      {
+        \@@_process:n {#1}
+        \@@_gmeasure@:n {#1}
+      }
+    \cs_new_eq:NN \@@_mmeasure@:n \mmeasure@
+    \cs_gset_protected:Npn \mmeasure@ #1
+      {
+        \@@_process:n {#1}
+        \@@_mmeasure@:n {#1}
+      }
+  }
+%    \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
 %    \begin{macrocode}
 \ExplSyntaxOff
 %    \end{macrocode}





More information about the latex3-commits mailing list.