[latex3-commits] [git/LaTeX3-latex3-latex2e] xcite: merge in egreg's xcite package (76255203)

David Carlisle d.p.carlisle at gmail.com
Tue Jul 23 10:13:58 CEST 2019


Repository : https://github.com/latex3/latex2e
On branch  : xcite
Link       : https://github.com/latex3/latex2e/commit/762552036ed80ab68419d353e1832ee594396581

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

commit 762552036ed80ab68419d353e1832ee594396581
Author: David Carlisle <d.p.carlisle at gmail.com>
Date:   Tue Jul 23 09:13:58 2019 +0100

    merge in egreg's xcite package


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

762552036ed80ab68419d353e1832ee594396581
 required/tools/xr.dtx | 19 ++++++++++++++-----
 1 file changed, 14 insertions(+), 5 deletions(-)

diff --git a/required/tools/xr.dtx b/required/tools/xr.dtx
index 7889f713..c8cc83cd 100644
--- a/required/tools/xr.dtx
+++ b/required/tools/xr.dtx
@@ -25,7 +25,7 @@
 %
 %<package>\NeedsTeXFormat{LaTeX2e}
 %<package>\ProvidesPackage{xr}
-%<package>         [2019/01/05 v5.04 eXternal References (DPC)]
+%<package>         [2019/07/22 v5.05 eXternal References (DPC)]
 %
 %<*driver>
 \documentclass{ltxdoc}
@@ -56,7 +56,8 @@
 %           aux files of \cmd\include'ed files. (Reported by J-PD)}
 %
 % \changes{v5.02}{1994/05/28}{Update for LaTeX2e}
-% \changes{v5.02}{1994/05/28}{Fix for conditionals in aux file}
+% \changes{v5.03}{2018/10/01}{Fix for conditionals in aux file}
+% \changes{v5.05}{2019/07/20}{include xcite}
 %
 %
 % This package implements a system for eXternal References.
@@ -83,6 +84,11 @@
 % characters can not usually be used in |\label|, and similarly may not
 % be used in the optional argument to |\externaldocument|.
 %
+% As first suggested in Enrico Gregorio's |xcite| package, the current version
+% also allows |\cite| to reference |\bibitem| in the external document.
+% For fcompatibility with |xcite|, |\externalcitedocument| is made available 
+% as an alias for |\externaldocument|
+%
 % \StopEventually{}
 %
 % \section{The macros}
@@ -94,6 +100,7 @@
 % Check for the optional argument.
 %    \begin{macrocode}
 \def\externaldocument{\@ifnextchar[\XR@{\XR@[]}}
+\let\externalcitedocument\externaldocument
 %    \end{macrocode}
 %
 % Save the optional prefix. Start processing the first |aux| file.
@@ -159,11 +166,13 @@
 \long\def\XR at test#1#2#3#4\XR@{%
   \let\XR at tempa\@gobbletwo
   \ifx#1\newlabel
-    \let\XR at tempa\@firstoftwo%
+    \let\XR at tempa\@firstoftwo
+  \else\ifx#1\bibcite
+    \let\XR at tempa\@firstoftwo
   \else\ifx#1\@input
      \let\XR at tempa\@secondoftwo
-  \fi\fi
-   \XR at tempa{\newlabel{\XR at prefix#2}{#3}}{\edef\XR at list{\XR at list#2\relax}}%
+  \fi\fi\fi
+   \XR at tempa{#1{\XR at prefix#2}{#3}}{\edef\XR at list{\XR at list#2\relax}}%
   \ifeof\@inputcheck\expandafter\XR at aux
   \else\expandafter\XR at read\fi}
 %    \end{macrocode}





More information about the latex3-commits mailing list