diff options
Diffstat (limited to 'Master/texmf-dist/source')
-rw-r--r-- | Master/texmf-dist/source/latex/collref/collref.dtx | 367 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/collref/collref.ins | 4 |
2 files changed, 211 insertions, 160 deletions
diff --git a/Master/texmf-dist/source/latex/collref/collref.dtx b/Master/texmf-dist/source/latex/collref/collref.dtx index 1b74ce4ac6a..85d80c15f0b 100644 --- a/Master/texmf-dist/source/latex/collref/collref.dtx +++ b/Master/texmf-dist/source/latex/collref/collref.dtx @@ -1,6 +1,6 @@ % \iffalse % -% collref.dtx Copyright (C) 2003-2009 Niklas Beisert +% collref.dtx Copyright (C) 2003-2014 Niklas Beisert % % This work may be distributed and/or modified under the % conditions of the LaTeX Project Public License, either version 1.3 @@ -11,17 +11,17 @@ % version 2005/12/01 or later. % % This work has the LPPL maintenance status `maintained'. -% +% % The Current Maintainer of this work is Niklas Beisert. % % This work consists of the files collref.dtx and collref.ins % and the derived files collref.sty and collsamp.tex % %<package|sample>\NeedsTeXFormat{LaTeX2e}[1996/12/01] -%<package>\ProvidesPackage{collref}[2009/09/07 v2.0 Collect References] -%<sample>\ProvidesFile{collsamp.tex}[2009/09/07 v2.0 Sample for Collect References] +%<package>\ProvidesPackage{collref}[2014/08/31 v2.0b Collect References] +%<sample>\ProvidesFile{collsamp.tex}[2014/08/31 v2.0b Sample for Collect References] %<*driver> -%\ProvidesFile{collref.drv}[2009/09/07 v2.0 Collect References Manual file] +%\ProvidesFile{collref.drv}[2014/08/31 v2.0b Collect References Manual file] \PassOptionsToClass{10pt,a4paper}{article} \documentclass{ltxdoc} @@ -32,39 +32,37 @@ \hypersetup{pdfstartview=FitH} \hypersetup{pdfpagemode=UseNone} - -%\newenvironment{thebib} -%{\list{[\theenumi]}{\parsep0cm\usecounter\enumi\def\makelabel##1{\hss\llap{##1}}}} -%{\endlist} - \newenvironment{thebib} {\list{[\theenumi]}{\parsep0pt\usecounter{enumi}}} {\endlist} \begin{document} -\title{The \textsf{collref} Package\thanks{\texttt{AEI-2009-054}}} +\title{The \textsf{collref} Package\thanks{% +Earlier versions developed at: Max-Planck-Institut f\"ur Gravitationsphysik (Albert-Einstein-Institut), Potsdam, Germany; +\texttt{AEI-2009-054}}} \hypersetup{pdftitle={The collref Package}} \author{Niklas Beisert\\[2ex] - Max-Planck-Institut f\"ur Gravitationsphysik\\ - Albert-Einstein-Institut - Am M\"uhlenberg 1\\ - 14476 Potsdam, Germany\\[1ex] - \href{mailto:nbeisert@aei.mpg.de}{\texttt{nbeisert@aei.mpg.de}}} + Institut f\"ur Theoretische Physik\\ + Eidgen\"ossische Technische Hochschule Z\"urich\\ + Wolfgang-Pauli-Strasse 27, 8093 Z\"urich, Switzerland\\[1ex] + \href{mailto:nbeisert@itp.phys.ethz.ch}{\texttt{nbeisert@itp.phys.ethz.ch}}} \hypersetup{pdfauthor={Niklas Beisert}} \hypersetup{pdfsubject={Manual for the LaTeX2e Package collref}} -\date{7 September 2009, \textsf{v2.0}} +\date{31 August 2014, \textsf{v2.0b}} \maketitle \begin{abstract}\noindent -\textsf{collref} is a \LaTeXe{} package to automatically collect -multiple \verb|\bibitem| references which always appear in the same sequence -in \verb|\cite| into a single \verb|\bibitem| block. +\textsf{collref} is a \LaTeXe{} package to automatically collect +multiple |\bibitem| references which always appear in the same sequence +in |\cite| into a single |\bibitem| block. \end{abstract} \tableofcontents -\section{Introduction} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\section{Introduction} Suppose a manuscript uses the following set of four references: % @@ -77,34 +75,36 @@ Suppose a manuscript uses the following set of four references: % Now if references B and C cover similar or related material, they might always be cited together as in ``[\ldots, 2, 3, \ldots]'' -throughout the manuscript. +throughout the manuscript. In some (physics) journals it is then customary to collect the two references into a single reference % \begin{thebib} \item Reference A -\item Reference B +\item Reference B \par Reference C \item Reference D \end{thebib} % and cite it by ``[\ldots, 2, \ldots]''. The package \textsf{collref} automates this process -by analysing the \verb|\cite| commands -and identifying blocks of references +by analysing the |\cite| commands +and identifying blocks of references which always appear in conjunction. These blocks are collapsed to a single item in the bibliography. -Please note that \textsf{collref} requires the sequence -of \verb|\bibitem| entries to match with -the sequence of \verb|\cite| blocks. +Please note that \textsf{collref} requires the sequence +of |\bibitem| entries to match with +the sequence of |\cite| blocks. This is most easily achieved through the use of \BibTeX{} with any \emph{unsorted} style. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Similar CTAN Packages.} -The objective and some of the implementation -of the \textsf{collref} package is similar to the -CTAN packages \href{http://www.ctan.org/tex-archive/macros/latex/contrib/mcite/}{\textsf{mcite}} by Thorsten Ohl + +The objective and some of the implementation +of the \textsf{collref} package is similar to the +CTAN packages \href{http://www.ctan.org/tex-archive/macros/latex/contrib/mcite/}{\textsf{mcite}} by Thorsten Ohl and \href{http://www.ctan.org/tex-archive/macros/latex/contrib/mciteplus/}{\textsf{mciteplus}} by Michael Shell, but the functionality is different is several respects: % @@ -114,40 +114,46 @@ but the functionality is different is several respects: \LaTeX{} documents which compile with \textsf{collref} should also compile fine without invoking \textsf{collref} (obviously without collected references). -The package decides automatically which references +The package decides automatically which references can be collapsed, no further interaction of the author is required. -\textsf{mcite} and \textsf{mciteplus} leave the -decision/duty to collapse certain references -using the modified syntax \verb|\cite{A,*B,*C}|. - +\textsf{mcite} and \textsf{mciteplus} leave the +decision/duty to collapse certain references +using the modified syntax |\cite{A,*B,*C}|. + \item \textsf{mcite} and \textsf{mciteplus} are intended to handle punctuations -in collapsed references correctly. +in collapsed references correctly. This requires a specialised \BibTeX{} style. No effort is made in \textsf{collref} in this regard. -Some minor modification in \texttt{collref.sty} -together with a modified \BibTeX{} style +Some minor modification in \texttt{collref.sty} +together with a modified \BibTeX{} style might achieve basic punctuation features similar to \textsf{mcite}. \end{itemize} % - -\section{Usage} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\section{Usage} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Inclusion.} -To use \textsf{collref} simply add the command -\begin{center}\verb|\usepackage{collref}|\end{center} + +To use \textsf{collref} simply add the command +\begin{center}|\usepackage{collref}|\end{center} to the preamble of your \LaTeX{} document. No further interaction is required. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Punctuation.} + \textsf{collref} provide basic punctuation between collected references. -This is specified through the package options -\verb|\usepackage[|\textit{opt}\verb|]{collref}| +This is specified through the package options +|\usepackage[|\textit{opt}|]{collref}| where \textit{opt} is one of the following \par\vspace{2ex}\noindent% \begin{minipage}[t]{0.24\linewidth} @@ -161,10 +167,10 @@ no separator: \end{minipage}% \begin{minipage}[t]{0.24\linewidth} \centerline{\texttt{parsep}}\par\vspace{1ex} -separated by \verb|\par|: +separated by |\par|: \begin{thebib} \item A -\item B +\item B \par C \item D \end{thebib} @@ -193,106 +199,127 @@ cf.\ note on spacing below. Alternative separators can be specified in the preamble through the command: \begin{center} -\verb|\collectsep[|\textit{punctuation}|]{|\textit{separator}\verb|}| +|\collectsep[|\textit{punctuation}|]{|\textit{separator}|}| \end{center} -The \textit{separator} appears between references in a block and +The \textit{separator} appears between references in a block and the \textit{punctuation} at the end of a block of references. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Bibliography Preparation.} + Please note that only such blocks of references can be collapsed -which appear in the same order for -\verb|\cite| commands as for \verb|thebibliography|. +which appear in the same order for +|\cite| commands as for |thebibliography|. It is recommended to prepare the bibliography through \BibTeX{} which does this automatically. You must use a style which does not sort the references -but preserves the order in which they were \verb|\cite|'d, +but preserves the order in which they were |\cite|'d, e.g.\ \texttt{unsrt.bst}. -Also note that \textsf{collref} suppresses -new paragraphs invoked by empty lines in the bibliography. -This allows to use standard \BibTeX{} styles -which commonly separate reference entries by empty lines. -If these empty lines would be expanded to new paragraphs, +Also note that \textsf{collref} suppresses +new paragraphs invoked by empty lines in the bibliography. +This allows to use standard \BibTeX{} styles +which commonly separate reference entries by empty lines. +If these empty lines would be expanded to new paragraphs, \textsf{collref} would not be able to join two references properly. -Therefore new paragraphs have to be invoked by the -command \verb|\par|. +Therefore new paragraphs have to be invoked by the +command |\par|. If you wish to use the style \texttt{punctsep}, please refer to the following note on spacing and punctuation. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Spacing and Punctuation.} -References are usually punctuated in some way. -Three of the predefined styles -- + +References are usually punctuated in some way. +Three of the predefined styles -- \texttt{nosep}, \texttt{parsep} and \texttt{bulletsep} -- preserve the punctuation from the bibliography. The fourth predefined style -- \texttt{punctsep} -- automatically performs the punctuation. -This however requires care in the preparation +This however requires care in the preparation of the bibliography: -The entries have to be provided \emph{without} punctuation. +The entries have to be provided \emph{without} punctuation. Furthermore, there must not be \emph{whitespaces} at the -end of an entry. -They can be suppressed with `\verb|%|' -or \verb|\ignorespaces| -directly following the last word of the entry. +end of an entry. +They can be suppressed with `|%|' +or |\ignorespaces| +directly following the last word of the entry. See Appendix \ref{sec:sample} for an example. The standard \BibTeX{} styles, e.g.\ \texttt{unsrt.bst}, have to be adjusted to remove the punctuation and whitespaces. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Control.} + The package \textsf{collref} provides one command to control which references (not) to collect: % \begin{center} -\verb|\nocollect{|\textit{label}\verb|}| +|\nocollect{|\textit{label}|}| \end{center} % It ensures that the label \textit{label} starts -a new block of references. -It is not collapsed with earlier references. -Later references, however, can still be collapsed +a new block of references. +It is not collapsed with earlier references. +Later references, however, can still be collapsed to the end of \textit{label}. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Labels for Blocks of References.} -While \textsf{collref} aims to automatically -collect similar references into a single block, it is often +While \textsf{collref} aims to automatically +collect similar references into a single block, it is often convenient for the author to refer to such blocks -with a single citation label. +with a single citation label. Standard \TeX/\LaTeX{} commands can be used to define such a block: \begin{center} -\verb|\newcommand{|\textit{$\backslash$blocklabel}\verb|}{|\textit{label1, label2, \ldots}\verb|}| +|\newcommand{|\textit{$\backslash$blocklabel}|}{|\textit{label1, label2, \ldots}|}| \end{center} Subsequently this block can be referenced with -\verb|\cite{|\textit{\ldots, $\backslash$blocklabel, \ldots}\verb|}|. +|\cite{|\textit{\ldots, $\backslash$blocklabel, \ldots}|}|. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \paragraph{Interaction with CTAN Packages.} The package \textsf{collref} has been tested with other CTAN packages concerned with citations and the bibliography: % \begin{itemize} -\item\textsf{cite}: +\item\textsf{cite}: \textsf{collref} works in conjunction with \textsf{cite}. Note that you must load \textsf{cite} \emph{before} \textsf{collref} -so that the latter can pass the correctly reduced list of +so that the latter can pass the correctly reduced list of references down to \textsf{cite}. -Tested with \textsf{cite v5.1}. +Tested with v5.1 and v5.3 (2010/09/10). \item -\textsf{hyperref}: +\textsf{hyperref}: \textsf{collref} works in conjunction with \textsf{hyperref}. The two packages can be loaded in any sequence. -Tested with \textsf{hyperref v6.78s}. +Tested with v6.78s and v6.83m (2012/11/06). \end{itemize} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \section{Revision History} -\paragraph{v2.0:} -2009/09/07 +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\paragraph{v2.0b:} 2014/08/31 + +\begin{itemize} +\item +updated author addresses +\item +minor internal changes +\end{itemize} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\paragraph{v2.0:} 2009/09/07 + \begin{itemize} \item proper punctuation added @@ -302,8 +329,9 @@ blocks of references enabled manual extended \end{itemize} -\paragraph{v1.0:} -2009/06/09 +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\paragraph{v1.0:} 2009/06/09 + \begin{itemize} \item streamlined detection of chains @@ -316,53 +344,67 @@ first version published on CTAN \end{itemize} \paragraph{v0.9:} + \begin{itemize} \item -package named \textsf{collect}; unpublished +package named \textsf{collect}; unpublished \end{itemize} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \section{Acknowledgements} -Thanks to Oleg Zhirov -for suggesting proper punctuation +Thanks to Oleg Zhirov +for suggesting proper punctuation and labels for blocks of references. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \appendix +\settowidth\MacroIndent{\rmfamily\scriptsize 000\ } +\parskip1ex +\parindent0pt + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \section{Files and Installation} -The package consists of the files +The package consists of the files % \begin{center} \begin{tabular}{ll} - \texttt{README} & readme file \\ - \texttt{collref.ins} & installation file \\ - \texttt{collref.dtx} & source file \\ - \texttt{collref.sty} & package file \\ - \texttt{collsamp.tex}& sample file \\ - \texttt{collref.pdf} & manual + |README| & readme file \\ + |collref.ins| & installation file \\ + |collref.dtx| & source file \\ + |collref.sty| & package file \\ + |collsamp.tex|& sample file \\ + |collref.pdf| & manual \end{tabular} \end{center} % -The distribution consists of the files -\texttt{README}, \texttt{collref.ins} and \texttt{collref.dtx}. +The distribution consists of the files +|README|, |collref.ins| and |collref.dtx|. % \begin{itemize} \item -Run (pdf)\LaTeX{} on \texttt{collref.dtx} to compile the manual \texttt{collref.pdf} (this file). +Run (pdf)\LaTeX{} on |collref.dtx| to compile the manual |collref.pdf| (this file). \item -Run \LaTeX{} on \texttt{collref.ins} to create the package \texttt{collref.sty} -and the sample \texttt{collsamp.tex}. -Copy the file \texttt{collref.sty} to an appropriate directory of your \LaTeX{} -distribution, e.g.\ \textit{texmf-root}\verb|/tex/latex/collref|. -Alternatively, you may copy \texttt{collref.sty} to the local directories of +Run \LaTeX{} on |collref.ins| to create the package |collref.sty| +and the sample |collsamp.tex|. +Copy the file |collref.sty| to an appropriate directory of your \LaTeX{} +distribution, e.g.\ \textit{texmf-root}|/tex/latex/collref|. +Alternatively, you may copy |collref.sty| to the local directories of manuscripts for which you wish to use \textsf{collref}. \end{itemize} \DocInput{collref.dtx} +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \section{Copyright} -Copyright \copyright{} 2003--2009 Niklas Beisert +Copyright \copyright{} 2003--2014 Niklas Beisert This work may be distributed and/or modified under the conditions of the \LaTeX{} Project Public License, either version 1.3 @@ -376,9 +418,9 @@ This work has the LPPL maintenance status `maintained'. The Current Maintainer of this work is Niklas Beisert. -This work consists of the files \texttt{README}, \texttt{collref.dtx} and \texttt{collref.ins} -as well as the derived files \texttt{collref.sty}, \texttt{collsamp.tex} -and \texttt{collref.pdf}. +This work consists of the files |README|, |collref.dtx| and |collref.ins| +as well as the derived files |collref.sty|, |collsamp.tex| +and |collref.pdf|. \end{document} @@ -386,7 +428,9 @@ and \texttt{collref.pdf}. % \fi % % -% +% +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \section{Sample File}\label{sec:sample} %\iffalse %<*sample> @@ -436,48 +480,51 @@ and \texttt{collref.pdf}. % \item reference 1; reference 2. % \item reference 3; reference 4. % \item reference 5 ; reference 6 . -% \item reference 7 . +% \item reference 7 . % \item reference 8; reference 9. % \end{thebib} % Note the different behaviour for references 5, 6 and 7 % for which trailing whitespaces were not removed. - +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \section{Implementation} %\iffalse %<*package> %\fi -% -% \parskip1ex -% \parindent0pt % -% In this section we describe the package \texttt{collref.sty}. +% In this section we describe the package |collref.sty|. % +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \paragraph{Internal Lists.} % -% For each bibliography label \textit{label} the package -% maintains a predecessor \verb|\nc@p@|\textit{label} -% and a successor \verb|\nc@s@|\textit{label}. +% For each bibliography label \textit{label} the package +% maintains a predecessor |\nc@p@|\textit{label} +% and a successor |\nc@s@|\textit{label}. % These are initially undefined. % When a label \textit{label} is first cited these labels % are set to the \textit{predecessor} and \textit{successor} labels, respectively, -% in \verb|\cite{|\textit{\ldots, predecessor, label, successor, \ldots}\verb|}|. -% An empty \verb|\nc@p@|\textit{label} or \verb|\nc@s@|\textit{label} +% in |\cite{|\textit{\ldots, predecessor, label, successor, \ldots}|}|. +% An empty |\nc@p@|\textit{label} or |\nc@s@|\textit{label} % refers to the beginning and end of a block, respectively. -% Whenever \verb|\cite| finds conflicting blocks -% (non-matching predecessors or successors in two \verb|\cite|'s), +% Whenever |\cite| finds conflicting blocks +% (non-matching predecessors or successors in two |\cite|'s), % it terminates the blocks to the maximum common overlap. -% -% +% +% +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \paragraph{Interface.} +% % The package provides two public commands, described above: % \begin{macrocode} \newcommand{\collectsep}[2][]{\def\nc@punct{#1}\def\nc@sep{#2}} \newcommand{\nocollect}[1]{\nc@breakbefore{#1}\ignorespaces} % \end{macrocode} +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \paragraph{Package Options.} +% % The package provides four predefined separators described above: % \begin{macrocode} \DeclareOption{nosep}{\collectsep{}} @@ -488,7 +535,9 @@ and \texttt{collref.pdf}. \ProcessOptions % \end{macrocode} +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \paragraph{Internal Commands.} +% % Some internal commands for abbreviation: % \begin{macrocode} \newcommand{\nc@getcsname}[1]{\csname #1\endcsname} @@ -496,7 +545,7 @@ and \texttt{collref.pdf}. % \end{macrocode} % Command to terminate the chain before a label: % The predecessor of the label is terminated. -% If the predecessor was active, its successor is also terminated. +% If the predecessor was active, its successor is also terminated. % \begin{macrocode} \newcommand{\nc@breakbefore}[1]{% \edef\nc@citepred{\@ifundefined{nc@p@#1}{}{\nc@getcsname{nc@p@#1}}}% @@ -513,11 +562,12 @@ and \texttt{collref.pdf}. } % \end{macrocode} +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \paragraph{Citations.} % -% Hack for \verb|\@citex|: -% It is assumed that (as in \LaTeXe) \verb|\cite| eventually -% passes down to \verb|\@citex|. +% Hack for |\@citex|: +% It is assumed that (as in \LaTeXe) |\cite| eventually +% passes down to |\@citex|. % \begin{macrocode} \let\nc@old@citex\@citex @@ -527,8 +577,8 @@ and \texttt{collref.pdf}. \let\nc@citelast\@empty% \edef\nc@citelist{#2}% % \end{macrocode} -% Main loop to process the arguments of \verb|\cite|. -% The current label is stored in \verb|\nc@citethis|. +% Main loop to process the arguments of |\cite|. +% The current label is stored in |\nc@citethis|. % \begin{macrocode} \@for\nc@citethis:={\nc@citelist}\do{% \edef\nc@citethis{\expandafter\@firstofone\nc@citethis\@empty}% @@ -537,9 +587,9 @@ and \texttt{collref.pdf}. % \begin{macrocode} \ifx\nc@citelast\@empty% \nc@breakbefore{\nc@citethis}% - \else% + \else% % \end{macrocode} -% Non-first entry: Fill undefined successor and predecessors entries +% Non-first entry: Fill undefined successor and predecessors entries % with the current chain sequence. % \begin{macrocode} \@ifundefined{nc@s@\nc@citelast}% @@ -547,7 +597,7 @@ and \texttt{collref.pdf}. \@ifundefined{nc@p@\nc@citethis}% {\nc@setcsname{nc@p@\nc@citethis}{\nc@citelast}}{}% % \end{macrocode} -% Get the successor and predecessors for the last and current entry, respectively. +% Get the successor and predecessors for the last and current entry, respectively. % \begin{macrocode} \edef\nc@citesucc{\nc@getcsname{nc@s@\nc@citelast}}% \edef\nc@citepred{\nc@getcsname{nc@p@\nc@citethis}}% @@ -566,8 +616,8 @@ and \texttt{collref.pdf}. \fi% \fi% % \end{macrocode} -% Get content of \verb|\b@|\textit{label} entry to find out -% whether the \verb|\bibitem{label}| entry exists. +% Get content of |\b@|\textit{label} entry to find out +% whether the |\bibitem{label}| entry exists. % We need to take special care of extended label definitions in \textsf{hyperref}. % \begin{macrocode} {\def\hyper@@link[##1]##2##3##4{##4}% @@ -580,9 +630,9 @@ and \texttt{collref.pdf}. \edef\nc@citestring{\nc@citestring\nc@citecomma\nc@citethis}% \fi% % \end{macrocode} -% Write \verb|\citation| tag to .aux file in original order. -% Some duplicate \verb|\citation|'s will be written by -% the original \verb|\citex| code, but these will have no impact. +% Write |\citation| tag to .aux file in original order. +% Some duplicate |\citation|'s will be written by +% the original |\citex| code, but these will have no impact. % \begin{macrocode} \if@filesw\immediate\write\@auxout{\string\citation{\nc@citethis}}\fi% % \end{macrocode} @@ -601,14 +651,15 @@ and \texttt{collref.pdf}. \nc@old@citex[#1]{\nc@citestring}% } % \end{macrocode} - + +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \paragraph{Bibliography.} % -% Enhance the \verb|thebibliography| environment to -% a) set the \verb|\nc@biblast| label to something, -% and empty \verb|\nc@nextpunct| -% (no predecessor for the first entry), -% b) convert linebreaks into whitespaces (avoid implicit \verb|\par|'s), and +% Enhance the |thebibliography| environment to +% a) set the |\nc@biblast| label to something, +% and empty |\nc@nextpunct| +% (no predecessor for the first entry), +% b) convert linebreaks into whitespaces (avoid implicit |\par|'s), and % c) put the final punctuation for the last entry. % % \begin{macrocode} @@ -625,32 +676,32 @@ and \texttt{collref.pdf}. \nc@nextpunct% \nc@old@endthebibliography} % \end{macrocode} - -% Overwrite \verb|\bibitem|: + +% Overwrite |\bibitem|: % It is assumed that the native \LaTeXe{} code % is equivalent but with the \LaTeX{} -% internals \verb|\@lbibitem| and \verb|\@bibitem|. -% Some other packages may also redefine \verb|\bibitem| +% internals |\@lbibitem| and |\@bibitem|. +% Some other packages may also redefine |\bibitem| % and this will inevitable cause compatibility issues. % This implementation is safe with current versions of \textsf{hyperref}. % \begin{macrocode} \def\bibitem{\@ifnextchar[\nc@lbibitem\nc@bibitem} % \end{macrocode} -% -% \verb|\nc@noitem| is invoked in place of the original \verb|\@bibitem| or \verb|\@lbibitem| +% +% |\nc@noitem| is invoked in place of the original |\@bibitem| or |\@lbibitem| % for collapsed references: % \begin{macrocode} \def\nc@noitem#1{% \if@filesw\immediate\write\@auxout{\string\bibcite{#1}{}}\fi% \ignorespaces} % \end{macrocode} - -% The hack for \verb|\@bibitem|: It checks whether -% this reference is part of a block. -% If so, put separator and collect by \verb|\nc@noitem|. -% Otherwise put punctuation and pass down to \verb|\@bibitem|. -% Finally let \verb|\nc@biblast| point to current item, -% and fill the punctuation \verb|\nc@nextpunct| for the next entry. + +% The hack for |\@bibitem|: It checks whether +% this reference is part of a block. +% If so, put separator and collect by |\nc@noitem|. +% Otherwise put punctuation and pass down to |\@bibitem|. +% Finally let |\nc@biblast| point to current item, +% and fill the punctuation |\nc@nextpunct| for the next entry. % \begin{macrocode} \def\nc@bibitem#1{% \edef\nc@bibpred{\@ifundefined{nc@p@#1}{}{\nc@getcsname{nc@p@#1}}}% @@ -660,8 +711,8 @@ and \texttt{collref.pdf}. \xdef\nc@nextpunct{\nc@punct}% \ignorespaces} % \end{macrocode} - -% Similar hack for \verb|@lbibitem|: + +% Similar hack for |@lbibitem|: % \begin{macrocode} \def\nc@lbibitem[#1]#2{% \edef\nc@bibpred{\@ifundefined{nc@p@#2}{}{\nc@getcsname{nc@p@#2}}}% diff --git a/Master/texmf-dist/source/latex/collref/collref.ins b/Master/texmf-dist/source/latex/collref/collref.ins index d7ad8b08e3f..3f2b0268e12 100644 --- a/Master/texmf-dist/source/latex/collref/collref.ins +++ b/Master/texmf-dist/source/latex/collref/collref.ins @@ -2,7 +2,7 @@ \input docstrip.tex \keepsilent -% collref.ins Copyright (C) 2003-2009 Niklas Beisert +% collref.ins Copyright (C) 2003-2014 Niklas Beisert % % This work may be distributed and/or modified under the % conditions of the LaTeX Project Public License, either version 1.3 @@ -14,7 +14,7 @@ \preamble -Copyright (C) 2003-2009 Niklas Beisert +Copyright (C) 2003-2014 Niklas Beisert This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, either version 1.3 |