diff options
author | Karl Berry <karl@freefriends.org> | 2015-01-11 22:26:04 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-01-11 22:26:04 +0000 |
commit | 74c6de0fc4511889c4197491944e13dc83e87838 (patch) | |
tree | 6aec96dec08e60789ddf6356ebb9d3983c98d2fd /Master/texmf-dist | |
parent | ffd0a5d337e9ff3c89109f208771ec70f599ebef (diff) |
lexref (11jan15)
git-svn-id: svn://tug.org/texlive/trunk@36026 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/latex/lexref/README | 4 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/lexref/lexref.pdf | bin | 373456 -> 378685 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/lexref/lexref.tex | 204 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/lexref/lexref.sty | 278 |
4 files changed, 274 insertions, 212 deletions
diff --git a/Master/texmf-dist/doc/latex/lexref/README b/Master/texmf-dist/doc/latex/lexref/README index d683552664e..1dd6e2eb856 100644 --- a/Master/texmf-dist/doc/latex/lexref/README +++ b/Master/texmf-dist/doc/latex/lexref/README @@ -1,8 +1,10 @@ -lexref 2014/01/21 v1.0.1 alpha +lexref 2015/01/11 v1.1 alpha Copyright (c) Adrien Vion. adrien[dot]vion3[at]gmail[dot]com. -------------------------------------------------------- This LaTeX package is aimed at continental lawyers (especially swiss and german). It provides macros to make references to legal provisions conveniently and uniformly. It also allows the user to automatically add cited Acts to a nomenclature list and to build specific indexes for each cited Act. +IMPORTANT NOTICE for users who were using version 1.0.1a: the \DeclareLex macro has changed and now requires four arguments instead of three. Please modify your .tex documents accordingly (see documentation). + Please read the package documentation for further information. This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, either version 1.3 of this license or any later version. diff --git a/Master/texmf-dist/doc/latex/lexref/lexref.pdf b/Master/texmf-dist/doc/latex/lexref/lexref.pdf Binary files differindex e13eaabc8be..bc23454bf64 100644 --- a/Master/texmf-dist/doc/latex/lexref/lexref.pdf +++ b/Master/texmf-dist/doc/latex/lexref/lexref.pdf diff --git a/Master/texmf-dist/doc/latex/lexref/lexref.tex b/Master/texmf-dist/doc/latex/lexref/lexref.tex index c0f374c9e17..158da6a964c 100644 --- a/Master/texmf-dist/doc/latex/lexref/lexref.tex +++ b/Master/texmf-dist/doc/latex/lexref/lexref.tex @@ -31,7 +31,6 @@ \usepackage{geometry} \geometry {left=5cm, right=2cm, top=1.5cm, bottom=1.3cm, includeheadfoot} -\usepackage[CHde]{lexref} \titlepage{% title={lexref}, @@ -39,8 +38,8 @@ url={}, author={Adrien Vion}, email={adrien[dot]vion3[at]gmail[dot]com}, - revision={1.0.1a}, - date={2014-01-21}} + revision={1.1a}, + date={2015-01-11}} \hypersetup{% pdftitle={lexref}, @@ -117,12 +116,23 @@ \newcommand{\variable}[1]{$\langle$\textsl{#1}$\rangle$} +\usepackage[CHde]{lexref} + + \begin{document} + +\DeclareLex{ZGB}{ZGB} +\DeclareLex{OR}{OR} +\DeclareLex{FG}{FG} + \printtitlepage \begin{quote} -This document contains information about the \lexref package. This \LaTeX{} package is aimed at continental lawyers (especially swiss and german). It provides macros to make \textbf{references to legal provisions} conveniently and uniformly. It also allows the user to automatically add cited Acts to a \textbf{nomenclature list} and to build \textbf{specific indexes} for each cited Act.\end{quote} +This document contains information about the \lexref package. This \LaTeX{} package is aimed at continental lawyers (especially swiss and german). It provides macros to make \textbf{references to legal provisions} conveniently and uniformly. It also allows the user to automatically add cited Acts to a \textbf{nomenclature list} and to build \textbf{specific indexes} for each cited Act. + +\textbf{Important notice} for users who were using version 1.0.1a: \textbf{the \cs{DeclareLex} macro has changed} and now requires four arguments instead of three. Please modify your \tex documents accordingly (see below). +\end{quote} \tableofcontents @@ -135,7 +145,7 @@ Lawyers have to make reference to Acts, Codes and various kind of regulations ev This package has \textbf{three purposes}: \begin{enumerate} \item First of all, this package will help you \textbf{reference conveniently and uniformly regulations} inside your text, whether in text body, brackets or footnotes. By using a simple \cs{DeclareLex} macro, you define precisely and once and for all how each Act will be referenced. -\item Acts cited must frequently be added to a nomenclature list. When done manually, this can be painful, especially in long documents citing many different Acts. This package can do this 'dirty job' for you, ensuring that every cited Act will be \textbf{included in the nomenclature}. The package I chose to build the nomenclature is \texttt{nomencl}\footnote{\url{http://www.ctan.org/tex-archive/macros/latex/contrib/nomencl}}. The nomenclature list can also be completed with any arbitrary other shortcuts. +\item Cited Acts must frequently be added to a nomenclature list. When done manually, this can be painful, especially in long documents citing many different Acts. This package can do this 'dirty job' for you, ensuring that every cited Act will be \textbf{included in the nomenclature}. The package I chose to build the nomenclature is \texttt{nomencl}\footnote{\url{http://www.ctan.org/tex-archive/macros/latex/contrib/nomencl}}. The nomenclature list can also be completed with any arbitrary other shortcuts. \item A very useful thing for readers of legal books is an \textbf{index of every legal disposition cited}. Again, doing this manually is a tedious task; \lexref will also do this for you. The package \texttt{splitidx}\footnote{\url{http://www.ctan.org/pkg/splitindex}} is used to this end and creates a \textbf{separate subindex} for every Act. \end{enumerate} @@ -219,20 +229,36 @@ The four following options can also be loaded: The first step is using the following macro for each Act you want to cite in your document. \begin{ltxsyntax} -\cmditem{DeclareLex}{abbreviation}[Act's full name][alt option] +\cmditem{DeclareLex}{Act's macro}{printed abbreviation}[Act's full name][alt option] \end{ltxsyntax} An example with swiss ZGB would be (assuming the package option CHde is set): \begin{ltxcode} -<<\DeclareLex>>{ZGB}[Schweizerisches Zivilgesetzbuch vom 10. Dezember 1907] +<<\DeclareLex>>{ZGB}{ZGB}[Schweizerisches Zivilgesetzbuch vom 10. Dezember 1907] \end{ltxcode} -The third argument can be either undefined (\oarg{}) or containing 'alt' (\oarg{alt}). When it is set to 'alt', the article prefixes (by default \cs{DispPrefixMain} and \cs{DispsPrefixMain}) will be overrided by alternate article prefixes (\cs{DispPrefixAlt} and \cs{DispsPrefixAlt}), in every citation of the defined Act. This is useful to cite Acts which use a different prefix. For instance, with package option CHde, \cs{DispPrefixMain} is set to 'Art.' and \cs{DispPrefixAlt} to '\S'. If you want to cite the german BGB in the same document, you can use: +This macro will use its first argument (\prm{Act's macro}) to create a series of other macros. In this example, this command will create a \cs{ZGB} command (among others), which you can use in the whole document to cite this Act. +Because it is used to create macros, you should avoid using any special character (no spaces, etc.) in the first argument of \cs{DeclareLex}, and make sure it is different from any other macro already defined (otherwise your compilation will crash). + +For example, using \cs{ZGB}\marg{2} will print 'Art. 2 ZGB'. +The printed Act's name in this output (ZGB) is given by the second argument of \cs{DeclareLex} (\prm{printed abbreviation}). + +In this example there is no difference between first and second argument. In some cases, you may want the citation macro to be different than the printed name. Suppose you want to cite the \textit{Dresdner Entwurf} of 1866. You can then type: \begin{ltxcode} -<<\DeclareLex>>{BGB}[B\"urgerliches Gesetzbuch][alt] +<<\DeclareLex>>{DEw}{Dres. Entw.}[Dresdner Entwurf (1866)] +\end{ltxcode} + +This will create a \cs{DEw} macro, which when used (for instance \cs{DEw}\marg{88}) will output 'Art. 88 Dres. Entw.'. + +The third argument (\prm{Act's full name}) is only used for the nomenclature list, if desired (see p. \pageref{nomenclature}). + +The fourth argument can be either undefined (\oarg{}) or containing 'alt' (\oarg{alt}). When it is set to 'alt', the article prefixes (by default \cs{DispPrefixMain} and \cs{DispsPrefixMain}) will be overrided by alternate article prefixes (\cs{DispPrefixAlt} and \cs{DispsPrefixAlt}), in every citation of the defined Act. This is useful to cite Acts which use a different prefix. For instance, with package option CHde, \cs{DispPrefixMain} is set to 'Art.' and \cs{DispPrefixAlt} to '\S'. If you want to cite the german BGB in the same document, you can use: + +\begin{ltxcode} +<<\DeclareLex>>{BGB}{BGB}[B\"urgerliches Gesetzbuch][alt] \end{ltxcode} so that for example \cs{ZGB}\marg{2} will output 'Art. 2 ZGB', whereas \cs{BGB}\marg{154} will output '\S{} 154 BGB'. @@ -244,34 +270,34 @@ so that for example \cs{ZGB}\marg{2} will output 'Art. 2 ZGB', whereas \cs{BGB}\ The \cs{DeclareLex} creates for each Act the following macros: \begin{ltxsyntax} -\cmditem{\prm{abbreviation}}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] +\cmditem{\prm{Act's macro}}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] \end{ltxsyntax} \begin{ltxsyntax} -\cmditem{np\prm{abbreviation}}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] +\cmditem{np\prm{Act's macro}}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] \end{ltxsyntax} \begin{ltxsyntax} -\cmditem{\prm{abbreviation}ns}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] +\cmditem{\prm{Act's macro}ns}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] \end{ltxsyntax} \begin{ltxsyntax} -\cmditem{np\prm{abbreviation}ns}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] +\cmditem{np\prm{Act's macro}ns}{art./Art.}[al./Abs.][ch./Ziff.][let./lit.] \end{ltxsyntax} -As you can see, the control sequences names of these macros depend on the \variable{abbreviation} set as first argument in \cs{DeclareLex}. In the csnames, 'np' stands for 'no prefix' and 'ns' for 'no suffix' (the suffix being the Act's name). That explains the output of the macros, for instance (assuming the package option CHde is set): +As you can see, the control sequences names of these macros depend on the \variable{Act's macro} set as first argument in \cs{DeclareLex}. In the csnames, 'np' stands for 'no prefix' and 'ns' for 'no suffix' (the suffix being the Act's name). That explains the output of the macros, as the following example will show. % which means the diffrerence between these two macros is that the first will omit the article prefix ('560 Abs. 1 ZGB', whereas the second macro will output 'Art. 560 Abs. 1 ZGB'). -An example with swiss ZGB would be : +An example with swiss ZGB would be (assuming the package option CHde is set) : \begin{ltxcode} -<<\DeclareLex>>{ZGB}[Schweizerisches Zivilgesetzbuch vom 10. Dezember 1907] +<<\DeclareLex>>{ZGB}{ZGB}[Schweizerisches Zivilgesetzbuch vom 10. Dezember 1907] \end{ltxcode} which allows you to you use the following in your document @@ -308,7 +334,6 @@ These variants are useful to write lists of dispositions in your text. For insta 'Siehe insbesondere <<\ZGBns>>{2}[2], <<\npZGBns>>{3}[1] und <<\npZGB>>{8}' \end{ltxcode} -\DeclareLex{ZGB} you will get 'Siehe insbesondere \ZGBns{2}[2], \npZGBns{3}[1] und \npZGB{8}' @@ -317,16 +342,16 @@ instead of getting 'Siehe insbesondere \ZGB{2}[2], \ZGB{3}[1] und \ZGB{8}' -(which is by far less elegant). +(which would be by far less elegant). An example with letters: \begin{ltxcode} -<<\DeclareLex>>{OR} +<<\DeclareLex>>{OR}{OR} <<\OR>>{40a}[1][][b] \end{ltxcode} -\DeclareLex{OR} + will output '\OR{40a}[1][][b]'. Note that the prefix will detect if you're citing more than one provision and will then be in plural form (for instance, \S\S {} instead of \S). @@ -400,14 +425,32 @@ $^{nonies}$ Example (with package option CHde): -\DeclareLex{FG} \begin{ltxcode} -<<\DeclareLex>>{FG}[Fiktives Gesetz] +<<\DeclareLex>>{FG}{FG}[Fiktives Gesetz] <<\FG>>{40<<\quinquies>>}[1 <<\sqq>>] \end{ltxcode} Output: \FG{40\quinquies}[1 \sqq] +\subsection{Important note: don't use the citation macros in titles} + +You shouldn't use the citation commands in the titles (chapter, section, etc.). +If you do so, output will be normally printed but the Act will probably disappear from the nomenclature list. +If you still want the index features, please use the macro \cs{idx\variable{Act's macro}} (see p. \pageref{indexwhithoutprint}). + +For instance, instead of writing this: + +\begin{ltxcode} +<<\section>>{Le fardeau de la preuve (\CC{8})} +\end{ltxcode} + +write this: + +\begin{ltxcode} +<<\section>>{Le fardeau de la preuve (art. 8 CC)}<<\idxCC>>{8} +\end{ltxcode} + + \section{Customizing shortcuts and prefixes}\label{customization} Default shortcuts are listed in the annex (p. \pageref{annex}) and depend on the language/region options. @@ -418,11 +461,11 @@ You can fully customize them by using the following macro: \cmditem{RenewLexShortcut}{LexShortcut}{redefinition}[nomenclature] \end{ltxsyntax} -Suppose you want for instance that \cs{\variable{abbreviation}} commands output full 'article' or 'articles' instead of 'art.'. You can do it this way: +Suppose you want for instance that \cs{\variable{Act's macro}} commands output full 'article' or 'articles' instead of 'art.'. You can do it this way: \begin{ltxcode} -<<\RenewLexShortcut>>{<<\DispPrefixMain>>}{article }[] -<<\RenewLexShortcut>>{<<\DispsPrefixMain>>}{articles }[] +<<\RenewLexShortcut>>{DispPrefixMain}{article }[] +<<\RenewLexShortcut>>{DispsPrefixMain}{articles }[] \end{ltxcode} By leaving the third argument blank, you ensure this redefined shortcut won't appear in the nomenclature list anymore. @@ -438,8 +481,8 @@ A precision about the nomenclature list title: it is controlled by the macro \cs The following conditions must be concurrently fulfilled in order for an Act to appear in the nomenclature list: \begin{enumerate} \item the Act must have been declared with \cs{DeclareLex} -\item the second argument of \cs{DeclareLex} (i. e. the full name of the Act) has to be defined (otherwise it makes no sense to have it in the list!) -\item the Act must have been at least cited once in the document, using either \cs{\variable{abbreviation}} or any other main citation macro (see list above: \ref{citationmainmacros}). +\item the third argument of \cs{DeclareLex} (i. e. the full name of the Act) has to be defined (otherwise it makes no sense to have it in the list!) +\item the Act must have been at least cited once in the document, using either \cs{\variable{Act's macro}} or any other main citation macro (see list above: \ref{citationmainmacros}). \end{enumerate} Follow these steps: @@ -478,7 +521,7 @@ for every item of the nomenclature list, then rerun the steps 2-4 and 6 of the The following conditions must concurrently be fulfilled in order for the references to be indexed: \begin{enumerate} \item the Act must have been declared with \cs{DeclareLex} -\item the Act must have been at least cited once in the document, using either \cs{\variable{abbreviation}}, any other main citation macro (see list above: \ref{citationmainmacros}) or \cs{idx\variable{abbreviation}} +\item the Act must have been at least cited once in the document, using either \cs{\variable{Act's macro}}, any other main citation macro (see list above: \ref{citationmainmacros}) or \cs{idx\variable{Act's macro}} \end{enumerate} Follow these steps: @@ -493,7 +536,7 @@ splitindex.pl filename.idx It may be a bit more complicated, e. g. you'll have to locate the splitindex.pl in your texlive directory and then, in the terminal, run the script on the file specifying its absolute path, etc. -This script will create a new .idx file for each different Act cited in the document, follwing this syntax \variable{filename}-\variable{abbreviation}.idx +This script will create a new .idx file for each different Act cited in the document, follwing this syntax \variable{filename}-\variable{Act's macro}.idx \item get to the directory where your .tex file is located (on UNIX-like systems, use the 'cd' command to do so). @@ -503,18 +546,20 @@ This script will create a new .idx file for each different Act cited in the docu makeindex filename-abbreviation.idx \end{ltxcode} +(Please note that on some configurations, this step wasn't necessary.) + This will create .ilg and .ind files for every abbreviation. \item Return to your \LaTeX{} editor and insert the following macros where you want your index printed: \begin{ltxcode} <<\pagebreak>> -\section*{Cited Acts index}% Modify this title as you wish +\section*{Cited Acts' index}% Modify this title as you wish <<\twocolumn>> -<<\printsubindex*>> +<<\printindex*>> \end{ltxcode} -You can finetune the output by using a \cs{printsubindex}\oarg{\variable{abbreviation}} macro for every Act appearing in the index, rather than using \cs{printsubindex*}. This will also allow you to print other indexes than the Acts' index (general index, authors index, etc.). See the \texttt{splitidx} manual for further information. +You can finetune the output by using a \cs{printindex}\oarg{\variable{Act's macro}} macro for every Act appearing in the index, rather than using \cs{printindex*}. This will also allow you to print other indexes than the Acts' index (general index, authors index, etc.). See the \texttt{splitidx} manual for further information. \item Run latex once again. \end{enumerate} @@ -523,12 +568,14 @@ You can finetune the output by using a \cs{printsubindex}\oarg{\variable{abbrevi \subsection{Indexing without printing} +\label{indexwhithoutprint} + If you want to do this globally, you should consider the \texttt{noprint} option (see p. \pageref{options}). If, for any reason, you want to create an index entry at a given location in your file without having any printed output there, you can use \begin{ltxsyntax} -\cmditem{idx\prm{abbreviation}}{art./Art.}[par./al./Abs.][nr./ch./Ziff.][let./lit.] +\cmditem{idx\prm{Act's macro}}{art./Art.}[par./al./Abs.][nr./ch./Ziff.][let./lit.] \end{ltxsyntax} The \variable{abbreviation} is the first argument used in \cs{DeclareLex}. @@ -536,11 +583,18 @@ The \variable{abbreviation} is the first argument used in \cs{DeclareLex}. \section{Version History} -\subsection*{Version 1.0.1$\alpha$, 21 january 2014} +\subsection*{Version 1.1$\alpha$, 11 January 2015} + +\begin{itemize} +\item Modification of the \cs{DeclareLex} macro, which has now four arguments instead of three. Aim is to separate the csname used for citations and the printed act's name. +\item Fixed a bug regarding the nomenclature, now using toggles to ensure that the \cs{nomenclature} macro will be only issued once per abbreviation. +\end{itemize} + +\subsection*{Version 1.0.1$\alpha$, 21 January 2014} Minor bug fix (unwanted space). -\subsection*{Version 1.0$\alpha$, 3 december 2013} +\subsection*{Version 1.0$\alpha$, 3 December 2013} First public version. @@ -551,19 +605,19 @@ First public version. \caption{Default settings (english)} \begin{tabularx}{\textwidth}{@{}p{4cm}@{}p{3cm}@{}X@{}} \toprule -\multicolumn{1}{@{}H}{macro} & +\multicolumn{1}{@{}H}{LexShortcut} & \multicolumn{1}{@{}H}{output} & \multicolumn{1}{@{}H}{nomenclature} \\ \cmidrule(r){1-1}\cmidrule(r){2-2}\cmidrule{3-3} -\cs{DispPrefixMain} & art. & article(s) \\ %\hline -\cs{DispsPrefixMain} & art. & \\ %\hline -\cs{DispPrefixAlt} &\S{} & \\ %\hline -\cs{DispsPrefixAlt} & \S\S{} & \\ %\hline -\cs{SubPrefix} & par. & paragraph(s)\\ %\hline -\cs{SubSubPrefixNumber} & nr. & number(s)\\ %\hline -\cs{SubSubPrefixLetter} & let. & letter(s)\\ %\hline -\cs{sq} & sq. & sequiturque\\ %\hline -\cs{sqq} & sqq. & sequunturque\\ %\hline +{DispPrefixMain} & art. & article(s) \\ %\hline +{DispsPrefixMain} & art. & \\ %\hline +{DispPrefixAlt} &\S{} & \\ %\hline +{DispsPrefixAlt} & \S\S{} & \\ %\hline +{SubPrefix} & par. & paragraph(s)\\ %\hline +{SubSubPrefixNumber} & nr. & number(s)\\ %\hline +{SubSubPrefixLetter} & let. & letter(s)\\ %\hline +{sq} & sq. & sequiturque\\ %\hline +{sqq} & sqq. & sequunturque\\ %\hline \cs{nomname} & Nomenclature & \\ %\hline \bottomrule \end{tabularx} @@ -574,19 +628,19 @@ First public version. \caption{CHfr settings} \begin{tabularx}{\textwidth}{@{}p{4cm}@{}p{3cm}@{}X@{}} \toprule -\multicolumn{1}{@{}H}{macro} & +\multicolumn{1}{@{}H}{LexShortcut} & \multicolumn{1}{@{}H}{output} & \multicolumn{1}{@{}H}{nomenclature} \\ \cmidrule(r){1-1}\cmidrule(r){2-2}\cmidrule{3-3} -\cs{DispPrefixMain} & art. & article(s) \\ %\hline -\cs{DispsPrefixMain} & art. & \\ %\hline -\cs{DispPrefixAlt} &\S{} & \\ %\hline -\cs{DispsPrefixAlt} & \S\S{} & \\ %\hline -\cs{SubPrefix} & al. & alin\'ea(s)\\ %\hline -\cs{SubSubPrefixNumber} & ch. & chiffre(s)\\ %\hline -\cs{SubSubPrefixLetter} & let. & lettre(s)\\ %\hline -\cs{sq} & s. & et suivant(e)\\ %\hline -\cs{sqq} & ss & et suivant(e)s\\ %\hline +{DispPrefixMain} & art. & article(s) \\ %\hline +{DispsPrefixMain} & art. & \\ %\hline +{DispPrefixAlt} &\S{} & \\ %\hline +{DispsPrefixAlt} & \S\S{} & \\ %\hline +{SubPrefix} & al. & alin\'ea(s)\\ %\hline +{SubSubPrefixNumber} & ch. & chiffre(s)\\ %\hline +{SubSubPrefixLetter} & let. & lettre(s)\\ %\hline +{sq} & s. & et suivant(e)\\ %\hline +{sqq} & ss & et suivant(e)s\\ %\hline \cs{nomname} & Abr\'eviations & \\ %\hline \bottomrule \end{tabularx} @@ -597,19 +651,19 @@ First public version. \caption{CHde settings} \begin{tabularx}{\textwidth}{@{}p{4cm}@{}p{3cm}@{}X@{}} \toprule -\multicolumn{1}{@{}H}{macro} & +\multicolumn{1}{@{}H}{LexShortcut} & \multicolumn{1}{@{}H}{output} & \multicolumn{1}{@{}H}{nomenclature} \\ \cmidrule(r){1-1}\cmidrule(r){2-2}\cmidrule{3-3} -\cs{DispPrefixMain} & Art. & Artikel \\ %\hline -\cs{DispsPrefixMain} & Art. & \\ %\hline -\cs{DispPrefixAlt} &\S{} & \\ %\hline -\cs{DispsPrefixAlt} & \S\S{} & \\ %\hline -\cs{SubPrefix} & Abs. & Absatz, -\"{ }e\\ %\hline -\cs{SubSubPrefixNumber} & Ziff. & Ziffer(n)\\ %\hline -\cs{SubSubPrefixLetter} & lit. & litera\\ %\hline -\cs{sq} & f. & und die folgende\\ %\hline -\cs{sqq} & ff. & und die folgenden\\ %\hline +{DispPrefixMain} & Art. & Artikel \\ %\hline +{DispsPrefixMain} & Art. & \\ %\hline +{DispPrefixAlt} &\S{} & \\ %\hline +{DispsPrefixAlt} & \S\S{} & \\ %\hline +{SubPrefix} & Abs. & Absatz, -\"{ }e\\ %\hline +{SubSubPrefixNumber} & Ziff. & Ziffer(n)\\ %\hline +{SubSubPrefixLetter} & lit. & litera\\ %\hline +{sq} & f. & und die folgende\\ %\hline +{sqq} & ff. & und die folgenden\\ %\hline \cs{nomname} & Abk\"urzungen & \\ %\hline \bottomrule \end{tabularx} @@ -620,19 +674,19 @@ First public version. \caption{DE settings} \begin{tabularx}{\textwidth}{@{}p{4cm}@{}p{3cm}@{}X@{}} \toprule -\multicolumn{1}{@{}H}{macro} & +\multicolumn{1}{@{}H}{LexShortcut} & \multicolumn{1}{@{}H}{output} & \multicolumn{1}{@{}H}{nomenclature} \\ \cmidrule(r){1-1}\cmidrule(r){2-2}\cmidrule{3-3} -\cs{DispPrefixMain} &\S{} & \\ %\hline -\cs{DispsPrefixMain} & \S\S{} & \\ %\hline -\cs{DispPrefixAlt} & Art. & Artikel \\ %\hline -\cs{DispsPrefixAlt} & Art. & \\ %\hline -\cs{SubPrefix} & Abs. & Absatz, -\"{ }e\\ %\hline -\cs{SubSubPrefixNumber} & Ziff. & Ziffer(n)\\ %\hline -\cs{SubSubPrefixLetter} & lit. & litera\\ %\hline -\cs{sq} & f. & und die folgende\\ %\hline -\cs{sqq} & ff. & und die folgenden\\ %\hline +{DispPrefixMain} &\S{} & \\ %\hline +{DispsPrefixMain} & \S\S{} & \\ %\hline +{DispPrefixAlt} & Art. & Artikel \\ %\hline +{DispsPrefixAlt} & Art. & \\ %\hline +{SubPrefix} & Abs. & Absatz, -\"{ }e\\ %\hline +{SubSubPrefixNumber} & Ziff. & Ziffer(n)\\ %\hline +{SubSubPrefixLetter} & lit. & litera\\ %\hline +{sq} & f. & und die folgende\\ %\hline +{sqq} & ff. & und die folgenden\\ %\hline \cs{nomname} & Abk\"urzungen & \\ %\hline \bottomrule \end{tabularx} diff --git a/Master/texmf-dist/tex/latex/lexref/lexref.sty b/Master/texmf-dist/tex/latex/lexref/lexref.sty index ed804a95500..220c356aef8 100644 --- a/Master/texmf-dist/tex/latex/lexref/lexref.sty +++ b/Master/texmf-dist/tex/latex/lexref/lexref.sty @@ -1,5 +1,9 @@ +%lexref 2015/01/11 v1.1 alpha +%Copyright (c) Adrien Vion. adrien[dot]vion3[at]gmail[dot]com. +%This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, either version 1.3 of this license or any later version. +%The latest version of this license is in http://www.latex-project.org/lppl.txt and version 1.3 or later is part of all distributions of LaTeX version 2005/12/01 or later. %------------ identification -------------- -\ProvidesPackage{lexref}[2014/01/21 v1.0.1a]% +\ProvidesPackage{lexref}[2015/01/11 v1.1a]% \NeedsTeXFormat{LaTeX2e}% %------------ package loading -------------- \RequirePackage{etoolbox}% @@ -23,13 +27,13 @@ \newcounter{lexcitecountinteger} % Error messages setting \newcommand{\lexcite@err@invalidthirdarg@DeclareLex}{\PackageError{lexref}{% -Third argument of \protect\DeclareLex\space must +Fourth argument of \protect\DeclareLex\space must be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} %------------ declaration of options -------------- \DeclareOption{noprint}{\toggletrue{lexnoprint}} \DeclareOption{indexing}{\toggletrue{lexindexing}\makeindex} \DeclareOption{nomencl}{\toggletrue{lexnomencl}\robustify{\nomenclature}\makenomenclature} -\DeclareOption{shortcutstolist}{\toggletrue{lexshortcutstolist}\makenomenclature}%\robustify{\nomenclature}} +\DeclareOption{shortcutstolist}{\toggletrue{lexshortcutstolist}\makenomenclature} \DeclareOption{CHfr}{\toggletrue{lexrefCHfr}} \DeclareOption{CHde}{\toggletrue{lexrefCHde}} \DeclareOption{DE}{\toggletrue{lexrefDE}} @@ -37,180 +41,166 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} \ProcessOptions %------------ main code -------------- % DEFINITION OF LITERAL PREFIXES AND SHORTCUTS +% +% \NewLexShortcut +% #1 = Shortcutname +% #2 = Printed Shortcut +% #3 (optional) = Unabreviated shortcut \newcommandx{\NewLexShortcut}[3][3]{% -\ifdef{#1}{% This test makes sure an already defined command is overrided, ensuring the nomenclature tests will work properly -\renewrobustcmd{#1}{#2% -\iftoggle{lexshortcutstolist}{% Entry in nomenclature, if option activated and #3 defined. - \ifstrempty{#3}% - {}% - {\ifcsdef{nomalreadydef#2}% Nomencl crashes if the same act is already passed to \nomenclature in another page, so this test ensures it won't be passed more than once - {}% - {% - \nomenclature{#2}{#3}% - \expandafter\newcommand\csname nomalreadydef#2\endcsname\relax% - }% - }% - }% - {}% -}}% -{% -\newrobustcmd{#1}{#2% -\iftoggle{lexshortcutstolist}{% Entry in nomenclature, if option activated and #3 defined. - \ifstrempty{#3}% +% 1) Creation of a toggle for nomenclature, if needed +\iftoggle{lexshortcutstolist}{\newtoggle{#1nmcl}\global\togglefalse{#1nmcl}}{}% +% 2) Creation of the Shortcut macro +\expandafter\newcommandx\csname#1\endcsname{#2% +% 3) Adding to nomenclature list, if needed +\iftoggle{lexshortcutstolist}{% +\ifstrempty{#3}{}{% + \iftoggle{#1nmcl}% {}% - {\ifcsdef{nomalreadydef#2}% Nomencl crashes if the same act is already passed to \nomenclature in another page, so this test ensures it won't be passed more than once - {}% - {% - \nomenclature{#2}{#3}% - \expandafter\newcommand\csname nomalreadydef#2\endcsname\relax% - }% - }% + {\nomenclature{#2}{#3}\global\toggletrue{#1nmcl}}% + }}% + {}% }% - {}% -}}% -}% -% Following shortcuts may be redefined using \RenewLexShortcut +} +% \RenewLexShortcut \newcommandx{\RenewLexShortcut}[3][3]{% -\renewrobustcmd{#1}{#2% -\iftoggle{lexshortcutstolist}{% Entry in nomenclature, if option activated and #3 defined. - \ifstrempty{#3}% +% 1) Creation of the Shortcut macro +\expandafter\renewcommandx\csname#1\endcsname{#2% +% 2) Adding to nomenclature list, if needed +\iftoggle{lexshortcutstolist}{% +\ifstrempty{#3}{}{% + \iftoggle{#1nmcl}% {}% - {\ifcsdef{nomalreadydef#2}% Nomencl crashes if the same act is already passed to \nomenclature in another page, so this test ensures it won't be passed more than once - {}% - {% - \nomenclature{#2}{#3}% - \expandafter\newcommand\csname nomalreadydef#2\endcsname\relax% - }% - }% + {\nomenclature{#2}{#3}\global\toggletrue{#1nmcl}}% + }}% + {}% }% - {}% -}} +} % Default shortcuts: english -\NewLexShortcut{\DispPrefixMain}{art.}[article(s)]% -\NewLexShortcut{\DispsPrefixMain}{art.}% -\NewLexShortcut{\DispPrefixAlt}{\S}% -\NewLexShortcut{\DispsPrefixAlt}{\S\S}% -\NewLexShortcut{\SubPrefix}{par.}[paragraph(s)] -\NewLexShortcut{\SubSubPrefixNumber}{nr.}[number(s)] -\NewLexShortcut{\SubSubPrefixLetter}{let.}[letter(s)] -\NewLexShortcut{\sq}{sq.}[sequiturque] -\NewLexShortcut{\sqq}{sqq.}[sequunturque] -\NewLexShortcut{\analog}{by an.}[by analogy] +\NewLexShortcut{DispPrefixMain}{art.}[article(s)]% +\NewLexShortcut{DispsPrefixMain}{art.}% +\NewLexShortcut{DispPrefixAlt}{\S}% +\NewLexShortcut{DispsPrefixAlt}{\S\S}% +\NewLexShortcut{SubPrefix}{par.}[paragraph(s)] +\NewLexShortcut{SubSubPrefixNumber}{nr.}[number(s)] +\NewLexShortcut{SubSubPrefixLetter}{let.}[letter(s)] +\NewLexShortcut{sq}{sq.}[sequiturque] +\NewLexShortcut{sqq}{sqq.}[sequunturque] +\NewLexShortcut{analog}{by an.}[by analogy] % french shortcuts \iftoggle{lexrefCHfr}{% -\RenewLexShortcut{\DispPrefixMain}{art.}[article(s)]% -\RenewLexShortcut{\DispsPrefixMain}{art.}% -\RenewLexShortcut{\DispPrefixAlt}{\S}% -\RenewLexShortcut{\DispsPrefixAlt}{\S\S}% -\RenewLexShortcut{\SubPrefix}{al.}[alin\'ea(s)] -\RenewLexShortcut{\SubSubPrefixNumber}{ch.}[chiffre(s)] -\RenewLexShortcut{\SubSubPrefixLetter}{let.}[lettre(s)] -\RenewLexShortcut{\sq}{s.}[et suivant(e)] -\RenewLexShortcut{\sqq}{ss}[et suivant(e)s] -\RenewLexShortcut{\analog}{p. an.}[par analogie] +\RenewLexShortcut{DispPrefixMain}{art.}[article(s)]% +\RenewLexShortcut{DispsPrefixMain}{art.}% +\RenewLexShortcut{DispPrefixAlt}{\S}% +\RenewLexShortcut{DispsPrefixAlt}{\S\S}% +\RenewLexShortcut{SubPrefix}{al.}[alin\'ea(s)] +\RenewLexShortcut{SubSubPrefixNumber}{ch.}[chiffre(s)] +\RenewLexShortcut{SubSubPrefixLetter}{let.}[lettre(s)] +\RenewLexShortcut{sq}{s.}[et suivant(e)] +\RenewLexShortcut{sqq}{ss}[et suivant(e)s] +\RenewLexShortcut{analog}{p. an.}[par analogie] \renewrobustcmd{\nomname}{Abr\'eviations} }{} % german CH shortcuts \iftoggle{lexrefCHde}{% -\RenewLexShortcut{\DispPrefixMain}{Art.}[Artikel(n)]% -\RenewLexShortcut{\DispsPrefixMain}{Art.}% -\RenewLexShortcut{\DispPrefixAlt}{\S}% -\RenewLexShortcut{\DispsPrefixAlt}{\S\S}% -\RenewLexShortcut{\SubPrefix}{Abs.}[Absatz, -\"{ }e] -\RenewLexShortcut{\SubSubPrefixNumber}{Ziff.}[Ziffer(n)] -\RenewLexShortcut{\SubSubPrefixLetter}{lit.}[litera] -\RenewLexShortcut{\sq}{f.}[und die folgende] -\RenewLexShortcut{\sqq}{ff.}[und die folgenden] -\RenewLexShortcut{\analog}{analog} +\RenewLexShortcut{DispPrefixMain}{Art.}[Artikel(n)]% +\RenewLexShortcut{DispsPrefixMain}{Art.}% +\RenewLexShortcut{DispPrefixAlt}{\S}% +\RenewLexShortcut{DispsPrefixAlt}{\S\S}% +\RenewLexShortcut{SubPrefix}{Abs.}[Absatz, -\"{ }e] +\RenewLexShortcut{SubSubPrefixNumber}{Ziff.}[Ziffer(n)] +\RenewLexShortcut{SubSubPrefixLetter}{lit.}[litera] +\RenewLexShortcut{sq}{f.}[und die folgende] +\RenewLexShortcut{sqq}{ff.}[und die folgenden] +\RenewLexShortcut{analog}{analog} \renewrobustcmd{\nomname}{Abk\"urzungen} }{} % german DE shortcuts \iftoggle{lexrefDE}{% -\RenewLexShortcut{\DispPrefixMain}{\S}% -\RenewLexShortcut{\DispsPrefixMain}{\S\S}% -\RenewLexShortcut{\DispPrefixAlt}{Art.}[Artikel(n)]% -\RenewLexShortcut{\DispsPrefixAlt}{Art.}% -\RenewLexShortcut{\SubPrefix}{Abs.}[Absatz, -\"{ }e] -\RenewLexShortcut{\SubSubPrefixNumber}{Ziff.}[Ziffer(n)] -\RenewLexShortcut{\SubSubPrefixLetter}{lit.}[litera] -\RenewLexShortcut{\sq}{f.}[und die folgende] -\RenewLexShortcut{\sqq}{ff.}[und die folgenden] -\RenewLexShortcut{\analog}{analog} +\RenewLexShortcut{DispPrefixMain}{\S}% +\RenewLexShortcut{DispsPrefixMain}{\S\S}% +\RenewLexShortcut{DispPrefixAlt}{Art.}[Artikel(n)]% +\RenewLexShortcut{DispsPrefixAlt}{Art.}% +\RenewLexShortcut{SubPrefix}{Abs.}[Absatz, -\"{ }e] +\RenewLexShortcut{SubSubPrefixNumber}{Ziff.}[Ziffer(n)] +\RenewLexShortcut{SubSubPrefixLetter}{lit.}[litera] +\RenewLexShortcut{sq}{f.}[und die folgende] +\RenewLexShortcut{sqq}{ff.}[und die folgenden] +\RenewLexShortcut{analog}{analog} \renewrobustcmd{\nomname}{Abk\"urzungen} }{} % Latin shortcuts -\NewLexShortcut{\bis}{$^{bis}$} -\NewLexShortcut{\ter}{$^{ter}$} -\NewLexShortcut{\quater}{$^{quater}$} -\NewLexShortcut{\quinquies}{$^{quinquies}$} -\NewLexShortcut{\sexies}{$^{sexies}$} -\NewLexShortcut{\septies}{$^{septies}$} -\NewLexShortcut{\octies}{$^{octies}$} -\NewLexShortcut{\nonies}{$^{nonies}$} +\NewLexShortcut{bis}{$^{bis}$} +\NewLexShortcut{ter}{$^{ter}$} +\NewLexShortcut{quater}{$^{quater}$} +\NewLexShortcut{quinquies}{$^{quinquies}$} +\NewLexShortcut{sexies}{$^{sexies}$} +\NewLexShortcut{septies}{$^{septies}$} +\NewLexShortcut{octies}{$^{octies}$} +\NewLexShortcut{nonies}{$^{nonies}$} % FRONT-END USER INTERFACE - % #1 = Act abbr. - % #2 = Act full name - % #3 = alt option + % #1 = CSname + % #2 = Printed Act abbr. + % #3 = Act full name + % #4 = alt option -\newcommandx{\DeclareLex}[3][2,3]{% +\newcommandx{\DeclareLex}[4][3,4]{% \protecting{% -% 1) Creation of \newindex, if needed -\iftoggle{lexindexing}{\newindex[#2]{#1}}{}% +% 1) Creation of \newindex + toggle for nomenclature, if needed +\iftoggle{lexindexing}{\newindex[#3]{#1}}{}% +\iftoggle{lexnomencl}{\newtoggle{#1nmcl}\global\togglefalse{#1nmcl}}{}% % 2) Creation of \#1 command \expandafter\newcommandx\csname#1\endcsname[4][2,3,4]{% -\ifstrempty{#3}{\togglefalse{lexaltoverride}}{\ifstrequal{#3}{alt}{\toggletrue{lexaltoverride}}{\lexcite@err@invalidthirdarg@DeclareLex}}%Checking whether #3 is blank or set to 'alt', else: error -\iftoggle{lexnoprint}{}{\LexRef{#1}{##1}[##2][##3][##4]}% Printing, unless noprint option activated -\iftoggle{lexnomencl}{% Entry in nomenclature, if option activated and #2 defined. - \ifstrempty{#2}% +\ifstrempty{#4}{\togglefalse{lexaltoverride}}{\ifstrequal{#4}{alt}{\toggletrue{lexaltoverride}}{\lexcite@err@invalidthirdarg@DeclareLex}}%Checking whether #4 is blank or set to 'alt', else: error +\iftoggle{lexnoprint}{}{\LexRef{#2}{##1}[##2][##3][##4]}% Printing, unless noprint option activated +\iftoggle{lexnomencl}{% Entry in nomenclature, if option activated and #3 defined. + \ifstrempty{#3}% {}% - {\ifcsdef{nomalreadydef#1}% Nomencl crashes if the same act is already passed to \nomenclature in another page, so this test ensures it won't be passed more than once + {\iftoggle{#1nmcl}% {}% - {% - \nomenclature{#1}{#2}% - \expandafter\newcommand\csname nomalreadydef#1\endcsname\relax}% + {\nomenclature{#2}{#3}\global\toggletrue{#1nmcl}}% }% }% {}% -\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]}{}% Indexing, if option activated +\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]{#2}}{}% Indexing, if option activated }% % 3) Creation of \#1ns command \expandafter\newcommandx\csname #1ns\endcsname[4][2,3,4]{% -\ifstrempty{#3}{\togglefalse{lexaltoverride}}{\ifstrequal{#3}{alt}{\toggletrue{lexaltoverride}}{\lexcite@err@invalidthirdarg@DeclareLex}}%Checking whether #3 is blank or set to 'alt', else: error -\iftoggle{lexnoprint}{}{\LexRefns{#1}{##1}[##2][##3][##4]}% Printing, unless noprint option activated -\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]}{}% Indexing, if option activated +\ifstrempty{#4}{\togglefalse{lexaltoverride}}{\ifstrequal{#4}{alt}{\toggletrue{lexaltoverride}}{\lexcite@err@invalidthirdarg@DeclareLex}}%Checking whether #4 is blank or set to 'alt', else: error +\iftoggle{lexnoprint}{}{\LexRefns{#2}{##1}[##2][##3][##4]}% Printing, unless noprint option activated +\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]{#2}}{}% Indexing, if option activated }% +% no need to entry anything in nomenclature here, cause act's name doesn't appear with \#1ns % 4) Creation of \np#1 command \expandafter\newcommandx\csname np#1\endcsname[4][2,3,4]{% -\iftoggle{lexnoprint}{}{\npLexRef{#1}{##1}[##2][##3][##4]}% Printing, unless noprint option activated -\iftoggle{lexnomencl}{% Entry in nomenclature, if option activated and #2 defined. - \ifstrempty{#2}% +% no need to test alt option here, cause no prefix is printed with \np#1 +\iftoggle{lexnoprint}{}{\npLexRef{#2}{##1}[##2][##3][##4]}% Printing, unless noprint option activated +\iftoggle{lexnomencl}{% Entry in nomenclature, if option activated and #3 defined. + \ifstrempty{#3}% {}% - {\ifcsdef{nomalreadydef#1}% Nomencl crashes if the same act is already passed to \nomenclature in another page, so this test ensures it won't be passed more than once + {\iftoggle{#1nmcl}% {}% - {% - \nomenclature{#1}{#2}% - \expandafter\newcommand\csname nomalreadydef#1\endcsname\relax}% - }% + {\nomenclature{#2}{#3}\global\toggletrue{#1nmcl}}% + }% }% {}% -\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]}{}% Indexing, if option activated +\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]{#2}}{}% Indexing, if option activated }% % 5) Creation of \np#1ns command \expandafter\newcommandx\csname np#1ns\endcsname[4][2,3,4]{% -\iftoggle{lexnoprint}{}{\npLexRefns{#1}{##1}[##2][##3][##4]}% Printing, unless noprint option activated -\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]}{}% Indexing, if option activated +\iftoggle{lexnoprint}{}{\npLexRefns{#2}{##1}[##2][##3][##4]}% Printing, unless noprint option activated +\iftoggle{lexindexing}{\LexIndex{#1}{##1}[##2][##3][##4]{#2}}{}% Indexing, if option activated }% % 6) Creation of \idx#1 command \iftoggle{lexindexing}{\expandafter\newcommandx\csname idx#1\endcsname[4][2,3,4]{% -\LexIndex{#1}{##1}[##2][##3][##4]}}{}% Indexing, if option activated +\LexIndex{#1}{##1}[##2][##3][##4]{#2}}}{}% Indexing, if option activated }} % PRINTING MACROS +% Testing if singular or plural prefix needed \newrobustcmd{\LexRefPrefixTests}[1]{% -% Testing if singular or plural profix needed \IfSubStr{#1}{\sq}% First testing if string contains \psq or \psqq {\toggletrue{lexpluralform}}% if yes, plural form {% else @@ -222,7 +212,7 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} {\togglefalse{lexpluralform}}% else singular form }% }% -% Printing MAIN or ALT Prefix depending on lexaltoverride, and singular/plural depending on previous test +% Printing MAIN or ALT Prefix depending on lexaltoverride toggle, and singular/plural depending on previous test \iftoggle{lexpluralform}% {\iftoggle{lexaltoverride}% {\DispsPrefixAlt}% @@ -235,6 +225,14 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} } % Macro with prefix and suffix + +% \LexRef and derivates' arguments +% #1 = Printed Act's name +% #2 = Cited art. number +% #3 (optionnal) = paragraph number +% #4 (optionnal) = number +% #5 (optionnal) = letter + \newcommandx{\LexRef}[5][3,4,5]{% \LexRefPrefixTests{#2} % #2% @@ -273,7 +271,15 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} % INDEXING MACRO -\newcommandx{\LexIndex}[5][3,4,5]{% +% \LexIndex arguments +% #1 = Act's CSname (= also name of the Act's index) +% #2 = Cited art. number +% #3 (optionnal) = paragraph number +% #4 (optionnal) = number +% #5 (optionnal) = letter +% #6 = Act's printed abbreviation (to be printed in the index) + +\newcommandx{\LexIndex}[6][3,4,5]{% % 1) First cleaning \noexpandarg% \IfSubStr{#2}{\sq}% Test \sq @@ -364,9 +370,9 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} and% not test {\ifstrempty{#5}}% }% - {\sindex[#1]{1@#1 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry + {\sindex[#1]{1@#6 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry {% - \sindex[#1]{1@#1 #2% else: indexing everything + \sindex[#1]{1@#6 #2% else: indexing everything \ifstrempty{#3}{}{!-- \SubPrefix{} #3}% \ifstrempty{#4}{}{!-- \SubSubPrefixNumber{} #4}% \ifstrempty{#5}{}{!-- \SubSubPrefixLetter{} #5}% @@ -380,9 +386,9 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} and% not test {\ifstrempty{#5}}% }% - {\sindex[#1]{10@#1 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry + {\sindex[#1]{10@#6 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry {% - \sindex[#1]{10@#1 #2% else: indexing everything + \sindex[#1]{10@#6 #2% else: indexing everything \ifstrempty{#3}{}{!-- \SubPrefix{} #3}% \ifstrempty{#4}{}{!-- \SubSubPrefixNumber{} #4}% \ifstrempty{#5}{}{!-- \SubSubPrefixLetter{} #5}% @@ -396,9 +402,9 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} and% not test {\ifstrempty{#5}}% }% - {\sindex[#1]{100@#1 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry + {\sindex[#1]{100@#6 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry {% - \sindex[#1]{100@#1 #2% else: indexing everything + \sindex[#1]{100@#6 #2% else: indexing everything \ifstrempty{#3}{}{!-- \SubPrefix{} #3}% \ifstrempty{#4}{}{!-- \SubSubPrefixNumber{} #4}% \ifstrempty{#5}{}{!-- \SubSubPrefixLetter{} #5}% @@ -412,9 +418,9 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} and% not test {\ifstrempty{#5}}% }% - {\sindex[#1]{1000@#1 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry + {\sindex[#1]{1000@#6 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry {% - \sindex[#1]{1000@#1 #2% else: indexing everything + \sindex[#1]{1000@#6 #2% else: indexing everything \ifstrempty{#3}{}{!-- \SubPrefix{} #3}% \ifstrempty{#4}{}{!-- \SubSubPrefixNumber{} #4}% \ifstrempty{#5}{}{!-- \SubSubPrefixLetter{} #5}% @@ -428,9 +434,9 @@ be either 'alt' or nothing. Check your \protect\DeclareCite\space macros}} and% not test {\ifstrempty{#5}}% }% - {\sindex[#1]{10000@#1 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry + {\sindex[#1]{10000@#6 #2!-- \SubPrefix{} #3}}% index only takes #3 as subentry {% - \sindex[#1]{10000@#1 #2% else: indexing everything + \sindex[#1]{10000@#6 #2% else: indexing everything \ifstrempty{#3}{}{!-- \SubPrefix{} #3}% \ifstrempty{#4}{}{!-- \SubSubPrefixNumber{} #4}% \ifstrempty{#5}{}{!-- \SubSubPrefixLetter{} #5}% |