[latex3-commits] [git/LaTeX3-latex3-latex2e] shipout-hook-adjust: add \kernel at after@shipout at background hook (3df8677b)
Frank Mittelbach
frank.mittelbach at latex-project.org
Fri Jan 8 20:59:20 CET 2021
Repository : https://github.com/latex3/latex2e
On branch : shipout-hook-adjust
Link : https://github.com/latex3/latex2e/commit/3df8677bd875270720cc841e121bf72abf2137e9
>---------------------------------------------------------------
commit 3df8677bd875270720cc841e121bf72abf2137e9
Author: Frank Mittelbach <frank.mittelbach at latex-project.org>
Date: Fri Jan 8 20:59:20 2021 +0100
add \kernel at after@shipout at background hook
>---------------------------------------------------------------
3df8677bd875270720cc841e121bf72abf2137e9
base/ltfilehook.dtx | 2 +-
base/lthooks.dtx | 2 +-
base/ltshipout.dtx | 16 ++++++++++++----
3 files changed, 14 insertions(+), 6 deletions(-)
diff --git a/base/ltfilehook.dtx b/base/ltfilehook.dtx
index b5b5de62..8601c20f 100644
--- a/base/ltfilehook.dtx
+++ b/base/ltfilehook.dtx
@@ -1,6 +1,6 @@
% \iffalse meta-comment
%%
-%% File: ltfilehook.dtx (C) Copyright 2020,2021 Frank Mittelbach,
+%% File: ltfilehook.dtx (C) Copyright 2020-2021 Frank Mittelbach,
%% Phelype Oleinik & LaTeX Team
%
% This file is part of the LaTeX base system.
diff --git a/base/lthooks.dtx b/base/lthooks.dtx
index 404938d2..4f8b1423 100644
--- a/base/lthooks.dtx
+++ b/base/lthooks.dtx
@@ -1,6 +1,6 @@
% \iffalse meta-comment
%%
-%% File: lthooks.dtx (C) Copyright 2020,2021 Frank Mittelbach,
+%% File: lthooks.dtx (C) Copyright 2020-2021 Frank Mittelbach,
%% Phelype Oleinik & LaTeX Team
%
% This file is part of the LaTeX base system.
diff --git a/base/ltshipout.dtx b/base/ltshipout.dtx
index 2ea0a1b6..64d77456 100644
--- a/base/ltshipout.dtx
+++ b/base/ltshipout.dtx
@@ -1,6 +1,6 @@
% \iffalse meta-comment
%%
-%% File: ltshipout.dtx (C) Copyright 2020,2021 Frank Mittelbach, LaTeX Team
+%% File: ltshipout.dtx (C) Copyright 2020-2021 Frank Mittelbach, LaTeX Team
%%
%
% This file is part of the LaTeX base system.
@@ -31,8 +31,8 @@
%%% From File: ltshipout.dtx
%
% \begin{macrocode}
-\providecommand\ltshipoutversion{v1.0d}
-\providecommand\ltshipoutdate{2020/12/06}
+\providecommand\ltshipoutversion{v1.0f}
+\providecommand\ltshipoutdate{2021/01/08}
% \end{macrocode}
%
%<*driver>
@@ -753,14 +753,22 @@
{ \hook_use:n {shipout/foreground} } }
% \end{macrocode}
% If there is no user hook, there might still code in the kernel hook.
+% We only test for the \cs{@kernel at before@shipout at background}
+% though. If the \cs{@kernel at after@shipout at background} needs
+% executing even if the user hook is empty then we can add another
+% test (or the kernel could put something into the before hook.
+%
% \changes{v1.0d}{2020/11/23}{Check for both kernel and user hook (gh/431)}
+% \changes{v1.0f}{2021/01/08}{Added another kernel hook for more
+% flexibility (cf \texttt{https://github.com/pgf-tikz/pgf/issues/960}}
% \begin{macrocode}
\bool_lazy_and:nnF
{ \hook_if_empty_p:n {shipout/background} }
{ \tl_if_empty_p:N \@kernel at before@shipout at background }
{ \@@_add_background_picture:n
{ \@kernel at before@shipout at background
- \hook_use:n {shipout/background} } }
+ \hook_use:n {shipout/background}
+ \@kernel at after@shipout at background } }
% \end{macrocode}
% We then run \cs{@@_execute_firstpage_hook:} that adds
% the content of the hook \hook{shipout/firstpage} to the
More information about the latex3-commits
mailing list.