summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/citeall
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/citeall')
-rw-r--r--Master/texmf-dist/tex/latex/citeall/citeall.sty177
1 files changed, 122 insertions, 55 deletions
diff --git a/Master/texmf-dist/tex/latex/citeall/citeall.sty b/Master/texmf-dist/tex/latex/citeall/citeall.sty
index fa949c920d5..377f9ae465d 100644
--- a/Master/texmf-dist/tex/latex/citeall/citeall.sty
+++ b/Master/texmf-dist/tex/latex/citeall/citeall.sty
@@ -5,12 +5,12 @@
%% www.troubleshooting-tex.de
%% Released under the LaTeX Project Public License v1.3c or later
%% See http://www.latex-project.org/lppl.txt
-%% $UFDate: 2015-04-28 13:27:07 +0200 -- Commit: f04431e -- master$
+%% $UFDate: 2017-12-03 18:19:20 +0100 -- Commit: 4f26014 (HEAD, master) -- master$
%% ---------------------------------------------------------------
-\RequirePackage{expl3,xparse}
+\RequirePackage{xparse}
-\ProvidesExplPackage {citeall} {2015/04/28} {1.2}
+\ProvidesExplPackage {citeall} {2017/12/03} {1.4}
{a package to test biblatex-cite commands}
\@ifpackageloaded{biblatex}{}{%
@@ -26,66 +26,128 @@
\DeclareBibliographyCategory{citeall}
% commands to hold arguments and temporary values
-\clist_new:N \l_UFca_citecommands_clist
-\tl_new:N \l_UFca_temp_citefunction_tl
-\tl_new:N \l_UFca_temp_entrykey_tl
-\int_new:N \l_UFca_temp_listitem_int
-\int_new:N \l_UFca_temp_listlength_int
-\int_new:N \l_UFca_entrynum_int
-\int_new:N \l_UFca_cur_entrynum_int
+\clist_new:N \l__UFca_citecommands_clist
+\tl_new:N \l__UFca_temp_citefunction_tl
+\tl_new:N \l__UFca_temp_entrykey_tl
+\int_new:N \l__UFca_temp_listitem_int
+\int_new:N \l__UFca_temp_listlength_int
+\int_new:N \l__UFca_entrynum_int
+\int_new:N \l__UFca_cur_entrynum_int
% formatting commands
-\NewDocumentCommand\citeallgroupseparator{}{\par}
-\NewDocumentCommand\citeallseparator {}{,\c_space_tl}
-\NewDocumentCommand\citeallfinentry {}{}
-\NewDocumentCommand\citealldefaultcite {}{\cite}
+\NewDocumentCommand \citeallgroupseparator {}{\par}
+\NewDocumentCommand \citeallseparator {}{,\c_space_tl}
+\NewDocumentCommand \citeallfinentry {}{}
+\NewDocumentCommand \citealldefaultcite {}{\cite}
+\NewDocumentCommand \citeallpreambledefinition {m}{}
+
+\clist_const:Nn\g_UFca_bbl_cmds_clist
+ {
+ true,
+ false,
+ field,
+ name,
+ strng,
+ keyw,
+ set,
+ warn,
+ inset,
+ range,
+ missing,
+ keyalias,
+ xref,
+ cnt,
+ annotation,
+ list
+ }
+
+\clist_const:Nn\g_UFca_bbl_envs_clist
+ {
+ refsection,
+ sortlist,
+ datalist
+ }
+
+\newcommand\@@UFca@bblcmd@true [2][]{{\ignorespaces}}
+\newcommand\@@UFca@bblcmd@false [2][]{{\ignorespaces}}
+\newcommand\@@UFca@bblcmd@field [3][]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@name [5][]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@strng [2]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@keyw [1]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@set [1]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@warn [1]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@inset [1]{\addtocategory{citeall}{#1}\ignorespaces}
+\newcommand\@@UFca@bblcmd@range [2]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@missing [1]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@keyalias[2]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@xref [1]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@cnt [2]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@annotation[5]{\ignorespaces}
+\newcommand\@@UFca@bblcmd@list [4][]{\ignorespaces}
+
+\newenvironment{@@UFca@bblenv@refsection}[1]{}{\ignorespaces}
+\newenvironment{@@UFca@bblenv@sortlist} [2][]{}{\ignorespaces}
+\newenvironment{@@UFca@bblenv@datalist} [2][]{}{\ignorespaces}
%init suitable definitions for the fields in the bbl
-\cs_new:Nn \_UFca_init_bblfields:
- {\newcommand\true [2][]{\ignorespaces}
- \newcommand\field[3][]{\ignorespaces}
- \newcommand\name [5][]{\ignorespaces}
- \newcommand\strng[2]{\ignorespaces}%
- \renewenvironment{refsection}[1]{}{\ignorespaces}
- \newenvironment{sortlist}[2]{}{\ignorespaces}
- %\renewcommand\verb{\@ifnextchar\bgroup{\@gobble}{\my@verb}}
- \def\verb##1\endverb{\ignorespaces}
- \renewcommand\list[4][]{\ignorespaces}
- \newcommand\inset[1]{\ignorespaces}
- \newcommand\keyw[1]{\ignorespaces}
- \newcommand\set[1]{\ignorespaces}
- \newcommand\warn[1]{\ignorespaces}
- \renewcommand\inset[1]{\addtocategory{citeall}{##1}\ignorespaces}
- \newcommand\range[2]{\ignorespaces} %for biblatex-dev
+\cs_new:Nn \__UFca_init_bblfields:
+ {
+ \let\preamble\citeallpreambledefinition
+ \clist_map_inline:Nn\g_UFca_bbl_cmds_clist
+ {
+ \cs_set_eq:cc { @@UFca@oricmd@##1 } { ##1 }
+ %\cs_show:c { @@UFca@oricmd@##1 }
+ \cs_set_eq:cc { ##1 } { @@UFca@bblcmd@##1 }
}
-
+ \def\verb##1\endverb {\ignorespaces}
+ \def\lverb##1\endlverb {\ignorespaces} %see https://github.com/plk/biblatex/issues/229
+ \cs_set_eq:NN \refsection \@@UFca@bblenv@refsection
+ \cs_set_eq:NN \endrefsection \end@@UFca@bblenv@refsection
+ \cs_set_eq:NN \sortlist \@@UFca@bblenv@sortlist
+ \cs_set_eq:NN \endsortlist \end@@UFca@bblenv@sortlist
+ \cs_set_eq:NN \datalist \@@UFca@bblenv@datalist
+ \cs_set_eq:NN \enddatalist \end@@UFca@bblenv@datalist
+ }
% init the entry environment
%#1=number of entries to process, if 0: process all
-\cs_new:Nn \_UFca_init_bblentryenv:n
- {\int_set:Nn \l_UFca_entrynum_int {#1}
- \int_zero:N \l_UFca_cur_entrynum_int
+\cs_new:Nn \__UFca_init_bblentryenv:n
+ {
+ \int_set:Nn \l__UFca_entrynum_int {#1}
+ \int_zero:N \l__UFca_cur_entrynum_int
\NewDocumentEnvironment{entry} {m m m}
- {\int_incr:N \l_UFca_cur_entrynum_int
- \tl_set:Nn \l_UFca_temp_entrykey_tl {##1}
- \int_zero:N \l_UFca_temp_listitem_int
- \int_set:Nn \l_UFca_temp_listlength_int
- {\clist_count:N\l_UFca_citecommands_clist}
+ {
+ \int_incr:N \l__UFca_cur_entrynum_int
+ \tl_set:Nn \l__UFca_temp_entrykey_tl {##1}
+ \int_zero:N \l__UFca_temp_listitem_int
+ \int_set:Nn \l__UFca_temp_listlength_int
+ {
+ \clist_count:N\l__UFca_citecommands_clist
+ }
\bool_if:nT
{
- \int_compare_p:n { \l_UFca_entrynum_int = 0 }
+ \int_compare_p:n { \l__UFca_entrynum_int = 0 }
||
- \int_compare_p:n { \l_UFca_cur_entrynum_int <= \l_UFca_entrynum_int}
+ \int_compare_p:n { \l__UFca_cur_entrynum_int <= \l__UFca_entrynum_int }
}
- {\addtocategory{citeall}{##1}
- \clist_map_variable:NNn \l_UFca_citecommands_clist \l_UFca_temp_citefunction_tl
+ {
+ \addtocategory{citeall}{##1}
+ \clist_map_variable:NNn \l__UFca_citecommands_clist \l__UFca_temp_citefunction_tl
{
- \int_incr:N \l_UFca_temp_listitem_int
- %\tl_set:Nn \l_UFca_temp_citefunction_tl {####1}
- \l_UFca_temp_citefunction_tl {\l_UFca_temp_entrykey_tl}
+ \int_incr:N \l__UFca_temp_listitem_int
+ \group_begin:
+ \cs_set_eq:NN\list\@@UFca@oricmd@list
+
+ \l__UFca_temp_citefunction_tl {\l__UFca_temp_entrykey_tl}
+ \group_end:
\int_compare:nNnTF
- {\l_UFca_temp_listitem_int}<{\l_UFca_temp_listlength_int}
- {\citeallseparator}{\citeallfinentry}
+ {\l__UFca_temp_listitem_int}<{\l__UFca_temp_listlength_int}
+ {
+ \citeallseparator
+ }
+ {
+ \citeallfinentry
+ }
}
\citeallgroupseparator
}
@@ -97,17 +159,22 @@
% the main command
\NewDocumentCommand\citeall { O{\citealldefaultcite} o}
- {\nocite{*} %cite all entries
- \clist_set:Nn\l_UFca_citecommands_clist{#1}
- \clist_if_empty:NT\l_UFca_citecommands_clist
+ {
+ \nocite{*} %cite all entries
+ \clist_set:Nn \l__UFca_citecommands_clist { #1 }
+ \clist_if_empty:NT \l__UFca_citecommands_clist
{
- \clist_put_right:Nn\l_UFca_citecommands_clist{\citealldefaultcite}
+ \clist_put_right:Nn \l__UFca_citecommands_clist { \citealldefaultcite }
}
\group_begin:
\IfNoValueTF{#2}
- {\_UFca_init_bblentryenv:n{0}}
- {\_UFca_init_bblentryenv:n{#2}}
- \_UFca_init_bblfields:
+ {
+ \__UFca_init_bblentryenv:n{0}
+ }
+ {
+ \__UFca_init_bblentryenv:n{#2}
+ }
+ \__UFca_init_bblfields:
\file_if_exist:nT
{\jobname.bbl}
{\file_input:n{\jobname.bbl}}%