[latex3-commits] [git/LaTeX3-latex3-latex2e] OR-lab: some hook renames (and an additional one) (1ac5c76f)

Frank Mittelbach frank.mittelbach at latex-project.org
Sun Feb 27 16:16:18 CET 2022


Repository : https://github.com/latex3/latex2e
On branch  : OR-lab
Link       : https://github.com/latex3/latex2e/commit/1ac5c76f6bc35fe2c75d397ab18228e587401913

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

commit 1ac5c76f6bc35fe2c75d397ab18228e587401913
Author: Frank Mittelbach <frank.mittelbach at latex-project.org>
Date:   Sun Feb 27 16:16:18 2022 +0100

    some hook renames (and an additional one)


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

1ac5c76f6bc35fe2c75d397ab18228e587401913
 required/latex-lab/latex-lab-footnotes.dtx         | 24 ++++++++++++++--------
 required/latex-lab/testfiles-OR/footmisc-002.tlg   |  4 +++-
 required/latex-lab/testfiles-OR/footmisc-003.tlg   |  4 +++-
 required/latex-lab/testfiles-OR/footmisc-004.tlg   |  4 +++-
 required/latex-lab/testfiles-OR/footmisc-005.tlg   |  4 +++-
 required/latex-lab/testfiles-OR/footmisc-006.tlg   |  4 +++-
 .../testfiles-OR/footmisc-009-multiple.tlg         |  4 +++-
 .../testfiles-OR/footmisc-010-setspace.lvt         |  2 +-
 .../testfiles-OR/footmisc-010-setspace.tlg         |  8 +++++---
 .../latex-lab/testfiles-OR/footmisc-011-para.tlg   |  4 +++-
 required/latex-lab/testfiles-OR/tagging-001.tlg    |  4 +++-
 11 files changed, 46 insertions(+), 20 deletions(-)

diff --git a/required/latex-lab/latex-lab-footnotes.dtx b/required/latex-lab/latex-lab-footnotes.dtx
index 254176bb..a6c95de9 100644
--- a/required/latex-lab/latex-lab-footnotes.dtx
+++ b/required/latex-lab/latex-lab-footnotes.dtx
@@ -214,7 +214,8 @@
 %-------------------------------------
 
 \NewHook{fntext/before}
-\NewHook{fntext/begin}
+\NewHook{fntext}
+\NewHook{fntext/para}
 \NewHook{fntext/after}
 
 
@@ -223,7 +224,8 @@
   \ShowCommand\@footnotetext at processii
   \ShowCommand\@footnotetext at processiii
   \LogHook{fntext/before}
-  \LogHook{fntext/begin}
+  \LogHook{fntext}
+  \LogHook{fntext/para}
   \LogHook{fntext/after}
   \global\let\debug at footnotetext\relax
   }
@@ -240,13 +242,14 @@
 % ./uafthesis/uafthesis.cls
 % ./setspace/setspace.sty
 % ./footmisc/footmisc.sty (normal)
-    \UseHook{fntext/begin}
+    \UseHook{fntext}
 %-------
     \reset at font
     \footnotesize
 %-------
 % some classes use a different font size, e.g.,
 % ./nrc/nrc1.cls  ./nrc/nrc2.cls
+% but those could be done in fntext/para instead
 %-------
     \interlinepenalty\interfootnotelinepenalty
     \splittopskip\footnotesep
@@ -254,12 +257,17 @@
     \floatingpenalty \@MM
     \hsize\columnwidth
     \@parboxrestore
+    \def\@currentcounter{footnote}
+    \protected at edef \@currentlabel { \p at footnote \@thefnmark }
 %-------
 % altering para parameters ...
+% code for resphilosophica came earlier but it could go here.
+% Has the advantage that one can also overwrite \cs{@currentcounter}
+% and \csπ@currentlabel} is that is necessary.
+%
 % ./resphilosophica/resphilosophica.cls
+    \UseHook{fntext/para}
 %-------
-    \def\@currentcounter{footnote}
-    \protected at edef \@currentlabel { \p at footnote \@thefnmark }
     \color at begingroup
 %-------
 % fnpara wants to replace \@makefntext{...} (footmisc probably too ...)
@@ -314,7 +322,7 @@
 
 \AddToHook{package/setspace/after}
    {\let \@footnotetext \FN at footnotetext % should not overwrite it but use hook
-    \AddToHook{fntext/begin}[setspace]{\let\baselinestretch\setspace at singlespace}}
+    \AddToHook{fntext}[setspace]{\let\baselinestretch\setspace at singlespace}}
 
           
 
@@ -753,11 +761,11 @@
    \FN at setspacetrue
    \@ifclassloaded{memoir}%
      {%
-       \AddToHook{fntext/begin}{\let\baselinestretch\m at m@singlespace}%
+       \AddToHook{fntext}{\let\baselinestretch\m at m@singlespace}%
        \let\FN at baselinestretch\m at m@singlespace
      }%
      {%
-%       \AddToHook{fntext/begin}{\let\baselinestretch\setspace at singlespace}%
+%       \AddToHook{fntext}{\let\baselinestretch\setspace at singlespace}%
        \let\FN at baselinestretch\setspace at singlespace
      }%
  }%
diff --git a/required/latex-lab/testfiles-OR/footmisc-002.tlg b/required/latex-lab/testfiles-OR/footmisc-002.tlg
index 8e30cb45..05532491 100644
--- a/required/latex-lab/testfiles-OR/footmisc-002.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-002.tlg
@@ -63,7 +63,9 @@ l. ...Test\footnote{A}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
diff --git a/required/latex-lab/testfiles-OR/footmisc-003.tlg b/required/latex-lab/testfiles-OR/footmisc-003.tlg
index ea297fe1..2a967567 100644
--- a/required/latex-lab/testfiles-OR/footmisc-003.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-003.tlg
@@ -63,7 +63,9 @@ l. ...Test\footnote{A}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
diff --git a/required/latex-lab/testfiles-OR/footmisc-004.tlg b/required/latex-lab/testfiles-OR/footmisc-004.tlg
index dbfb38d8..7e5a0e5c 100644
--- a/required/latex-lab/testfiles-OR/footmisc-004.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-004.tlg
@@ -63,7 +63,9 @@ l. ...Test\footnote{A}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
diff --git a/required/latex-lab/testfiles-OR/footmisc-005.tlg b/required/latex-lab/testfiles-OR/footmisc-005.tlg
index 84f78c13..b4f23265 100644
--- a/required/latex-lab/testfiles-OR/footmisc-005.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-005.tlg
@@ -63,7 +63,9 @@ l. ...Test\footnote{A}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
diff --git a/required/latex-lab/testfiles-OR/footmisc-006.tlg b/required/latex-lab/testfiles-OR/footmisc-006.tlg
index 198d15f0..f283f3c6 100644
--- a/required/latex-lab/testfiles-OR/footmisc-006.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-006.tlg
@@ -63,7 +63,9 @@ l. ...Test\footnote{A}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
diff --git a/required/latex-lab/testfiles-OR/footmisc-009-multiple.tlg b/required/latex-lab/testfiles-OR/footmisc-009-multiple.tlg
index b6a72a10..f6d035b8 100644
--- a/required/latex-lab/testfiles-OR/footmisc-009-multiple.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-009-multiple.tlg
@@ -78,7 +78,9 @@ l. ...Test\footnote{A}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
diff --git a/required/latex-lab/testfiles-OR/footmisc-010-setspace.lvt b/required/latex-lab/testfiles-OR/footmisc-010-setspace.lvt
index 1403af56..532ebab8 100644
--- a/required/latex-lab/testfiles-OR/footmisc-010-setspace.lvt
+++ b/required/latex-lab/testfiles-OR/footmisc-010-setspace.lvt
@@ -15,7 +15,7 @@
 
 \START
 
-\ShowHook{fntext/begin}
+\ShowHook{fntext}
 
 
 \doublespacing
diff --git a/required/latex-lab/testfiles-OR/footmisc-010-setspace.tlg b/required/latex-lab/testfiles-OR/footmisc-010-setspace.tlg
index 12c23d3c..22d6e6b8 100644
--- a/required/latex-lab/testfiles-OR/footmisc-010-setspace.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-010-setspace.tlg
@@ -1,6 +1,6 @@
 This is a generated file for the l3build validation system.
 Don't change this file in any respect.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
 > Code chunks:
 >     setspace -> \let \baselinestretch \setspace at singlespace 
 > Document-level (top-level) code (executed last):
@@ -12,7 +12,7 @@ Don't change this file in any respect.
 > Execution order:
 >     setspace.
 <recently read> }
-l. ...\ShowHook{fntext/begin}
+l. ...\ShowHook{fntext}
 > \@kernel at after@fnmark=macro:
 ->.
 <argument> \@kernel at after@fnmark 
@@ -81,7 +81,7 @@ l. ...Test\footnote{\lipsum[1][1-7]}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
 > Code chunks:
 >     setspace -> \let \baselinestretch \setspace at singlespace 
 > Document-level (top-level) code (executed last):
@@ -92,6 +92,8 @@ l. ...Test\footnote{\lipsum[1][1-7]}
 >     ---
 > Execution order:
 >     setspace.
+-> The hook 'fntext/para':
+> The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
 >     latex-lab-testphase-new-or -> \cs_if_exist:NT \tag_struct_begin:n {\bool_gset_eq:NN \g__tag_in_mc_bool \g__tag_saved_in_mc_bool }
diff --git a/required/latex-lab/testfiles-OR/footmisc-011-para.tlg b/required/latex-lab/testfiles-OR/footmisc-011-para.tlg
index 5d41ba6a..3f8232f6 100644
--- a/required/latex-lab/testfiles-OR/footmisc-011-para.tlg
+++ b/required/latex-lab/testfiles-OR/footmisc-011-para.tlg
@@ -68,7 +68,9 @@ l. ...Test\footnote{A}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:
diff --git a/required/latex-lab/testfiles-OR/tagging-001.tlg b/required/latex-lab/testfiles-OR/tagging-001.tlg
index 6ec7f681..7409dbd7 100644
--- a/required/latex-lab/testfiles-OR/tagging-001.tlg
+++ b/required/latex-lab/testfiles-OR/tagging-001.tlg
@@ -68,7 +68,9 @@ l. ...abc \footnote{blub}
 >     ---
 > Execution order:
 >     latex-lab-testphase-new-or.
--> The hook 'fntext/begin':
+-> The hook 'fntext':
+> The hook is empty.
+-> The hook 'fntext/para':
 > The hook is empty.
 -> The hook 'fntext/after':
 > Code chunks:





More information about the latex3-commits mailing list.