[latex3-commits] [git/LaTeX3-latex3-hyperref] cleanup-patches: remove lastpage patch, is unneeded (07eafb1)
Ulrike Fischer
fischer at troubleshooting-tex.de
Mon Jul 12 23:43:30 CEST 2021
Repository : https://github.com/latex3/hyperref
On branch : cleanup-patches
Link : https://github.com/latex3/hyperref/commit/07eafb154c15bb626d4c2de8231143fb718dcf6c
>---------------------------------------------------------------
commit 07eafb154c15bb626d4c2de8231143fb718dcf6c
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date: Mon Jul 12 23:43:30 2021 +0200
remove lastpage patch, is unneeded
>---------------------------------------------------------------
07eafb154c15bb626d4c2de8231143fb718dcf6c
ChangeLog.txt | 2 ++
hyperref.dtx | 76 +----------------------------------------------------------
2 files changed, 3 insertions(+), 75 deletions(-)
diff --git a/ChangeLog.txt b/ChangeLog.txt
index b9a13e2..4a2cb5e 100644
--- a/ChangeLog.txt
+++ b/ChangeLog.txt
@@ -4,6 +4,8 @@ XXXX-XX-XX Ulrike Fischer/David Carlisle
* move (basically unneeded) listings patches to external
package
* remove patch for titletoc, is now done by titletoc itself.
+ * remove lastpage patch, is no longer used as lastpage supports
+ hyperref directly.
2021-06-07 Ulrike Fischer/David Carlisle
diff --git a/hyperref.dtx b/hyperref.dtx
index 2687e12..27ec3c8 100644
--- a/hyperref.dtx
+++ b/hyperref.dtx
@@ -10732,82 +10732,8 @@
% \end{macrocode}
% \end{macro}
%
-%
-% \section{Package lastpage support}
-% Package lastpage directly writes the |\newlabel| command to the
-% aux file. Because package hyperref requires additional arguments,
-% the internal command |\lastpage at putlabel| is redefined.
-% The patch is deferred by |\AtBeginDocument|, because it is possible
-% that package lastpage is loaded after package hyperref.
-% The same algorithm (options hypertexnames and plainpages)
-% is used to get the page anchor name as
-% in |\Hy at EveryPageAnchor| (see sec. \ref{pagenum}).
-% The link will not work if option pageanchor is set to false.
-% \begin{macro}{\lastpage at putlabel}
-% \begin{macrocode}
-\Hy at AtBeginDocument{%
- \@ifclassloaded{revtex4}{%
- \@namedef{ver at lastpage.sty}{1994/06/25}%
- }{}%
- \@ifpackageloaded{lastpage}{%
- \ifHy at pageanchor
- \else
- \Hy at WarningNoLine{%
- The \string\pageref{LastPage} link doesn't work\MessageBreak
- with disabled option `pageanchor'%
- }%
- \fi
- \def\lastpage at putlabel{%
- \addtocounter{page}{-1}%
- \if at filesw
- \begingroup
- \let\@number\@firstofone
- \ifHy at pageanchor
- \ifHy at hypertexnames
- \ifHy at plainpages
- \def\Hy at temp{\arabic{page}}%
- \else
- \Hy at unicodefalse
- \pdfstringdef\Hy at temp{\thepage}%
- \fi
- \else
- \def\Hy at temp{\the\Hy at pagecounter}%
- \fi
- \fi
- \immediate\write\@auxout{%
- \string\newlabel
- {LastPage}{{}{\thepage}{}{%
- \ifHy at pageanchor page.\Hy at temp\fi}{}}%
- }%
- \endgroup
- \fi
- \addtocounter{page}{1}%
- }%
- \@ifclassloaded{revtex4}{%
- \begingroup
- \toks@\expandafter{\lastpage at putlabel}%
- \edef\x{\endgroup
- \def\noexpand\lastpage at putlabel{%
- \noexpand\stepcounter{page}%
- \the\toks@
- \noexpand\addtocounter{page}\noexpand\m at ne
- }%
- }%
- \x
- }{}%
- }{}%
-}
%</package>
-%<*check>
-\checkpackage{lastpage}[1994/06/25]
-\checkcommand\def\lastpage at putlabel{%
- \addtocounter{page}{-1}%
- \immediate\write\@auxout{%
- \string\newlabel{LastPage}{{}{\thepage}}%
- }%
- \addtocounter{page}{1}%
-}
-%</check>
+
%<*package>
% \end{macrocode}
% \end{macro}
More information about the latex3-commits
mailing list.