From c48ccf7d508e674e10d9771d333993da3a957589 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 7 Mar 2016 23:27:17 +0000 Subject: biblatex 3.3 (7mar16) git-svn-id: svn://tug.org/texlive/trunk@39966 c570f23f-e606-0410-a88d-b1316a301751 --- .../tex/latex/biblatex/bbx/authortitle.bbx | 2 +- .../tex/latex/biblatex/bbx/authoryear.bbx | 4 +- Master/texmf-dist/tex/latex/biblatex/bbx/debug.bbx | 48 +- .../texmf-dist/tex/latex/biblatex/bbx/numeric.bbx | 2 +- .../texmf-dist/tex/latex/biblatex/bbx/reading.bbx | 12 +- .../texmf-dist/tex/latex/biblatex/bbx/standard.bbx | 10 +- Master/texmf-dist/tex/latex/biblatex/biblatex.def | 2937 ----- Master/texmf-dist/tex/latex/biblatex/biblatex.sty | 47 +- Master/texmf-dist/tex/latex/biblatex/biblatex1.sty | 10894 ----------------- Master/texmf-dist/tex/latex/biblatex/biblatex2.sty | 11285 ------------------ Master/texmf-dist/tex/latex/biblatex/biblatex_.def | 2794 +++++ Master/texmf-dist/tex/latex/biblatex/biblatex_.sty | 11607 +++++++++++++++++++ .../tex/latex/biblatex/biblatex_legacy.def | 2262 ++++ .../tex/latex/biblatex/biblatex_legacy.sty | 10608 +++++++++++++++++ .../texmf-dist/tex/latex/biblatex/blx-compat.def | 2 +- Master/texmf-dist/tex/latex/biblatex/blx-dm.def | 27 +- .../tex/latex/biblatex/cbx/authortitle-comp.cbx | 4 +- .../tex/latex/biblatex/cbx/authortitle-ibid.cbx | 6 +- .../tex/latex/biblatex/cbx/authortitle-icomp.cbx | 6 +- .../tex/latex/biblatex/cbx/authortitle-tcomp.cbx | 4 +- .../tex/latex/biblatex/cbx/authortitle-terse.cbx | 2 +- .../tex/latex/biblatex/cbx/authortitle-ticomp.cbx | 4 +- .../tex/latex/biblatex/cbx/authortitle.cbx | 4 +- .../tex/latex/biblatex/cbx/authoryear-comp.cbx | 6 +- .../tex/latex/biblatex/cbx/authoryear-ibid.cbx | 10 +- .../tex/latex/biblatex/cbx/authoryear-icomp.cbx | 8 +- .../tex/latex/biblatex/cbx/authoryear.cbx | 8 +- .../tex/latex/biblatex/cbx/verbose-ibid.cbx | 4 +- .../tex/latex/biblatex/cbx/verbose-inote.cbx | 6 +- .../tex/latex/biblatex/cbx/verbose-note.cbx | 4 +- .../tex/latex/biblatex/cbx/verbose-trad1.cbx | 6 +- .../tex/latex/biblatex/cbx/verbose-trad2.cbx | 6 +- .../tex/latex/biblatex/cbx/verbose-trad3.cbx | 4 +- .../texmf-dist/tex/latex/biblatex/cbx/verbose.cbx | 2 +- .../texmf-dist/tex/latex/biblatex/lbx/french.lbx | 6 +- 35 files changed, 27412 insertions(+), 25229 deletions(-) delete mode 100644 Master/texmf-dist/tex/latex/biblatex/biblatex.def delete mode 100644 Master/texmf-dist/tex/latex/biblatex/biblatex1.sty delete mode 100644 Master/texmf-dist/tex/latex/biblatex/biblatex2.sty create mode 100644 Master/texmf-dist/tex/latex/biblatex/biblatex_.def create mode 100644 Master/texmf-dist/tex/latex/biblatex/biblatex_.sty create mode 100644 Master/texmf-dist/tex/latex/biblatex/biblatex_legacy.def create mode 100644 Master/texmf-dist/tex/latex/biblatex/biblatex_legacy.sty (limited to 'Master/texmf-dist/tex/latex/biblatex') diff --git a/Master/texmf-dist/tex/latex/biblatex/bbx/authortitle.bbx b/Master/texmf-dist/tex/latex/biblatex/bbx/authortitle.bbx index 557a8e44704..a3f26dd9fe2 100644 --- a/Master/texmf-dist/tex/latex/biblatex/bbx/authortitle.bbx +++ b/Master/texmf-dist/tex/latex/biblatex/bbx/authortitle.bbx @@ -4,7 +4,7 @@ \RequireBibliographyStyle{standard} \ExecuteBibliographyOptions{pagetracker} -\DeclareBibliographyOption{dashed}[true]{% +\DeclareBibliographyOption[boolean]{dashed}[true]{% \ifstrequal{#1}{true} {\ExecuteBibliographyOptions{pagetracker}% \renewbibmacro*{bbx:savehash}{\savefield{fullhash}{\bbx@lasthash}}} diff --git a/Master/texmf-dist/tex/latex/biblatex/bbx/authoryear.bbx b/Master/texmf-dist/tex/latex/biblatex/bbx/authoryear.bbx index f4413275e39..6b3984ebade 100644 --- a/Master/texmf-dist/tex/latex/biblatex/bbx/authoryear.bbx +++ b/Master/texmf-dist/tex/latex/biblatex/bbx/authoryear.bbx @@ -3,13 +3,13 @@ \RequireBibliographyStyle{standard} -\DeclareBibliographyOption{dashed}[true]{% +\DeclareBibliographyOption[boolean]{dashed}[true]{% \ifstrequal{#1}{true} {\ExecuteBibliographyOptions{pagetracker}% \renewbibmacro*{bbx:savehash}{\savefield{fullhash}{\bbx@lasthash}}} {\renewbibmacro*{bbx:savehash}{}}} -\DeclareBibliographyOption{mergedate}[true]{% +\DeclareBibliographyOption[boolean]{mergedate}[true]{% \ifcsdef{bbx@opt@mergedate@#1} {\csuse{bbx@opt@mergedate@#1}} {\PackageError{biblatex} diff --git a/Master/texmf-dist/tex/latex/biblatex/bbx/debug.bbx b/Master/texmf-dist/tex/latex/biblatex/bbx/debug.bbx index afd8b5e311e..319b26e0553 100644 --- a/Master/texmf-dist/tex/latex/biblatex/bbx/debug.bbx +++ b/Master/texmf-dist/tex/latex/biblatex/bbx/debug.bbx @@ -35,22 +35,38 @@ {\endlist} {\item} -\DeclareNameFormat{debug}{% - \bbx@mklabel{\currentname}% - \ifblank{#3}{}{\detokenize{#3}\space}% - \ifblank{#5}{}{\detokenize{#5}\ifpunctmark{'}{}{\space}}% - \detokenize{#1}% - \ifblank{#7}{}{\space\detokenize{#7}}% - \ifblank{#3}{}{\bbx@mksublabel{first}\detokenize{#3}}% - \ifblank{#1}{}{\bbx@mksublabel{last}\detokenize{#1}}% - \ifblank{#5}{}{\bbx@mksublabel{prefix}\detokenize{#5}}% - \ifblank{#7}{}{\bbx@mksublabel{affix}\detokenize{#7}}% - \bbx@mksublabel{inits}% - \ifblank{#4}{}{\detokenize{#4}\space}% - \ifblank{#6}{}{\detokenize{#6}\ifpunctmark{'}{}{\space}}% - \detokenize{#2}% - \ifblank{#8}{}{\space\detokenize{#8}}% -} +\@ifpackageloaded{biblatex_legacy} + {\DeclareNameFormat{debug}{% + \bbx@mklabel{\currentname}% + \ifblank{#3}{}{\detokenize{#3}\space}% + \ifblank{#5}{}{\detokenize{#5}\ifpunctmark{'}{}{\space}}% + \detokenize{#1}% + \ifblank{#7}{}{\space\detokenize{#7}}% + \ifblank{#3}{}{\bbx@mksublabel{given}\detokenize{#3}}% + \ifblank{#1}{}{\bbx@mksublabel{family}\detokenize{#1}}% + \ifblank{#5}{}{\bbx@mksublabel{prefix}\detokenize{#5}}% + \ifblank{#7}{}{\bbx@mksublabel{affix}\detokenize{#7}}% + \bbx@mksublabel{inits}% + \ifblank{#4}{}{\detokenize{#4}\space}% + \ifblank{#6}{}{\detokenize{#6}\ifpunctmark{'}{}{\space}}% + \detokenize{#2}% + \ifblank{#8}{}{\space\detokenize{#8}}}} + {\DeclareNameFormat{debug}{% + \nameparts{#1}% + \bbx@mklabel{\currentname}% + \ifdefvoid{\namepartgiven}{}{\expandafter\detokenize\expandafter{\namepartgiven}\space}% + \ifdefvoid{\namepartprefix}{}{\expandafter\detokenize\expandafter{\namepartprefix}\ifpunctmark{'}{}{\space}}% + \expandafter\detokenize\expandafter{\namepartfamily}% + \ifdefvoid{\namepartsuffix}{}{\expandafter\space\expandafter\detokenize\expandafter{\namepartsuffix}}% + \ifdefvoid{\namepartgiven}{}{\bbx@mksublabel{given}\expandafter\detokenize\expandafter{\namepartgiven}}% + \ifdefvoid{\namepartfamily}{}{\bbx@mksublabel{family}\expandafter\detokenize\expandafter{\namepartfamily}}% + \ifdefvoid{\namepartprefix}{}{\bbx@mksublabel{prefix}\expandafter\detokenize\expandafter{\namepartprefix}}% + \ifdefvoid{\namepartsuffix}{}{\bbx@mksublabel{suffix}\expandafter\detokenize\expandafter{\namepartsuffix}}% + \bbx@mksublabel{inits}% + \ifdefvoid{\namepartgiveni}{}{\expandafter\detokenize\expandafter{\namepartgiveni}\space}% + \ifdefvoid{\namepartprefixi}{}{\expandafter\detokenize\expandafter{\namepartprefixi}\ifpunctmark{'}{}{\space}}% + \expandafter\detokenize\expandafter{\namepartfamilyi}% + \ifdefvoid{\namepartsuffixi}{}{\expandafter\space\expandafter\detokenize\expandafter{\namepartsuffixi}}}} \DeclareListFormat{debug}{% \bbx@mklabel{\currentlist}% diff --git a/Master/texmf-dist/tex/latex/biblatex/bbx/numeric.bbx b/Master/texmf-dist/tex/latex/biblatex/bbx/numeric.bbx index ddbd31b81c0..02299df2a6a 100644 --- a/Master/texmf-dist/tex/latex/biblatex/bbx/numeric.bbx +++ b/Master/texmf-dist/tex/latex/biblatex/bbx/numeric.bbx @@ -6,7 +6,7 @@ \providebool{bbx:subentry} -\DeclareBibliographyOption{subentry}[true]{% +\DeclareBibliographyOption[boolean]{subentry}[true]{% \setbool{bbx:subentry}{#1}} \DeclareNameAlias{author}{default} diff --git a/Master/texmf-dist/tex/latex/biblatex/bbx/reading.bbx b/Master/texmf-dist/tex/latex/biblatex/bbx/reading.bbx index f571a5a633c..6e9e25be2d1 100644 --- a/Master/texmf-dist/tex/latex/biblatex/bbx/reading.bbx +++ b/Master/texmf-dist/tex/latex/biblatex/bbx/reading.bbx @@ -102,21 +102,21 @@ \newbool{bbx:library} \newbool{bbx:file} -\DeclareBibliographyOption{entryhead}[true]{% +\DeclareBibliographyOption[boolean]{entryhead}[true]{% \ifcsdef{bbx@item@#1} {\letcs\bbx@item{bbx@item@#1}} {\PackageError{biblatex} {Invalid option 'header=#1'} {Valid values: header=true, false, full, name.}}} -\DeclareBibliographyOption{entrykey}[true]{% +\DeclareBibliographyOption[boolean]{entrykey}[true]{% \setbool{bbx:entrykey}{#1}} -\DeclareBibliographyOption{annotation}[true]{% +\DeclareBibliographyOption[boolean]{annotation}[true]{% \setbool{bbx:annotation}{#1}} -\DeclareBibliographyOption{abstract}[true]{% +\DeclareBibliographyOption[boolean]{abstract}[true]{% \setbool{bbx:abstract}{#1}} -\DeclareBibliographyOption{library}[true]{% +\DeclareBibliographyOption[boolean]{library}[true]{% \setbool{bbx:library}{#1}} -\DeclareBibliographyOption{file}[true]{% +\DeclareBibliographyOption[boolean]{file}[true]{% \setbool{bbx:file}{#1}} \ExecuteBibliographyOptions{loadfiles,entryhead,entrykey,annotation,abstract,library,file} diff --git a/Master/texmf-dist/tex/latex/biblatex/bbx/standard.bbx b/Master/texmf-dist/tex/latex/biblatex/bbx/standard.bbx index f81dd4aaaad..c1d480d4d70 100644 --- a/Master/texmf-dist/tex/latex/biblatex/bbx/standard.bbx +++ b/Master/texmf-dist/tex/latex/biblatex/bbx/standard.bbx @@ -7,15 +7,15 @@ \newtoggle{bbx:eprint} \newtoggle{bbx:related} -\DeclareBibliographyOption{isbn}[true]{% +\DeclareBibliographyOption[boolean]{isbn}[true]{% \settoggle{bbx:isbn}{#1}} -\DeclareBibliographyOption{url}[true]{% +\DeclareBibliographyOption[boolean]{url}[true]{% \settoggle{bbx:url}{#1}} -\DeclareBibliographyOption{doi}[true]{% +\DeclareBibliographyOption[boolean]{doi}[true]{% \settoggle{bbx:doi}{#1}} -\DeclareBibliographyOption{eprint}[true]{% +\DeclareBibliographyOption[boolean]{eprint}[true]{% \settoggle{bbx:eprint}{#1}} -\DeclareBibliographyOption{related}[true]{% +\DeclareBibliographyOption[boolean]{related}[true]{% \settoggle{bbx:related}{#1}} \ExecuteBibliographyOptions{isbn,url,doi,eprint,related} diff --git a/Master/texmf-dist/tex/latex/biblatex/biblatex.def b/Master/texmf-dist/tex/latex/biblatex/biblatex.def deleted file mode 100644 index 51414258a7d..00000000000 --- a/Master/texmf-dist/tex/latex/biblatex/biblatex.def +++ /dev/null @@ -1,2937 +0,0 @@ -% -*- mode: LaTeX -*- -\ProvidesFile{biblatex.def} - -% ------------------------------------------------------------------ -% FORMATTING COMMANDS -% ------------------------------------------------------------------ - -% Generic formatting commands and hooks -% ------------------------------------------------------------------ - -% Used in citations, bibliography and bibliography lists - -\newcommand*{\mkbibnamefirst}[1]{#1} -\newcommand*{\mkbibnamelast}[1]{#1} -\newcommand*{\mkbibnameprefix}[1]{#1} -\newcommand*{\mkbibnameaffix}[1]{#1} -\newcommand*{\bibellipsis}{[\textellipsis\unkern]\midsentence} - -% Delimiters used in citations, bibliography and bibliography lists - -\newcommand*{\multinamedelim}{\addcomma\space} -\newcommand*{\finalnamedelim}{% - \ifnumgreater{\value{liststop}}{2}{\finalandcomma}{}% - \addspace\bibstring{and}\space} -\newcommand*{\revsdnamedelim}{} -\newcommand*{\andothersdelim}{\addspace} - -\newcommand*{\multilistdelim}{\addcomma\space} -\newcommand*{\finallistdelim}{% - \ifnumgreater{\value{liststop}}{2}{\finalandcomma}{}% - \addspace\bibstring{and}\space} -\newcommand*{\andmoredelim}{\addspace} - -% Used in citations - -\newcommand*{\multicitedelim}{\addsemicolon\space} -\newcommand*{\compcitedelim}{\addcomma\space} -\newcommand*{\supercitedelim}{\addcomma} -\newcommand*{\prenotedelim}{\addspace} -\newcommand*{\postnotedelim}{\addcomma\space} -\newcommand*{\nametitledelim}{\addcomma\space} -\newcommand*{\nameyeardelim}{\addspace} -\newcommand*{\volcitedelim}{\addcomma\space} -\newcommand*{\textcitedelim}{% - \iffinalcitedelim - {\ifnumgreater{\value{textcitetotal}}{2} - {\iftextcitepunct{\finalandsemicolon}{\finalandcomma}}{}% - \addspace\bibstring{and}} - {\iftextcitepunct{\addsemicolon}{\addcomma}}% - \space} - -% This is a provisional definition for \iffinalcitedelim{}{}, a -% test that should expand if the next non-compact citation delimiter -% is the last one in the citation list printed by \textcite or \textcites. -\newcommand*{\iffinalcitedelim}{\@secondoftwo} - -% Expand if the citation labels in the citation list printed by \textcite -% or \textcites contains the serial comma \finalandcomma -\newcommand*{\iftextcitepunct}{% - \ifboolexpr{ not test {\ifdefempty{\finalandsemicolon}} - and test {\ifnumgreater{\value{textcitemaxnames}}{2}} }} - -% Counters for the number of citation labels separated by non-compact delimiters -% in the citation list printed by \textcite or \textcites. Counter values should -% be managed by the citation style. -\newcounter{textcitecount} -\newcounter{textcitetotal} -\setcounter{textcitecount}{0} -\setcounter{textcitetotal}{0} - -% Counters for the maximum number of names among citation labels in the citation -% list printed by \textcite or \textcites. Counter value should be managed by -% the citation style. -\newcounter{textcitemaxnames} -\setcounter{textcitemaxnames}{0} - -% Used in the bibliography and bibliography lists - -\newcommand*{\newunitpunct}{\addperiod\space} -\newcommand*{\entrysetpunct}{\addsemicolon\space} -\newcommand*{\finentrypunct}{\addperiod} -\newcommand*{\labelnamepunct}{\newunitpunct} -\newcommand*{\subtitlepunct}{\newunitpunct} -\newcommand*{\intitlepunct}{\addcolon\space} -\newcommand*{\bibpagespunct}{\addcomma\space} -\newcommand*{\bibpagerefpunct}{\addspace} -\newcommand*{\revsdnamepunct}{\addcomma} -\newcommand*{\bibnamedash}{% - \ifdimless{\leftmargin}{0.75em} - {\mbox{\textemdash\space}} - {\makebox[\leftmargin][l]{% - \ifdimless{\leftmargin}{1.25em} - {\textendash} - {\textemdash}}}} -\newcommand*{\relatedpunct}{\addspace} -\newcommand*{\relateddelim}{\adddot\par\nobreak} -\newcommand{\mkrelatedstring}{\mainlang} - -% Used for indexing - -\newcommand*{\bibindexnamedelima}{ } -\newcommand*{\bibindexnamedelimb}{ } -\newcommand*{\bibindexnamedelimc}{ } -\newcommand*{\bibindexnamedelimd}{ } -\newcommand*{\bibindexnamedelimi}{ } -\newcommand*{\bibindexinitperiod}{.} -\newcommand*{\bibindexinitdelim}{ } -\newcommand*{\bibindexinithyphendelim}{.-} - -% \bibsetup is a generic hook controlling the (low-level) layout of -% the bibliography and bibliography lists. The default -% definition should work fine in most cases. - -\newcommand*{\bibsetup}{% - \interlinepenalty=5000\relax - \widowpenalty=10000\relax - \clubpenalty=10000\relax - \raggedbottom - \frenchspacing - \biburlsetup} - -% The penalties above are not specific to biblatex. These are -% low-level TeX features. \interlinepenalty is the penalty assigned -% to page breaks within a paragraph (i.e., in this case, a -% bibliography entry); \clubpenalty is an additional penalty -% assigned to page breaks after the first line of a paragraph; -% \widowpenalty is an additional penalty assigned to page breaks -% before the last line of a paragraph. Note that the value 10000 -% means 'infinite' as far as TeX is concerned. Setting a penalty to -% 10000 will unconditionally suppress the respective breakpoint. -% -% The net effect of the above settings is as follows. Breaking a -% bibliography entry across pages is discouraged, but not suppressed -% altogether. If a bibliography entry spans less than four lines, -% TeX will always keep it on one page. If it spans four or more -% lines, it may be broken across pages, provided that there are at -% least two lines on the page before and after the break. -% -% These penalties should normally be used in conjunction with -% \raggedbottom. If you don't like that and remove \raggedbottom -% from the definition of \bibsetup, make sure to provide some -% stretchability between bibliography entries by setting \bibitemsep -% to a suitable value, e.g.: -% -% \setlength{\bibitemsep}{0.5\baselineskip plus 0.5\baselineskip} -% -% Using \frenchspacing in the bibliography is recommended. If you -% want more visual separation, try the package option 'block=space'. -% This will yield better results than \nonfrenchspacing. - -% \citesetup is a generic hook for citations. - -\newcommand*{\citesetup}{% - \biburlsetup} - -% Local setup for \url; see comments in url.sty for details. - -\newcounter{biburlnumpenalty} -\newcounter{biburlucpenalty} -\newcounter{biburllcpenalty} - -\newcommand*{\biburlsetup}{% - \Urlmuskip=0mu plus 3mu\relax - \mathchardef\UrlBigBreakPenalty=100\relax - \mathchardef\UrlBreakPenalty=200\relax - \def\UrlBigBreaks{\do\:\do\-}% - \def\UrlBreaks{% - \do\.\do\@\do\/\do\\\do\!\do\_\do\|\do\;\do\>\do\]\do\)\do\}% - \do\,\do\?\do\'\do\+\do\=\do\#\do\$\do\&\do\*\do\^\do\"}% - \ifnumgreater{\value{biburlnumpenalty}}{0} - {\def\do##1{\appto\UrlSpecials{\do##1{\mathchar`##1 \penalty\value{biburlnumpenalty}}}}% - \do\1\do\2\do\3\do\4\do\5\do\6\do\7\do\8\do\9\do\0} - {}% - \ifnumgreater{\value{biburlucpenalty}}{0} - {\def\do##1{\appto\UrlSpecials{\do##1{\mathchar`##1 \penalty\value{biburlucpenalty}}}}% - \do\A\do\B\do\C\do\D\do\E\do\F\do\G\do\H\do\I\do\J - \do\K\do\L\do\M\do\N\do\O\do\P\do\Q\do\R\do\S\do\T - \do\U\do\V\do\W\do\X\do\Y\do\Z} - {}% - \ifnumgreater{\value{biburllcpenalty}}{0} - {\def\do##1{\appto\UrlSpecials{\do##1{\mathchar`##1 \penalty\value{biburllcpenalty}}}}% - \do\a\do\b\do\c\do\d\do\e\do\f\do\g\do\h\do\i\do\j - \do\k\do\l\do\m\do\n\do\o\do\p\do\q\do\r\do\s\do\t - \do\u\do\v\do\w\do\x\do\y\do\z} - {}% - \let\do=\noexpand} - -% The above code allows linebreaks before numbers and letters. -% This is often the only way to break DOIs. It also allows breaks -% after hyphens and adjusts \Urlmuskip to add some stretchability -% to URLs. - -% The default font of the bibliography and the bibliography lists. -% We simply reset the current font to the global defaults. - -\newcommand*{\bibfont}{\normalfont\normalsize} - -% Some length registers which may be used to fine-tune the -% (high-level) layout of the bibliography. - -% Default \bibhang to 1em if \parindent is 0 for some reason -\setlength{\bibhang}{\ifnumequal{\parindent}{0}{1em}{\parindent}} -\setlength{\biblabelsep}{2\labelsep} -\setlength{\bibitemsep}{\itemsep} -\setlength{\bibnamesep}{0pt} -\setlength{\bibinitsep}{0pt} -\setlength{\bibparsep}{0pt} - -% Miscellaneous facilities -% ------------------------------------------------------------------ - -% The counter 'abbrvpenalty' holds the penalty used in short or -% abbreviated bibliography strings. For example, a linebreak in -% expressions such as "et al." or "ed. by" is unfortunate, but should -% still be possible to prevent overfull boxes. We use TeX's -% \hyphenpenalty (normally 50) as the default value. The idea is -% making TeX treat the whole expression as if it were a single, -% hyphenatable word as far as line-breaking is concerned. If you -% dislike such linebreaks, use a higher value. If you do not mind -% them at all, set this counter to zero. If you want to suppress them -% unconditionally, set it to 10000. -\defcounter{abbrvpenalty}{\hyphenpenalty} - -% The counter 'highnamepenalty' also holds a penalty affecting the -% line-breaking of names. This penalty is inserted between smaller -% chunks of a name, for example between the first and the middle -% name. The default value is \hyphenpenalty. If you dislike such -% linebreaks, use a higher value. If you do not mind them at all, -% set this counter to zero. If you prefer the traditional BibTeX -% behavior, set it to 10000. -\defcounter{highnamepenalty}{\hyphenpenalty} - -% The counter 'lownamepenalty' holds a penalty which affects the -% line-breaking of names. This penalty is inserted between larger -% chunks of a name, for example between the chunk consisting of all -% first names and the last name. The default value is half the -% \hyphenpenalty. If you dislike such linebreaks, use a higher -% value. If you do not mind them at all, set this counter to zero. -\defcounter{lownamepenalty}{\hyphenpenalty/2} - -% Note that default values assigned to the above counters are -% deliberately very low to prevent overfull boxes. This implies that -% you will hardly notice any effect on line-breaking if the text is -% set justified. If you set these counters to 10000 to suppress the -% respective breakpoints, you will notice their effect but you may -% also be confronted with overfull boxes. Keep in mind that -% line-breaking in the bibliography is often more difficult than in -% the body text and that you can not resort to rephrasing a -% sentence. In some cases it may be preferable to set the entire -% bibliography \raggedright (by modifying \bibsetup) to prevent -% suboptimal linebreaks. In this case, even the very low default -% penalties will make a visible difference. - -% File name prefixes for external abstracts and annotations -\newcommand*{\bibabstractprefix}{bibabstract-} -\newcommand*{\bibannotationprefix}{bibannotation-} - -% Print acronyms in small caps if possible -\newcommand*{\mkbibacro}[1]{% - \ifcsundef{\f@encoding/\f@family/\f@series/sc} - {#1} - {\textsc{\MakeLowercase{#1}}}} - -% ------------------------------------------------------------------ -% ADDITIONAL PACKAGE OPTIONS -% ------------------------------------------------------------------ - -% Style of compressed page ranges in back references - -\DeclareBibliographyOption{backrefstyle}{% - \ifcsdef{abx@opt@pagerefstyle@#1} - {\letcs\abx@pagerefstyle{abx@opt@pagerefstyle@#1}} - {\PackageError{biblatex} - {Option 'backrefstyle=#1' invalid} - {The option you have supplied is invalid.\MessageBreak - See the biblatex manual for valid option keys - and possible values}}} -\newcommand*{\abx@pagerefstyle}{1} -\csdef{abx@opt@pagerefstyle@none}{-1} -\csdef{abx@opt@pagerefstyle@two}{0} -\csdef{abx@opt@pagerefstyle@three}{1} -\csdef{abx@opt@pagerefstyle@two+}{2} -\csdef{abx@opt@pagerefstyle@three+}{3} -\csdef{abx@opt@pagerefstyle@all+}{4} - -% arXiv path/format selector -% -% abs = abstract page -% ps = PostScript version -% pdf = PDF version -% format = format selector - -\DeclareBibliographyOption{arxiv}{\def\abx@arxivpath{#1}} -\newcommand*{\abx@arxivpath}{abs} - -% ------------------------------------------------------------------ -% FIELD FORMATS (#1 is the value of the field) -% ------------------------------------------------------------------ - -% The fallback used by \printfield - -\DeclareFieldFormat{default}{#1} - -% The default used by \citefield - -\DeclareFieldFormat{citefield}{#1} - -% Used in citations - -\DeclareFieldFormat{citetitle}{\mkbibemph{#1}} -\DeclareFieldFormat - [article,inbook,incollection,inproceedings,patent,thesis,unpublished] - {citetitle}{\mkbibquote{#1\isdot}} -\DeclareFieldFormat - [suppbook,suppcollection,suppperiodical] - {citetitle}{#1} -% labelyear can be a localisation string to allow for "no date" etc. -\DeclareFieldFormat{labelyear}{% = the '1995' part in 'Jones 1995a' - \ifbibstring{#1}{\bibstring{#1}}{\stripzeros{#1}}} -\DeclareFieldFormat{extrayear}{% = the 'a' in 'Jones 1995a' - \iffieldnums{labelyear} - {\mknumalph{#1}} - {\mkbibparens{\mknumalph{#1}}}} -\DeclareFieldFormat{labelalpha}{#1}% = the 'Jon95' part of 'Jon95a' -\DeclareFieldFormat{extraalpha}{\mknumalph{#1}}% = the 'a' in 'Jon95a' -\DeclareFieldFormat{shorthand}{#1\isdot} -\DeclareFieldFormat{shorthandintro}{% - \ifcapital{\MakeCapital{#1}}{#1}\isdot} -% citation commands -\DeclareFieldFormat{prenote}{#1\isdot} -\DeclareFieldFormat{postnote}{\mkpageprefix[pagination]{#1}} -\DeclareFieldFormat{volcitevolume}{\bibstring{volume}\ppspace#1} -\DeclareFieldFormat{volcitepages}{\mkpageprefix[pagination]{#1}} -\DeclareFieldFormat{volcitenote}{\mkvolcitenote#1} -\newrobustcmd*{\mkvolcitenote}[2]{% - \printtext[volcitevolume]{#1}% - \ifblank{#2}{}{\volcitedelim\printtext[volcitepages]{#2}}} - -% multicite commands -\DeclareFieldFormat{multiprenote}{#1\isdot} -\DeclareFieldFormat{multipostnote}{\mkpageprefix[pagination]{#1}} - -% Used by \citeurl - -\DeclareFieldFormat{citeurl}{\url{#1}} - -% Used in the bibliography and bibliography lists - -\DeclareFieldFormat{doi}{% - \mkbibacro{DOI}\addcolon\space - \ifhyperref - {\href{http://dx.doi.org/#1}{\nolinkurl{#1}}} - {\nolinkurl{#1}}} -\DeclareFieldFormat{edition}{% - \ifinteger{#1} - {\mkbibordedition{#1}~\bibstring{edition}} - {#1\isdot}} -\DeclareFieldFormat{eprint}{% - \iffieldundef{eprinttype} - {eprint} - {\thefield{eprinttype}}% - \addcolon\space - \ifhyperref - {\url{#1}} - {\nolinkurl{#1}}% - \iffieldundef{eprintclass} - {} - {\addspace\mkbibparens{\thefield{eprintclass}}}} -\DeclareFieldFormat{eprint:hdl}{% - HDL\addcolon\space - \ifhyperref - {\href{http://hdl.handle.net/#1}{\nolinkurl{#1}}} - {\nolinkurl{#1}}} -\DeclareFieldAlias{eprint:HDL}{eprint:hdl} -\DeclareFieldFormat{eprint:arxiv}{% - arXiv\addcolon\space - \ifhyperref - {\href{http://arxiv.org/\abx@arxivpath/#1}{% - \nolinkurl{#1}% - \iffieldundef{eprintclass} - {} - {\addspace\texttt{\mkbibbrackets{\thefield{eprintclass}}}}}} - {\nolinkurl{#1} - \iffieldundef{eprintclass} - {} - {\addspace\texttt{\mkbibbrackets{\thefield{eprintclass}}}}}} -\DeclareFieldAlias{eprint:arXiv}{eprint:arxiv} -\DeclareFieldFormat{eprint:jstor}{% - JSTOR\addcolon\space - \ifhyperref - {\href{http://www.jstor.org/stable/#1}{\nolinkurl{#1}}} - {\nolinkurl{#1}}} -\DeclareFieldAlias{eprint:JSTOR}{eprint:jstor} -\DeclareFieldFormat{eprint:pubmed}{% - PMID\addcolon\space - \ifhyperref - {\href{http://www.ncbi.nlm.nih.gov/pubmed/#1}{\nolinkurl{#1}}} - {\nolinkurl{#1}}} -\DeclareFieldAlias{eprint:PubMed}{eprint:pubmed} -\DeclareFieldFormat{eprint:googlebooks}{% - Google Books\addcolon\space - \ifhyperref - {\href{http://books.google.com/books?id=#1}{\nolinkurl{#1}}} - {\nolinkurl{#1}}} -\DeclareFieldAlias{eprint:Google Books}{eprint:googlebooks} -\DeclareFieldFormat{file}{\url{#1}} -\DeclareFieldFormat{isbn}{\mkbibacro{ISBN}\addcolon\space #1} -\DeclareFieldFormat{isrn}{\mkbibacro{ISRN}\addcolon\space #1} -\DeclareFieldFormat{issn}{\mkbibacro{ISSN}\addcolon\space #1} -\DeclareFieldFormat{journaltitle}{\mkbibemph{#1}} -\DeclareFieldFormat{issuetitle}{\mkbibemph{#1}} -\DeclareFieldFormat{maintitle}{\mkbibemph{#1}} -\DeclareFieldFormat{booktitle}{\mkbibemph{#1}} -\DeclareFieldFormat{chapter}{\bibstring{chapter}~#1} -\DeclareFieldFormat{month}{\mkbibmonth{#1}} -\DeclareFieldFormat{note}{#1\isdot} -\DeclareFieldFormat{number}{#1}% number in a series -\DeclareFieldFormat[article,periodical]{number}{#1}% number of a journal -\DeclareFieldFormat{pages}{\mkpageprefix[bookpagination]{#1}} -\DeclareFieldFormat{pagetotal}{\mkpagetotal[bookpagination]{#1}} -\DeclareFieldFormat{part}{.#1}% physical part of a logical volume -\DeclareFieldFormat{series}{#1}% publication series -\DeclareFieldFormat[article,periodical]{series}{% series of a journal - \ifinteger{#1} - {\mkbibordseries{#1}~\bibstring{jourser}} - {\ifbibstring{#1}{\bibstring{#1}}{#1}}} -\DeclareFieldFormat{pubstate}{\ifbibstring{#1}{\bibstring{#1}}{#1}} -\DeclareFieldFormat{title}{\mkbibemph{#1}} -\DeclareFieldFormat - [article,inbook,incollection,inproceedings,patent,thesis,unpublished] - {title}{\mkbibquote{#1\isdot}} -\DeclareFieldFormat - [suppbook,suppcollection,suppperiodical] - {title}{#1} -\DeclareFieldFormat{type}{\ifbibstring{#1}{\bibstring{#1}}{#1}} -\DeclareFieldFormat{url}{\mkbibacro{URL}\addcolon\space\url{#1}} -\DeclareFieldFormat{urldate}{\mkbibparens{\bibstring{urlseen}\space#1}} -\DeclareFieldFormat{version}{\bibstring{version}~#1} -\DeclareFieldFormat{volume}{\bibstring{volume}~#1}% volume of a book -\DeclareFieldFormat[article,periodical]{volume}{#1}% volume of a journal -\DeclareFieldFormat{volumes}{#1~\bibstring{volumes}} -\DeclareFieldFormat{related}{#1} -\DeclareFieldFormat{related:multivolume}{\par\nobreak#1} -\DeclareFieldFormat{related:origpubin}{\mkbibparens{#1}} -\DeclareFieldFormat{related:origpubas}{\mkbibparens{#1}} -\DeclareFieldFormat{relatedstring:default}{#1\printunit{\relatedpunct}} -\DeclareFieldFormat{relatedstring:reprintfrom}{#1\addspace} - -% Generic formats for \printtext and \printfield - -\DeclareFieldFormat{emph}{\mkbibemph{#1}} -\DeclareFieldFormat{bold}{\textbf{#1}} -\DeclareFieldFormat{smallcaps}{\textsc{#1}} -\DeclareFieldFormat{parens}{\mkbibparens{#1}} -\DeclareFieldFormat{brackets}{\mkbibbrackets{#1}} -\DeclareFieldFormat{bibhyperref}{\bibhyperref{#1}} -\DeclareFieldFormat{bibhyperlink}{\bibhyperlink{\thefield{entrykey}}{#1}} -\DeclareFieldFormat{bibhypertarget}{\bibhypertarget{\thefield{entrykey}}{#1}} -\DeclareFieldFormat{titlecase}{#1} -\DeclareFieldFormat{noformat}{#1} - -% ------------------------------------------------------------------ -% LITERAL LIST FORMATS (#1 is the current item) -% ------------------------------------------------------------------ - -% Formatting directives for literal lists -% ------------------------------------------------------------------ - -% The fallback used by \printlist - -\DeclareListFormat{default}{% - \usebibmacro{list:delim}{#1}% - #1\isdot - \usebibmacro{list:andothers}} - -% The default used by \citelist - -\DeclareListAlias{citelist}{default} - -% Used in the bibliography - -\DeclareListFormat{publisher}{% - \usebibmacro{list:delim}{#1}% - #1\isdot - \usebibmacro{list:andothers}} - -\DeclareListFormat{language}{% - \usebibmacro{list:delim}{% - \ifbibstring{#1} - {\bibxstring{#1}} - {\ifbibstring{lang#1} - {\bibxstring{lang#1}} - {#1}}}% - \ifbibstring{#1} - {\bibstring{#1}} - {\ifbibstring{lang#1} - {\bibstring{lang#1}} - {#1}}% - \usebibmacro{list:andothers}} - -\DeclareListFormat{location}{% - \usebibmacro{list:delim}{#1}% - #1\isdot - \usebibmacro{list:andothers}} - -\DeclareListFormat[patent]{location}{% - \usebibmacro{list:plain}% - \ifbibstring{#1}{\bibstring{#1}}{#1\isdot}% - \usebibmacro{list:andothers}} - -\DeclareListFormat{pageref}{% - \ifnumless{\abx@pagerefstyle}{0} - {\usebibmacro{list:plain}% - \ifhyperref - {\hyperlink{page.#1}{#1}} - {#1}} - {\ifnumequal{\value{listcount}}{1} - {\usebibmacro{pageref:init}} - {}% - \usebibmacro{pageref:comp}{#1}% - \ifnumequal{\value{listcount}}{\value{liststop}} - {\usebibmacro{pageref:dump}} - {}}} - -\DeclareListAlias{origlocation}{location} -\DeclareListAlias{origpublisher}{publisher} -\DeclareListAlias{institution}{default} -\DeclareListAlias{organization}{default} - -% Auxiliary macros for list formatting directives -% ------------------------------------------------------------------ - -\newbibmacro*{list:delim}[1]{% - \ifnumgreater{\value{listcount}}{\value{liststart}} - {\ifboolexpr{ - test {\ifnumless{\value{listcount}}{\value{liststop}}} - or - test \ifmoreitems - } - {\multilistdelim} - {\lbx@finallistdelim{#1}}} - {}} - -\newbibmacro*{list:plain}{% - \ifnumgreater{\value{listcount}}{\value{liststart}} - {\multilistdelim} - {}} - -\newbibmacro*{list:andothers}{% - \ifboolexpr{ - test {\ifnumequal{\value{listcount}}{\value{liststop}}} - and - test \ifmoreitems - } - {\ifnumgreater{\value{liststop}}{1} - {\finalandcomma} - {}% - \andmoredelim\bibstring{andmore}} - {}} - -\newbibmacro*{pageref:init}{% - \let\abx@range@hold=\empty - \def\abx@range@diff{0}% - \def\abx@range@prev{-1}% - \def\abx@range@this{0}% - \def\abx@range@last{-1}} - -\newbibmacro*{pageref:comp}[1]{% - \numdef\abx@range@prev{\abx@range@prev+1}% - \ifinteger{#1} - {\def\abx@range@num{#1}% - \def\abx@range@this{1}% - \ifnumequal{\abx@range@this}{\abx@range@last} - {} - {\def\abx@range@prev{-1}}} - {\ifrmnum{#1} - {\numdef\abx@range@num{\rmntonum{#1}}% - \def\abx@range@this{2}% - \ifnumequal{\abx@range@this}{\abx@range@last} - {} - {\def\abx@range@prev{-1}}} - {\undef\abx@range@num - \def\abx@range@this{0}% - \def\abx@range@prev{-1}}}% - \ifdef\abx@range@num - {\ifnumequal{\abx@range@num}{\abx@range@prev} - {\def\abx@range@hold{#1}% - \numdef\abx@range@diff{\abx@range@diff+1}} - {\usebibmacro{pageref:dump}% - \ifnumgreater{\abx@range@last}{-1} - {\multilistdelim} - {}% - \ifhyperref - {\hyperlink{page.#1}{#1}} - {#1}}% - \edef\abx@range@prev{\abx@range@num}} - {\usebibmacro{pageref:dump}% - \ifnumgreater{\abx@range@last}{-1} - {\multilistdelim} - {}% - \ifhyperref - {\hyperlink{page.#1}{#1}} - {#1}% - \def\abx@range@prev{-1}}% - \edef\abx@range@last{\abx@range@this}} - -\newbibmacro*{pageref:dump}{% - \ifnumgreater{\abx@range@diff}{0} - {\ifcase\abx@pagerefstyle\relax % two - \bibrangedash - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\abx@range@hold}} - {\abx@range@hold}% - \or % three - \ifnumless{\abx@range@diff}{2} - {\multilistdelim} - {\bibrangedash}% - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\abx@range@hold}} - {\abx@range@hold}% - \or % two+ - \ifnumless{\abx@range@diff}{2} - {\sqspace - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\bibstring{sequens}}} - {\bibstring{sequens}}} - {\bibrangedash - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\abx@range@hold}} - {\abx@range@hold}}% - \or % three+ - \ifnumless{\abx@range@diff}{2} - {\sqspace - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\bibstring{sequens}}} - {\bibstring{sequens}}} - {\ifnumless{\abx@range@diff}{3} - {\sqspace - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\bibstring{sequentes}}} - {\bibstring{sequentes}}} - {\bibrangedash - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\abx@range@hold}} - {\abx@range@hold}}}% - \else % all+ - \ifnumless{\abx@range@diff}{2} - {\sqspace - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\bibstring{sequens}}} - {\bibstring{sequens}}} - {\sqspace - \ifhyperref - {\hyperlink{page.\abx@range@hold}{\bibstring{sequentes}}} - {\bibstring{sequentes}}}% - \fi - \def\abx@range@diff{0}} - {}} - -% ------------------------------------------------------------------ -% NAME LIST FORMATS -% ------------------------------------------------------------------ - -% Argments passed to formatting directives for name lists: -% -% #1 = last name -% #2 = last name (initials) -% #3 = first name -% #4 = first name (initials) -% #5 = name prefix, a.k.a. 'von part' -% #6 = name prefix (initials) -% #7 = name affix, a.k.a. 'junior part' -% #8 = name affix (initials) - -% Formatting directives for name lists -% ------------------------------------------------------------------ - -\DeclareNameFormat{first-last}{% - \iffirstinits - {\usebibmacro{name:first-last}{#1}{#4}{#5}{#7}} - {\usebibmacro{name:first-last}{#1}{#3}{#5}{#7}}% - \usebibmacro{name:andothers}} - -\DeclareNameFormat{last-first}{% - \iffirstinits - {\usebibmacro{name:last-first}{#1}{#4}{#5}{#7}} - {\usebibmacro{name:last-first}{#1}{#3}{#5}{#7}}% - \usebibmacro{name:andothers}} - -\DeclareNameFormat{last-first/first-last}{% - \ifnumequal{\value{listcount}}{1} - {\iffirstinits - {\usebibmacro{name:last-first}{#1}{#4}{#5}{#7}} - {\usebibmacro{name:last-first}{#1}{#3}{#5}{#7}}% - \ifblank{#3#5} - {} - {\usebibmacro{name:revsdelim}}} - {\iffirstinits - {\usebibmacro{name:first-last}{#1}{#4}{#5}{#7}} - {\usebibmacro{name:first-last}{#1}{#3}{#5}{#7}}}% - \usebibmacro{name:andothers}} - -\DeclareNameFormat{initsonly}{% - \usebibmacro{name:first-last}{#2}{#4}{#6}{#8}% - \usebibmacro{name:andothers}} - -% Fallback used by \printnames - -\DeclareNameAlias{default}{first-last} - -% Default used by \citename - -\DeclareNameAlias{citename}{default} - -% Used in some citations - -\DeclareNameFormat{labelname}{% - \ifcase\value{uniquename}% - \usebibmacro{name:last}{#1}{#3}{#5}{#7}% - \or - \ifuseprefix - {\usebibmacro{name:first-last}{#1}{#4}{#5}{#8}} - {\usebibmacro{name:first-last}{#1}{#4}{#6}{#8}}% - \or - \usebibmacro{name:first-last}{#1}{#3}{#5}{#7}% - \fi - \usebibmacro{name:andothers}} - -% Used in the bibliography - -\DeclareNameAlias{sortname}{last-first/first-last} - -\DeclareNameAlias{author}{default} -\DeclareNameAlias{bookauthor}{author} -\DeclareNameAlias{editor}{default} -\DeclareNameAlias{editora}{editor} -\DeclareNameAlias{editorb}{editor} -\DeclareNameAlias{editorc}{editor} -\DeclareNameAlias{translator}{default} - -\DeclareNameAlias{byauthor}{default} -\DeclareNameAlias{bybookauthor}{byauthor} -\DeclareNameAlias{byeditor}{default} -\DeclareNameAlias{byeditora}{byeditor} -\DeclareNameAlias{byeditorb}{byeditor} -\DeclareNameAlias{byeditorc}{byeditor} -\DeclareNameAlias{bytranslator}{default} - -\DeclareNameAlias{withcommentator}{default} -\DeclareNameAlias{withannotator}{default} -\DeclareNameAlias{withintroduction}{default} -\DeclareNameAlias{withforeword}{default} -\DeclareNameAlias{withafterword}{default} - -\DeclareFieldFormat{authortype}{#1} -\DeclareFieldFormat{editortype}{#1} - -% Auxiliary macros for name formatting directives -% ------------------------------------------------------------------ - -\newbibmacro*{name:last}[4]{% - \ifuseprefix - {\usebibmacro{name:delim}{#3#1}% - \usebibmacro{name:hook}{#3#1}% - \ifblank{#3} - {} - {\ifcapital - {\mkbibnameprefix{\MakeCapital{#3}}\isdot} - {\mkbibnameprefix{#3}\isdot}% - \ifprefchar{}{\bibnamedelimc}}} - {\usebibmacro{name:delim}{#1}% - \usebibmacro{name:hook}{#1}}% - \mkbibnamelast{#1}\isdot}% - -\newbibmacro*{name:first-last}[4]{% - \usebibmacro{name:delim}{#2#3#1}% - \usebibmacro{name:hook}{#2#3#1}% - \ifblank{#2}{}{\mkbibnamefirst{#2}\isdot\bibnamedelimd}% - \ifblank{#3}{}{% - \mkbibnameprefix{#3}\isdot - \ifprefchar{} - {} - {\ifuseprefix{\bibnamedelimc}{\bibnamedelimd}}}% - \mkbibnamelast{#1}\isdot - \ifblank{#4}{}{\bibnamedelimd\mkbibnameaffix{#4}\isdot}} - -\newbibmacro*{name:last-first}[4]{% - \ifuseprefix - {\usebibmacro{name:delim}{#3#1}% - \usebibmacro{name:hook}{#3#1}% - \ifblank{#3}{}{% - \ifcapital - {\mkbibnameprefix{\MakeCapital{#3}}\isdot} - {\mkbibnameprefix{#3}\isdot}% - \ifprefchar{}{\bibnamedelimc}}% - \mkbibnamelast{#1}\isdot - \ifblank{#4}{}{\bibnamedelimd\mkbibnameaffix{#4}\isdot}% - \ifblank{#2}{}{\revsdnamepunct\bibnamedelimd\mkbibnamefirst{#2}\isdot}} - {\usebibmacro{name:delim}{#1}% - \usebibmacro{name:hook}{#1}% - \mkbibnamelast{#1}\isdot - \ifblank{#4}{}{\bibnamedelimd\mkbibnameaffix{#4}\isdot}% - \ifblank{#2#3}{}{\revsdnamepunct}% - \ifblank{#2}{}{\bibnamedelimd\mkbibnamefirst{#2}\isdot}% - \ifblank{#3}{}{\bibnamedelimd\mkbibnameprefix{#3}\isdot}}} - -\newbibmacro*{name:hook}[1]{% - \ifnumequal{\value{listcount}}{1} - {\lbx@initnamehook{#1}} - {}} - -\newbibmacro*{name:delim}[1]{% - \ifnumgreater{\value{listcount}}{\value{liststart}} - {\ifboolexpr{ - test {\ifnumless{\value{listcount}}{\value{liststop}}} - or - test \ifmorenames - } - {\multinamedelim} - {\lbx@finalnamedelim{#1}}} - {}} - -\newbibmacro*{name:revsdelim}{% - \ifboolexpr{ - ( - test {\ifnumequal{\value{liststop}}{1}} - and - test \ifmorenames - ) - or - test {\ifnumequal{\value{liststop}}{2}} - } - {\revsdnamedelim} - {}} - -\newbibmacro*{name:andothers}{% - \ifboolexpr{ - test {\ifnumequal{\value{listcount}}{\value{liststop}}} - and - test \ifmorenames - } - {\ifnumgreater{\value{liststop}}{1} - {\finalandcomma} - {}% - \andothersdelim\bibstring{andothers}} - {}} - -% ------------------------------------------------------------------ -% INDEX FORMATS FOR FIELDS (#1 is the value of the field) -% ------------------------------------------------------------------ - -% There is no need to test if a field to be indexed is empty because -% \indexfield performs this test implicitly. - -% The fallback used by \indexfield - -\DeclareIndexFieldFormat{default}{\index{#1}} - -% Used in the bibliography and in citations - -\DeclareIndexFieldFormat{indextitle}{% - \usebibmacro{index:title}{\index}{#1}} - -\newbibmacro*{index:title}[2]{% - \usebibmacro{index:field}{#1}{\thefield{indexsorttitle}}{\emph{#2}}} - -\newbibmacro*{index:field}[3]{% - \usebibmacro{index:entry}{#1}{\mkbibindexfield{#2}{#3}}} - -% Auxiliary macros for field indexing directives -% ------------------------------------------------------------------ - -\newbibmacro*{index:entry}[2]{% - \begingroup - \protected@edef\theindexentry{\unexpanded{#1}{#2}}% - \theindexentry - \endgroup} - -\newcommand*{\mkbibindexfield}[2]{\mkbibindexentry{#1}{\unexpanded{#2}}} -\newcommand*{\mkbibindexentry}[2]{#1\actualoperator#2} - -% ------------------------------------------------------------------ -% INDEX FORMATS FOR LITERAL LISTS (#1 is the current item) -% ------------------------------------------------------------------ - -% The fallback used by \indexlist - -\DeclareIndexListFormat{default}{\index{#1}} - -% ------------------------------------------------------------------ -% INDEX FORMATS FOR NAME LISTS -% ------------------------------------------------------------------ - -% Argments passed to indexing directives for name lists: -% -% #1 = last name -% #2 = last name (initials) -% #3 = first name -% #4 = first name (initials) -% #5 = name prefix, a.k.a 'von part' -% #6 = name prefix (initials) -% #7 = name affix, a.k.a 'junior part' -% #8 = name affix (initials) - -% Indexing directives for name lists -% ------------------------------------------------------------------ - -% The fallback used by \indexnames - -\DeclareIndexNameFormat{default}{% - \usebibmacro{index:name}{\index}{#1}{#3}{#5}{#7}} - -% Used in citations - -\DeclareIndexNameAlias{labelname}{default} - -% Used in the bibliography - -\DeclareIndexNameAlias{author}{default} -\DeclareIndexNameAlias{editor}{default} -\DeclareIndexNameAlias{bookauthor}{default} - -% Auxiliary macros for name indexing directives -% ------------------------------------------------------------------ - -% When generating an index entry, we need to test which parts of a -% name are actually available to prevent spurious punctuation and -% spaces. Since those parts which are not available yield an empty -% argument, we can use the \ifblank test from etoolbox.sty to analyze -% the name. -% -% Note that the standard LaTeX \index command simply writes its -% argument to the .idx file without preventing expansion. This means -% that all \ifblank tests are expanded on the way and will not end -% up in the index. The index package, however, prevents expansion. -% This would lead to \ifblank ending up in the .idx file. To avoid -% that, we preprocess the index entry inside an \edef. We use -% \unexpanded to protect the \index command and the actual data from -% expansion. This definition will work with both index.sty and the -% standard indexing facilities. -% -% We also use \ifuseprefix to ensure that the name prefix is handled -% properly. \actualoperator is the so-called actual operator, as -% defined by the 'actual' specifier in the .ist file. The makeindex -% program will use the part preceeding the \actualoperator -% delimiter for sorting. The part after the delimiter is used as the -% index is printed. Note that this is not specific to biblatex, see -% the makeindex documentation for details. - -\newcommand*{\actualoperator}{@} -\newcommand*{\subentryoperator}{!} - -\newbibmacro*{index:name}[5]{% - \usebibmacro{index:entry}{#1}{\mkbibindexname{#2}{#3}{#4}{#5}}} - -% {}{}{}{} - -\newcommand*{\mkbibindexname}[4]{% - \ifuseprefix - {\ifblank{#3}{}{#3 }% - \@firstofone #1% remove spurious braces - \ifblank{#4}{}{ #4}% - \ifblank{#2}{}{, #2}% - \actualoperator - \ifblank{#3}{}{\MakeCapital{#3} }% - #1% - \ifblank{#4}{}{ #4}% - \ifblank{#2}{}{, #2}} - {\@firstofone #1% remove spurious braces - \ifblank{#4}{}{ #4}% - \ifblank{#2#3}{}{,}% - \ifblank{#2}{}{ #2}% - \ifblank{#3}{}{ #3}}} - -% {}{} - -\newcommand*{\mkbibindexsubentry}[2]{% - \ifblank{#1}{}{\subentryoperator#1\actualoperator#2}} - -% Additional macros with subentries - -\newbibmacro*{index:name:field}[6]{% - \usebibmacro{index:name:subentry}{#1}{#2}{#3}{#4}{#5} - {\thefield{#6}}{\csfield{#6}}} - -\newbibmacro*{index:name:title}[5]{% - \usebibmacro{index:name:subentry}{#1}{#2}{#3}{#4}{#5} - {\thefield{indexsorttitle}}{\emph{\csfield{indextitle}}}} - -\newbibmacro*{index:name:subentry}[7]{% - \usebibmacro{index:entry}{#1}{% - \mkbibindexname{#2}{#3}{#4}{#5}\mkbibindexsubentry{#6}{#7}}} - -% ------------------------------------------------------------------ -% Driver sourcemaps -% ------------------------------------------------------------------ - -\DeclareDriverSourcemap[datatype=bibtex]{ - \map{ - \step[fieldset=day, null] - } - \map{ - \step[typesource=conference, typetarget=inproceedings] - \step[typesource=electronic, typetarget=online] - \step[typesource=www, typetarget=online] - } - \map{ - \step[typesource=mastersthesis, typetarget=thesis, final] - \step[fieldset=type, fieldvalue=mathesis] - } - \map{ - \step[typesource=phdthesis, typetarget=thesis, final] - \step[fieldset=type, fieldvalue=phdthesis] - } - \map{ - \step[typesource=techreport, typetarget=report, final] - \step[fieldset=type, fieldvalue=techreport] - } - \map{ - \step[fieldsource=hyphenation, fieldtarget=langid] - \step[fieldsource=address, fieldtarget=location] - \step[fieldsource=school, fieldtarget=institution] - \step[fieldsource=annote, fieldtarget=annotation] - \step[fieldsource=archiveprefix, fieldtarget=eprinttype] - \step[fieldsource=journal, fieldtarget=journaltitle] - \step[fieldsource=primaryclass, fieldtarget=eprintclass] - \step[fieldsource=key, fieldtarget=sortkey] - \step[fieldsource=pdf, fieldtarget=file] - } -} - -\DeclareDriverSourcemap[datatype=endnotexml]{ - \map{ - \step[typesource={Aggregated Database}, typetarget=misc] - \step[typesource={Ancient Text}, typetarget=misc] - \step[typesource=Artwork, typetarget=artwork] - \step[typesource={Audiovisual Material}, typetarget=misc] - \step[typesource=Bill, typetarget=jurisdiction] - \step[typesource=Blog, typetarget=online] - \step[typesource=Book, typetarget=book] - \step[typesource={Book Section}, typetarget=inbook] - \step[typesource=Case, typetarget=jurisdiction] - \step[typesource=Catalog, typetarget=misc] - \step[typesource={Chart or Table}, typetarget=misc] - \step[typesource={Classical Work}, typetarget=misc] - \step[typesource={Computer Program}, typetarget=software] - \step[typesource={Conference Paper}, typetarget=inproceedings] - \step[typesource={Conference Proceedings}, typetarget=proceedings] - \step[typesource=Dictionary, typetarget=inreference] - \step[typesource={Edited Book}, typetarget=collection] - \step[typesource={Electronic Article}, typetarget=article] - \step[typesource={Electronic Book}, typetarget=book] - \step[typesource={Encyclopedia}, typetarget=reference] - \step[typesource=Equation, typetarget=misc] - \step[typesource=Figure, typetarget=misc] - \step[typesource={Film or Broadcast}, typetarget=movie] - \step[typesource={Government Document}, typetarget=report] - \step[typesource=Grant, typetarget=misc] - \step[typesource=Hearing, typetarget=jurisdiction] - \step[typesource={Journal Article}, typetarget=article] - \step[typesource={Legal Rule or Regulation}, typetarget=legislation] - \step[typesource={Magazine Article}, typetarget=article] - \step[typesource=Manuscript, typetarget=unpublished] - \step[typesource=Map, typetarget=misc] - \step[typesource={Newspaper Article}, typetarget=article] - \step[typesource={Online Database}, typetarget=online] - \step[typesource={Online Multimedia}, typetarget=online] - \step[typesource=Pamphlet, typetarget=booklet] - \step[typesource=Patent, typetarget=patent] - \step[typesource={Personal Communication}, typetarget=letter] - \step[typesource=Report, typetarget=report] - \step[typesource=Serial, typetarget=periodical] - \step[typesource=Standard, typetarget=standard] - \step[typesource=Statute, typetarget=legislation] - \step[typesource=Thesis, typetarget=thesis] - \step[typesource={Unpublished Work}, typetarget=unpublished] - \step[typesource={Web Page}, typetarget=online] - } - \map{ - \step[fieldsource={electronic-resource-num}, fieldtarget=eprint] - \step[fieldsource={alt-title}, fieldtarget=shorttitle] - \step[fieldsource={meeting-place}, fieldtarget=venue] - \step[fieldsource={pub-location}, fieldtarget=location] - \step[fieldsource={orig-pub}, fieldtarget=origpublisher] - \step[fieldsource={authors}, fieldtarget=author] - \step[fieldsource={secondary-authors}, fieldtarget=editor] - \step[fieldsource={tertiary-authors}, fieldtarget=commentator] - \step[fieldsource={subsidiary-authors}, fieldtarget=translator] - \step[fieldsource={year}, fieldtarget=date] - \step[fieldsource={pub-dates}, fieldtarget=date] - \step[fieldsource={num-vols}, fieldtarget=volumes] - \step[fieldsource={call-num}, fieldtarget=library] - \step[fieldsource={notes}, fieldtarget=note] - \step[fieldsource={secondary-title}, fieldtarget=subtitle] - \step[fieldsource={work-type}, fieldtarget=type] - } - \map{ - \pertype{Edited Book} - \step[fieldsource=contributors/authors, fieldtarget=contributors/editor] - } - \map{ - \pertype{Electronic Article} - \pertype{Journal Article} - \pertype{Magazine Article} - \pertype{Newspaper Article} - \step[fieldsource=isbn, fieldtarget=issn] - } - \map{ - \pertype{Patent} - \pertype{Report} - \pertype{Government Document} - \pertype{Legal Rule or Regulation} - \step[fieldsource=isbn, fieldtarget=number] - } - \map{ - \pertype{Blog} - \pertype{Online Database} - \pertype{Online Multimedia} - \pertype{Web Page} - \step[fieldsource={titles/secondary-title}, fieldtarget={titles/title}] - } - \map{ - \pertype{Book Section} - \step[fieldsource={titles/secondary-title}, fieldtarget={titles/booktitle}] - } - \map{ - \pertype{Book} - \pertype{Electronic Book} - \pertype{Manuscript} - \pertype{Unpublished Work} - \step[fieldsource={titles/secondary-title}, fieldtarget={titles/series}] - } - \map{ - \pertype{Conference Paper} - \pertype{Conference Proceedings} - \step[fieldsource={titles/secondary-title}, fieldtarget={titles/eventtitle}] - } - \map{ - \pertype{Electronic Article} - \pertype{Journal Article} - \pertype{Magazine Article} - \pertype{Newspaper Article} - \step[fieldsource={titles/secondary-title}, fieldtarget={titles/journaltitle}] - } - \map{ - \pertype{Book Section} - \step[fieldsource={titles/tertiary-title}, fieldtarget={titles/booktitle}] - } - \map{ - \pertype{Conference Proceedings} - \pertype{periodical} - \step[fieldsource={titles/tertiary-title}, fieldtarget={titles/series}] - } -} -\DeclareDriverSourcemap[datatype=ris]{ - \map{ - \step[typesource=ART, typetarget=artwork] - \step[typesource=BILL, typetarget=jurisdiction] - \step[typesource=BOOK, typetarget=book] - \step[typesource=CHAP, typetarget=inbook] - \step[typesource=COMP, typetarget=software] - \step[typesource=CONF, typetarget=proceedings] - \step[typesource=GEN, typetarget=misc] - \step[typesource=JFULL, typetarget=article] - \step[typesource=JOUR, typetarget=article] - \step[typesource=MGZN, typetarget=misc] - \step[typesource=MPCT, typetarget=movie] - \step[typesource=NEWS, typetarget=misc] - \step[typesource=PAMP, typetarget=misc] - \step[typesource=PAT, typetarget=patent] - \step[typesource=PCOMM, typetarget=misc] - \step[typesource=RPRT, typetarget=report] - \step[typesource=SER, typetarget=misc] - \step[typesource=SLIDE, typetarget=misc] - \step[typesource=SOUND, typetarget=audio] - \step[typesource=STAT, typetarget=legal] - \step[typesource=THES, typetarget=thesis] - \step[typesource=UNBILL, typetarget=jurisdiction] - \step[typesource=UNPB, typetarget=unpublished] - } - \map{ - \step[fieldsource=Y1, fieldtarget=date] - \step[fieldsource=PY, fieldtarget=date] - \step[fieldsource=Y2, fieldtarget=eventdate] - \step[fieldsource=A1, fieldtarget=author] - \step[fieldsource=AU, fieldtarget=author] - \step[fieldsource=A2, fieldtarget=editor] - \step[fieldsource=A3, fieldtarget=editor] - \step[fieldsource=ED, fieldtarget=editor] - \step[fieldsource=SPEP, fieldtarget=pages] - \step[fieldsource=N1, fieldtarget=note] - \step[fieldsource=N2, fieldtarget=abstract] - \step[fieldsource=AB, fieldtarget=abstract] - \step[fieldsource=JO, fieldtarget=journaltitle] - \step[fieldsource=JF, fieldtarget=journaltitle] - \step[fieldsource=JA, fieldtarget=shortjournal] - \step[fieldsource=VL, fieldtarget=volume] - \step[fieldsource=IS, fieldtarget=issue] - \step[fieldsource=CP, fieldtarget=issue] - \step[fieldsource=CY, fieldtarget=location] - \step[fieldsource=SN, fieldtarget=isbn] - \step[fieldsource=PB, fieldtarget=publisher] - \step[fieldsource=KW, fieldtarget=keywords] - \step[fieldsource=TI, fieldtarget=title] - \step[fieldsource=U1, fieldtarget=usera] - \step[fieldsource=U2, fieldtarget=userb] - \step[fieldsource=U3, fieldtarget=userc] - \step[fieldsource=U4, fieldtarget=userd] - \step[fieldsource=U5, fieldtarget=usere] - \step[fieldsource=UR, fieldtarget=url] - \step[fieldsource=L1, fieldtarget=file] - } -} -\DeclareDriverSourcemap[datatype=zoterordfxml]{ - \map{ - \step[typesource=conferencePaper, typetarget=inproceedings] - \step[typesource=bookSection, typetarget=inbook] - \step[typesource=journalArticle, typetarget=article] - \step[typesource=magazineArticle, typetarget=article] - \step[typesource=newspaperArticle, typetarget=article] - \step[typesource=encyclopediaArticle, typetarget=inreference] - \step[typesource=manuscript, typetarget=unpublished] - \step[typesource=document, typetarget=misc] - \step[typesource=dictionaryEntry, typetarget=inreference] - \step[typesource=interview, typetarget=misc] - \step[typesource=film, typetarget=movie] - \step[typesource=webpage, typetarget=online] - \step[typesource=note, typetarget=misc] - \step[typesource=attachment, typetarget=misc] - \step[typesource=bill, typetarget=legislation] - \step[typesource=case, typetarget=jurisdiction] - \step[typesource=hearing, typetarget=jurisdiction] - \step[typesource=statute, typetarget=legislation] - \step[typesource=email, typetarget=letter] - \step[typesource=map, typetarget=image] - \step[typesource=blogPost, typetarget=online] - \step[typesource=instantMessage, typetarget=letter] - \step[typesource=forumPost, typetarget=online] - \step[typesource=audioRecording, typetarget=audio] - \step[typesource=presentation, typetarget=inproceedings] - \step[typesource=videoRecording, typetarget=video] - \step[typesource=tvBroadcast, typetarget=misc] - \step[typesource=radioBroadcast, typetarget=misc] - \step[typesource=podcast, typetarget=online] - \step[typesource=computerProgram, typetarget=software] - } - \map{ - \step[fieldsource=bib:contributors, fieldtarget=author] - \step[fieldsource=bib:authors, fieldtarget=author] - \step[fieldsource=z:interviewers, fieldtarget=author] - \step[fieldsource=z:directors, fieldtarget=author] - \step[fieldsource=z:scriptwriters, fieldtarget=author] - \step[fieldsource=z:bookAuthor, fieldtarget=author] - \step[fieldsource=z:inventors, fieldtarget=author] - \step[fieldsource=z:recipients, fieldtarget=author] - \step[fieldsource=z:counsels, fieldtarget=author] - \step[fieldsource=z:artists, fieldtarget=author] - \step[fieldsource=z:podcasters, fieldtarget=author] - \step[fieldsource=z:presenters, fieldtarget=author] - \step[fieldsource=z:commenters, fieldtarget=author] - \step[fieldsource=z:programers, fieldtarget=author] - \step[fieldsource=z:composers, fieldtarget=author] - \step[fieldsource=z:producers, fieldtarget=author] - \step[fieldsource=z:performers, fieldtarget=author] - \step[fieldsource=bib:editors, fieldtarget=editor] - \step[fieldsource=z:translators, fieldtarget=translator] - \step[fieldsource=z:seriesEditors, fieldtarget=editor] - \step[fieldsource=dc:date, fieldtarget=date] - \step[fieldsource=bib:pages, fieldtarget=pages] - \step[fieldsource=dc:title, fieldtarget=title] - \step[fieldsource=z:proceedingsTitle, fieldtarget=title] - \step[fieldsource=z:encyclopediaTitle, fieldtarget=title] - \step[fieldsource=z:dictionaryTitle, fieldtarget=title] - \step[fieldsource=z:websiteTitle, fieldtarget=title] - \step[fieldsource=z:forumTitle, fieldtarget=title] - \step[fieldsource=z:blogTitle, fieldtarget=title] - \step[fieldsource=z:nameOfAct, fieldtarget=title] - \step[fieldsource=z:caseName, fieldtarget=title] - \step[fieldsource=z:meetingName, fieldtarget=eventtitle] - \step[fieldsource=prism:volume, fieldtarget=volume] - \step[fieldsource=numberOfVolumes, fieldtarget=volumes] - \step[fieldsource=z:numPages, fieldtarget=pagetotal] - \step[fieldsource=prism:edition, fieldtarget=edition] - \step[fieldsource=dc:description, fieldtarget=note] - \step[fieldsource=dc:alternative, fieldtarget=shortjournal] - \step[fieldsource=dcterms:abstract, fieldtarget=abstract] - \step[fieldsource=dc:type, fieldtarget=type] - \step[fieldsource=z:shortTitle, fieldtarget=shorttitle] - \step[fieldsource=z:bookTitle, fieldtarget=booktitle] - \step[fieldsource=prism:number, fieldtarget=number] - \step[fieldsource=z:patentNumber, fieldtarget=number] - \step[fieldsource=z:codeNumber, fieldtarget=number] - \step[fieldsource=z:reportNumber, fieldtarget=number] - \step[fieldsource=z:billNumber, fieldtarget=number] - \step[fieldsource=z:documentNumber, fieldtarget=number] - \step[fieldsource=z:publicLawNumber, fieldtarget=number] - \step[fieldsource=z:applicationNumber, fieldtarget=number] - \step[fieldsource=z:episodeNumber, fieldtarget=number] - \step[fieldsource=dc:coverage, fieldtarget=location] - \step[fieldsource=z:university, fieldtarget=institution] - \step[fieldsource=z:language, fieldtarget=language] - \step[fieldsource=z:version, fieldtarget=version] - \step[fieldsource=z:libraryCatalog, fieldtarget=library] - \step[fieldsource=dcterms:isPartOf, fieldtarget=BIBERCUSTOMpartof] - \step[fieldsource=dc:identifier, fieldtarget=BIBERCUSTOMidentifier] - \step[fieldsource=dc:publisher, fieldtarget=BIBERCUSTOMpublisher] - \step[fieldsource=dc:presentedAt, fieldtarget=BIBERCUSTOMpresentedat] - \step[fieldsource=dc:subject, fieldtarget=BIBERCUSTOMsubject] - \step[fieldsource={dcterms:BIBERCUSTOMpartof/bib:Journal}, - fieldtarget={dcterms:BIBERCUSTOMpartof/periodical}] - \step[fieldsource={dcterms:BIBERCUSTOMpartof/bib:Book}, - fieldtarget={dcterms:BIBERCUSTOMpartof/book}] - \step[fieldsource={dcterms:BIBERCUSTOMpartof/bib:ConferenceProceedings}, - fieldtarget={dcterms:BIBERCUSTOMpartof/proceedings}] - } -} - -% ------------------------------------------------------------------ -% META-FIELDS -% ------------------------------------------------------------------ - -\DeclareLabelname{% - \field{shortauthor} - \field{author} - \field{shorteditor} - \field{editor} - \field{translator} -} - -\DeclareLabeldate{% - \field{date} - \field{eventdate} - \field{origdate} - \field{urldate} - \literal{nodate} -} - -\DeclareLabeltitle{% - \field{shorttitle} - \field{title} -} - -% ------------------------------------------------------------------ -% LABELALPHA TEMPLATE -% ------------------------------------------------------------------ - -\DeclareLabelalphaTemplate{ - \labelelement{ - \field[final]{shorthand} - \field{label} - \field[strwidth=3,strside=left,ifnames=1,pcompound=true]{labelname} - \field[strwidth=1,strside=left,pcompound=true]{labelname} - } - \labelelement{ - \field[strwidth=2,strside=right]{year} - } -} - -% ------------------------------------------------------------------ -% SORTING -% ------------------------------------------------------------------ - -\DeclarePresort{mm} - -\DeclareSortingScheme{shorthand}{ - \sort[final]{ - \field{sortshorthand} - } - \sort{ - \field{shorthand} - } -} - -\DeclareSortingScheme{none}{ - \sort{\citeorder} -} - -\DeclareSortingScheme{debug}{ - \sort{ - \field{entrykey} - } -} - -\DeclareSortingScheme{nty}{ - \sort{ - \field{presort} - } - \sort[final]{ - \field{sortkey} - } - \sort{ - \field{sortname} - \field{author} - \field{editor} - \field{translator} - \field{sorttitle} - \field{title} - } - \sort{ - \field{sorttitle} - \field{title} - } - \sort{ - \field{sortyear} - \field{year} - } - \sort{ - \field[padside=left,padwidth=4,padchar=0]{volume} - \literal{0000} - } -} - -\DeclareSortingScheme{nyt}{ - \sort{ - \field{presort} - } - \sort[final]{ - \field{sortkey} - } - \sort{ - \field{sortname} - \field{author} - \field{editor} - \field{translator} - \field{sorttitle} - \field{title} - } - \sort{ - \field{sortyear} - \field{year} - } - \sort{ - \field{sorttitle} - \field{title} - } - \sort{ - \field[padside=left,padwidth=4,padchar=0]{volume} - \literal{0000} - } -} - -\DeclareSortingScheme{nyvt}{ - \sort{ - \field{presort} - } - \sort[final]{ - \field{sortkey} - } - \sort{ - \field{sortname} - \field{author} - \field{editor} - \field{translator} - \field{sorttitle} - \field{title} - } - \sort{ - \field{sortyear} - \field{year} - } - \sort{ - \field[padside=left,padwidth=4,padchar=0]{volume} - \literal{0000} - } - \sort{ - \field{sorttitle} - \field{title} - } -} - -\DeclareSortingScheme{anyt}{ - \sort{ - \field{presort} - } - \sort{ - \field{labelalpha} - } - \sort[final]{ - \field{sortkey} - } - \sort{ - \field{sortname} - \field{author} - \field{editor} - \field{translator} - \field{sorttitle} - \field{title} - } - \sort{ - \field{sortyear} - \field{year} - } - \sort{ - \field{sorttitle} - \field{title} - } - \sort{ - \field[padside=left,padwidth=4,padchar=0]{volume} - \literal{0000} - } -} - -\DeclareSortingScheme{anyvt}{ - \sort{ - \field{presort} - } - \sort{ - \field{labelalpha} - } - \sort[final]{ - \field{sortkey} - } - \sort{ - \field{sortname} - \field{author} - \field{editor} - \field{translator} - \field{sorttitle} - \field{title} - } - \sort{ - \field{sortyear} - \field{year} - } - \sort{ - \field[padside=left,padwidth=4,padchar=0]{volume} - \literal{0000} - } - \sort{ - \field{sorttitle} - \field{title} - } -} - -\DeclareSortingScheme{ynt}{ - \sort{ - \field{presort} - } - \sort[final]{ - \field{sortkey} - } - \sort{ - \field{sortyear} - \field{year} - \literal{9999} - } - \sort{ - \field{sortname} - \field{author} - \field{editor} - \field{translator} - \field{sorttitle} - \field{title} - } - \sort{ - \field{sorttitle} - \field{title} - } -} - -\DeclareSortingScheme{ydnt}{ - \sort{ - \field{presort} - } - \sort[final]{ - \field{sortkey} - } - \sort[direction=descending]{ - \field[strside=left,strwidth=4]{sortyear} - \field[strside=left,strwidth=4]{year} - \literal{9999} - } - \sort{ - \field{sortname} - \field{author} - \field{editor} - \field{translator} - \field{sorttitle} - \field{title} - } - \sort{ - \field{sorttitle} - \field{title} - } -} - -% ------------------------------------------------------------------ -% DATA INHERITANCE (CROSSREF) -% ------------------------------------------------------------------ - -\DefaultInheritance{all=true,override=false} - -\DeclareDataInheritance{mvbook,book}{inbook,bookinbook,suppbook}{% - \inherit{author}{author} - \inherit{author}{bookauthor} -} - -\DeclareDataInheritance{mvbook}{book,inbook,bookinbook,suppbook}{% - \inherit{title}{maintitle} - \inherit{subtitle}{mainsubtitle} - \inherit{titleaddon}{maintitleaddon} - \noinherit{shorttitle} - \noinherit{sorttitle} - \noinherit{indextitle} - \noinherit{indexsorttitle} -} - -\DeclareDataInheritance{mvcollection,mvreference} -{collection,reference,incollection,inreference,suppcollection}{% - \inherit{title}{maintitle} - \inherit{subtitle}{mainsubtitle} - \inherit{titleaddon}{maintitleaddon} - \noinherit{shorttitle} - \noinherit{sorttitle} - \noinherit{indextitle} - \noinherit{indexsorttitle} -} - -\DeclareDataInheritance{mvproceedings}{proceedings,inproceedings}{% - \inherit{title}{maintitle} - \inherit{subtitle}{mainsubtitle} - \inherit{titleaddon}{maintitleaddon} - \noinherit{shorttitle} - \noinherit{sorttitle} - \noinherit{indextitle} - \noinherit{indexsorttitle} -} - -\DeclareDataInheritance{book}{inbook,bookinbook,suppbook}{% - \inherit{title}{booktitle} - \inherit{subtitle}{booksubtitle} - \inherit{titleaddon}{booktitleaddon} - \noinherit{shorttitle} - \noinherit{sorttitle} - \noinherit{indextitle} - \noinherit{indexsorttitle} -} - -\DeclareDataInheritance{collection,reference} -{incollection,inreference,suppcollection}{% - \inherit{title}{booktitle} - \inherit{subtitle}{booksubtitle} - \inherit{titleaddon}{booktitleaddon} - \noinherit{shorttitle} - \noinherit{sorttitle} - \noinherit{indextitle} - \noinherit{indexsorttitle} -} - -\DeclareDataInheritance{proceedings}{inproceedings}{% - \inherit{title}{booktitle} - \inherit{subtitle}{booksubtitle} - \inherit{titleaddon}{booktitleaddon} - \noinherit{shorttitle} - \noinherit{sorttitle} - \noinherit{indextitle} - \noinherit{indexsorttitle} -} - -\DeclareDataInheritance{periodical}{article,suppperiodical}{% - \inherit{title}{journaltitle} - \inherit{subtitle}{journalsubtitle} - \noinherit{shorttitle} - \noinherit{sorttitle} - \noinherit{indextitle} - \noinherit{indexsorttitle} -} - -\DeclareDataInheritance{*}{*}{% - \noinherit{ids} - \noinherit{crossref} - \noinherit{xref} - \noinherit{entryset} - \noinherit{entrysubtype} - \noinherit{execute} - \noinherit{label} - \noinherit{options} - \noinherit{presort} - \noinherit{related} - \noinherit{relatedoptions} - \noinherit{relatedstring} - \noinherit{relatedtype} - \noinherit{shorthand} - \noinherit{shorthandintro} - \noinherit{sortkey} -} - -% ------------------------------------------------------------------ -% MACROS FOR LBX FILES -% ------------------------------------------------------------------ - -\newcommand*{\lbx@initnamehook}[1]{} -\newcommand*{\lbx@inittitlehook}[1]{} -\newcommand*{\lbx@finalnamedelim}[1]{\finalnamedelim} -\newcommand*{\lbx@finallistdelim}[1]{\finallistdelim} - -\newcommand*{\lbx@lfromlang}{% - \iffieldundef{origlanguage} - {\unspace} - {\biblstring{from\thefield{origlanguage}}}} - -\newcommand*{\lbx@sfromlang}{% - \iffieldundef{origlanguage} - {\unspace} - {\bibsstring{from\thefield{origlanguage}}}} - -% ------------------------------------------------------------------ -% MISCELLANEOUS -% ------------------------------------------------------------------ - -% ordinals - -\newcommand*{\mkbibordedition}{\mkbibordinal} -\newcommand*{\mkbibordseries}{\mkbibordinal} - -% american - -\newrobustcmd*{\uspunctuation}{% - \DeclareQuotePunctuation{.,}% - \DeclarePunctuationPairs{comma}{*}} -\newrobustcmd*{\stdpunctuation}{% - \DeclareQuotePunctuation{}% - \DeclarePunctuationPairs{comma}{*!?}} - -% catalan and french - -\newtoggle{smartof} -\newrobustcmd*{\smartof}{\global\toggletrue{smartof}} -\newrobustcmd*{\forceD}[1]{#1} -\newrobustcmd*{\forceDE}[1]{#1} - -\AtBeginDocument{% - \@ifpackageloaded{babel} - {\ifdef\AutoSpaceBeforeFDP - {\newrobustcmd*{\EnsureAutoSpaceBeforeFDP}{% - \iflanguage{french} - {\AutoSpaceBeforeFDP} - {}}% - \appto\bibsetup{\EnsureAutoSpaceBeforeFDP}% - \appto\citesetup{\EnsureAutoSpaceBeforeFDP}} - {}} - {}} - -% spanish - -\newcounter{smartand} -\defcounter{smartand}{1} -\newrobustcmd*{\forceY}[1]{#1} -\newrobustcmd*{\forceE}[1]{#1} - -% ------------------------------------------------------------------ -% PREDEFINED HEADINGS -% ------------------------------------------------------------------ - -\newcommand*{\abx@classtype}{0} -\@ifclassloaded{article} - {} - {\@ifclassloaded{book} - {\def\abx@classtype{1}} - {\@ifclassloaded{report} - {\def\abx@classtype{1}} - {\@ifclassloaded{scrartcl} - {\def\abx@classtype{2}} - {\@ifclassloaded{scrbook} - {\def\abx@classtype{3}} - {\@ifclassloaded{scrreprt} - {\def\abx@classtype{3}} - {\@ifclassloaded{memoir} - {\ifbool{artopt} - {\def\abx@classtype{4}} - {\def\abx@classtype{5}}} - {\ifundef\chapter - {} - {\def\abx@classtype{1}}}}}}}}} - -\defbibheading{none}{} - -\ifcase\abx@classtype\relax % article - \defbibheading{bibliography}[\refname]{% - \section*{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{biblist}[\biblistname]{% - \section*{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{bibintoc}[\refname]{% - \section*{#1}% - \addcontentsline{toc}{section}{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{biblistintoc}[\biblistname]{% - \section*{#1}% - \addcontentsline{toc}{section}{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{bibnumbered}[\refname]{% - \section{#1}% - \if@twoside\markright{\MakeUppercase{#1}}\fi} - \defbibheading{biblistnumbered}[\biblistname]{% - \section{#1}% - \if@twoside\markright{\MakeUppercase{#1}}\fi} - \defbibheading{subbibliography}[\refname]{% - \subsection*{#1}} - \defbibheading{subbibintoc}[\refname]{% - \subsection*{#1}% - \addcontentsline{toc}{subsection}{#1}} - \defbibheading{subbibnumbered}[\refname]{% - \subsection{#1}} - -\or % book/report - \defbibheading{bibliography}[\bibname]{% - \chapter*{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{biblist}[\biblistname]{% - \chapter*{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{bibintoc}[\bibname]{% - \chapter*{#1}% - \addcontentsline{toc}{chapter}{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{biblistintoc}[\biblistname]{% - \chapter*{#1}% - \addcontentsline{toc}{chapter}{#1}% - \markboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}} - \defbibheading{bibnumbered}[\bibname]{% - \chapter{#1}% - \if@twoside\markright{\MakeUppercase{#1}}\fi} - \defbibheading{biblistnumbered}[\biblistname]{% - \chapter{#1}% - \if@twoside\markright{\MakeUppercase{#1}}\fi} - \defbibheading{subbibliography}[\refname]{% - \section*{#1}% - \if@twoside\markright{\MakeUppercase{#1}}\fi} - \defbibheading{subbibintoc}[\refname]{% - \section*{#1}% - \addcontentsline{toc}{section}{#1}% - \if@twoside\markright{\MakeUppercase{#1}}\fi} - \defbibheading{subbibnumbered}[\refname]{% - \section{#1}} - -\or % scrartcl - \defbibheading{bibliography}[\refname]{% - \ifkomabibtotocnumbered - {\section{#1}} - {\ifkomabibtotoc - {\addsec{#1}} - {\section*{#1}}% - \markboth{#1}{#1}}} - \defbibheading{biblist}[\biblistname]{% - \ifkomabibtotocnumbered - {\section{#1}} - {\ifkomabibtotoc - {\addsec{#1}} - {\section*{#1}}% - \markboth{#1}{#1}}} - \defbibheading{bibintoc}[\refname]{% - \addsec{#1}% - \markboth{#1}{#1}} - \defbibheading{biblistintoc}[\biblistname]{% - \addsec{#1}% - \markboth{#1}{#1}} - \defbibheading{bibnumbered}[\refname]{% - \section{#1}% - \markboth{\sectionmarkformat#1}{\sectionmarkformat#1}} - \defbibheading{biblistnumbered}[\biblistname]{% - \section{#1}% - \markboth{\sectionmarkformat#1}{\sectionmarkformat#1}} - \defbibheading{subbibliography}[\refname]{% - \subsection*{#1}} - \defbibheading{subbibintoc}[\refname]{% - \subsection*{#1}% - \addcontentsline{toc}{subsection}{#1}} - \defbibheading{subbibnumbered}[\refname]{% - \subsection{#1}} - -\or % scrbook/scrreprt - \defbibheading{bibliography}[\bibname]{% - \ifkomabibtotocnumbered - {\chapter{#1}} - {\ifkomabibtotoc - {\addchap{#1}} - {\chapter*{#1}}% - \markboth{#1}{#1}}} - \defbibheading{biblist}[\biblistname]{% - \ifkomabibtotocnumbered - {\chapter{#1}} - {\ifkomabibtotoc - {\addchap{#1}} - {\chapter*{#1}}% - \markboth{#1}{#1}}} - \defbibheading{bibintoc}[\bibname]{% - \addchap{#1}% - \markboth{#1}{#1}} - \defbibheading{biblistintoc}[\biblistname]{% - \addchap{#1}% - \markboth{#1}{#1}} - \defbibheading{bibnumbered}[\bibname]{% - \chapter{#1}% - \markboth{\chaptermarkformat#1}{\chaptermarkformat#1}} - \defbibheading{biblistnumbered}[\biblistname]{% - \chapter{#1}% - \markboth{\chaptermarkformat#1}{\chaptermarkformat#1}} - \defbibheading{subbibliography}[\refname]{% - \section*{#1}% - \if@twoside\markright{#1}\fi} - \defbibheading{subbibintoc}[\refname]{% - \addsec{#1}% - \markboth{#1}{#1}} - \defbibheading{subbibnumbered}[\refname]{% - \section{#1}} - -\or % memoir (article) - \ifdef\memUChead{}{\let\memUChead\MakeUppercase} - \defbibheading{bibliography}[\refname]{% - \chapter*{#1}% - \ifmemoirbibintoc - {\phantomsection - \addcontentsline{toc}{chapter}{#1}} - {}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{biblist}[\biblistname]{% - \chapter*{#1}% - \ifmemoirbibintoc - {\phantomsection - \addcontentsline{toc}{chapter}{#1}} - {}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{bibintoc}[\refname]{% - \chapter*{#1}% - \phantomsection - \addcontentsline{toc}{chapter}{#1}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{biblistintoc}[\biblistname]{% - \chapter*{#1}% - \phantomsection - \addcontentsline{toc}{chapter}{#1}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{bibnumbered}[\refname]{% - \chapter{#1}} - \defbibheading{biblistnumbered}[\biblistname]{% - \chapter{#1}} - \defbibheading{subbibliography}[\refname]{% - \section*{#1}% - \ifmemoirbibintoc - {\phantomsection - \addcontentsline{toc}{section}{#1}} - {}% - \if@twoside\markright{\memUChead{#1}}\fi} - \defbibheading{subbibintoc}[\refname]{% - \section*{#1}% - \phantomsection - \addcontentsline{toc}{section}{#1}% - \if@twoside\markright{\memUChead{#1}}\fi} - \defbibheading{subbibnumbered}[\refname]{% - \section{#1}} - -\or % memoir (book) - \ifdef\memUChead{}{\let\memUChead\MakeUppercase} - \defbibheading{bibliography}[\bibname]{% - \chapter*{#1}% - \ifmemoirbibintoc - {\phantomsection - \addcontentsline{toc}{chapter}{#1}} - {}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{biblist}[\biblistname]{% - \chapter*{#1}% - \ifmemoirbibintoc - {\phantomsection - \addcontentsline{toc}{chapter}{#1}} - {}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{bibintoc}[\bibname]{% - \chapter*{#1}% - \phantomsection - \addcontentsline{toc}{chapter}{#1}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{biblistintoc}[\biblistname]{% - \chapter*{#1}% - \phantomsection - \addcontentsline{toc}{chapter}{#1}% - \markboth{\memUChead{#1}}{\memUChead{#1}}} - \defbibheading{bibnumbered}[\bibname]{% - \chapter{#1}% - \if@twoside\markright{\memUChead{#1}}\fi} - \defbibheading{biblistnumbered}[\biblistname]{% - \chapter{#1}% - \if@twoside\markright{\memUChead{#1}}\fi} - \defbibheading{subbibliography}[\refname]{% - \section*{#1}% - \ifmemoirbibintoc - {\phantomsection - \addcontentsline{toc}{section}{#1}} - {}% - \if@twoside\markright{\memUChead{#1}}\fi} - \defbibheading{subbibintoc}[\refname]{% - \section*{#1}% - \phantomsection - \addcontentsline{toc}{section}{#1}% - \if@twoside\markright{\memUChead{#1}}\fi} - \defbibheading{subbibnumbered}[\refname]{% - \section{#1}} - -\fi - -% ------------------------------------------------------------------ -% GENERIC CITATION COMMANDS -% ------------------------------------------------------------------ - -\DeclareCiteCommand{\fullcite} - {\usebibmacro{prenote}} - {\usedriver - {\DeclareNameAlias{sortname}{default}} - {\thefield{entrytype}}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand{\footfullcite}[\mkbibfootnote] - {\usebibmacro{prenote}} - {\usedriver - {\DeclareNameAlias{sortname}{default}} - {\thefield{entrytype}}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand{\citeauthor} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\ifciteindex - {\indexnames{labelname}} - {}% - \printnames{labelname}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand*{\citeauthor} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\ifciteindex - {\indexnames{labelname}} - {}% - \printnames[][1-1]{labelname}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand{\citetitle} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\ifciteindex - {\indexfield{indextitle}} - {}% - \printfield[citetitle]{labeltitle}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand*{\citetitle} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\ifciteindex - {\indexfield{indextitle}} - {}% - \printfield[citetitle]{title}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand{\citeyear} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\printfield{year}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand*{\citeyear} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\printfield{year}\printfield{extrayear}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand{\citedate} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\printdate} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand*{\citedate} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\printdateextra} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand{\citeurl} - {\boolfalse{citetracker}% - \boolfalse{pagetracker}% - \usebibmacro{prenote}} - {\printfield[citeurl]{url}} - {\multicitedelim} - {\usebibmacro{postnote}} - -\DeclareCiteCommand{\notecite} - {\printfield{prenote}% - \setunit*{\prenotedelim}} - {\nocite{\thefield{entrykey}}} - {} - {\printfield{postnote}} - -\DeclareCiteCommand{\pnotecite}[\mkbibparens] - {\printfield{prenote}% - \setunit*{\prenotedelim}} - {\nocite{\thefield{entrykey}}} - {} - {\printfield{postnote}} - -\DeclareCiteCommand{\fnotecite}[\mkbibfootnote] - {\printfield{prenote}% - \setunit*{\prenotedelim}} - {\nocite{\thefield{entrykey}}} - {} - {\printfield{postnote}} - -\newrobustcmd*{\volcite}{\volcitecmd\cite} -\newrobustcmd*{\pvolcite}{\volcitecmd\parencite} -\newrobustcmd*{\fvolcite}{\volcitecmd\footcite} -\newrobustcmd*{\ftvolcite}{\volcitecmd\footcitetext} -\newrobustcmd*{\svolcite}{\volcitecmd\smartcite} -\newrobustcmd*{\tvolcite}{\volcitecmd\textcite} -\newrobustcmd*{\avolcite}{\volcitecmd\autocite} - -\newrobustcmd*{\volcites}{\multivolcitecmd\cites} -\newrobustcmd*{\pvolcites}{\multivolcitecmd\parencites} -\newrobustcmd*{\fvolcites}{\multivolcitecmd\footcites} -\newrobustcmd*{\ftvolcites}{\multivolcitecmd\footcitetexts} -\newrobustcmd*{\svolcites}{\multivolcitecmd\smartcites} -\newrobustcmd*{\tvolcites}{\multivolcitecmd\textcites} -\newrobustcmd*{\avolcites}{\multivolcitecmd\autocites} - -\newrobustcmd*{\Cite}{\bibsentence\cite} -\newrobustcmd*{\Parencite}{\bibsentence\parencite} -\newrobustcmd*{\Footcite}{\footcite} -\newrobustcmd*{\Footcitetext}{\footcitetext} -\newrobustcmd*{\Smartcite}{\bibsentence\smartcite} -\newrobustcmd*{\Textcite}{\bibsentence\textcite} -\newrobustcmd*{\Citeauthor}{% - \@ifstar{\bibsentence\citeauthor*}{\bibsentence\citeauthor}} -\newrobustcmd*{\Citetitle}{\bibsentence\citetitle} - -\newrobustcmd*{\Volcite}{\volcitecmd\Cite} -\newrobustcmd*{\Pvolcite}{\volcitecmd\Parencite} -\newrobustcmd*{\Fvolcite}{\volcitecmd\Footcite} -\newrobustcmd*{\Ftvolcite}{\volcitecmd\Footcitetext} -\newrobustcmd*{\Svolcite}{\volcitecmd\Smartcite} -\newrobustcmd*{\Tvolcite}{\volcitecmd\Textcite} -\newrobustcmd*{\Avolcite}{\volcitecmd\Autocite} - -\newrobustcmd*{\Volcites}{\multivolcitecmd\Cites} -\newrobustcmd*{\Pvolcites}{\multivolcitecmd\Parencites} -\newrobustcmd*{\Fvolcites}{\multivolcitecmd\Footcites} -\newrobustcmd*{\Ftvolcites}{\multivolcitecmd\Footcitetext} -\newrobustcmd*{\Svolcites}{\multivolcitecmd\Smartcites} -\newrobustcmd*{\Tvolcites}{\multivolcitecmd\Textcites} -\newrobustcmd*{\Avolcites}{\multivolcitecmd\Autocites} - -\newrobustcmd*{\Notecite}{\bibsentence\notecite} -\newrobustcmd*{\Pnotecite}{\bibsentence\pnotecite} -\newrobustcmd*{\Fnotecite}{\fnotecite} - -\DeclareMultiCiteCommand{\cites}{\cite}{\multicitedelim} -\DeclareMultiCiteCommand{\parencites}[\mkbibparens]{\parencite}{\multicitedelim} -\DeclareMultiCiteCommand{\footcites}[\mkbibfootnote]{\footcite}{\multicitedelim} -\DeclareMultiCiteCommand{\footcitetexts}[\mkbibfootnotetext] - {\footcitetext}{\multicitedelim} -\DeclareMultiCiteCommand{\smartcites}[\iffootnote\mkbibparens\mkbibfootnote] - {\smartcite}{\multicitedelim} -\DeclareMultiCiteCommand{\supercites}[\mkbibsuperscript] - {\supercite}{\supercitedelim} -\DeclareMultiCiteCommand{\textcites}{\textcite}{\multicitedelim} - -\newrobustcmd*{\Cites}{\bibsentence\cites} -\newrobustcmd*{\Parencites}{\bibsentence\parencites} -\newrobustcmd*{\Footcites}{\footcites} -\newrobustcmd*{\Footcitetexts}{\footcitetexts} -\newrobustcmd*{\Smartcites}{\bibsentence\smartcites} -\newrobustcmd*{\Textcites}{\bibsentence\textcites} - -\DeclareAutoCiteCommand{plain}{\cite}{\cites} -\DeclareAutoCiteCommand{inline}{\parencite}{\parencites} -%\DeclareAutoCiteCommand{footnote}[l]{\footcite}{\footcites} -\DeclareAutoCiteCommand{footnote}[f]{\smartcite}{\smartcites} -\DeclareAutoCiteCommand{superscript}[l]{\supercite}{\supercites} - -\newrobustcmd*{\Autocite}{\bibsentence\autocite} -\newrobustcmd*{\Autocites}{\bibsentence\autocites} - -% ------------------------------------------------------------------ -% GENERIC CITATION MACROS -% ------------------------------------------------------------------ - -\newbibmacro*{citeindex}{% - \ifciteindex - {\indexnames{labelname}% - \indexfield{indextitle}} - {}} - -\newbibmacro*{shorthandintro}{% - \iffieldundef{shorthandintro} - {\iffieldundef{shorthand} - {} - {\setunit{\addspace}% - \printtext[parens]{% - \bibstring{citedas}\space - \printfield{shorthand}}}} - {\setunit{\addspace}% - \printtext[parens]{\printfield{shorthandintro}}}} - -% citation commands - -\newbibmacro*{prenote}{% - \iffieldundef{prenote} - {} - {\printfield{prenote}% - \setunit{\prenotedelim}}} - -\newbibmacro*{postnote}{% - \iffieldundef{postnote} - {} - {\setunit{\postnotedelim}% - \printfield{postnote}}} - -% multicite commands - -\newbibmacro*{multiprenote}{% - \iffieldundef{multiprenote} - {} - {\printfield{multiprenote}% - \prenotedelim}} - -\newbibmacro*{multipostnote}{% - \iffieldundef{multipostnote} - {} - {\postnotedelim - \printfield{multipostnote}}} - -% ------------------------------------------------------------------ -% GENERIC BIBLIOGRAPHY MACROS -% ------------------------------------------------------------------ - -\newbibmacro*{bibindex}{% - \ifbibindex - {\indexnames{labelname}% - \indexfield{indextitle}} - {}} - -\newbibmacro*{author/editor}{% - \ifboolexpr{ - test \ifuseauthor - and - not test {\ifnameundef{author}} - } - {\usebibmacro{author}} - {\usebibmacro{editor}}} - -\newbibmacro*{author/editor+others}{% - \ifboolexpr{ - test \ifuseauthor - and - not test {\ifnameundef{author}} - } - {\usebibmacro{author}} - {\usebibmacro{editor+others}}} - -\newbibmacro*{author/translator}{% - \ifboolexpr{ - test \ifuseauthor - and - not test {\ifnameundef{author}} - } - {\usebibmacro{author}} - {\usebibmacro{translator}}} - -\newbibmacro*{author/translator+others}{% - \ifboolexpr{ - test \ifuseauthor - and - not test {\ifnameundef{author}} - } - {\usebibmacro{author}} - {\usebibmacro{translator+others}}} - -\newbibmacro*{author/editor/translator}{% - \ifboolexpr{ - test \ifuseauthor - and - not test {\ifnameundef{author}} - } - {\usebibmacro{author}} - {\ifboolexpr{ - test \ifuseeditor - and - not test {\ifnameundef{editor}} - } - {\usebibmacro{editor}} - {\usebibmacro{translator}}}} - -\newbibmacro*{author/editor+others/translator+others}{% - \ifboolexpr{ - test \ifuseauthor - and - not test {\ifnameundef{author}} - } - {\usebibmacro{author}} - {\ifboolexpr{ - test \ifuseeditor - and - not test {\ifnameundef{editor}} - } - {\usebibmacro{editor+others}} - {\usebibmacro{translator+others}}}} - -\newbibmacro*{author}{% - \ifboolexpr{ - test \ifuseauthor - and - not test {\ifnameundef{author}} - } - {\printnames{author}% - \iffieldundef{authortype} - {} - {\setunit{\addcomma\space}% - \usebibmacro{authorstrg}}} - {}} - -\newbibmacro*{editor}{% - \ifboolexpr{ - test \ifuseeditor - and - not test {\ifnameundef{editor}} - } - {\printnames{editor}% - \setunit{\addcomma\space}% - \usebibmacro{editorstrg}% - \clearname{editor}} - {}} - -\newbibmacro*{editor+others}{% - \ifboolexpr{ - test \ifuseeditor - and - not test {\ifnameundef{editor}} - } - {\printnames{editor}% - \setunit{\addcomma\space}% - \usebibmacro{editor+othersstrg}% - \clearname{editor}} - {}} - -\newbibmacro*{translator}{% - \ifboolexpr{ - test \ifusetranslator - and - not test {\ifnameundef{translator}} - } - {\printnames{translator}% - \setunit{\addcomma\space}% - \usebibmacro{translatorstrg}% - \clearname{translator}} - {}} - -\newbibmacro*{translator+others}{% - \ifboolexpr{ - test \ifusetranslator - and - not test {\ifnameundef{translator}} - } - {\printnames{translator}% - \setunit{\addcomma\space}% - \usebibmacro{translator+othersstrg}% - \clearname{translator}} - {}} - -\newbibmacro*{authorstrg}{% - \iffieldundef{authortype} - {} - {\printtext[authortype]{% - \ifbibxstring{\thefield{authortype}} - {\ifboolexpr{ - test {\ifnumgreater{\value{author}}{1}} - or - test {\ifandothers{author}} - } - {\bibstring{\thefield{authortype}s}} - {\bibstring{\thefield{authortype}}}} - {\thefield{authortype}}}}} - -\newbibmacro*{editorstrg}{% - \printtext[editortype]{% - \iffieldundef{editortype} - {\ifboolexpr{ - test {\ifnumgreater{\value{editor}}{1}} - or - test {\ifandothers{editor}} - } - {\bibstring{editors}} - {\bibstring{editor}}} - {\ifbibxstring{\thefield{editortype}} - {\ifboolexpr{ - test {\ifnumgreater{\value{editor}}{1}} - or - test {\ifandothers{editor}} - } - {\bibstring{\thefield{editortype}s}} - {\bibstring{\thefield{editortype}}}} - {\thefield{editortype}}}}} - -\newbibmacro*{editor+othersstrg}{% - \iffieldundef{editortype} - {\ifboolexpr{ - test {\ifnumgreater{\value{editor}}{1}} - or - test {\ifandothers{editor}} - } - {\def\abx@tempa{editors}} - {\def\abx@tempa{editor}}} - {\ifboolexpr{ - test {\ifnumgreater{\value{editor}}{1}} - or - test {\ifandothers{editor}} - } - {\edef\abx@tempa{\thefield{editortype}s}} - {\edef\abx@tempa{\thefield{editortype}}}}% - \let\abx@tempb=\empty - \ifnamesequal{editor}{translator} - {\appto\abx@tempa{tr}% - \appto\abx@tempb{\clearname{translator}}} - {}% - \ifnamesequal{editor}{commentator} - {\appto\abx@tempa{co}% - \appto\abx@tempb{\clearname{commentator}}} - {\ifnamesequal{editor}{annotator} - {\appto\abx@tempa{an}% - \appto\abx@tempb{\clearname{annotator}}} - {}}% - \ifnamesequal{editor}{introduction} - {\appto\abx@tempa{in}% - \appto\abx@tempb{\clearname{introduction}}} - {\ifnamesequal{editor}{foreword} - {\appto\abx@tempa{fo}% - \appto\abx@tempb{\clearname{foreword}}} - {\ifnamesequal{editor}{afterword} - {\appto\abx@tempa{af}% - \appto\abx@tempb{\clearname{afterword}}} - {}}}% - \ifbibxstring{\abx@tempa} - {\printtext[editortype]{\bibstring{\abx@tempa}}\abx@tempb} - {\usebibmacro{editorstrg}}} - -\newbibmacro*{translatorstrg}{% - \ifboolexpr{ - test {\ifnumgreater{\value{translator}}{1}} - or - test {\ifandothers{translator}} - } - {\bibstring{translators}} - {\bibstring{translator}}} - -\newbibmacro*{translator+othersstrg}{% - \ifboolexpr{ - test {\ifnumgreater{\value{translator}}{1}} - or - test {\ifandothers{translator}} - } - {\def\abx@tempa{translators}} - {\def\abx@tempa{translator}}% - \ifnamesequal{translator}{commentator} - {\appto\abx@tempa{co}% - \clearname{commentator}} - {\ifnamesequal{translator}{annotator} - {\appto\abx@tempa{an}% - \clearname{annotator}} - {}}% - \ifnamesequal{translator}{introduction} - {\appto\abx@tempa{in}% - \clearname{introduction}} - {\ifnamesequal{translator}{foreword} - {\appto\abx@tempa{fo}% - \clearname{foreword}} - {\ifnamesequal{translator}{afterword} - {\appto\abx@tempa{af}% - \clearname{afterword}} - {}}}% - \bibstring{\abx@tempa}} - -\newbibmacro*{byauthor}{% - \ifboolexpr{ - test \ifuseauthor - or - test {\ifnameundef{author}} - } - {} - {\usebibmacro{bytypestrg}{author}{author}% - \setunit{\addspace}% - \printnames[byauthor]{author}}} - -\newbibmacro*{bybookauthor}{% - \ifnamesequal{author}{bookauthor} - {} - {\printnames{bookauthor}}} - -\newbibmacro*{byeditor}{% - \ifnameundef{editor} - {} - {\usebibmacro{bytypestrg}{editor}{editor}% - \setunit{\addspace}% - \printnames[byeditor]{editor}% - \newunit}% - \usebibmacro{byeditorx}} - -\newbibmacro*{byeditorx}{% - \ifnameundef{editora} - {} - {\usebibmacro{bytypestrg}{editora}{editor}% - \setunit{\addspace}% - \printnames[byeditora]{editora}% - \newunit}% - \ifnameundef{editorb} - {} - {\usebibmacro{bytypestrg}{editorb}{editor}% - \setunit{\addspace}% - \printnames[byeditorb]{editorb}% - \newunit}% - \ifnameundef{editorc} - {} - {\usebibmacro{bytypestrg}{editorc}{editor}% - \setunit{\addspace}% - \printnames[byeditorc]{editorc}% - \newunit}} - -\newbibmacro*{bytranslator}{% - \ifnameundef{translator} - {} - {\bibstring{bytranslator}% - \setunit{\addspace}% - \printnames[bytranslator]{translator}}} - -\newbibmacro*{byholder}{% - \printnames{holder}} - -\newbibmacro*{byeditor+others}{% - \ifnameundef{editor} - {} - {\usebibmacro{byeditor+othersstrg}% - \setunit{\addspace}% - \printnames[byeditor]{editor}% - \clearname{editor}% - \newunit}% - \usebibmacro{byeditorx}% - \usebibmacro{bytranslator+others}} - -\newbibmacro*{bytranslator+others}{% - \ifnameundef{translator} - {} - {\usebibmacro{bytranslator+othersstrg}% - \setunit{\addspace}% - \printnames[bytranslator]{translator}% - \clearname{translator}% - \newunit}% - \usebibmacro{withothers}} - -\newbibmacro*{bytypestrg}[2]{% - \iffieldundef{#1type} - {\bibstring{by#2}} - {\ifbibxstring{by\thefield{#1type}} - {\bibstring{by\thefield{#1type}}} - {\printtext{\thefield{#1type}}}}} - -\newbibmacro*{byeditor+othersstrg}{% - \iffieldundef{editortype} - {\def\abx@tempa{byeditor}} - {\edef\abx@tempa{by\thefield{editortype}}}% - \let\abx@tempb=\empty - \ifnamesequal{editor}{translator} - {\appto\abx@tempa{tr}% - \appto\abx@tempb{\clearname{translator}}} - {}% - \ifnamesequal{editor}{commentator} - {\appto\abx@tempa{co}% - \appto\abx@tempb{\clearname{commentator}}} - {\ifnamesequal{editor}{annotator} - {\appto\abx@tempa{an}% - \appto\abx@tempb{\clearname{annotator}}} - {}}% - \ifnamesequal{editor}{introduction} - {\appto\abx@tempa{in}% - \appto\abx@tempb{\clearname{introduction}}} - {\ifnamesequal{editor}{foreword} - {\appto\abx@tempa{fo}% - \appto\abx@tempb{\clearname{foreword}}} - {\ifnamesequal{editor}{afterword} - {\appto\abx@tempa{af}% - \appto\abx@tempb{\clearname{afterword}}} - {}}}% - \ifbibxstring{\abx@tempa} - {\printtext{\bibstring{\abx@tempa}}\abx@tempb} - {\usebibmacro{bytypestrg}{editor}{editor}}} - -\newbibmacro*{bytranslator+othersstrg}{% - \def\abx@tempa{bytranslator}% - \ifnamesequal{translator}{commentator} - {\appto\abx@tempa{co}% - \clearname{commentator}} - {\ifnamesequal{translator}{annotator} - {\appto\abx@tempa{an}% - \clearname{annotator}} - {}}% - \ifnamesequal{translator}{introduction} - {\appto\abx@tempa{in}% - \clearname{introduction}} - {\ifnamesequal{translator}{foreword} - {\appto\abx@tempa{fo}% - \clearname{foreword}} - {\ifnamesequal{translator}{afterword} - {\appto\abx@tempa{af}% - \clearname{afterword}} - {}}}% - \bibstring{\abx@tempa}} - -\newbibmacro*{withcommentator}{% - \ifnameundef{commentator} - {} - {\bibstring{withcommentator}% - \setunit{\addspace}% - \printnames[withcommentator]{commentator}}} - -\newbibmacro*{withannotator}{% - \ifnameundef{annotator} - {} - {\bibstring{withannotator}% - \setunit{\addspace}% - \printnames[withannotator]{annotator}}} - -\newbibmacro*{withintroduction}{% - \ifnameundef{introduction} - {} - {\bibstring{withintroduction}% - \setunit{\addspace}% - \printnames[withintroduction]{introduction}}} - -\newbibmacro*{withforeword}{% - \ifnameundef{foreword} - {} - {\bibstring{withforeword}% - \setunit{\addspace}% - \printnames[withforeword]{foreword}}} - -\newbibmacro*{withafterword}{% - \ifnameundef{afterword} - {} - {\bibstring{withafterword}% - \setunit{\addspace}% - \printnames[withafterword]{afterword}}} - -\newbibmacro*{withothers}{% - \usebibmacro{withcommentator}% - \clearname{commentator}% - \newunit - \usebibmacro{withannotator}% - \clearname{annotator}% - \newunit - \usebibmacro{withintroduction}% - \clearname{introduction}% - \newunit - \usebibmacro{withforeword}% - \clearname{foreword}% - \newunit - \usebibmacro{withafterword}% - \clearname{afterword}} - -\newbibmacro*{title}{% - \ifboolexpr{ - test {\iffieldundef{title}} - and - test {\iffieldundef{subtitle}} - } - {} - {\printtext[title]{% - \printfield[titlecase]{title}% - \setunit{\subtitlepunct}% - \printfield[titlecase]{subtitle}}% - \newunit}% - \printfield{titleaddon}} - -\newbibmacro*{booktitle}{% - \ifboolexpr{ - test {\iffieldundef{booktitle}} - and - test {\iffieldundef{booksubtitle}} - } - {} - {\printtext[booktitle]{% - \printfield[titlecase]{booktitle}% - \setunit{\subtitlepunct}% - \printfield[titlecase]{booksubtitle}}% - \newunit}% - \printfield{booktitleaddon}} - -\newbibmacro*{maintitle}{% - \ifboolexpr{ - test {\iffieldundef{maintitle}} - and - test {\iffieldundef{mainsubtitle}} - } - {} - {\printtext[maintitle]{% - \printfield[titlecase]{maintitle}% - \setunit{\subtitlepunct}% - \printfield[titlecase]{mainsubtitle}}% - \newunit}% - \printfield{maintitleaddon}} - -\newbibmacro*{journal}{% - \iffieldundef{journaltitle} - {} - {\printtext[journaltitle]{% - \printfield[titlecase]{journaltitle}% - \setunit{\subtitlepunct}% - \printfield[titlecase]{journalsubtitle}}}} - -\newbibmacro*{periodical}{% - \iffieldundef{title} - {} - {\printtext[title]{% - \printfield[titlecase]{title}% - \setunit{\subtitlepunct}% - \printfield[titlecase]{subtitle}}}} - -\newbibmacro*{issue}{% - \iffieldundef{issuetitle} - {} - {\printtext[issuetitle]{% - \printfield[titlecase]{issuetitle}% - \setunit{\subtitlepunct}% - \printfield[titlecase]{issuesubtitle}}}} - -\newbibmacro*{in:}{% - \printtext{% - \bibstring{in}\intitlepunct}} - -\newbibmacro*{date}{\printdate} - -\newbibmacro*{url+urldate}{% - \usebibmacro{url}% - \iffieldundef{urlyear} - {} - {\setunit*{\addspace}% - \usebibmacro{urldate}}} - -\newbibmacro*{url}{\printfield{url}} -\newbibmacro*{urldate}{\printurldate} - -\newbibmacro*{pageref}{% - \iflistundef{pageref} - {} - {\printtext[parens]{% - \ifnumgreater{\value{pageref}}{1} - {\bibstring{backrefpages}\ppspace} - {\bibstring{backrefpage}\ppspace}% - \printlist[pageref][-\value{listtotal}]{pageref}}}} - -\newbibmacro*{setpageref}{% - \iflistundef{pageref} - {} - {\printtext{% - \ifnumgreater{\value{pageref}}{1} - {\bibstring{backrefpages}\ppspace} - {\bibstring{backrefpage}\ppspace}% - \printlist[pageref][-\value{listtotal}]{pageref}}}} - -\newbibmacro*{eprint}{% - \iffieldundef{eprinttype} - {\printfield{eprint}} - {\printfield[eprint:\strfield{eprinttype}]{eprint}}} - -\newbibmacro*{annotation}{% - \iffieldundef{annotation} - {\printfile[annotation]{\bibannotationprefix\thefield{entrykey}.tex}} - {\printfield{annotation}}} - -\newbibmacro*{abstract}{% - \iffieldundef{abstract} - {\printfile[abstract]{\bibabstractprefix\thefield{entrykey}.tex}} - {\printfield{abstract}}} - -\newbibmacro*{related:default}[1]{% - \entrydata*{#1}{% - \usedriver - {\ifnameundef{savedauthor} - {\ifnameundef{savededitor} - {} - {\ifnamesequal{editor}{savededitor} - {\clearname{editor}} - {}}} - {\ifnamesequal{author}{savedauthor} - {\clearname{author}} - {}}% - \renewbibmacro*{related:init}{}% - \DeclareNameAlias{sortname}{default}% - \ifbibmacroundef{date+extrayear} - {} - {\renewbibmacro*{date+extrayear}{}% - \renewbibmacro*{date}{\printdate}}% - \renewbibmacro*{pageref}{}} - {\thefield{entrytype}}}} - -\newbibmacro*{related:bytranslator}[1]{% - \entrydata{#1}{% - \renewbibmacro*{name:hook}[1]{% - \ifnumequal{\value{listcount}}{1} - {\begingroup - \mkrelatedstring% - \lbx@initnamehook{#1}% - \endgroup} - {}}% - \printnames[bytranslator]{translator}% - \setunit*{\addspace\bibstring[\mkrelatedstring]{astitle}\space}% - \usebibmacro{title}% - \setunit{\addspace}% - \printtext[parens]{% - \printlist{location}% - \iflistundef{publisher} - {\setunit*{\addcomma\space}} - {\setunit*{\addcolon\space}}% - \printlist{publisher}% - \setunit*{\addcomma\space}% - \printdate}}} - -\newbibmacro*{related:multivolume}[1]{% - \entrydata*{#1}{% - \printtext{% - \printfield{volume}% - \printfield{part}}% - \setunit*{\addcolon\space}% - \usebibmacro{title}% - \ifboolexpr{ - test {\ifnamesequal{author}{savedauthor}} - or - test {\ifnameundef{author}} - } - {} - {\usebibmacro{bytypestrg}{author}{author}% - \setunit{\addspace}% - \printnames[byauthor]{author} - \newunit\newblock}% - \ifboolexpr{ - test {\ifnamesequal{editor}{savededitor}} - or - test {\ifnameundef{editor}} - } - {} - {\usebibmacro{byeditor+others}% - \newunit\newblock}% - \printdate}} - -\newbibmacro*{related:origpubin}[1]{% - \entrydata*{#1}{% - \printfield{year}% - \ifboolexpr{ - test {\iflistsequal{publisher}{savedpublisher}} - or - test {\iflistundef{publisher}} - } - {} - {\setunit{\addspace\bibstring[\mkrelatedstring]{bypublisher}\space}% - \printlist{publisher}% - \setunit{\addcomma\space}% - \iflistsequal{location}{savedlocation} - {} - {\printlist{location}}}}} - -\newbibmacro*{related:origpubas}[1]{% - \entrydata*{#1}{% - \usebibmacro{title}% - \ifboolexpr{ - test {\iflistsequal{publisher}{savedpublisher}} - or - test {\iflistundef{publisher}} - } - {} - {\setunit{\addspace\bibstring[\mkrelatedstring]{bypublisher}\space}% - \printlist{publisher}% - \setunit{\addcomma\space}% - \iflistsequal{location}{savedlocation} - {} - {\printlist{location}}}}} - -\DeclareFieldFormat{title:hook}{% - \begingroup - \mkrelatedstring% - \lbx@inittitlehook{#1}% - \endgroup - \mkbibemph{#1}} - -\newbibmacro*{related:reprintfrom}[1]{% - \entrydata*{#1}{% - \iffieldundef{journaltitle} - {\iffieldundef{maintitle} - {\printfield[title:hook]{booktitle}} - {\printfield[title:hook]{maintitle}}% - \newunit\newblock - \usebibmacro{byeditor+others}% - \newunit\newblock - \printfield{edition}% - \newunit - \iffieldundef{volume} - {} - {\printfield{volume}% - \printfield{part}} - \newunit\newblock - \usebibmacro{series+number}% - \newunit\newblock - \printfield{note}% - \newunit\newblock - \usebibmacro{publisher+location+date}% - \newunit\newblock - \usebibmacro{chapter+pages}} - {\printfield[title:hook]{journaltitle}% - \newunit\newblock - \usebibmacro{byeditor+others}% - \newunit\newblock - \usebibmacro{note+pages}}}} - -\endinput diff --git a/Master/texmf-dist/tex/latex/biblatex/biblatex.sty b/Master/texmf-dist/tex/latex/biblatex/biblatex.sty index 2effcae5d26..3271b7b39a5 100644 --- a/Master/texmf-dist/tex/latex/biblatex/biblatex.sty +++ b/Master/texmf-dist/tex/latex/biblatex/biblatex.sty @@ -3,8 +3,8 @@ %% % Set up the version strings here, so they are the same for both branches -\def\abx@date{2015/12/22} -\def\abx@version{3.2} +\def\abx@date{2016/03/03} +\def\abx@version{3.3} \def\abx@bbxid{\abx@date\space v\abx@version\space biblatex bibliography style (PK/JW/AB)} \def\abx@cbxid{\abx@date\space v\abx@version\space biblatex citation style (PK/JW/AB)} \def\abx@lbxid{\abx@date\space v\abx@version\space biblatex localization (PK/JW/AB)} @@ -12,18 +12,18 @@ % This is not updated by build script as the controlfile version % does not necessarily change with the package version. % This is used when writing the .bcf -\def\blx@bcfversion{2.9} +\def\blx@bcfversion{3.0} % This is not updated by build script as the bbl version % does not necessarily change with the package version. % This is used when checking the .bbl -\def\blx@bblversion{2.5} +\def\blx@bblversion{2.6} \NeedsTeXFormat{LaTeX2e}[2005/12/01] \ProvidesPackage{biblatex} [\abx@date\space v\abx@version\space programmable bibliographies (PK/JW/AB)] % Set up a switch for choosing the version -\newif\ifblx@load@version@one +\newif\ifblx@load@version@legacy % A switch so we can issue a message about the backend \newif\ifblx@load@backend@seen @@ -31,31 +31,31 @@ % Fake keyval options to detect the backend % All basically the same, so passing the backend is done simply \DeclareOption{backend=bibtex}{% - \PassOptionsToPackage{\CurrentOption}{biblatex1}% - \blx@load@version@onetrue + \PassOptionsToPackage{\CurrentOption}{biblatex_legacy}% + \blx@load@version@legacytrue \blx@load@backend@seentrue } \DeclareOption{backend=bibtex8}{% - \PassOptionsToPackage{\CurrentOption}{biblatex1}% - \blx@load@version@onetrue + \PassOptionsToPackage{\CurrentOption}{biblatex_legacy}% + \blx@load@version@legacytrue \blx@load@backend@seentrue } \DeclareOption{backend=bibtexu}{% - \PassOptionsToPackage{\CurrentOption}{biblatex1}% - \blx@load@version@onetrue + \PassOptionsToPackage{\CurrentOption}{biblatex_legacy}% + \blx@load@version@legacytrue \blx@load@backend@seentrue } \DeclareOption{backend=biber}{% - \blx@load@version@onefalse + \blx@load@version@legacyfalse \blx@load@backend@seentrue } \DeclareOption*{% - \PassOptionsToPackage{\CurrentOption}{biblatex1}% - \PassOptionsToPackage{\CurrentOption}{biblatex2}% + \PassOptionsToPackage{\CurrentOption}{biblatex_legacy}% + \PassOptionsToPackage{\CurrentOption}{biblatex_}% } % Default to the Biber backend -\blx@load@version@onefalse +\blx@load@version@legacyfalse \ProcessOptions\relax \ifblx@load@backend@seen @@ -70,25 +70,16 @@ % Now do the loading: avoid any awkward stuff with the conditional by % expanding first -\ifblx@load@version@one +\ifblx@load@version@legacy \expandafter\@firstoftwo \else \expandafter\@secondoftwo \fi - {% - % A few things not defined by v1 so has to be handled if using v1 - \protected\long\def\DeclareDriverSourcemap[#1]#2{}% - \protected\long\def\DeclareLabelalphaTemplate#1{}% - \protected\long\def\DeclareLabeltitle#1{}% - \protected\long\def\DeclareLabelname#1{}% - \protected\long\def\DeclareLabeldate#1{}% - \protected\long\def\abx@dointernalfields{}% - \RequirePackage{biblatex1}% - } - {\RequirePackage{biblatex2}} + {\RequirePackage{biblatex_legacy}} + {\RequirePackage{biblatex_}} %% Copyright (C) 2006-2011 Philipp Lehman -%% 2012-2014 Philip Kime, Audrey Boruvka, Joseph Wright +%% 2012-2016 Philip Kime, Audrey Boruvka, Joseph Wright %% %% It may be distributed and/or modified under the conditions of %% the LaTeX Project Public License (LPPL), either version 1.3c of diff --git a/Master/texmf-dist/tex/latex/biblatex/biblatex1.sty b/Master/texmf-dist/tex/latex/biblatex/biblatex1.sty deleted file mode 100644 index 6f25355af52..00000000000 --- a/Master/texmf-dist/tex/latex/biblatex/biblatex1.sty +++ /dev/null @@ -1,10894 +0,0 @@ -% $Id: biblatex.sty,v 1.7 2011/11/13 19:09:07 lehman stable $ - -% Copyright (c) 2006-2011 Philipp Lehman. -% -% Permission is granted to copy, distribute and/or modify this -% software under the terms of the LaTeX Project Public License -% (LPPL), version 1.3. -% -% The LPPL maintenance status of this software is -% 'author-maintained'. -% -% This software is provided 'as is', without warranty of any kind, -% either expressed or implied, including, but not limited to, the -% implied warranties of merchantability and fitness for a -% particular purpose. - -\NeedsTeXFormat{LaTeX2e}[2005/12/01] -\ProvidesPackage{biblatex1} -[\abx@date\space v\abx@version\space programmable bibliographies (bibtex) (PK/JW/AB)] - -%% Dependencies - -\RequirePackage{etoolbox} -\RequirePackage{keyval} -\RequirePackage{logreq} -\RequirePackage{ifthen} -\RequirePackage{url} - -\@ifpackagelater{etoolbox}{2010/11/29} - {} - {\PackageError{biblatex} - {Outdated 'etoolbox' package} - {Upgrade to etoolbox v2.1 (2010/11/29) or later.\MessageBreak - I found: '\csuse{ver@etoolbox.sty}'.\MessageBreak - This is a fatal error. I'm aborting now.}% - \endinput} - -%% Category codes - -\def\blx@docatcodes{% - \do\=\do\<\do\>\do\-\do\"\do\'\do\`\do\.% - \do\,\do\;\do\:\do\!\do\?\do\/} -\def\do#1{\catcode\number`#1=\the\catcode`#1\relax} -\edef\blx@catcodes{\blx@docatcodes\do\^\do\~\do\&\do\|} -\let\do\noexpand - -\def\blx@saneccodes{% - \catcode`\~=\active - \let\do\@makeother - \blx@docatcodes - \let\do\noexpand} - -\blx@saneccodes -\catcode`\&=3 -\catcode`\|=3 -\catcode`\^=7 -\def\blx@nl{^^J} - -%% Compatibility - -\AtEndPreamble{% - \def\do#1{% - \@ifpackageloaded{#1} - {\blx@error - {Incompatible package '#1'} - {The '#1' package and biblatex are incompatible}} - {}}% - \docsvlist{% - amsrefs,apacite,babelbib,backref,bibtopic,bibunits,chapterbib, - cite,citeref,drftcite,footbib,inlinebib,jurabib,mcite,mciteplus, - mlbib,multibbl,multibib,natbib,opcit,overcite,splitbib,ucs}% - \def\blx@langstrings{}% - % Set up sortlocale defaults - \ifdefstring\blx@sortlocale{auto} - {\ifdef\bbl@main@language% babel or polyglossia is loaded - {\edef\blx@sortlocale{\bbl@main@language}} - {\def\blx@sortlocale{english}}} - {}% - \@ifpackageloaded{polyglossia} - {\ifboolexpr{ - not test {\iftoggle{blx@autolangbib}} - and - not test {\iftoggle{blx@autolangcite}}} - {\blx@mknoautolang} - {\blx@mkautolangpoly}} - {\@ifpackageloaded{babel} - {\ifboolexpr{ - not test {\iftoggle{blx@autolangbib}} - and - not test {\iftoggle{blx@autolangcite}}} - {\blx@mknoautolang} - {\blx@mkautolangbabel}} - {\blx@mknoautolang}}% - % These already have defaults set to basically do nothing - % so if the toggles are true, we need to define again since - % mkautolang* redefines \blx@beglang - % In turn, \blx@beglang defines \blx@endlang and so \blx@beglangcite and - % \blx@endlangcite need redefining inside \blx@beglang after \blx@endlang - % has been defined. - \iftoggle{blx@autolangbib} - {\let\blx@beglangbib\blx@beglang} - {}% - \iftoggle{blx@autolangcite} - {\let\blx@beglangcite\blx@beglang} - {}% - \csuse{abx@extras@\blx@languagename}% - \csuse{abx@strings@\blx@languagename}% - \undef\blx@mkautolangbabel - \undef\blx@mkautolangpoly - \undef\blx@mknoautolang - \ifnum\blx@hyperref=\z@ - \blx@mknohyperref - \else - \@ifpackageloaded{hyperref} - {\blx@mkhyperref} - {\ifnum\blx@hyperref=\@ne - \blx@warning@noline{% - Missing 'hyperref' package.\MessageBreak - Setting hyperref=false}% - \fi - \blx@mknohyperref}% - \fi - \providecommand*{\nolinkurl}{\url}% - \undef\blx@mkhyperref - \undef\blx@mknohyperref - \ifundef\TE@hook - {\let\TE@hook\@empty - \toggletrue{blx@tempa}% - \def\do#1{% - \patchcmd#1% - {\let\isundefined\TE@undef} - {\let\isundefined\TE@undef\TE@hook} - {\togglefalse{blx@tempa}\listbreak} - {}}% - \docsvlist{% - \ifthenelse,% ifthen - \org@ifthenelse,% babel - \HyOrg@ifthenelse,% hyperref - \NROrg@ifthenelse}% nameref - \iftoggle{blx@tempa} - {\blx@err@patch{'ifthen' package}} - {}} - {}% - \appto\TE@hook{\blx@TE@hook}% - \toggletrue{blx@tempa}% - \def\do#1{% - \patchcmd#1% - {\color@begingroup} - {\color@begingroup\toggletrue{blx@footnote}} - {\togglefalse{blx@tempa}\listbreak} - {}}% - \docsvlist{% - \@footnotetext,% latex - \H@@footnotetext,% hyperref - \V@@footnotetext,% fancyvrb - \scr@saved@footnotetext,% koma-script 3.x - \l@dold@footnotetext,% ledmac - \l@doldold@footnotetext,% ledmac - \@fntORI}% frenchle - \iftoggle{blx@tempa}% ams classes - {\patchcmd\@footnotetext - {\@makefntext} - {\toggletrue{blx@footnote}\@makefntext} - {\togglefalse{blx@tempa}} - {}} - {}% - \@ifclassloaded{memoir} - {\def\do#1{% - \patchcmd#1% - {\color@begingroup} - {\color@begingroup\toggletrue{blx@footnote}} - {} - {}}% - \docsvlist{% - \m@mold@footnotetext,% - \@plainfootnotetext,% - \@twocolfootnotetext,% - \@threecolfootnotetext,% - \@parafootnotetext}% - \def\do#1{% - \patchcmd#1% - {\color@begingroup\@makefntext} - {\color@begingroup\toggletrue{blx@footnote}\@makefntext} - {} - {}}% - \docsvlist{% - \@footnotetext,% patch twice - \H@@footnotetext,% patch twice - \@plainfootnotetext}} - {}% - \iftoggle{blx@tempa} - {\blx@warning@noline{% - Patching footnotes failed.\MessageBreak - Footnote detection will not work}} - {}% - \@ifpackageloaded{endnotes} - {\patchcmd\theendnotes - {\enoteformat} - {\toggletrue{blx@footnote}\enoteformat} - {} - {\blx@err@patch{'endnotes' package}}} - {}% - \@ifpackageloaded{bigfoot} - {\apptocmd\@makefnstartbox - {\toggletrue{blx@footnote}} - {} - {\blx@err@patch{'bigfoot' package}}} - {}% - \@ifpackageloaded{showkeys} - {\ifdef\SK@ - {\AtEveryBibitem{\SK@\SK@@label{\thefield{entrykey}}}% - \AtEveryLositem{\SK@\SK@@label{\thefield{entrykey}}}% - \ifundef\SK@cite % = 'notcite' disabled - {\AtEveryCitekey{\SK@\SK@@ref{\thefield{entrykey}}}} - {}} - {}} - {}% - \apptocmd\@floatboxreset - {\boolfalse{citetracker}% - \boolfalse{pagetracker}} - {} - {\blx@err@patch{floats}}% - \ifdef\TX@endtabularx % tabularx/memoir - {\pretocmd\TX@endtabularx - {\addtocounter{tabx@nest}{1}}% track nestes tabularx environments - {} - {\blx@err@patch{'tabularx'}}% - % no need to conditionalise on top-level tabx as the search/replace - % will only match once anyway - \patchcmd\TX@endtabularx - {\edef\TX@ckpt{\cl@@ckpt}} - {\edef\TX@ckpt{\cl@@ckpt\abx@resttrackers}% - \abx@savetrackers} - {} - {\blx@err@patch{'tabularx'}}% - \apptocmd\TX@endtabularx - {\ifnum\value{tabx@nest}=1% only clear trackers for top-level tabularx - \abx@cleartrackers - \fi - \addtocounter{tabx@nest}{-1}} - {} - {\blx@err@patch{'tabularx'}}} - {}% - \@ifpackageloaded{csquotes} - {\@ifpackagelater{csquotes}{2009/05/30} - {} - {\blx@error - {Outdated 'csquotes' package} - {Upgrade to csquotes v4.4 (2009/05/30) or later.\MessageBreak - I found: '\csuse{ver@csquotes.sty}'}}% - \BlockquoteDisable{\let\blx@thecheckpunct\@gobble}% - \@ifpackagelater{csquotes}{2009/08/27} - {\appto\@blockquote@prehook{\abx@savetrackers}% - \appto\@blockquote@posthook{\abx@resttrackers\abx@cleartrackers}} - {}% - \@ifpackagelater{csquotes}{2010/06/09} - {} - {\newcommand*{\@quotereset}{}\newcount\@quotereset}} - {\@ifpackageloaded{babel} - {\blx@warning@noline{% - 'babel/polyglossia' detected but 'csquotes' missing.\MessageBreak - Loading 'csquotes' recommended}} - {}% - \newcommand*{\@quotelevel}{}% - \newcount\@quotelevel - \newcommand*{\@quotereset}{}% - \newcount\@quotereset - \newcommand*{\@setquotesfcodes}{}% - \let\@setquotesfcodes\relax - \newrobustcmd*{\initoquote}{\@quotelevel\@ne}% - \newrobustcmd*{\initiquote}{\@quotelevel\tw@}% - \newrobustcmd*{\textooquote}{``}% - \newrobustcmd*{\textcoquote}{''}% - \newrobustcmd*{\textoiquote}{`\relax}% block ligs - \newrobustcmd*{\textciquote}{'\relax}% block ligs - \newrobustcmd*{\enquote}{\@ifstar\blx@enquote@ii\blx@enquote}% - \def\blx@enquote{% - \ifnum\@quotelevel>\z@ - \expandafter\blx@enquote@ii - \else - \expandafter\blx@enquote@i - \fi}% - \long\def\blx@enquote@i#1{% - \begingroup\initoquote - \textooquote#1\textcoquote - \endgroup}% - \long\def\blx@enquote@ii#1{% - \begingroup\initiquote - \textoiquote#1\textciquote - \endgroup}% - \appto\blx@setsfcodes{% - \sfcode`\`=\z@ - \sfcode`\'=\z@}}% - \let\do\noexpand} - -\begingroup -\@makeother\# -% \relax: gobble newline -> titletoc.sty -\AtEndPreamble{% - \addtocontents{toc}{% - \boolfalse{citerequest}% - \boolfalse{citetracker}% - \boolfalse{pagetracker}% - \boolfalse{backtracker}\relax}% - \addtocontents{lof}{% - \boolfalse{citerequest}% - \boolfalse{citetracker}% - \boolfalse{pagetracker}% - \boolfalse{backtracker}\relax}% - \addtocontents{lot}{% - \boolfalse{citerequest}% - \boolfalse{citetracker}% - \boolfalse{pagetracker}% - \boolfalse{backtracker}\relax}% - \patchcmd\addtocontents - {\string\@writefile} - {\string\@writefile{#1}{\defcounter{refsection}{\the\c@refsection}\relax}% - \string\@writefile} - {} - {\blx@err@patch{\string\addtocontents}}} -\endgroup - -% trick hyperref into believing we're natbib -\let\NAT@parse\@empty -% trick showkeys into believing we're havard -\let\HAR@checkdef\@empty - -%% Allocation - -\providecommand{\@gobblefive}[5]{} - -% Counter to track nested tabularx environemnts so we don't -% try to patch the commands more than once below as this undefs some -% macros and an error is thrown -\newcounter{tabx@nest} -\setcounter{tabx@nest}{0} - -\newcounter{listtotal} -\def\thelisttotal{\the\c@listtotal} -\newcounter{listcount} -\def\thelistcount{\the\c@listcount} -\newcounter{liststart} -\def\theliststart{\the\c@liststart} -\newcounter{liststop} -\def\theliststop{\the\c@liststop} -\newcounter{citecount} -\def\thecitecount{\the\c@citecount} -\newcounter{citetotal} -\def\thecitetotal{\the\c@citetotal} -\newcounter{multicitecount} -\def\themulticitecount{\the\c@multicitecount} -\newcounter{multicitetotal} -\def\themulticitetotal{\the\c@multicitetotal} -\newcounter{instcount} -\def\theinstcount{\the\c@instcount} -\newcounter{maxnames} -\def\themaxnames{\the\c@maxnames} -\newcounter{minnames} -\def\theminnames{\the\c@minnames} -\newcounter{maxitems} -\def\themaxitems{\the\c@maxitems} -\newcounter{minitems} -\def\theminitems{\the\c@minitems} -\newcounter{citecounter} -\def\thecitecount{\the\c@citecounter} -\newcounter{savedcitecounter} -\def\thecitecount{\the\c@savedcitecounter} -\newcounter{uniquelist} -\def\theuniquelist{\the\c@uniquelist} -\newcounter{uniquename} -\def\theuniquename{\the\c@uniquename} -\newcounter{refsection} -\def\therefsection{\the\c@refsection} -\newcounter{refsegment} -\def\therefsegment{\the\c@refsegment} -\newcounter{maxextrayear} -\def\themaxextrayear{\the\c@maxextrayear} -\newcounter{maxextraalpha} -\def\themaxextraalpha{\the\c@maxextraalpha} -\newcounter{abbrvpenalty} -\def\theabbrvpenalty{\the\c@abbrvpenalty} -\newcounter{highnamepenalty} -\def\thehighnamepenalty{\the\c@highnamepenalty} -\newcounter{lownamepenalty} -\def\thelownamepenalty{\the\c@lownamepenalty} -\newcounter{maxparens} -\def\themaxparens{\the\c@maxparens} -\newcounter{parenlevel} -\def\theparenlevel{\the\c@parenlevel} - -\newcount\blx@tempcnta -\newcount\blx@tempcntb -\newcount\blx@tempcntc -\newcount\blx@maxsection -\newcount\blx@maxsegment -\newcount\blx@notetype -\newcount\blx@parenlevel@text -\newcount\blx@parenlevel@foot - -\def\blx@backend{0} -\def\blx@uniquename{0} -\def\blx@uniquelist{0} -\def\blx@maxbibnames{0} -\def\blx@minbibnames{0} -\def\blx@maxcitenames{0} -\def\blx@mincitenames{0} -\def\blx@maxbibnames@type{\blx@maxbibnames} -\def\blx@minbibnames@type{\blx@minbibnames} -\def\blx@maxcitenames@type{\blx@maxcitenames} -\def\blx@mincitenames@type{\blx@mincitenames} -\def\blx@maxalphanames{0} -\def\blx@minalphanames{0} -\def\blx@maxitems{0} -\def\blx@minitems{0} -\def\blx@maxitems@type{\blx@maxitems} -\def\blx@minitems@type{\blx@minitems} - -\newlength{\labelnumberwidth} -\newlength{\labelalphawidth} -\newlength{\shorthandwidth} -\newlength{\biblabelsep} -\ifdef\bibitemsep % memoir - {} - {\newlength{\bibitemsep}} -\newlength{\bibnamesep} -\newlength{\bibinitsep} -\newlength{\bibparsep} -\newlength{\bibhang} - -\newbool{citetracker} -\newbool{pagetracker} -\newbool{backtracker} -\newbool{citerequest} -\booltrue{citerequest} - -\newtoggle{blx@tempa} -\newtoggle{blx@tempb} -\newtoggle{blx@runltx} -\newtoggle{blx@runbtx} -\newtoggle{blx@block} -\newtoggle{blx@unit} -\newtoggle{blx@skipentry} -\newtoggle{blx@insert} -\newtoggle{blx@lastins} -\newtoggle{blx@keepunit} -\newtoggle{blx@debug} -\newtoggle{blx@sortcase} -\newtoggle{blx@sortupper} -\newtoggle{blx@autolangbib} -\newtoggle{blx@autolangcite} -\newtoggle{blx@clearlang} -\newtoggle{blx@defernumbers} -\newtoggle{blx@omitnumbers} -\newtoggle{blx@footnote} -\newtoggle{blx@labelalpha} -\newtoggle{blx@labelnumber} -\newtoggle{blx@labeldate} -\newtoggle{blx@natbib} -\newtoggle{blx@mcite} -\newtoggle{blx@loadfiles} -\newtoggle{blx@singletitle} -\newtoggle{blx@terseinits} -\newtoggle{blx@firstinits} -\newtoggle{blx@useauthor} -\newtoggle{blx@useeditor} -\newtoggle{blx@usetranslator} -\newtoggle{blx@useprefix} -\newtoggle{blx@addset} -\newtoggle{blx@setonly} -\newtoggle{blx@dataonly} -\newtoggle{blx@skipbib} -\newtoggle{blx@skipbiblist} -\newtoggle{blx@skiplab} -\newtoggle{blx@citation} -\newtoggle{blx@bibliography} -\newtoggle{blx@reencode} -\newtoggle{blx@citeindex} -\newtoggle{blx@bibindex} - -\newread\blx@auxin -\newwrite\blx@auxout - -\def\blx@onlypreamble#1{% - \gappto\blx@dopreamblecmds{\do#1}} - -\def\blx@dopreamblecmds{% - \do\blx@dopreamblecmds - \do\blx@onlypreamble} - -%% Initialization - -\def\blx@blxinit{% - \let\blx@blxinit\relax - \blx@initunit} - -\edef\blx@auxfile@bibtex{\jobname} -\let\blx@auxout@bibtex\@mainaux -\newcommand*{\labelalphaothers}{+} -\newcommand*{\sortalphaothers}{\labelalphaothers} -\newcommand*{\blxauxsuffix}{-blx} - -\begingroup -\def\blx@tempa#1"#2{% - #1\ifx#2\@empty\else - \expandafter\blx@tempa - \fi#2} -\edef\blx@ctrlfile@bibtex{% - \noexpand\blx@tempa - \expandafter\blx@tempa\jobname"\@empty - \space\noexpand\@empty} -\def\blx@tempa#1 #2{% - #1\ifx#2\@empty\else - \string_\expandafter\blx@tempa - \fi#2} -\xdef\blx@ctrlfile@bibtex{\blx@ctrlfile@bibtex} -\endgroup - -\def\blx@secinit{% - \ifcsundef{blx@sort@\the\c@refsection} - {\global\cslet{blx@sort@\the\c@refsection}\@empty} - {}% - \ifcsundef{blx@sbib@\the\c@refsection} - {\global\cslet{blx@sbib@\the\c@refsection}\@empty} - {}% - \ifcsundef{blx@bsee@\the\c@refsection} - {\global\cslet{blx@bsee@\the\c@refsection}\@empty} - {}% - \ifcsundef{blx@fsee@\the\c@refsection} - {\global\cslet{blx@fsee@\the\c@refsection}\@empty} - {}% - \ifcsundef{blx@losh@\the\c@refsection} - {\global\cslet{blx@losh@\the\c@refsection}\@empty} - {}% - \blx@ibidreset@force - \blx@idemreset@force - \blx@opcitreset@force - \blx@loccitreset@force - \ifcsundef{blx@segm@\the\c@refsection @\the\c@refsegment} - {\global\cslet{blx@segm@\the\c@refsection @\the\c@refsegment}\@empty} - {}} - -%% Auxiliary commands - -\protected\def\blx@safe@actives{% - \let\blx@if@safe@actives\if@safe@actives - \let\if@safe@actives\iftrue} - -\protected\def\blx@rest@actives{% - \let\if@safe@actives\blx@if@safe@actives} - -\protected\def\blx@regimc#1{% - \xappto\blx@blxinit{% - \let\noexpand#1\expandafter\noexpand\csname - blx@imc@\expandafter\@gobble\string#1\endcsname}} - -\protected\def\blx@regimcs#1{\blx@regimcs@i#1&} -\def\blx@regimcs@i#1{% - \ifx#1&\else - \blx@regimc#1% - \expandafter\blx@regimcs@i - \fi} - -% {} => \do{}\do{}... - -\def\blx@imc@docsvfield#1{% - \blx@imc@iffieldundef{#1} - {} - {\expandafter\expandafter\expandafter\docsvlist - \expandafter\expandafter\expandafter{% - \csname abx@field@#1\endcsname}}} - -% {}{} => {}{}... - -\def\blx@imc@forcsvfield#1#2{% - \blx@imc@iffieldundef{#2} - {} - {\expandafter\expandafter\expandafter\blx@imc@forcsvfield@i - \expandafter\expandafter\expandafter{% - \csname abx@field@#2\endcsname}{#1}}} - -\def\blx@imc@forcsvfield@i#1#2{\forcsvlist{#2}{#1}} - -\blx@regimcs{\docsvfield \forcsvfield} - -% {|} - -\protected\long\def\blx@listloop#1{% - \expandafter\blx@listloop@i#1|&} -\long\def\blx@listloop@i#1|{% - \ifblank{#1} - {\blx@break} - {\blx@do{#1}\blx@listloop@i}} - -\long\def\blx@break#1&{% - \blx@done - \undef\blx@do - \undef\blx@done} - -% {}{} => matches in - -\protected\def\blx@filter#1#2{% - \def\do##1{% - \ifinlistcs{##1}{#2} - {\listadd#1{##1}} - {}}% - \blx@runfilter#1} - -% {}{} => matches in -% Slightly odd use of filtering to do citation sorting. -% Same as blx@filter but it keeps \tempcnta in step with the -% resulting number of things in the filtered list. This is -% because \tempcnta is used to set citetotal - this use -% of filtering for cite sorting has the side-effect of stripping -% duplicated like \cite{foo,foo} but we need then to keep citetotal -% in sync. - -\protected\def\blx@filtercitesort#1#2{% - \blx@tempcnta\z@ - \def\do##1{% - \ifinlistcs{##1}{#2} - {\listadd#1{##1}% - \advance\blx@tempcnta\@ne} - {}}% - \blx@runfilter#1} - -% {}{} => neg. matches in - -\protected\def\blx@notfilter#1#2{% - \def\do##1{% - \ifinlistcs{##1}{#2} - {} - {\listadd#1{##1}}}% - \blx@runfilter#1} - -\def\blx@runfilter#1{% - \begingroup\edef#1{\endgroup - \unexpanded{\let#1\@empty\dolistloop}{#1}}% - #1\let\do\noexpand} - -% {}{} => {} - -\protected\def\blx@xsanitizeafter#1#2{% - \begingroup - \abx@hook@xsanitize - \def\blx@tempa{\endgroup#1}% - \edef\blx@tempb{#2}% - \expandafter\blx@tempa - \expandafter{\detokenize\expandafter{\blx@tempb}}} - -\def\abx@hook@xsanitize{% - \blx@safe@actives - \let\protect\string} - -% {}{} => {} - -\begingroup -\catcode`\<=\active -\catcode`\>=\active -\catcode`\&=\active -\catcode`\"=\active -\catcode`\'=\active -\protected\gdef\blx@xmlsanitizeafter#1#2{% - \begingroup - \abx@hook@xsanitize - \def\blx@tempa{\endgroup#1}% - \edef\blx@tempb{#2}% - \let\do\@makeother - \dospecials - \catcode`\<=\active - \catcode`\>=\active - \catcode`\&=\active - \catcode`\"=\active - \catcode`\'=\active - \edef<{\string<\string;}% - \edef>{\string>\string;}% - \edef&{\string&\string;}% - \edef"{\string"\string;}% - \edef'{\string&apos\string;}% - \endlinechar\m@ne - \everyeof{\noexpand}% - \edef\blx@tempb{\scantokens\expandafter{\blx@tempb}}% - \expandafter\blx@tempa - \expandafter{\detokenize\expandafter{\blx@tempb}}} -\endgroup - -% {}{}{}{}{}{} - -\protected\long\def\blx@inputonce#1#2#3#4#5#6{% - \ifcsundef{blx@file@#1} - {\blx@info@noline{Trying to load #2..}% - \IfFileExists{#1} - {\blx@info@noline{... file '#1' found}% - \listxadd\blx@list@req@stat{#1}% - #3\@@input\@filef@und#4#5} - {\blx@info@noline{... file '#1' not found}#6}% - \global\csdef{blx@file@#1}{}% - \@addtofilelist{#1}} - {#5}} - -% {}{}{} - -\protected\def\blx@auxwrite#1#2#3{% - \if@filesw - \begingroup - \blx@safe@actives - \let\protect\string - #2% - \immediate\write#1{#3}% - \endgroup - \fi} - -\def\blx@auxinit@bibtex#1{% - \blx@auxwrite\blx@auxout@bibtex - {\def\do##1{,\blx@stripbib{##1}}} - {\ifx\blx@auxout@bibtex\@mainaux - \else - \blx@msg@aux - \fi - \string\bibstyle{biblatex}\blx@nl - \string\bibdata{% - \blx@ctrlfile@bibtex\blxauxsuffix - \ifx#1\@empty - \else - \dolistloop#1% - \fi}\blx@nl - \string\citation{biblatex-control}}} - -% {}{}{}{} - -\def\blx@ifsigned#1#2{% - \begingroup - \let\blx@tempa\@firstoftwo - \edef\blx@tempb{\csuse{blx@sig@#2}}% - \edef\blx@tempb{\detokenize\expandafter{\blx@tempb}}% - \openin\blx@auxin #1.#2\relax - \ifeof\blx@auxin - \else - \endlinechar\m@ne - \readline\blx@auxin to \blx@tempc - \ifeof\blx@auxin - \else - \ifx\blx@tempb\blx@tempc - \readline\blx@auxin to \blx@tempc - \edef\blx@tempb{\csuse{blx@ver@#2}}% - \edef\blx@tempb{\detokenize\expandafter{\blx@tempb}}% - \ifx\blx@tempb\blx@tempc - \else - \blx@warning@noline{% - File '#1.#2' created by wrong version} - \fi - \else - \blx@error - {File '#1.#2' not created by biblatex} - {This file was apparently not created by biblatex. - Rename it or\MessageBreak move it to a location were - TeX will not find it. If this error\MessageBreak - persists, consider redefining \string\blxauxsuffix.% - See the biblatex\MessageBreak manual for details}% - \let\blx@tempa\@secondoftwo - \fi - \fi - \fi - \closein\blx@auxin - \expandafter\endgroup\blx@tempa} - -\def\blx@sig@bib{@Comment{$ biblatex control file $}} -\edef\blx@ver@bib{@Comment{$ biblatex version \blx@bblversion\space $}} -\edef\blx@sig@aux{\@percentchar\space $ biblatex auxiliary file $} -\edef\blx@ver@aux{\@percentchar\space$ biblatex version \blx@bblversion\space $} -\let\blx@sig@bbl\blx@sig@aux -\let\blx@ver@bbl\blx@ver@aux -\edef\blx@sig@bcf{\detokenize{}} -\edef\blx@ver@bcf{% - \detokenize{}} - -\edef\blx@msg@aux{% - \blx@sig@aux\blx@nl - \blx@ver@aux\blx@nl - \@percentchar\space Do not modify this file!\blx@nl - \@percentchar\blx@nl - \@percentchar\space This is an auxiliary file - used by the 'biblatex' package.\blx@nl - \@percentchar\space This file may safely be deleted. - It will be recreated as\blx@nl - \@percentchar\space required.\blx@nl - \@percentchar\blx@nl\string\relax\blx@nl} -\edef\blx@msg@bib{% - \blx@sig@bib\blx@nl - \blx@ver@bib\blx@nl - Do not modify this file!\blx@nl\blx@nl - This is an auxiliary file used - by the 'biblatex' package.\blx@nl - This file may safely be deleted. - It will be recreated as\blx@nl - required.\blx@nl\blx@nl} - -% {}{} - -\newrobustcmd*{\lbx@ifutfinput}{\ifboolexpr{% - test {\ifdefstring\inputencodingname{utf8}} - or - test {\ifdefstring\inputencodingname{utf8x}} - or - test {\ifdefstring\inputencodingname{lutf8}} - or - ( test {\ifundef\inputencodingname} - and - ( not test {\ifundef\XeTeXrevision} - or - not test {\ifundef\luatexversion} - ) - ) -}} - -%% User feedback - -\protected\def\blx@error#1#2{% - \begingroup - \blx@safe@actives - \PackageError{biblatex}{#1}{#2.}% - \endgroup} - -\protected\def\blx@warning@noline#1{% - \begingroup - \blx@safe@actives - \PackageWarningNoLine{biblatex}{#1}% - \endgroup} -\let\blx@warning\blx@warning@noline -\AtEndOfPackage{ - \protected\def\blx@warning#1{% - \begingroup - \blx@safe@actives - \PackageWarning{biblatex}{#1}% - \endgroup}} - -\protected\def\blx@warning@entry#1{% - \ifdef\abx@field@entrykey - {\blx@warning{#1\MessageBreak at entry '\abx@field@entrykey'}} - {\blx@warning{#1}}} - -\protected\def\blx@info@noline#1{% - \begingroup - \blx@safe@actives - \PackageInfo{biblatex}{#1\@gobble}% - \endgroup} -\let\blx@info\blx@info@noline -\AtEndOfPackage{ - \protected\def\blx@info#1{% - \begingroup - \blx@safe@actives - \PackageInfo{biblatex}{#1}% - \endgroup}} - -\let\blx@noline\@gobble -\AtEndOfPackage{\let\blx@noline\@empty} -\def\blx@imc@BibliographyWarning{\blx@warning@entry} -\blx@regimc\BibliographyWarning - -\protected\def\abx@missing#1{% - \mbox{\reset@font\bfseries#1}} - -\def\blx@err@patch#1{% - \blx@error - {Patching #1 failed} - {This is an internal issue typically caused by a - conflict\MessageBreak between biblatex and some - other package. Modifying\MessageBreak the package - loading order may fix the problem}} - -\def\blx@err@nolang#1{% - \blx@error - {Language '#1' not found} - {The localization module for '#1' could not be found}} - -\def\blx@err@invarg#1#2{% - \blx@error - {Argument '#1' invalid} - {\ifblank{#2} - {The argument you have supplied is invalid.\MessageBreak - See the biblatex manual for details} - {#2}}} - -\def\blx@err@invopt#1#2{% - \blx@error - {Option '#1' invalid} - {\ifblank{#2} - {The option you have supplied is invalid.\MessageBreak - See the biblatex manual for valid option keys and - possible values} - {#2}}} - -\def\blx@err@confopt#1#2{% - \blx@error - {Conflicting options\ifblank{#1}{}{ (#1)}} - {\ifblank{#2} - {The option you have supplied conflicts with another one.\MessageBreak - See the biblatex manual for valid option keys and possible values} - {#2}}} - -\def\blx@err@optdef#1{% - \blx@error - {Conflicting options} - {The option '#1' is already defined}} - -\def\blx@err@nodocdiv#1{% - \blx@error - {\@backslashchar#1 not provided by class} - {The document class does not seems to support #1s}} - -\def\blx@err@nosec#1{% - \blx@error - {Section '#1' not found} - {The reference section '#1' could not be found}} - -\def\blx@err@secfirst{% - \blx@error - {'section' not first filter} - {When passing multiple filter options, - the 'section' filter must be given first}} - -\protected\def\blx@err@nestcite{% - \blx@error - {Nested citation command} - {Citation commands may not be nested}} - -\def\blx@err@nestenv#1{% - \blx@error - {Nested '#1' environment} - {This environment may not be nested}} - -\protected\def\blx@err@citecmd#1{% - \begingroup - \escapechar\m@ne - \blx@error - {Command '\@backslashchar\string#1' undefined} - {The citation command '\@backslashchar\string#1' - has not been defined\MessageBreak by the - selected citation style}% - \endgroup} - -\def\blx@err@endnote#1{% - \blx@error - {Missing or incomplete endnote support} - {There does not seem to be endnote support available\MessageBreak - or the available support is incomplete.\MessageBreak - If you continue, I will fall back to '\string#1'}% - #1} - -\def\blx@err@matchparen#1{% - \blx@error - {Unbalanced parentheses or brackets} - {\iftoggle{blx@footnote}{#1 in foot or endnote}{#1}.\MessageBreak - This error is triggered if \string\bibopenparen\space and - \string\bibcloseparen\MessageBreak or - \string\bibopenbracket\space and \string\bibclosebracket\space - are unbalanced\MessageBreak or mismatched}} - -\def\blx@err@nestparen#1{% - \blx@error - {Too deeply nested parentheses or brackets} - {#1 nested too deeply% - \iftoggle{blx@footnote}{\space in foot or endnote}{}.\MessageBreak - This error may also be triggered if \string\mkbibparens\MessageBreak - or \string\mkbibbrackets\space are nested too deeply}} - -\def\blx@err@filter{% - \blx@error - {Invalid filter expression} - {The filter expression you have supplied is invalid.\MessageBreak - See the biblatex manual for details}} - -\def\blx@warn@nohyph#1{% - \blx@warning{No hyphenation patterns for '#1'}} - -\protected\def\blx@warn@citecmd#1#2{% - \blx@warning{% - '\string#1' not defined by citation style.\MessageBreak - Falling back to '\string#2'}% - #2} - -\protected\def\blx@warn@nostring#1{% - \blx@warning@entry{Bibliography string '#1' undefined}% - \abx@missing{#1}} - -\def\blx@warn@conflopt#1{% - \blx@warning{Conflicting options.\MessageBreak#1}} - -\def\blx@warn@depropt#1{% - \blx@warning{Deprecated option.\MessageBreak Ignoring '#1'}} - -\def\blx@warn@bibempty{% - \@latex@warning{Empty bibliography}} - -\def\blx@warn@losempty{% - \@latex@warning{Empty list of shorthands}} - -\def\blx@inf@refsec{% - \blx@info{Reference section=\the\c@refsection}}% - -\def\blx@inf@refseg{% - \ifnum\c@refsection=\z@ - \blx@info{Reference segment=\the\c@refsegment}% - \else - \blx@info{% - Reference section/segment=% - \the\c@refsection/\the\c@refsegment}% - \fi} - -\def\blx@inf@creset{% - \blx@info{Resetting trackers}}% - -\def\blx@msg@cundef#1{% - Citation '#1' undefined} -\def\blx@msg@cundefon#1{% - Citation '#1' on page \the\c@page\space undefined} - -\newrobustcmd*{\RequireBiber}[1][2]{% - \ifnumgreater{#1}\blx@reqbiber - {\numgdef\blx@reqbiber{#1}} - {}} -\@onlypreamble\RequireBiber -\let\blx@reqbiber\z@ - -\def\blx@checkbackend#1{% - \ifnumequal\blx@backend\blx@backend@biber - {} - {\ifcase\blx@reqbiber - \or - \blx@info@noline{% - backend=biber recommended by #1}% - \or - \blx@warning@noline{% - backend=biber required by #1.\MessageBreak - Some features may not work properly}% - \else - \blx@error - {backend=biber required by #1} - {The selected style or one of the .bib files - requires backend=biber.\MessageBreak It will - not work at all with any other backend}% - \fi}} - -% \blx@list@active active aux files (basename) -% [internal list] -% \blx@list@inactive inactive aux files (basename) -% [internal list] -% \blx@list@bibfiles@ aux file -> bib file mapping (refsections) -% aux file (basename) -> bib files (full) -% [internal list] - -\let\blx@list@active\@empty -\let\blx@list@inactive\@empty -\listeadd\blx@list@inactive{\jobname} - -\protected\def\blx@regbibfiles#1#2{% - \forlistloop{\blx@regbibfile{#1}}{#2}} - -\def\blx@regbibfile#1#2{% - \ifcsundef{blx@res@loca@#2} - {\blx@regbibfile@i{#1}{#2}} - {\ifcsstring{blx@res@loca@#2}{local} - {\blx@regbibfile@i{#1}{#2}} - {}}} - -\def\blx@regbibfile@i#1#2{% - \ifinlistcs{#2}{blx@list@bibfiles@#1} - {} - {\listcsxadd{blx@list@bibfiles@#1}{#2}}} - -\def\blx@check@logreq{% - \begingroup - \ifnum\blx@backend=\blx@backend@biber - \ltxrequest{biblatex}{{\iftoggle{blx@runltx}{1}{0}}}{% - \provides[type=dynamic]{ - \file{\jobname.bcf} - } - \requires[type=dynamic]{ - \file{\jobname.bbl} - } - \ifdef\blx@list@req@edit - {\requires[type=editable]{ - \forlistloop\file\blx@list@req@edit - }} - {} - \ifdef\blx@list@req@stat - {\requires[type=static]{ - \forlistloop\file\blx@list@req@stat - }} - {} - }% - \logrequest[package=biblatex,priority=5,active={{\iftoggle{blx@runbtx}{1}{0}}}]{% - \generic{biber} - \cmdline{ - \binary{biber} - \infile{\jobname} - } - \input{ - \file{\jobname.bcf} - } - \output{ - \file{\jobname.bbl} - } - \provides[type=dynamic]{ - \file{\jobname.bbl} - } - \requires[type=dynamic]{ - \file{\jobname.bcf} - } - \ifcsdef{blx@list@bibfiles@\jobname} - {\requires[type=editable]{ - \def\do{\file} - \dolistcsloop{blx@list@bibfiles@\jobname} - }} - {} - }% - \else - \ltxrequest{biblatex}{{\iftoggle{blx@runltx}{1}{0}}}{% - \provides[type=dynamic]{ - \def\do##1{\file{##1.aux}} - \dolistloop\blx@list@inactive - \file{\blx@ctrlfile@bibtex\blxauxsuffix.bib} - } - \requires[type=dynamic]{ - \def\do##1{\file{##1.bbl}} - \dolistloop\blx@list@inactive - } - \ifdef\blx@list@req@edit - {\requires[type=editable]{ - \forlistloop\file\blx@list@req@edit - }} - {} - \ifdef\blx@list@req@stat - {\requires[type=static]{ - \forlistloop\file\blx@list@req@stat - }} - {} - }% - \def\do##1{% - \ifinlist{##1}{\blx@list@active} - {\blx@logreq@bibtex{1}{##1}} - {\blx@logreq@bibtex{0}{##1}}}% - \dolistloop\blx@list@inactive - \fi - \endgroup} - -\def\blx@logreq@bibtex#1#2{% - \logrequest[package=biblatex,priority=5,active=#1]{% - \generic{bibtex} - \cmdline{% - \ifcase\blx@backend - \binary{bibtex} - \option{-min-crossrefs \blx@mincrossrefs} - \or - \binary{bibtex8} - \option{--wolfgang} - \option{--min\string_crossrefs \blx@mincrossrefs} - \ifdef\blx@csfencoding - {\option{--csfile \blx@csfencoding.csf}} - {}% - \or - \binary{bibtexu} - \option{--wolfgang} - \option{--min\string_crossrefs \blx@mincrossrefs} - \fi - \infile{#2} - } - \input{ - \file{#2.aux} - } - \output{ - \file{#2.bbl} - } - \provides[type=dynamic]{ - \file{#2.bbl} - } - \requires[type=dynamic]{ - \file{#2.aux} - \file{\blx@ctrlfile@bibtex\blxauxsuffix.bib} - } - \requires[type=editable]{ - \ifcsdef{blx@list@bibfiles@#2} - {\def\do{\file} - \dolistcsloop{blx@list@bibfiles@#2}} - {} - } - \requires[type=static]{ - \file{biblatex.bst} - \ifnum\blx@backend=\blx@backend@bibtexe - \ifdef\blx@csfencoding - {\file{\blx@csfencoding.csf}} - {}% - \fi - } - }% -} - -\def\blx@logreq@active#1{% - \ifnum\blx@backend=\blx@backend@biber - \else - \xifinlist{\blx@auxfile@bibtex}{\blx@list@active} - {} - {\listxadd\blx@list@active{\blx@auxfile@bibtex}}% - \fi - \ifblank{#1} - {} - {\@latex@warning{#1}}% - \blx@rerun@latex - \blx@rerun@bibtex} - -\def\blx@logreq@inactive{% - \ifnum\blx@backend=\blx@backend@biber - \else - \xifinlist{\blx@auxfile@bibtex}{\blx@list@inactive} - {} - {\listxadd\blx@list@inactive{\blx@auxfile@bibtex}}% - \fi} - -\def\blx@rerun@latex{% - \G@refundefinedtrue - \global\toggletrue{blx@runltx}% - \global\let\blx@rerun@latex\relax} - -\def\blx@rerun@bibtex{% - \global\toggletrue{blx@runbtx}% - \global\let\blx@rerun@bibtex\relax} - -\let\blx@checksum@old\@empty -\let\blx@checksum@new\@empty -\let\blx@pagesum@old\@empty -\let\blx@pagesum@new\@empty - -\def\blx@checksum#1#2#3{% - \begingroup - \blx@tempcnta\the\numexpr0#2*0#3\relax - \blx@tempcntb\blx@tempcnta - \divide\blx@tempcntb10 - \multiply\blx@tempcntb10 - \advance\blx@tempcnta-\blx@tempcntb - \xdef#1{#1\the\blx@tempcnta}% - \endgroup} - -\def\blx@addchecksum{\blx@checksum\blx@checksum@old} -\def\blx@addpagesum{\blx@checksum\blx@pagesum@old} -\AtEndDocument{% - \def\blx@addchecksum{\blx@checksum\blx@checksum@new}% - \def\blx@addpagesum{\blx@checksum\blx@pagesum@new}} - -\protected\def\blx@check@rerun{% - \begingroup - \blx@tempcnta\z@ - \iftoggle{blx@runltx} - {\blx@tempcnta\@ne} - {\ifx\blx@checksum@old\blx@checksum@new - \ifx\blx@pagesum@old\blx@pagesum@new - \else - \blx@tempcnta\@ne - \fi - \else - \blx@tempcnta\@ne - \fi}% - \iftoggle{blx@runbtx} - {\advance\blx@tempcnta\tw@} - {}% - \ifcase\blx@tempcnta - \or - \blx@rerun@latex - \blx@warning@noline{% - Please rerun LaTeX% - \ifx\blx@pagesum@old\blx@pagesum@new\else - .\MessageBreak Page breaks have changed% - \fi}% - \else - \blx@rerun@latex - \blx@warn@auxlist - \fi - \endgroup} - -\def\blx@warn@auxlist{% - \begingroup - \ifnum\blx@backend=\blx@backend@biber - \edef\blx@tempa{% - Please (re)run Biber on the file:\MessageBreak - \jobname}% - \else - \edef\blx@tempa{Please (re)run BibTeX on the file(s):}% - \def\do##1{\appto\blx@tempa{\MessageBreak##1}}% - \dolistloop\blx@list@active - \fi - \blx@warning@noline{% - \blx@tempa\MessageBreak - and rerun LaTeX afterwards}% - \endgroup} - -\AfterEndDocument{% - \blx@check@rerun - \blx@check@logreq} - -%% Punctuation and capitalization - -% 1001 apostrophe (\printnames only) -% 1002 abbreviation period (dot) -% 1003/1250 comma -% 1004/1500 semicolon -% 1005/2000 colon -% 1006/3000 period -% 1007/3001 exclamation mark -% 1008/3002 question mark -% 1009 suppress punctuation -% 1010 new paragaph - -\mathchardef\blx@sf@apo=1001 -\mathchardef\blx@sf@dot=1002 -\mathchardef\blx@sf@comma=1003 -\mathchardef\blx@sf@semicolon=1004 -\mathchardef\blx@sf@colon=1005 -\mathchardef\blx@sf@period=1006 -\mathchardef\blx@sf@exclam=1007 -\mathchardef\blx@sf@question=1008 -\mathchardef\blx@sf@nopunct=1009 -\mathchardef\blx@sf@par=1010 -\mathchardef\blx@sf@threshold@low=1002 -\mathchardef\blx@sf@threshold@high=1009 - -\csdef{blx@sf@1250}{\the\blx@sf@comma} -\csdef{blx@sf@1500}{\the\blx@sf@semicolon} -\csdef{blx@sf@2000}{\the\blx@sf@colon} -\csdef{blx@sf@3000}{\the\blx@sf@period} -\csdef{blx@sf@3001}{\the\blx@sf@exclam} -\csdef{blx@sf@3002}{\the\blx@sf@question} - -\csdef{blx@pm@,}{comma} -\csdef{blx@pm@;}{semicolon} -\csdef{blx@pm@:}{colon} -\csdef{blx@pm@.}{period} -\csdef{blx@pm@!}{exclam} -\csdef{blx@pm@?}{question} - -\def\blx@setsfcodes{% - \let\blx@setsfcodes\relax - \let\frenchspacing\blx@setfrcodes - \let\nonfrenchspacing\blx@setencodes - \ifnum\sfcode`\.>2000 - \blx@setencodes - \else - \blx@setfrcodes - \fi - \@setquotesfcodes - \sfcode`\(=\z@ - \sfcode`\)=\z@ - \sfcode`\[=\z@ - \sfcode`\]=\z@ - \sfcode`\<=\z@ - \sfcode`\>=\z@} - -\def\blx@setfrcodes{% - \ifnum\sfcode`\A=\@m - \else - \blx@setazcodes - \fi - \sfcode`\,=\blx@sf@comma - \sfcode`\;=\blx@sf@semicolon - \sfcode`\:=\blx@sf@colon - \sfcode`\.=\blx@sf@period - \sfcode`\!=\blx@sf@exclam - \sfcode`\?=\blx@sf@question -} - -\def\blx@setencodes{% - \sfcode`\,=1250 - \sfcode`\;=1500 - \sfcode`\:=2000 - \sfcode`\.=3000 - \sfcode`\!=3001 - \sfcode`\?=3002 -} - -\def\blx@namecodes{% - \ifnum\sfcode`\A=\@m - \else - \blx@setazcodes - \fi - \sfcode`\'=\blx@sf@apo -} - -\begingroup -\let\blx@setazcodes\@empty -\def\blx@tempa{% - \xdef\blx@setazcodes{% - \blx@setazcodes - \sfcode\the\blx@tempcnta=\@m} - \ifnum\blx@tempcnta<\blx@tempcntb - \advance\blx@tempcnta\@ne - \expandafter\blx@tempa - \fi} -\blx@tempcnta`\A -\blx@tempcntb`\Z -\blx@tempa -\ifnum\inputlineno=\m@ne\else - \blx@tempcnta"80 - \blx@tempcntb"9C - \blx@tempa - \blx@tempcnta"C0 - \blx@tempcntb"DF - \blx@tempa -\fi -\endgroup - -\def\blx@spacefactor{% - \ifhmode - \ifcsundef{blx@sf@\the\spacefactor} - {\the\spacefactor} - {\csname blx@sf@\the\spacefactor\endcsname}% - \else - \the\blx@sf@par - \fi} - -\protected\def\blx@leavevmode{% - \ifhmode - \else - \leavevmode\spacefactor\blx@sf@par - \fi} - -\protected\def\blx@leavevmode@cite{% - \ifhmode - \ifnum\spacefactor=\blx@sf@par - \else - \spacefactor\@m - \fi - \else - \leavevmode - \fi} - -\protected\def\blx@imc@setpunctfont#1{% - \blx@ifpuncthook - {\gdef\abx@puncthook{% - \ifdim\lastkern>\z@\unkern\fi - \blx@imc@resetpunctfont#1}} - {}} -\protected\def\blx@imc@resetpunctfont{% - \blx@ifpuncthook - {\global\let\abx@puncthook\@firstofone} - {}} - -\protected\def\blx@setpostpunct#1{% - \blx@ifuspunct - {\global\let\blx@postpunct\blx@dopostpunct - \ifdef\blx@thepostpunct - {\gappto\blx@thepostpunct{#1}} - {\gdef\blx@thepostpunct{#1}}} - {}} - -\def\blx@dopostpunct{% - \blx@thepostpunct - \global\let\blx@postpunct\@empty - \global\undef\blx@thepostpunct} - -\protected\def\blx@postpunct@agroup{% - \aftergroup\blx@postpunct - \let\blx@postpunct@agroup\@empty} - -% {} - -\newrobustcmd*{\DeclareCapitalPunctuation}[1]{% - \cslet{blx@cap@\the\blx@sf@par}\@empty - \csundef{blx@cap@\the\blx@sf@comma}% - \csundef{blx@cap@\the\blx@sf@semicolon}% - \csundef{blx@cap@\the\blx@sf@colon}% - \csundef{blx@cap@\the\blx@sf@period}% - \csundef{blx@cap@\the\blx@sf@exclam}% - \csundef{blx@cap@\the\blx@sf@question}% - \ifblank{#1} - {} - {\expandafter\blx@defcapstring\detokenize{#1}\relax}} - -\def\blx@defcapstring#1{% - \ifx#1\relax - \else - \begingroup - \blx@setfrcodes - \ifcsdef{blx@pm@#1} - {\expandafter\endgroup - \expandafter\let - \csname blx@cap@\the\sfcode`#1\endcsname\@empty} - {\blx@warning{Ignoring invalid punctuation mark '#1'}% - \endgroup}% - \expandafter\blx@defcapstring - \fi} - -% {} - -\newrobustcmd*{\DeclareQuotePunctuation}[1]{% - \csdef{blx@qp@comma}{\blx@postpunct}% - \csdef{blx@qp@semicolon}{\blx@postpunct}% - \csdef{blx@qp@colon}{\blx@postpunct}% - \csdef{blx@qp@period}{\blx@postpunct}% - \csdef{blx@qp@exclam}{\blx@postpunct}% - \csdef{blx@qp@question}{\blx@postpunct}% - \cslet{blx@pq@comma}\@empty - \cslet{blx@pq@semicolon}\@empty - \cslet{blx@pq@colon}\@empty - \cslet{blx@pq@period}\@empty - \cslet{blx@pq@exclam}\@empty - \cslet{blx@pq@question}\@empty - \let\blx@quotepunct\@empty - \ifblank{#1} - {\let\blx@ifuspunct\@secondoftwo} - {\let\blx@ifuspunct\@firstoftwo - \expandafter\blx@defquotepunct\detokenize{#1}&}} - -\def\blx@defquotepunct#1{% - \ifx\relax - \else - \ifcsdef{blx@pm@#1} - {\appto\blx@quotepunct{#1}% - \cslet{blx@qp@\csuse{blx@pm@#1}}\@empty - \csdef{blx@pq@\csuse{blx@pm@#1}}{\blx@postpunct}} - {\blx@warning{Ignoring invalid punctuation mark '#1'}}% - \expandafter\blx@defquotepunct - \fi} - -% {}{} - -\newrobustcmd*{\DeclarePunctuationPairs}[2]{% - \ifcsdef{blx@sf@\detokenize{#1}} - {\ifnum\csname blx@sf@\detokenize{#1}\endcsname>\blx@sf@apo - \ifnum\csname blx@sf@\detokenize{#1}\endcsname<\blx@sf@nopunct - \expandafter\blx@defpunctpairs - \expandafter{\the\csname blx@sf@\detokenize{#1}\endcsname}{#2}% - \else - \blx@err@invarg{\detokenize{#1}{}}% - \fi - \else - \blx@err@invarg{\detokenize{#1}{}}% - \fi} - {\blx@err@invarg{\detokenize{#1}{}}}} - -\def\blx@defpunctpairs#1#2{% - \blx@undefpair{#1}{\the\blx@sf@dot}% - \blx@undefpair{#1}{\the\blx@sf@comma}% - \blx@undefpair{#1}{\the\blx@sf@semicolon}% - \blx@undefpair{#1}{\the\blx@sf@colon}% - \blx@undefpair{#1}{\the\blx@sf@period}% - \blx@undefpair{#1}{\the\blx@sf@exclam}% - \blx@undefpair{#1}{\the\blx@sf@question}% - \ifblank{#2} - {} - {\begingroup - \def\blx@tempa{#1}% - \let\blx@tempb\@empty - \blx@setfrcodes - \sfcode`\*=\blx@sf@dot - \expandafter\blx@defpair\detokenize{#2}&% - \expandafter\endgroup\blx@tempb}} - -\def\blx@defpair#1{% - \ifx% - \else - \ifnum\the\sfcode`#1>\blx@sf@apo - \ifnum\the\sfcode`#1<\blx@sf@nopunct - \eappto\blx@tempb{% - \cslet{blx@pp@\blx@tempa @\the\sfcode`#1}\noexpand\@empty}% - \else - \blx@err@invarg{#1}{}% - \fi - \else - \blx@err@invarg{#1}{}% - \fi - \expandafter\blx@defpair - \fi} - -\def\blx@undefpair#1#2{% - \ifcsdef{blx@pp@#1@#2} - {\csundef{blx@pp@#1@#2}} - {}} - -\protected\def\blx@resetpunct{% - \DeclareCapitalPunctuation{.!?}% - \DeclarePunctuationPairs{dot}{}% - \DeclarePunctuationPairs{comma}{*!?}% - \DeclarePunctuationPairs{semicolon}{*!?}% - \DeclarePunctuationPairs{colon}{*!?}% - \DeclarePunctuationPairs{period}{}% - \DeclarePunctuationPairs{exclam}{*}% - \DeclarePunctuationPairs{question}{*}% - \DeclareQuotePunctuation{}% - \def\abx@dot{\ifdim\lastkern>\z@\unkern\fi.\spacefactor\blx@sf@dot}% - \def\abx@comma{\ifdim\lastkern>\z@\unkern\fi\abx@puncthook{,}}% - \def\abx@semicolon{\abx@puncthook{;}}% - \def\abx@colon{\abx@puncthook{:}}% - \def\abx@period{\ifdim\lastkern>\z@\unkern\fi\abx@puncthook{.}}% - \def\abx@exclam{\abx@puncthook{!}}% - \def\abx@question{\abx@puncthook{?}}% - \global\let\abx@puncthook\@firstofone - \global\let\blx@postpunct\@empty} - -\blx@resetpunct - -% {}{}{} - -\protected\def\blx@imc@ifpunctmark#1{% - \ifhmode - \begingroup - \sfcode`\*=\blx@sf@dot - \ifnum\sfcode`#1=\spacefactor - \endgroup - \expandafter\expandafter - \expandafter\@firstoftwo - \else - \endgroup - \expandafter\expandafter - \expandafter\@secondoftwo - \fi - \else - \expandafter\@secondoftwo - \fi} - -% {}{} - -\protected\def\blx@imc@ifterm{% - \ifhmode - \expandafter\blx@imc@ifcapital - \else - \expandafter\@secondoftwo - \fi} - -% {}{} - -\protected\def\blx@imc@ifcapital{% - \ifcsdef{blx@cap@\blx@spacefactor}} - -% {}{} - -\protected\def\blx@imc@ifpunct{% - \ifnum\blx@spacefactor>\blx@sf@threshold@low - \ifnum\blx@spacefactor<\blx@sf@threshold@high - \expandafter\expandafter - \expandafter\@firstoftwo - \else - \expandafter\expandafter - \expandafter\@secondoftwo - \fi - \else - \expandafter\@secondoftwo - \fi} - -% {} - -\newrobustcmd*{\autocap}[1]{#1} - -\protected\def\blx@imc@autocap{% - \blx@imc@ifcapital\MakeUppercase\@firstofone} - -\protected\def\blx@imc@nopunct{% - \leavevmode\spacefactor\blx@sf@nopunct} - -\protected\def\blx@imc@isdot{% - \ifnum\blx@spacefactor=\blx@sf@period - \spacefactor\blx@sf@dot - \fi} - -\protected\def\blx@imc@adddot{% - \blx@addpunct{dot}% - \ifnum\blx@spacefactor=\blx@sf@period - \spacefactor\blx@sf@dot - \fi} - -\protected\def\blx@imc@addperiod{% - \blx@addpunct{period}% - \ifnum\blx@spacefactor=\blx@sf@dot - \spacefactor\blx@sf@period - \fi} - -\protected\def\blx@imc@addcomma{\blx@addpunct{comma}} -\protected\def\blx@imc@addsemicolon{\blx@addpunct{semicolon}} -\protected\def\blx@imc@addcolon{\blx@addpunct{colon}} -\protected\def\blx@imc@addexclam{\blx@addpunct{exclam}} -\protected\def\blx@imc@addquestion{\blx@addpunct{question}} - -\def\blx@addpunct#1{% - \unspace - \ifnum\blx@spacefactor<\blx@sf@threshold@low - \csuse{blx@qp@#1}\csuse{abx@#1}% - \else - \ifnum\blx@spacefactor>\blx@sf@threshold@high - \csuse{blx@qp@#1}\csuse{abx@#1}% - \else - \ifcsdef{blx@pp@\the\csname blx@sf@#1\endcsname @\blx@spacefactor} - {\csuse{blx@qp@#1}\csuse{abx@#1}} - {\csuse{blx@qp@#1}}% - \fi - \fi - \csuse{blx@pq@#1}} - -\providerobustcmd*{\unspace}{% - \ifbool{hmode} - {\ifdimgreater\lastskip\z@ - {\unskip\unspace} - {\ifnumgreater\lastpenalty\z@ - {\unpenalty\unspace} - {}}} - {}} - -\newrobustcmd*{\bibsentence}{% - \leavevmode\spacefactor\blx@sf@par - \ignorespaces} - -\newrobustcmd*{\midsentence}{% - \leavevmode - \@ifstar - {\ifnum\spacefactor=\blx@sf@dot - \else - \spacefactor\@m - \fi} - {\spacefactor\@m}} - -\newrobustcmd*{\addslash}{% - \unspace/\penalty\hyphenpenalty\hskip\z@skip} - -\newrobustcmd*{\addspace}{% - \unspace\blx@postpunct - \space\blx@imc@resetpunctfont} - -\newrobustcmd*{\addnbspace}{% - \unspace\blx@postpunct - \nobreak\space\blx@imc@resetpunctfont} - -\newrobustcmd*{\addthinspace}{% - \unspace\blx@postpunct - \hskip0.16667em\relax - \blx@imc@resetpunctfont} - -\newrobustcmd*{\addnbthinspace}{% - \unspace\blx@postpunct - \nobreak\hskip0.16667em\relax - \blx@imc@resetpunctfont} - -\newrobustcmd*{\addlowpenspace}{% - \unspace\blx@postpunct - \penalty\value{lownamepenalty}\space - \blx@imc@resetpunctfont} - -\newrobustcmd*{\addhighpenspace}{% - \unspace\blx@postpunct - \penalty\value{highnamepenalty}\space - \blx@imc@resetpunctfont} - -\newrobustcmd*{\addlpthinspace}{% - \unspace\blx@postpunct - \penalty\value{lownamepenalty}% - \hskip0.16667em\relax\blx@imc@resetpunctfont} - -\newrobustcmd*{\addhpthinspace}{% - \unspace\blx@postpunct - \penalty\value{highnamepenalty}% - \hskip0.16667em\relax\blx@imc@resetpunctfont} - -\newrobustcmd*{\addabbrvspace}{% - \unspace\blx@postpunct - \penalty\value{abbrvpenalty}% - \space\blx@imc@resetpunctfont} - -\newrobustcmd*{\addabthinspace}{% - \unspace\blx@postpunct - \penalty\value{abbrvpenalty}% - \hskip0.16667em\relax - \blx@imc@resetpunctfont} - -\newrobustcmd*{\adddotspace}{% - \unspace\adddot\blx@postpunct - \penalty\value{abbrvpenalty}% - \space\blx@imc@resetpunctfont} - -\providerobustcmd*{\noligature}{% - \penalty\@M\discretionary{-}{}{\kern0.03em}% - \nobreak\hskip\z@skip} - -\providerobustcmd*{\hyphen}{% - \nobreak-\nobreak\hskip\z@skip} - -\providerobustcmd*{\nbhyphen}{% - \nobreak\mbox{-}\nobreak\hskip\z@skip} - -\providerobustcmd*{\hyphenate}{% - \nobreak\-\nobreak\hskip\z@skip} - -\providerobustcmd*{\allowhyphens}{% - \nobreak\hskip\z@skip} - -\providerobustcmd*{\nohyphenation}{% - \lefthyphenmin\@m} - -\providerobustcmd*{\textnohyphenation}[1]{% - \bgroup\nohyphenation#1\egroup} - -\blx@regimcs{% - \setpunctfont \resetpunctfont \ifcapital \autocap \ifpunctmark - \ifpunct \ifterm \nopunct \isdot \adddot \addperiod \addcomma - \addsemicolon \addcolon \addexclam \addquestion} - -\appto\blx@blxinit{% - \appto\nocorrlist{\isdot\adddot\addperiod\addcomma}} - -%% Style definition - -% {} - -\newrobustcmd*{\RequireBibliographyStyle}[1]{% - \blx@inputonce{#1.bbx}{bibliography style '#1'}{}{}{} - {\blx@error - {Style '#1' not found} - {The bibliography style '#1' could not be found}}} -\@onlypreamble\RequireBibliographyStyle - -% {} - -\newrobustcmd*{\InitializeBibliographyStyle}{\appto\blx@hook@bbxinit} -\@onlypreamble\InitializeBibliographyStyle - -% {}{} - -\newrobustcmd*{\DeclareBibliographyDriver}[1]{% - \long\csdef{blx@bbx@#1}} -\@onlypreamble\DeclareBibliographyDriver - -% {} - -\def\blx@driver#1{% - \ifcsdef{blx@bbx@#1} - {\csuse{blx@bbx@#1}} - {\ifcsdef{blx@bbx@*} - {\blx@warning{% - No driver for entry type '#1'.\MessageBreak - Using fallback driver}% - \csuse{blx@bbx@*}} - {\blx@error - {No driver found} - {I can't find a driver for the entry type - '\abx@field@entrytype'\MessageBreak - and there is no fallback driver either}}}} - -% {}{}{} - -\def\blx@imc@ifdriver#1{\ifcsdef{blx@bbx@#1}} - -% {}{} - -\newrobustcmd*{\DeclareBibliographyAlias}[2]{% - \csedef{blx@bbx@#1}{% - \expandafter\noexpand\csname blx@bbx@#2\endcsname}} -\@onlypreamble\DeclareBibliographyAlias - -% {}[]{} - -\newrobustcmd*{\DeclareBibliographyOption}[1]{% - \@ifnextchar[%] - {\blx@defbibopt{#1}} - {\blx@defbibopt{#1}[]}} - -\long\def\blx@defbibopt#1[#2]#3{% - \ifcsundef{KV@blx@opt@ldt@#1} - {\ifcsundef{KV@blx@opt@pre@#1} - {\ifblank{#2} - {\define@key{blx@opt@pre}{#1}{#3}} - {\define@key{blx@opt@pre}{#1}[#2]{#3}}} - {\blx@err@optdef{#1}}} - {\blx@err@optdef{#1}}} - -% {}[]{} - -\newrobustcmd*{\DeclareTypeOption}[1]{% - \@ifnextchar[%] - {\blx@deftypeopt{#1}} - {\blx@deftypeopt{#1}[]}} - -\long\def\blx@deftypeopt#1[#2]#3{% - \ifcsundef{KV@blx@opt@typ@#1} - {\ifblank{#2} - {\define@key{blx@opt@typ}{#1}{#3}} - {\define@key{blx@opt@typ}{#1}[#2]{#3}}} - {\blx@err@optdef{#1}}} - -% {}[]{} - -\newrobustcmd*{\DeclareEntryOption}[1]{% - \@ifnextchar[%] - {\blx@defentryopt{#1}} - {\blx@defentryopt{#1}[]}} - -\long\def\blx@defentryopt#1[#2]#3{% - \ifcsundef{KV@blx@opt@ent@#1} - {\ifblank{#2} - {\define@key{blx@opt@ent}{#1}{#3}} - {\define@key{blx@opt@ent}{#1}[#2]{#3}}} - {\blx@err@optdef{#1}}} - -%% Auxiliary commands - -\newrobustcmd*{\citereset}{% - \csuse{blx@hook@cbxinit}% - \@ifstar - {} - {\global\cslet{blx@bsee@\the\c@refsection}\@empty - \global\cslet{blx@fsee@\the\c@refsection}\@empty - \blx@ibidreset@force - \blx@idemreset@force - \blx@opcitreset@force - \blx@loccitreset@force}} - -\def\blx@save#1{% - \ifcsdef{blx@saved@#1} - {} - {\blx@safe@actives - \csletcs{blx@saved@#1}{#1}% - \blx@rest@actives}} - -\def\blx@restore#1{% - \ifcsdef{blx@saved@#1} - {\blx@safe@actives - \csletcs{#1}{blx@saved@#1}% - \csundef{blx@saved@#1}% - \blx@rest@actives} - {}} - -\newrobustcmd*{\savecommand}[1]{% - \ifcsdef{blx@saved@cmd@\detokenize{#1}} - {} - {\cslet{blx@saved@cmd@\detokenize{#1}}{#1}}} - -\newrobustcmd*{\restorecommand}[1]{% - \ifcsdef{blx@saved@cmd@\detokenize{#1}} - {\letcs{#1}{blx@saved@cmd@\detokenize{#1}}% - \csundef{blx@saved@cmd@\detokenize{#1}}} - {}} - -% {} - -\newrobustcmd*{\savebibmacro}[1]{% - \blx@save{abx@macro@\detokenize{#1}}} - -\newrobustcmd*{\restorebibmacro}[1]{% - \blx@restore{abx@macro@\detokenize{#1}}} - -% {}[][]{} - -\newrobustcmd*{\newbibmacro}{% - \@star@or@long\blx@newbibmacro} - -\def\blx@newbibmacro#1{% - \ifcsundef{abx@macro@\detokenize{#1}} - {\blx@defbibmacro\new@command{#1}} - {\blx@warning{% - Macro '\detokenize{#1}' already defined.\MessageBreak - Using \string\renewbibmacro} - \blx@defbibmacro\renew@command{#1}}} - -\newrobustcmd*{\renewbibmacro}{% - \@star@or@long\blx@renewbibmacro} - -\def\blx@renewbibmacro#1{% - \ifcsundef{abx@macro@\detokenize{#1}} - {\blx@warning{% - Macro '\detokenize{#1}' undefined.\MessageBreak - Using \string\newbibmacro} - \blx@defbibmacro\new@command{#1}} - {\blx@defbibmacro\renew@command{#1}}} - -\newrobustcmd*{\providebibmacro}{% - \@star@or@long{\blx@defbibmacro\provide@command}} - -\def\blx@defbibmacro#1#2{% - \expandafter#1\csname abx@macro@\detokenize{#2}\endcsname} - -% {} - -\newrobustcmd*{\usebibmacro}{% - \@ifstar - {\blx@usebibmacro@i} - {\blx@usebibmacro}} - -\def\blx@usebibmacro#1{% - \blx@usebibmacro@i{\detokenize{#1}}} - -\def\blx@usebibmacro@i#1{% - \ifcsundef{abx@macro@#1} - {\blx@error - {Bibliography macro '#1' undefined} - {Use '\string\newbibmacro' to define this macro}} - {\csuse{abx@macro@#1}}} - -% {}{}{} - -\def\blx@imc@ifbibmacroundef#1{% - \ifcsundef{abx@macro@#1}} - -% {} - -\def\blx@imc@thefield#1{\csuse{abx@field@#1}} - -\def\blx@imc@strfield#1{% - \ifcsdef{abx@field@#1} - {\detokenize\expandafter\expandafter\expandafter - {\csname abx@field@#1\endcsname}} - {}} - -\def\blx@imc@csfield#1{\usefield{\unexpanded}{#1}} - -% {}{} - -\def\blx@imc@usefield#1#2{% - \expandafter\expandafter\expandafter#1% - \expandafter\expandafter\expandafter{\csname abx@field@#2\endcsname}} - -% {} - -\def\blx@imc@thelist#1{\csuse{abx@list@#1}} - -% {} - -\def\blx@imc@thename#1{\csuse{abx@name@#1}} - -% {} - -\protected\def\blx@imc@clearfield#1{% - \csundef{abx@field@#1}} - -% {} - -\protected\def\blx@imc@clearlist#1{% - \ifcsundef{abx@list@#1} - {} - {\togglefalse{abx@bool@more#1}% - \csundef{abx@list@#1}% - \csname c@#1\endcsname\z@}} - -% {} - -\protected\def\blx@imc@clearname#1{% - \ifcsundef{abx@name@#1} - {} - {\togglefalse{abx@bool@more#1}% - \csundef{abx@name@#1}% - \csname c@#1\endcsname\z@}} - -% {}{} - -\protected\def\blx@imc@restorefield#1{\cslet{abx@field@#1}} - -% {}{} - -\protected\def\blx@imc@restorelist#1{\cslet{abx@list@#1}} - -% {}{} - -\protected\def\blx@imc@restorename#1{\cslet{abx@name@#1}} - -% {}{} - -\protected\def\blx@imc@savefield{% - \@ifstar{\blx@savedata{field}}{\global\blx@savedata{field}}} -\def\blx@savedata#1#2#3{\letcs#3{abx@#1@#2}} - -% {}{} - -\protected\def\blx@imc@savelist{% - \@ifstar{\blx@savedata{list}}{\global\blx@savedata{list}}} - -% {}{} - -\protected\def\blx@imc@savename{% - \@ifstar{\blx@savedata{name}}{\global\blx@savedata{name}}} - -% {}{} - -\protected\def\blx@imc@savefieldcs{% - \@ifstar{\blx@savedatacs{field}}{\global\blx@savedatacs{field}}} -\def\blx@savedatacs#1#2#3{\csletcs{#3}{abx@#1@#2}} - -% {}{} - -\protected\def\blx@imc@savelistcs{% - \@ifstar{\blx@savedatacs{list}}{\global\blx@savedatacs{list}}} - -% {}{} - -\protected\def\blx@imc@savenamecs{% - \@ifstar{\blx@savedatacs{name}}{\global\blx@savedatacs{name}}} - -% {}{}{} - -\def\blx@imc@iffieldundef#1{% - \ifcsundef{abx@field@#1}} - -% {}{}{} - -\def\blx@imc@iflistundef#1{% - \ifcsundef{abx@list@#1}} - -% {}{}{} - -\def\blx@imc@ifnameundef#1{% - \ifcsundef{abx@name@#1}} - -% {}{}{}{} - -\def\blx@imc@iffieldsequal#1#2{% - \ifcsequal{abx@field@#1}{abx@field@#2}} - -% {}{}{}{} - -\def\blx@imc@iflistsequal#1#2{% - \ifcsequal{abx@list@#1}{abx@list@#2}} - -% {}{}{}{} - -\def\blx@imc@ifnamesequal#1#2{% - \ifcsundef{abx@name@#1} - {\@secondoftwo} - {\ifcsundef{abx@name@#2} - {\@secondoftwo} - {\blx@ifnamesequal{#1}{#2}}}} - -\def\blx@ifnamesequal#1#2{% - \begingroup - \let\blx@tempa\@empty - \expandafter\expandafter - \expandafter\blx@ifnamesequal@i\csname abx@name@#2\endcsname - \let\blx@tempb\blx@tempa - \let\blx@tempa\@empty - \expandafter\expandafter - \expandafter\blx@ifnamesequal@i\csname abx@name@#1\endcsname - \expandafter\endgroup - \ifx\blx@tempa\blx@tempb - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi} - -\def\blx@ifnamesequal@i#1#2{% - \expandafter\blx@ifnamesequal@ii#2{}&} - -\def\blx@ifnamesequal@ii#1{% - \ifblank{#1} - {\blx@namebreak} - {\blx@ifnamesequal@iii#1% - \blx@ifnamesequal@ii}} - -\def\blx@ifnamesequal@iii#1#2#3#4#5#6#7#8#9{% - \setkeys{blx@opt@name}{#1}% - \ifdef\abx@field@hash - {\eappto\blx@tempa{{\abx@field@hash}}} - {\appto\blx@tempa{{{#2}{#4}{#6}{#8}}}}} - -% {}{}{}{} - -\def\blx@imc@iffieldequals#1#2{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\ifundef#2% - {\@secondoftwo} - {\expandafter\ifx\csname abx@field@#1\endcsname#2% - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi}}} - -% {}{}{}{} - -\def\blx@imc@iflistequals#1#2{% - \blx@imc@iflistundef{#1} - {\@secondoftwo} - {\ifundef#2% - {\@secondoftwo} - {\expandafter\ifx\csname abx@list@#1\endcsname#2% - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi}}} - -% {}{}{}{} - -\def\blx@imc@ifnameequals#1#2{% FIXME - \blx@imc@ifnameundef{#1} - {\@secondoftwo} - {\ifundef#2% - {\@secondoftwo} - {\expandafter\ifx\csname abx@name@#1\endcsname#2% - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi}}} - -% {}{}{}{} - -\def\blx@imc@iffieldequalcs#1{% - \ifcsequal{abx@field@#1}} - -% {}{}{}{} - -\def\blx@imc@iflistequalcs#1{% - \ifcsequal{abx@list@#1}} - -% {}{}{}{} - -\def\blx@imc@ifnameequalcs#1{% FIXME - \ifcsequal{abx@name@#1}} - -% {}{}{}{} - -\protected\long\def\blx@imc@iffieldequalstr#1#2{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\expandafter\expandafter\expandafter\ifstrequal - \expandafter\expandafter\expandafter{% - \csname abx@field@#1\endcsname}{#2}}} - -% {}{}{} - -\protected\def\blx@imc@iffieldxref#1{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\blx@whichxref - {\blx@iffieldxref{#1}} - {\@secondoftwo}}} - -\def\blx@iffieldxref#1#2{% - \begingroup - \letcs\blx@tempa{abx@field@#2}% - \letcs\blx@tempb{abx@field@#1}% - \csundef{abx@field@#1}% - \blx@getdata{\blx@tempa}% - \blx@imc@iffieldequals{#1}\blx@tempb - {\aftergroup\@firstoftwo} - {\aftergroup\@secondoftwo}% - \endgroup} - -\def\blx@whichxref#1#2{% - \blx@imc@iffieldundef{crossref} - {\blx@imc@iffieldundef{xref} - {#2} - {#1{xref}}} - {#1{crossref}}} - -% {}{}{} - -\protected\def\blx@imc@iflistxref#1{% - \blx@imc@iflistundef{#1} - {\@secondoftwo} - {\blx@whichxref - {\blx@iflistxref{#1}} - {\@secondoftwo}}} - -\def\blx@iflistxref#1#2{% - \begingroup - \letcs\blx@tempa{abx@field@#2}% - \letcs\blx@tempb{abx@list@#1}% - \csundef{abx@list@#1}% - \blx@getdata{\blx@tempa}% - \blx@imc@iflistequals{#1}\blx@tempb - {\aftergroup\@firstoftwo} - {\aftergroup\@secondoftwo}% - \endgroup} - -% {}{}{} - -\protected\def\blx@imc@ifnamexref#1{% - \blx@imc@ifnameundef{#1} - {\@secondoftwo} - {\blx@whichxref - {\blx@ifnamexref{#1}} - {\@secondoftwo}}} - -\def\blx@ifnamexref#1#2{% - \begingroup - \letcs\blx@tempa{abx@field@#2}% - \letcs\blx@tempb{abx@name@#1}% - \csundef{abx@name@#1}% - \blx@getdata{\blx@tempa}% - \blx@imc@ifnameequals{#1}\blx@tempb - {\aftergroup\@firstoftwo} - {\aftergroup\@secondoftwo}% - \endgroup} - -% {}{}{} - -\protected\def\blx@imc@ifcurrentfield#1{% - \begingroup - \def\blx@tempa{#1}% - \ifx\currentfield\blx@tempa - \aftergroup\@firstoftwo - \else - \aftergroup\@secondoftwo - \fi - \endgroup} - -% {}{}{} - -\protected\def\blx@imc@ifcurrentlist#1{% - \begingroup - \def\blx@tempa{#1}% - \ifx\currentlist\blx@tempa - \aftergroup\@firstoftwo - \else - \aftergroup\@secondoftwo - \fi - \endgroup} - -% {}{}{} - -\protected\def\blx@imc@ifcurrentname#1{% - \begingroup - \def\blx@tempa{#1}% - \ifx\currentname\blx@tempa - \aftergroup\@firstoftwo - \else - \aftergroup\@secondoftwo - \fi - \endgroup} - -% {}{}{} - -\protected\def\blx@imc@ifentrytype#1{% - \begingroup - \def\blx@tempa{#1}% - \ifx\abx@field@entrytype\blx@tempa - \aftergroup\@firstoftwo - \else - \aftergroup\@secondoftwo - \fi - \endgroup} - -% {}{} - -\def\blx@imc@ifmorenames{% - \ifundef\currentname - {\@secondoftwo} - {\iftoggle{abx@bool@more\currentname} - {\@firstoftwo} - {\ifnum\c@listtotal>\c@liststop - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi}}} - -% {}{} - -\def\blx@imc@ifmoreitems{% - \ifundef\currentlist - {\@secondoftwo} - {\iftoggle{abx@bool@more\currentlist} - {\@firstoftwo} - {\ifnum\c@listtotal>\c@liststop - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi}}} - -% {}{} - -\def\blx@imc@iffirstcitekey{% - \ifboolexpr{ ( test {\ifnumequal\c@multicitetotal\z@} - and test {\ifnumequal\c@citecount\@ne} ) - or ( test {\ifnumgreater\c@multicitetotal\z@} - and test {\ifnumequal\c@multicitecount\@ne} - and test {\ifnumequal\c@citecount\@ne} ) }} - -\def\blx@imc@iflastcitekey{% - \ifboolexpr{ test {\ifnumequal\c@citecount\c@citetotal} - and test {\ifnumequal\c@multicitecount\c@multicitetotal} }} - -% {}{}{} - -\protected\def\blx@imc@ifcategory{% - \ifdef\abx@field@entrykey - {\blx@imc@ifentrycategory\abx@field@entrykey} - {\expandafter\@secondoftwo\@gobble}} - -% {}{}{}{} - -\protected\def\blx@imc@ifentrycategory{% - \blx@xsanitizeafter\blx@imc@ifentrycategory@i} - -\def\blx@imc@ifentrycategory@i#1#2{% - \ifcsdef{blx@catg@\detokenize{#2}} - {\ifinlistcs{#1}{blx@catg@\detokenize{#2}}} - {\@secondoftwo}} - -% {}{}{} - -\protected\def\blx@imc@ifkeyword{% - \ifdef\abx@field@entrykey - {\blx@imc@ifentrykeyword\abx@field@entrykey} - {\expandafter\@secondoftwo\@gobble}} - -% {}{}{}{} - -\protected\def\blx@imc@ifentrykeyword{% - \blx@xsanitizeafter\blx@imc@ifentrykeyword@i} - -\def\blx@imc@ifentrykeyword@i#1#2{% - \ifcsdef{blx@keyw@\the\c@refsection @\detokenize{#2}} - {\ifinlistcs{#1}{blx@keyw@\the\c@refsection @\detokenize{#2}}} - {\@secondoftwo}} - -% {}{} - -\protected\def\blx@ifciteseen@global{% - \ifbool{citetracker} - {\ifdef\abx@field@entrykey - {\expandafter\blx@ifseen@global - \expandafter{\abx@field@entrykey}} - {\@secondoftwo}} - {\@secondoftwo}} - -\protected\def\blx@ifciteseen@context{% - \ifbool{citetracker} - {\ifdef\abx@field@entrykey - {\expandafter\blx@ifseen@context - \expandafter{\abx@field@entrykey}} - {\@secondoftwo}} - {\@secondoftwo}} - -% {}{}{} - -\protected\def\blx@ifentryseen@global{% - \blx@xsanitizeafter\blx@ifseen@global} - -\protected\def\blx@ifentryseen@context{% - \blx@xsanitizeafter\blx@ifseen@context} - -\def\blx@ifseen@global#1{% - \ifbool{citetracker} - {\ifinlistcs{#1}{blx@bsee@\the\c@refsection}} - {\@secondoftwo}} - -\def\blx@ifseen@context#1{% - \ifbool{citetracker} - {\iftoggle{blx@footnote} - {\ifinlistcs{#1}{blx@fsee@\the\c@refsection}} - {\ifinlistcs{#1}{blx@bsee@\the\c@refsection}}} - {\@secondoftwo}} - -% {}{} - -\def\blx@ifciteibid@global{% - \ifbool{citetracker} - {\blx@imc@iffieldequals{entrykey}\blx@lastkey@text} - {\@secondoftwo}} - -\def\blx@ifciteibid@context{% - \ifbool{citetracker} - {\iftoggle{blx@footnote} - {\blx@imc@iffieldequals{entrykey}\blx@lastkey@foot} - {\blx@imc@iffieldequals{entrykey}\blx@lastkey@text}} - {\@secondoftwo}} - -\def\blx@ifciteibid@strict{% - \ifbool{citetracker} - {\blx@ifcitesingle - {\blx@ifciteibid@global} - {\@secondoftwo}} - {\@secondoftwo}} - -\def\blx@ifciteibid@constrict{% - \ifbool{citetracker} - {\blx@ifcitesingle - {\iftoggle{blx@footnote} - {\blx@ifmpfncheck - {\blx@imc@iffieldequals{entrykey}\blx@lastkey@foot} - {\@secondoftwo}} - {\blx@imc@iffieldequals{entrykey}\blx@lastkey@text}} - {\@secondoftwo}} - {\@secondoftwo}} - -% {}{} - -\def\blx@ifciteidem@global{% - \ifbool{citetracker} - {\blx@imc@iffieldequals{fullhash}\blx@lasthash@text} - {\@secondoftwo}} - -\def\blx@ifciteidem@context{% - \ifbool{citetracker} - {\iftoggle{blx@footnote} - {\blx@imc@iffieldequals{fullhash}\blx@lasthash@foot} - {\blx@imc@iffieldequals{fullhash}\blx@lasthash@text}} - {\@secondoftwo}} - -\let\blx@ifciteidem@strict\blx@ifciteidem@global - -\def\blx@ifciteidem@constrict{% - \ifbool{citetracker} - {\iftoggle{blx@footnote} - {\blx@ifmpfncheck - {\blx@imc@iffieldequals{fullhash}\blx@lasthash@foot} - {\@secondoftwo}} - {\blx@imc@iffieldequals{fullhash}\blx@lasthash@text}} - {\@secondoftwo}} - -% {}{} - -\def\blx@ifopcit@global{% - \ifbool{citetracker} - {\blx@imc@iffieldundef{namehash} - {\@secondoftwo} - {\blx@imc@iffieldequalcs{entrykey}{blx@lastkey@text@\abx@field@namehash}}} - {\@secondoftwo}} - -\def\blx@ifopcit@context{% - \ifbool{citetracker} - {\blx@imc@iffieldundef{namehash} - {\@secondoftwo} - {\iftoggle{blx@footnote} - {\blx@imc@iffieldequalcs{entrykey}{blx@lastkey@foot@\abx@field@namehash}} - {\blx@imc@iffieldequalcs{entrykey}{blx@lastkey@text@\abx@field@namehash}}}} - {\@secondoftwo}} - -\def\blx@ifopcit@strict{% - \ifbool{citetracker} - {\blx@ifcitesingle - {\blx@ifopcit@global} - {\@secondoftwo}} - {\@secondoftwo}} - -\def\blx@ifopcit@constrict{% - \ifbool{citetracker} - {\blx@ifcitesingle - {\blx@imc@iffieldundef{namehash} - {\@secondoftwo} - {\iftoggle{blx@footnote} - {\blx@ifmpfncheck - {\blx@imc@iffieldequalcs{entrykey}{blx@lastkey@foot@\abx@field@namehash}} - {\@secondoftwo}} - {\blx@imc@iffieldequalcs{entrykey}{blx@lastkey@text@\abx@field@namehash}}}} - {\@secondoftwo}} - {\@secondoftwo}} - -% {}{} - -\def\blx@ifloccit@global{% - \ifbool{citetracker} - {\blx@loccit@check{text}} - {\@secondoftwo}} - -\def\blx@ifloccit@context{% - \ifbool{citetracker} - {\iftoggle{blx@footnote} - {\blx@loccit@check{foot}} - {\blx@loccit@check{text}}} - {\@secondoftwo}} - -\def\blx@ifloccit@strict{% - \ifbool{citetracker} - {\blx@ifcitesingle - {\blx@loccit@numcheck{text}} - {\@secondoftwo}} - {\@secondoftwo}} - -\def\blx@ifloccit@constrict{% - \ifbool{citetracker} - {\blx@ifcitesingle - {\iftoggle{blx@footnote} - {\blx@ifmpfncheck - {\blx@loccit@numcheck{foot}} - {\@secondoftwo}} - {\blx@loccit@numcheck{text}}} - {\@secondoftwo}} - {\@secondoftwo}} - -\def\blx@loccit@check#1{% - \blx@imc@iffieldundef{postnote} - {\@secondoftwo} - {\blx@imc@iffieldequalcs{postnote}{blx@lastnote@#1@\abx@field@entrykey}}} - -\def\blx@loccit@numcheck#1{% - \blx@imc@iffieldundef{postnote} - {\@secondoftwo} - {\expandafter\blx@imc@ifpages - \expandafter{\abx@field@postnote} - {\blx@imc@iffieldequalcs{postnote}{blx@lastnote@#1@\abx@field@entrykey}} - {\@secondoftwo}}} - -% {}{} - -\def\blx@ifmpfncheck{% - \ifnum\numexpr\value\@mpfn-\blx@lastmpfn<\tw@ - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi} - -\def\blx@mpfnsave{% - \xdef\blx@lastmpfn{\the\value\@mpfn}} - -\def\blx@mpfnreset{% - \global\let\blx@lastmpfn\z@} - -\blx@mpfnreset - -% {}{} - -\def\blx@imc@iffirstonpage{% - \ifbool{pagetracker} - {\iftoggle{blx@footnote} - {\blx@iffirstonpage{fnpage}} - {\blx@iffirstonpage{page}}} - {\@secondoftwo}} - -\def\blx@iffirstonpage#1{% - \ifcsundef{blx@#1@\number\c@instcount} - {\@secondoftwo} - {\expandafter\blx@iffirstonpage@i - \expandafter{\number\numexpr\c@instcount-1}{#1}}} - -\def\blx@iffirstonpage@i#1#2{% - \ifcsundef{blx@#2@#1} - {\ifnum#1>\@ne - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi - {\expandafter\blx@iffirstonpage@i - \expandafter{\number\numexpr#1-1}{#2}} - {\@firstoftwo}} - {\ifnum\csuse{blx@#2@\number\c@instcount}=% - \csuse{blx@#2@#1} % - \expandafter\@secondoftwo - \else - \expandafter\@firstoftwo - \fi}} - -% {}{}{}{} - -\def\blx@imc@ifsamepage#1#2{% - \ifbool{pagetracker} - {\ifcsundef{blx@page@\number\numexpr#1} - {\ifcsundef{blx@fnpage@\number\numexpr#1} - {\@secondoftwo} - {\blx@ifsamepage{#1}{#2}{fnpage}}} - {\blx@ifsamepage{#1}{#2}{page}}} - {\@secondoftwo}} - -\def\blx@ifsamepage#1#2#3{% - \ifcsundef{blx@page@\number\numexpr#2} - {\ifcsundef{blx@fnpage@\number\numexpr#2} - {\@secondoftwo} - {\blx@ifsamepage@i{#1}{#2}{#3}{fnpage}}} - {\blx@ifsamepage@i{#1}{#2}{#3}{page}}} - -\def\blx@ifsamepage@i#1#2#3#4{% - \ifnum\csuse{blx@#3@\number\numexpr#1}=% - \csuse{blx@#4@\number\numexpr#2} % - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi} - -% {}{}{} - -\protected\long\def\blx@imc@ifinteger#1{% - \begingroup - \def\do##1{\uccode`##1=`\%}% - \do\0\do\1\do\2\do\3\do\4\do\5\do\6\do\7\do\8\do\9% - \makeatletter - \catcode`\%=9 - \endlinechar\m@ne - \uppercase{\scantokens{\def\blx@tempa{#1}}}% - \ifx\blx@tempa\@empty - \aftergroup\@firstoftwo - \else - \aftergroup\@secondoftwo - \fi - \endgroup} - -% {}{}{} - -\protected\def\blx@imc@iffieldint#1{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\expandafter\expandafter - \expandafter\ifinteger - \expandafter\expandafter - \expandafter{\csname abx@field@#1\endcsname}}} - -% {}{}{} - -\protected\def\blx@imc@ifnumeral{% - \blx@ifnum\blx@hook@ifnum} - -\protected\def\blx@imc@ifnumerals{% - \blx@ifnum\blx@hook@ifnums} - -\protected\def\blx@imc@ifpages{% - \blx@ifnum\blx@hook@ifpages} - -\long\def\blx@ifnum#1#2{% - \begingroup - \let\protect\@unexpandable@protect - \uppercase{\edef\blx@tempa{#2}}% - \ifx\blx@tempa\@empty - \aftergroup\@secondoftwo - \else - \makeatletter - \catcode`\%=9 - \endlinechar\m@ne - \everyeof{\noexpand}#1% - \uppercase{\edef\blx@tempa{\scantokens{#2}}}% - \ifx\blx@tempa\@empty - \aftergroup\@firstoftwo - \else - \aftergroup\@secondoftwo - \fi - \fi - \endgroup} - -\def\blx@hook@ifnum{% - \def\do##1{\uccode`##1=`\%}% - \do\ \do\0\do\1\do\2\do\3\do\4\do\5\do\6\do\7\do\8\do\9% - \do\i\do\v\do\x\do\l\do\c\do\d\do\m - \do\I\do\V\do\X\do\L\do\C\do\D\do\M - \blx@donumchars - \let\RN\@firstofone - \let\Rn\@firstofone} - -\def\blx@hook@ifnums{% - \blx@hook@ifnum - \def\do##1{\uccode`##1=`\%}% - \blx@dorangechars - \def\do##1{\let##1\@empty}% - \blx@dorangecmds} - -\def\blx@hook@ifpages{% - \blx@hook@ifnum - \blx@hook@ifnums - \def\do##1{\let##1\@empty}% - \blx@dopagecmds} - -% {}{}{} - -\protected\def\blx@imc@iffieldnum#1{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\expandafter\expandafter - \expandafter\blx@imc@ifnumeral - \expandafter\expandafter - \expandafter{\csname abx@field@#1\endcsname}}} - -\protected\def\blx@imc@iffieldnums#1{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\expandafter\expandafter - \expandafter\blx@imc@ifnumerals - \expandafter\expandafter - \expandafter{\csname abx@field@#1\endcsname}}} - -\protected\def\blx@imc@iffieldpages#1{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\expandafter\expandafter - \expandafter\blx@imc@ifpages - \expandafter\expandafter - \expandafter{\csname abx@field@#1\endcsname}}} - -% {} - -\newrobustcmd*{\DeclareNumChars}{% - \@ifstar - {\blx@defnumchars} - {\global\let\blx@donumchars\@empty - \blx@defnumchars}} - -\def\blx@defnumchars#1{% - \ifblank{#1} - {} - {\expandafter\blx@defdochars - \expandafter\blx@donumchars - \detokenize{#1}\relax}} - -% {} - -\newrobustcmd*{\DeclareRangeChars}{% - \@ifstar - {\blx@defrangechars} - {\global\let\blx@dorangechars\@empty - \blx@defrangechars}} - -\def\blx@defrangechars#1{% - \ifblank{#1} - {} - {\expandafter\blx@defdochars - \expandafter\blx@dorangechars - \detokenize{#1}\relax}} - -\def\blx@defdochars#1#2{% - \ifx#2\relax - \else - \xdef#1{% - \expandonce#1\noexpand\do - \expandafter\noexpand\csname#2\endcsname}% - \expandafter\blx@defdochars - \expandafter#1% - \fi} - -% {} - -\newrobustcmd*{\DeclareRangeCommands}{% - \@ifstar - {\blx@defrangecmds} - {\global\let\blx@dorangecmds\@empty - \blx@defrangecmds}} - -\def\blx@defrangecmds#1{% - \ifblank{#1} - {} - {\blx@defrangecmds@i#1&}} - -\def\blx@defrangecmds@i#1{% - \ifx% - \else - \gappto\blx@dorangecmds{\do#1}% - \expandafter\blx@defrangecmds@i - \fi} - -% {} - -\newrobustcmd*{\DeclarePageCommands}{% - \@ifstar - {\blx@defpagecmds} - {\global\let\blx@dopagecmds\@empty - \blx@defpagecmds}} - -\def\blx@defpagecmds#1{% - \ifblank{#1} - {} - {\blx@defpagecmds@i#1&}} - -\def\blx@defpagecmds@i#1{% - \ifx% - \else - \gappto\blx@dopagecmds{\do#1}% - \expandafter\blx@defpagecmds@i - \fi} - -\DeclareNumChars{.} -\DeclareRangeChars{~,;-+/} -\DeclareRangeCommands{% - \ \,\space\nobreakspace\addspace\addnbspace - \addthinspace\addnbthinspace\addlowpenspace - \addhighpenspace\addlpthinspace\addhpthinspace - \adddotspace\addabbrvspace\&\psq\psqq - \bibrangedash\bibdatedash\textendash\textemdash} -\DeclarePageCommands{\pno\ppno} - -% *{} - -\newrobustcmd*{\NumCheckSetup}{\appto\blx@hook@ifnum} -\newcommand*{\NumcheckSetup}{\NumCheckSetup} - -% [][]{} - -\newrobustcmd*{\blx@imc@mkpageprefix}[1][pagination]{% - \begingroup - \def\blx@tempa{\blx@mkpageprefix{page}}% - \iffieldundef{#1} - {} - {\iffieldequalstr{#1}{none} - {\def\blx@tempa{\blx@mkpageprefix@i}} - {\iffieldbibstring{#1} - {\edef\blx@tempa{\blx@mkpageprefix{\thefield{#1}}}} - {\blx@warning@entry{% - Unknown pagination type '\strfield{#1}'}}}}% - \@ifnextchar[%] - {\blx@tempa} - {\blx@tempa[\@firstofone]}} - -\protected\long\def\blx@mkpageprefix#1[#2]#3{% - \ifnumeral{#3} - {\bibstring{#1}\ppspace} - {\ifnumerals{#3} - {\bibstring{#1s}\ppspace} - {\def\pno{\bibstring{#1}}% - \def\ppno{\bibstring{#1s}}}}% - \blx@mkpageprefix@i[#2]{#3}} - -\long\def\blx@mkpageprefix@i[#1]#2{#1{#2}\endgroup} - -% [][]{} - -\newrobustcmd*{\blx@imc@mkpagetotal}[1][bookpagination]{% - \begingroup - \def\blx@tempa{\blx@mkpagetotal{page}}% - \iffieldundef{#1} - {} - {\iffieldequalstr{#1}{none} - {\def\blx@tempa{\blx@mkpagetotal@i}} - {\iffieldbibstring{#1} - {\edef\blx@tempa{\blx@mkpagetotal{\thefield{#1}}}} - {\blx@warning@entry{% - Unknown pagination type '\strfield{#1}'}}}}% - \@ifnextchar[%] - {\blx@tempa} - {\blx@tempa[\@firstofone]}} - -\protected\long\def\blx@mkpagetotal#1[#2]#3{% - \ifnumeral{#3} - {\setbox\@tempboxa=\hbox{% - \blx@tempcnta0#3\relax - \ifnum\blx@tempcnta=\@ne - \aftergroup\@firstoftwo - \else - \aftergroup\@secondoftwo - \fi}% - {#2{#3}\ppspace\bibstring{#1}} - {#2{#3}\ppspace\bibstring{#1s}}} - {\def\pno{\bibstring{#1}}% - \def\ppno{\bibstring{#1s}}% - #2{#3}}% - \endgroup} - -\long\def\blx@mkpagetotal@i[#1]#2{#1{#2}\endgroup} - -\newcounter{mincomprange} -\newcounter{maxcomprange} -\newcounter{mincompwidth} -\setcounter{mincomprange}{10} -\setcounter{maxcomprange}{100000} -\setcounter{mincompwidth}{1} -\def\abx@rangeproclimit{100000} - -% {} -% This mustn't be robust as it's likely to be used mainly tests and so -% needs to be expandable -\newcommand*{\rangelen}[1]{% - \blx@rangelen@range#1\bibrangedash\bibrangedash&} - -\def\blx@rangelen@range#1\bibrangedash#2\bibrangedash#3&{% - \ifblank{#3} - {\blx@rangelen@hyphen#1--&} - {\ifblank{#2} - {0}% n\bibrangedash - {\ifblank{#1} - {0}% \bibrangedash n - {\blx@rangelen@check{#1}{#2}}}}} - -\def\blx@rangelen@hyphen#1-#2-#3&{% - \ifblank{#3} - {1}% n - {\ifblank{#2} - {\ifblank{#1} - {\let\blx@tempb\@empty} - {\def\blx@tempb{#1}}% - \blx@rangelen@hyphen@i#3&} - {\ifblank{#1} - {0}% -n - {\blx@rangelen@check{#1}{#2}}}}} - -\def\blx@rangelen@hyphen@i#1-#2&{% - \ifblank{#1#2} - {0}% n- - {\notblank{#1} - {\ifdefempty\blx@tempb - {0} - {\expandafter\blx@rangelen@check - \expandafter{\blx@tempb}{#1}}} - {\blx@rangelen@hyphen@i#2&}}} - -\def\blx@rangelen@check#1#2{% - \blx@imc@ifinteger{#1} - {\blx@imc@ifinteger{#2} - {\the\numexpr#2-#1\relax}% n-m - {0}} - {0}} - -% <*>[]{} - -\newrobustcmd*{\mkcomprange}{% - \begingroup - \@ifstar - {\blx@comprange\blx@comprange@ii} - {\blx@comprange\blx@comprange@i}} - -\def\blx@comprange#1{% - \@ifnextchar[{#1}{#1[\@firstofone]}} - -\def\blx@comprange@i[#1]#2{% - \let\blx@tempa\@empty - \protected\def\blx@range@out@value{\appto\blx@tempa}% - \let\blx@range@out@delim\blx@range@out@value - \let\blx@range@split\blx@comprange@split - \blx@range@chunk{#2}% - \edef\blx@tempa{\endgroup - \unexpanded{#1}{\expandonce\blx@tempa}}% - \blx@tempa} - -\def\blx@comprange@ii[#1]#2{% - \protected\def\blx@range@out@value{#1}% - \let\blx@range@out@delim\@firstofone - \let\blx@range@split\blx@comprange@split - \blx@range@chunk{#2}% - \endgroup} - -\def\blx@comprange@split#1{% - \def\blx@comprange@abort{\blx@range@out@value{#1}}% - \blx@imc@ifpages{#1} - {\blx@comprange@range#1\bibrangedash\bibrangedash&} - {\blx@comprange@abort}} - -\def\blx@comprange@range#1\bibrangedash#2\bibrangedash#3&{% - \ifblank{#3} - {\blx@comprange@hyphen#1--&} - {\ifblank{#2} - {\blx@range@out@value{#1\bibrangedash}} - {\ifblank{#1} - {\blx@range@out@value{\bibrangedash#2}} - {\blx@comprange@check{#1}{#2}}}}} - -\def\blx@comprange@hyphen#1-#2-#3&{% - \ifblank{#3} - {\blx@comprange@abort} - {\ifblank{#2} - {\ifblank{#1} - {\let\blx@tempb\@empty} - {\def\blx@tempb{#1}}% - \blx@comprange@hyphen@i#3&} - {\ifblank{#1} - {\blx@range@out@value{\bibrangedash#2}} - {\blx@comprange@check{#1}{#2}}}}} - -\def\blx@comprange@hyphen@i#1-#2&{% - \ifblank{#1#2} - {\expandafter\blx@range@out@value - \expandafter{\blx@tempb\bibrangedash}} - {\notblank{#1} - {\ifdefempty\blx@tempb - {\blx@range@out@value{\bibrangedash#1}} - {\expandafter\blx@comprange@check - \expandafter{\blx@tempb}{#1}}} - {\blx@comprange@hyphen@i#2&}}} - -\def\blx@comprange@check#1#2{% - \blx@imc@ifinteger{#1} - {\blx@imc@ifinteger{#2} - {\blx@comprange@comp{#1}{#2}} - {\blx@range@out@value{#1\bibrangedash#2}}} - {\blx@range@out@value{#1\bibrangedash#2}}} - -\def\blx@comprange@comp#1#2{% - \def\blx@tempb{#1}% - \def\blx@tempc{#2}% - \let\blx@tempd\blx@tempc - \ifnum\c@maxcomprange<\abx@rangeproclimit\relax - \numdef\blx@tempe\abx@rangeproclimit - \else - \numdef\blx@tempe\c@maxcomprange - \fi - \blx@tempcntc=\blx@tempe\relax - \ifnum - \ifnum\c@mincompwidth<1\space1\fi - \ifnum\c@maxcomprange<10\space1\fi - \ifnum\c@mincomprange<\blx@tempb\space\else1\fi - \ifnum\blx@tempb<\numexpr\blx@tempcntc*10\relax\else1\fi - 0=\z@ - \expandafter\blx@comprange@comp@div - \else - \expandafter\blx@comprange@end - \fi} - -\def\blx@comprange@end{% - \numdef\blx@tempb\blx@tempb - \ifnum\blx@tempe>\c@maxcomprange\relax - \numdef\blx@tempc\blx@tempc - \else - \numdef\blx@tempc\blx@tempd - \fi - \edef\blx@tempb{\blx@range@out@value{\blx@tempb\noexpand\bibrangedash\blx@tempc}}% - \blx@tempb} - -\def\blx@comprange@comp@div{% - \unless\ifnum\blx@tempb<\blx@tempcntc - \blx@tempcnta\blx@tempb\relax - \blx@tempcntb\blx@tempc\relax - \divide\blx@tempcnta\blx@tempcntc - \divide\blx@tempcntb\blx@tempcntc - \ifnum\blx@tempcnta=\blx@tempcntb - \edef\blx@tempd{\expandafter\@gobble\blx@tempd}% - \numdef\blx@tempe\blx@tempcntc - \fi - \fi - \divide\blx@tempcntc10\relax - \ifnum - \ifnum\blx@tempcntc<10 1\fi - \ifnum\blx@tempcntc>\c@mincompwidth\else 1\fi - 0=\z@ - \expandafter\blx@comprange@comp@div - \else - \expandafter\blx@comprange@end - \fi} - -\def\blx@range@chunk#1{% - \blx@range@chunk@semcol#1;&} - -\def\blx@range@chunk@semcol#1;#2&{% - \notblank{#1} - {\blx@range@chunk@comma#1,&} - {}% - \notblank{#2} - {\notblank{#1}{\blx@range@out@delim{;\space}}{}% - \blx@range@chunk@semcol#2&} - {}} - -\def\blx@range@chunk@comma#1,#2&{% - \notblank{#1} - {\expandafter\blx@range@split - \expandafter{\@firstofone#1}} - {}% - \notblank{#2} - {\notblank{#1}{\blx@range@out@delim{,\space}}{}% - \blx@range@chunk@comma#2&} - {}} - -% <*>[]{} - -\newrobustcmd*{\mkfirstpage}{% - \begingroup - \@ifstar - {\blx@firstpage\blx@firstpage@ii} - {\blx@firstpage\blx@firstpage@i}} - -\def\blx@firstpage#1{% - \@ifnextchar[{#1}{#1[\@firstofone]}} - -\def\blx@firstpage@i[#1]#2{% - \let\blx@tempa\@empty - \protected\def\blx@range@out@value{\appto\blx@tempa}% - \let\blx@range@out@delim\blx@range@out@value - \let\blx@range@split\blx@firstpage@split - \blx@range@chunk{#2}% - \edef\blx@tempa{\endgroup - \unexpanded{#1}{\expandonce\blx@tempa}}% - \blx@tempa} - -\def\blx@firstpage@ii[#1]#2{% - \protected\def\blx@range@out@value{#1}% - \let\blx@range@out@delim\@firstofone - \let\blx@range@split\blx@firstpage@split - \blx@range@chunk{#2}% - \endgroup} - -\def\blx@firstpage@split#1{% - \def\blx@firstpage@abort{\blx@range@out@value{#1}}% - \blx@firstpage@range#1\bibrangedash\bibrangedash&} - -\def\blx@firstpage@range#1\bibrangedash#2\bibrangedash#3&{% - \ifblank{#3} - {\blx@firstpage@hyphen#1--&} - {\ifblank{#1} - {\blx@range@out@value{\bibrangedash#2}} - {\blx@range@out@value{#1}}}} - -\def\blx@firstpage@hyphen#1-#2-#3&{% - \ifblank{#3} - {\blx@firstpage@abort} - {\ifblank{#1} - {\ifblank{#2} - {\blx@firstpage@hyphen@i#3&} - {\blx@range@out@value{\bibrangedash#2}}} - {\blx@range@out@value{#1}}}} - -\def\blx@firstpage@hyphen@i#1-#2&{% - \ifblank{#1} - {\ifblank{#2} - {\blx@firstpage@abort} - {\blx@firstpage@hyphen@i#2&}} - {\blx@range@out@value{\bibrangedash#1}}} - -\newcommand*{\ppspace}{\addnbspace} -\newcommand*{\sqspace}{\addnbspace} - -\newrobustcmd*{\RN}[1]{% - \begingroup - \expandafter\RNfont - \expandafter{\romannumeral#1}% - \endgroup} -\newrobustcmd*{\Rn}[1]{% - \begingroup - \expandafter\Rnfont - \expandafter{\romannumeral#1}% - \endgroup} - -\newcommand*{\RNfont}{\uppercase} -\newcommand*{\Rnfont}{} - -% {}{} - -\protected\def\blx@imc@usedriver#1#2{% - \begingroup - \let\finentry\blx@finentry@usedrv - \let\newblock\relax - \let\abx@macro@bibindex\@empty - \let\abx@macro@pageref\@empty - \csuse{blx@hook@bbxinit}#1% - \blx@beglangbib - \blx@driver{#2}% - \blx@endlangbib - \endgroup} - -% Punctuation - -\protected\def\blx@initunit{% - \global\togglefalse{blx@block}% - \global\togglefalse{blx@unit}% - \global\togglefalse{blx@insert}% - \global\togglefalse{blx@lastins}% - \global\togglefalse{blx@keepunit}% - \global\let\blx@unitpunct\newunitpunct - \blx@imc@resetpunctfont} - -\def\blx@begunit{% - \toggletrue{blx@tempa}% - \iftoggle{blx@insert} - {\iftoggle{blx@unit} - {\begingroup - \let\blx@begunit\@empty - \let\blx@endunit\@empty - \let\blx@endnounit\@empty - \blx@unitpunct\blx@postpunct - \endgroup - \global\togglefalse{blx@unit}% - \togglefalse{blx@tempa}} - {\blx@postpunct}% - \iftoggle{blx@block} - {\begingroup - \let\blx@begunit\@empty - \let\blx@endunit\@empty - \let\blx@endnounit\@empty - \newblockpunct - \endgroup - \global\togglefalse{blx@block}% - \togglefalse{blx@tempa}} - {}} - {}% - \blx@postpunct - \blx@imc@resetpunctfont - \iftoggle{blx@tempa} - {} - {\global\togglefalse{blx@insert}}% - \blx@leavevmode - \begingroup} - -\def\blx@endunit{% - \endgroup - \global\toggletrue{blx@insert}% - \global\toggletrue{blx@lastins}} - -\def\blx@nounit{% - \global\togglefalse{blx@lastins}} - -\def\blx@endnounit{% - \endgroup\blx@nounit} - -\protected\def\blx@imc@newblock{% - \global\toggletrue{blx@block}}% - -\protected\def\blx@imc@newunit{% - \iftoggle{blx@keepunit} - {} - {\global\let\blx@unitpunct\newunitpunct - \global\toggletrue{blx@unit}}} - -\protected\def\blx@imc@setunit{% - \@ifstar\blx@setunit@i\blx@setunit} - -\long\def\blx@setunit#1{% - \iftoggle{blx@keepunit} - {} - {\long\gdef\blx@unitpunct{#1}% - \global\toggletrue{blx@unit}}} - -\def\blx@setunit@i{% - \iftoggle{blx@lastins} - {\blx@setunit} - {\@gobble}} - -\protected\def\blx@imc@printunit{% - \@ifstar\blx@printunit@i\blx@printunit} - -\def\blx@printunit#1{% - \long\gdef\blx@unitpunct{#1\global\togglefalse{blx@keepunit}}% - \global\toggletrue{blx@keepunit}% - \global\toggletrue{blx@unit}} - -\def\blx@printunit@i{% - \iftoggle{blx@lastins} - {\blx@printunit} - {\@gobble}} - -\protected\def\blx@imc@finentry{% - \unspace\finentrypunct - \blx@postpunct - \blx@initunit} - -\protected\def\blx@finentry@usedrv{% - \blx@setunit\relax} - -\protected\def\blx@finentry@inset{% - \blx@setunit\entrysetpunct - \global\toggletrue{blx@block}} - -\blx@regimcs{% - \ifdriver \thefield \strfield \csfield \usefield \thelist \thename - \clearfield \clearlist \clearname \restorefield \restorelist \restorename - \ifcategory \ifentrycategory \ifkeyword \ifentrykeyword - \ifciteseen \ifentryseen \ifentryinbib \ifciteibid \ifciteidem \ifopcit \ifloccit - \ifcurrentfield \ifcurrentlist \ifcurrentname \ifentrytype - \iffieldequalcs \iffieldequals \iffieldequalstr \iffieldsequal - \ifbibmacroundef \iffieldundef \iffieldxref \iflistequalcs \iflistequals - \iflistsequal \iflistundef \iflistxref - \ifmorenames \ifmoreitems \iffirstcitekey \iflastcitekey - \ifnameequalcs \ifnameequals \ifnamesequal \ifnameundef \ifnamexref - \iffirstonpage \ifsamepage \savefield \savefieldcs \savelist - \savelistcs \savename \savenamecs \usedriver - \ifinteger \ifnumeral \ifnumerals \ifpages - \iffieldint \iffieldnum \iffieldnums \iffieldpages - \mkpageprefix \mkpagetotal \mkpagefirst - \newblock \newunit \setunit \printunit \finentry} - -\appto\blx@blxinit{% - \def\ifnatbibmode{\iftoggle{blx@natbib}}% - \def\ifcitation{\iftoggle{blx@citation}}% - \def\ifbibliography{\iftoggle{blx@bibliography}}% - \def\ifciteindex{\iftoggle{blx@citeindex}}% - \def\ifbibindex{\iftoggle{blx@bibindex}}% - \def\iffootnote{\iftoggle{blx@footnote}}% - \def\ifuseprefix{\iftoggle{blx@useprefix}}% - \def\ifuseauthor{\iftoggle{blx@useauthor}}% - \def\ifuseeditor{\iftoggle{blx@useeditor}}% - \def\ifusetranslator{\iftoggle{blx@usetranslator}}% - \def\ifterseinits{\iftoggle{blx@terseinits}}% - \def\iffirstinits{\iftoggle{blx@firstinits}}% - \def\ifsingletitle{\iftoggle{abx@bool@singletitle}}% - \def\ifandothers#1{\iftoggle{abx@bool@more#1}}% - \protected\def\pno{\bibstring{page}}% - \protected\def\ppno{\bibstring{pages}}% - \let\nopp\relax - \protected\def\psq{\sqspace\bibstring{sequens}}% - \protected\def\psqq{\sqspace\bibstring{sequentes}}} - -% Make sure that commands which might pop up inside an \edef will be defined -% as something. If they are taken \AtBeginDocument then we assume that all will -% be well. If not, then provide a definition which will give an error outside -% of a citation context. -\AtBeginDocument{% - \protected\def\do#1{% - \ifdefined#1% - \else - \protected\def#1{\ERROR}% - \fi - }% - \docsvlist{\pno,\ppno,\nopp,\psq,\psqq}% -} - -%% Global formatting hooks - -% capitalization - -% {} - -\newrobustcmd{\MakeCapital}[1]{% - \begingroup - \blx@mkcp@init - \protected@edef\blx@tempa{#1}% - \expandafter\blx@mkcp@parse\blx@tempa\@empty\blx@mkcp@end} - -\def\blx@mkcp@init{% - \def\blx@mkcp@iec{\noexpand\blx@mkcp@iec\noexpand}% - \def\blx@mkcp@bbl{\noexpand\blx@mkcp@bbl\noexpand}% - \def\blx@mkcp@sgl{\noexpand\blx@mkcp@sgl\noexpand}% - \def\blx@mkcp@dbl{\noexpand\blx@mkcp@dbl\noexpand}% - \def\do##1{\def##1{\blx@mkcp@sgl##1}}\abx@dosingleaccents - \def\do##1{\def##1{\blx@mkcp@dbl##1}}\abx@dodoubleaccents - \def\IeC##1{\blx@mkcp@iec\IeC{##1}}% - \def\@tabacckludge##1{% - \expandafter\blx@mkcp@sgl\csname\string##1\endcsname}} - -\begingroup -\catcode`\"=\active -\gappto\blx@mkcp@init{% - \ifnum\catcode`\"=\active - \def"#1{\blx@mkcp@bbl"\noexpand#1}% - \fi} -\endgroup - -\def\blx@mkcp@parse{% - \futurelet\@let@token\blx@mkcp@eval} - -\long\def\blx@mkcp@eval{% - \ifx\@let@token\blx@mkcp@iec - \expandafter\blx@mkcp@getiec - \fi - \ifx\@let@token\blx@mkcp@bbl - \expandafter\blx@mkcp@gettwo - \fi - \ifx\@let@token\blx@mkcp@sgl - \expandafter\blx@mkcp@gettwo - \fi - \ifx\@let@token\blx@mkcp@dbl - \expandafter\blx@mkcp@getthree - \fi - \blx@mkcp@case} - -\def\blx@mkcp@getiec#1\blx@mkcp@case#2#3#4{% - \blx@mkcp@case{#2#3{#4}}} - -\def\blx@mkcp@gettwo#1\blx@mkcp@case#2#3#4{% - \blx@mkcp@case{#2#3#4}} - -\def\blx@mkcp@getthree#1\blx@mkcp@case#2#3#4#5{% - \blx@mkcp@case{#2#3#4#5}} - -\long\def\blx@mkcp@case#1{% - \begingroup - \def\i{I}\def\j{J}% - \def\do##1##2{\let##1##2\do}% - \expandafter\do\@uclclist\relax{\relax\@gobble}% - \uppercase{\protected@edef\blx@tempa{\endgroup\blx@mkcp@end#1}}% - \blx@tempa} - -\protected\long\def\blx@mkcp@end#1\blx@mkcp@end{% - \let\blx@mkcp@iec\noexpand - \let\blx@mkcp@bbl\noexpand - \let\blx@mkcp@sgl\noexpand - \let\blx@mkcp@dbl\noexpand - \protected@edef\blx@tempa{\endgroup#1}% - \blx@tempa} - -\def\abx@dosingleaccents{% - \do\"\do\'\do\`\do\^\do\~\do\=\do\.% - \do\H\do\b\do\c\do\d\do\r\do\u\do\v} -\def\abx@dodoubleaccents{% - \do\t} - -% {} - -\newrobustcmd*{\MakeSentenceCase}{% - \@ifstar\blx@mksc@i\blx@mksc@ii} - -\def\blx@mksc@i{% - \ifdef\abx@field@langid - {\xifinlist\abx@field@langid\blx@cmksc@lang - {\blx@mksc@ii} - {\@firstofone}} - {\blx@mksc@ii}} - -\long\def\blx@mksc@ii#1{% - \begingroup - \let\blx@tempa\@empty - \let\blx@tempb\@empty - \blx@mksc@init - \protected@edef\@tempa{#1}% - \expandafter\blx@mksc@parse\@tempa\blx@mksc@end} - -\def\blx@mksc@init{% - \blx@mkcp@init - \def\blx@mkcp@nil{\noexpand\blx@mkcp@nil\noexpand}% - \def\i{\blx@mkcp@nil\i}\def\j{\blx@mkcp@nil\j}% - \def\do##1{% - \ifx##1\relax - \else - \def##1{\blx@mkcp@nil##1}% - \expandafter\do - \fi}% - \expandafter\do\@uclclist\relax} - -\def\blx@mksc@parse{% - \futurelet\@let@token\blx@mksc@eval} - -\def\blx@mksc@eval{% - \ifx\@let@token\blx@mksc@end - \expandafter\blx@mksc@end - \fi - \ifx\@let@token\bgroup - \expandafter\blx@mksc@group - \fi - \ifx\@let@token\@sptoken - \expandafter\blx@mksc@space - \fi - \ifx\@let@token\blx@mkcp@nil - \expandafter\blx@mksc@getone - \fi - \ifx\@let@token\blx@mkcp@iec - \expandafter\blx@mksc@getiec - \fi - \ifx\@let@token\blx@mkcp@bbl - \expandafter\blx@mksc@gettwo - \fi - \ifx\@let@token\blx@mkcp@sgl - \expandafter\blx@mksc@gettwo - \fi - \ifx\@let@token\blx@mkcp@dbl - \expandafter\blx@mksc@getthree - \fi - \if\noexpand\@let@token\relax - \expandafter\blx@mksc@cs - \fi - \blx@mksc@other} - -\def\blx@mksc@end#1\blx@mksc@end{% - \blx@mksc@eject - \let\blx@mkcp@nil\noexpand - \let\blx@mkcp@iec\noexpand - \let\blx@mkcp@bbl\noexpand - \let\blx@mkcp@sgl\noexpand - \let\blx@mkcp@dbl\noexpand - \let\MakeUppercase\relax - \let\MakeLowercase\relax - \protected@edef\blx@tempa{\endgroup\blx@tempa}% - \blx@tempa} - -\long\def\blx@mksc@group#1\blx@mksc@other#2{% - \futurelet\@let@token\blx@mksc@ingroup#2&{#2}% - \blx@mksc@endhead - \blx@mksc@parse} - -\long\def\blx@mksc@ingroup#1{% - \if\noexpand\@let@token\relax - \blx@mksc@locase{{#2}}% - \else - \blx@mksc@nocase{{#2}}% - \fi} - -\def\blx@mksc@space{\def\blx@mksc@space##1\blx@mksc@other} -\csuse{blx@mksc@space} {% - \blx@mksc@anycase{ }% - \blx@mksc@endhead - \blx@mksc@parse} - -\long\def\blx@mksc@cs#1\blx@mksc@other#2{% - \ifcat\noexpand~\noexpand#2% - \blx@mksc@locase{#2}% - \else - \blx@mksc@nocase{#2}% - \fi - \blx@mksc@endhead - \blx@mksc@parse} - -\def\blx@mksc@getiec#1\blx@mksc@other#2#3#4{% - \blx@mksc@other{#2#3{#4}}} - -\def\blx@mksc@getone#1\blx@mksc@other#2#3{% - \blx@mksc@other{#2#3}} - -\def\blx@mksc@gettwo#1\blx@mksc@other#2#3#4{% - \blx@mksc@other{#2#3#4}} - -\def\blx@mksc@getthree#1\blx@mksc@other#2#3#4#5{% - \blx@mksc@other{#2#3#4#5}} - -\long\def\blx@mksc@other#1{% - \blx@mksc@locase{#1}% - \blx@mksc@endhead - \blx@mksc@parse} - -\def\blx@mksc@locase{% - \appto\blx@tempb} - -\def\blx@mksc@nocase{% - \blx@mksc@eject - \appto\blx@tempa} - -\def\blx@mksc@anycase{% - \ifx\blx@tempb\@empty - \expandafter\appto - \expandafter\blx@tempa - \else - \expandafter\appto - \expandafter\blx@tempb - \fi} - -\def\blx@mksc@eject{% - \ifx\blx@tempb\@empty - \else - \eappto\blx@tempa{\noexpand\MakeLowercase{\expandonce\blx@tempb}}% - \let\blx@tempb\@empty - \fi} - -\def\blx@mksc@endhead{% - \ifx\blx@tempb\@empty - \else - \eappto\blx@tempa{\noexpand\MakeCapital{\expandonce\blx@tempb}}% - \let\blx@tempb\@empty - \fi - \let\blx@mksc@endhead\relax} - -% {} - -\newrobustcmd*{\DeclareCaseLangs}{% - \@ifstar - {\blx@defcaselangs} - {\global\let\blx@cmksc@lang\@empty - \blx@defcaselangs}} - -\def\blx@defcaselangs#1{% - \ifblank{#1} - {} - {\forcsvlist{\listgadd\blx@cmksc@lang}{#1}}} - -\DeclareCaseLangs{% - american,british,canadian, - english,USenglish,UKenglish, - australian,newzealand} - -%% Main formatting commands - -% []{}{} - -\newrobustcmd*{\DeclareNameFormat}{% - \@ifstar - {\blx@defformat\blx@defnameformat{nfd}*} - {\blx@defformat\blx@defnameformat{nfd}{}}} -\newrobustcmd*{\DeclareIndexNameFormat}{% - \@ifstar - {\blx@defformat\blx@defnameformat{nid}*} - {\blx@defformat\blx@defnameformat{nid}{}}} - -\newrobustcmd*{\DeclareListFormat}{% - \@ifstar - {\blx@defformat\blx@defplainformat{lfd}*} - {\blx@defformat\blx@defplainformat{lfd}{}}} -\newrobustcmd*{\DeclareIndexListFormat}{% - \@ifstar - {\blx@defformat\blx@defplainformat{lid}*} - {\blx@defformat\blx@defplainformat{lid}{}}} - -\newrobustcmd*{\DeclareFieldFormat}{% - \@ifstar - {\blx@defformat\blx@defplainformat{ffd}*} - {\blx@defformat\blx@defplainformat{ffd}{}}} -\newrobustcmd*{\DeclareIndexFieldFormat}{% - \@ifstar - {\blx@defformat\blx@defplainformat{fid}*} - {\blx@defformat\blx@defplainformat{fid}{}}} - -% {}{}{<*>} - -\def\blx@defformat#1#2#3{% - \@ifnextchar[%] - {\blx@defformat@i{#1}{#2}{#3}} - {\blx@defformat@i{#1}{#2}{#3}[*]}} - -% {}{}{<*>}[]{} - -\def\blx@defformat@i#1#2#3[#4]#5{% - \notblank{#3} - {\blx@resetformat{#2}{#5}} - {}% - \def\blx@defformat@a{#2}% - \def\blx@defformat@b{#4}% - \blx@xsanitizeafter{\def\blx@defformat@c}{#5}% - \afterassignment\blx@defformat@ii - #1} - -\def\blx@defformat@ii{% - \expandafter\forcsvlist - \expandafter\blx@defformat@iii - \expandafter{\blx@defformat@b}} - -\def\blx@defformat@iii#1{% - \cslet{abx@\blx@defformat@a @#1@\blx@defformat@c}\blx@defformat@d} - -\def\blx@defplainformat{% - \long\def\blx@defformat@d##1} - -\def\blx@defnameformat{% - \long\def\blx@defformat@d##1##2##3##4##5##6##7##8} - -\def\blx@resetformat#1#2{% - \let\blx@saved@do\do - \def\do##1{\blx@resetformat@i{#1}{#2}{##1}}% - \blx@safe@actives - \abx@dotypes - \blx@rest@actives - \let\do\blx@saved@do} - -\def\blx@resetformat@i#1#2#3{% - \ifcsdef{abx@#1@#3@#2} - {\csundef{abx@#1@#3@#2}} - {}} - -% {}{} - -\def\blx@letformat#1#2{% - \blx@safe@actives - \afterassignment\blx@rest@actives - \csletcs{#1}{#2}} - -% [aliastype]{aliasname}[formattype]{formatname} - -\def\blx@defalias#1{% - \@ifnextchar[%] - {\blx@defalias@i{#1}} - {\blx@defalias@i{#1}[*]}} -\def\blx@defalias@i#1[#2]#3{% - \@ifnextchar[%] - {\blx@defalias@ii{#1}{#2}{#3}} - {\blx@defalias@ii{#1}{#2}{#3}[*]}} -\def\blx@defalias@ii#1#2#3[#4]#5{% - \blx@safe@actives - \afterassignment\blx@rest@actives - \csedef{abx@#1@#2@#3}{% - \expandonce{\csname abx@#1@#4@#5\endcsname}}} - -% {}{}{}{} - -\def\blx@getformat#1#2#3#4{% - \blx@safe@actives - \afterassignment\blx@rest@actives - \ifcsundef{abx@#2@\blx@imc@thefield{entrytype}@#3} - {\ifcsundef{abx@#2@*@#3} - {\ifcsundef{abx@#2@\blx@imc@thefield{entrytype}@#4} - {\ifcsundef{abx@#2@*@#4} - {\letcs#1{abx@#2@*@default}} - {\letcs#1{abx@#2@*@#4}}} - {\letcs#1{abx@#2@\blx@imc@thefield{entrytype}@#4}}} - {\letcs#1{abx@#2@*@#3}}} - {\letcs#1{abx@#2@\blx@imc@thefield{entrytype}@#3}}} - -% []{} - -\newrobustcmd*{\savefieldformat}[2][*]{\blx@save{abx@ffd@#1@#2}} -\newrobustcmd*{\savelistformat}[2][*]{\blx@save{abx@lfd@#1@#2}} -\newrobustcmd*{\savenameformat}[2][*]{\blx@save{abx@nfd@#1@#2}} - -\newrobustcmd*{\restorefieldformat}[2][*]{\blx@restore{abx@ffd@#1@#2}} -\newrobustcmd*{\restorelistformat}[2][*]{\blx@restore{abx@lfd@#1@#2}} -\newrobustcmd*{\restorenameformat}[2][*]{\blx@restore{abx@nfd@#1@#2}} - -% []{}{}{} - -\newrobustcmd*{\iffieldformatundef}[2][*]{\ifcsundef{abx@ffd@#1@#2}} -\newrobustcmd*{\iflistformatundef}[2][*]{\ifcsundef{abx@lfd@#1@#2}} -\newrobustcmd*{\ifnameformatundef}[2][*]{\ifcsundef{abx@nfd@#1@#2}} - -% []{}[]{} - -\newrobustcmd*{\DeclareNameAlias}{\blx@defalias{nfd}} -\newrobustcmd*{\DeclareIndexNameAlias}{\blx@defalias{nid}} - -\newrobustcmd*{\DeclareListAlias}{\blx@defalias{lfd}} -\newrobustcmd*{\DeclareIndexListAlias}{\blx@defalias{lid}} - -\newrobustcmd*{\DeclareFieldAlias}{\blx@defalias{ffd}} -\newrobustcmd*{\DeclareIndexFieldAlias}{\blx@defalias{fid}} - -% []{} - -\newrobustcmd{\blx@imc@printtext}[2][]{% - \ifblank{#2} - {\blx@nounit} - {\ifblank{#1} - {\let\blx@theformat\@firstofone} - {\blx@getformat\blx@theformat{ffd}{#1}{}}% - \ifdefvoid\blx@theformat - {\blx@nounit} - {\blx@begunit - \blx@theformat{#2}% - \blx@endunit}}} - -% []{} - -\newrobustcmd*{\blx@imc@printfield}[2][]{% - \blx@imc@iffieldundef{#2} - {\blx@nounit} - {\blx@getformat\blx@theformat{ffd}{#1}{#2}% - \ifdefvoid\blx@theformat - {\blx@nounit} - {\blx@begunit - \def\currentfield{#2}% - \expandafter\expandafter - \expandafter\blx@theformat - \expandafter\expandafter - \expandafter{\csname abx@field@#2\endcsname}% - \blx@endunit}}} - -% []{} - -\newcommand*{\blx@imc@indexfield}[2][]{% - \blx@imc@iffieldundef{#2} - {} - {\blx@getformat\blx@theformat{fid}{#1}{#2}% - \ifdefvoid\blx@theformat - {} - {\begingroup - \def\currentfield{#2}% - \letcs\blx@tempa{abx@field@#2}% - \expandafter\blx@theformat\expandafter{\blx@tempa}% - \endgroup}}} - -% []{} - -\newrobustcmd*{\blx@imc@printfile}[2][]{% - \iftoggle{blx@loadfiles} - {\IfFileExists{#2} - {\listxadd\blx@list@req@edit{#2}% - \blx@imc@printtext[#1]{\input{#2}\unspace}} - {\blx@nounit}} - {\blx@nounit}} - -% {}[][-] -% => {}{}{} - -\def\blx@listargs#1{% - \@ifnextchar[%] - {\blx@listargs@i{#1}} - {#1{}{}{}}} - -\def\blx@listargs@i#1[#2]{% - \@ifnextchar[%] - {\blx@listargs@ii{#1}{#2}} - {#1{#2}{}{}}} - -\def\blx@listargs@ii#1#2[#3]{% - \blx@listargs@iii{#1}{#2}#3&} - -\def\blx@listargs@iii#1#2#3-#4&{% - #1{#2}{#3}{#4}} - -% [][-]{} - -\protected\def\blx@imc@printnames{% - \blx@listargs\blx@printnames} - -% {}{}{}{} - -\def\blx@printnames#1#2#3#4{% - \blx@imc@ifnameundef{#4} - {\blx@nounit} - {\blx@getformat\blx@theformat{nfd}{#1}{#4}% - \ifdefvoid\blx@theformat - {\blx@nounit} - {\blx@begunit - \blx@namesetup{#2}{#3}{#4}% - \expandafter\blx@nameparser\blx@thedata{}&% - \blx@endunit}}} - -\def\blx@namesetup#1#2#3{% - \def\currentname{#3}% - \c@listcount\@ne - \c@listtotal\csname c@#3\endcsname - \blx@namesetup@i{#3}% - \ifblank{#1} - {\c@liststart\@ne} - {\ifnum#1<\@ne - \c@liststart\@ne - \else - \c@liststart#1\relax - \fi}% - \ifblank{#2} - {\c@liststop\c@listtotal - \ifnum\c@liststop>\c@maxnames - \c@liststop\c@minnames - \ifnum\c@uniquelist>\c@liststop - \c@liststop\c@uniquelist - \fi - \fi} - {\ifnum#2>\c@listtotal - \c@liststop\c@listtotal - \else - \ifnum#2<\@ne - \c@liststop\@ne - \else - \c@liststop#2\relax - \fi - \fi}% - \ifnumequal\blx@backend\blx@backend@biber - {} - {\let~\bibnamedelima}% BibTeX only - \blx@namecodes} - -\def\blx@namesetup@i#1{% - \expandafter\expandafter - \expandafter\blx@namesetup@ii\csname abx@name@#1\endcsname} - -\def\blx@namesetup@ii#1#2{% - \c@uniquelist\z@ - \ifblank{#1} - {} - {\setkeys{blx@opt@name}{#1}}% - \def\blx@thedata{#2}} - -\define@key{blx@opt@name}{uniquelist}{\c@uniquelist#1\relax} -\define@key{blx@opt@name}{uniquename}{\c@uniquename#1\relax} -\define@key{blx@opt@name}{hash}{\edef\abx@field@hash{\detokenize{#1}}} - -\newrobustcmd*{\bibinitperiod}{\adddot} -\newrobustcmd*{\bibinitdelim}{\addnbspace} -\newrobustcmd*{\bibinithyphendelim}{.\mbox{-}} -\newrobustcmd*{\bibnamedelima}{\addhighpenspace} -\newrobustcmd*{\bibnamedelimb}{\addlowpenspace} -\newrobustcmd*{\bibnamedelimc}{\addhighpenspace} -\newrobustcmd*{\bibnamedelimd}{\addlowpenspace} -\newrobustcmd*{\bibnamedelimi}{\addnbspace} - -% [][-]{} - -\protected\def\blx@imc@indexnames{% - \blx@listargs\blx@indexnames} - -% {}{}{}{} - -\def\blx@indexnames#1#2#3#4{% - \blx@imc@ifnameundef{#4} - {} - {\blx@getformat\blx@theformat{nid}{#1}{#4}% - \ifdefvoid\blx@theformat - {} - {\begingroup - \blx@namesetup{#2}{#3}{#4}% - \blx@indexnamesetup - \expandafter\blx@nameparser\blx@thedata{}&% - \endgroup}}} - -\def\blx@indexnamesetup{% - \let\bibinitperiod\bibindexinitperiod - \let\bibinitdelim\bibindexinitdelim - \let\bibinithyphendelim\bibindexinithyphendelim - \let\bibnamedelima\bibindexnamedelima - \let\bibnamedelimb\bibindexnamedelimb - \let\bibnamedelimc\bibindexnamedelimc - \let\bibnamedelimd\bibindexnamedelimd - \let\bibnamedelimi\bibindexnamedelimi} - -% {}{}{...} - -\long\def\blx@nameparser#1{% - \ifblank{#1} - {\blx@namebreak} - {\ifnum\c@listcount<\c@liststart - \else - \blx@nameparser@i#1% - \fi - \advance\c@listcount\@ne - \ifnum\c@listcount>\c@liststop - \expandafter\blx@namebreak - \fi - \blx@nameparser}} - -\long\def\blx@nameparser@i#1{% - \ifblank{#1} - {} - {\setkeys{blx@opt@name}{#1}}% - \blx@theformat} - -\long\def\blx@namebreak#1&{} - -% [][-]{} - -\protected\def\blx@imc@printlist{% - \blx@listargs\blx@printlist} - -% {}{}{}{} - -\def\blx@printlist#1#2#3#4{% - \blx@imc@iflistundef{#4} - {\blx@nounit} - {\blx@getformat\blx@theformat{lfd}{#1}{#4}% - \ifdefvoid\blx@theformat - {\blx@nounit} - {\blx@begunit - \blx@listsetup{#2}{#3}{#4}% - \expandafter\blx@listparser\blx@thedata{}&% - \blx@endunit}}} - -\def\blx@listsetup#1#2#3{% - \def\currentlist{#3}% - \c@listcount\@ne - \expandafter\c@listtotal\csname c@#3\endcsname - \letcs\blx@thedata{abx@list@#3}% - \ifblank{#1} - {\c@liststart\@ne} - {\ifnum#1<\@ne - \c@liststart\@ne - \else - \c@liststart#1\relax - \fi}% - \ifblank{#2} - {\c@liststop\c@listtotal - \ifnum\c@listtotal>\c@maxitems - \c@liststop\c@minitems - \fi} - {\ifnum#2>\c@listtotal - \c@liststop\c@listtotal - \else - \ifnum#2<\@ne - \c@liststop\@ne - \else - \c@liststop#2\relax - \fi - \fi}} - -% [][-]{} - -\protected\def\blx@imc@indexlist{% - \blx@listargs\blx@indexlist} - -% {}{}{}{} - -\def\blx@indexlist#1#2#3#4{% - \blx@imc@iflistundef{#4} - {} - {\blx@getformat\blx@theformat{lid}{#1}{#4}% - \ifdefvoid\blx@theformat - {} - {\begingroup - \blx@listsetup{#2}{#3}{#4}% - \expandafter\blx@listparser\blx@thedata{}&% - \endgroup}}} - -% {}{}{...} - -\long\def\blx@listparser#1{% - \ifblank{#1} - {\blx@listbreak} - {\ifnum\c@listcount<\c@liststart - \else - \blx@theformat{#1}% - \fi - \advance\c@listcount\@ne - \ifnum\c@listcount>\c@liststop - \expandafter\blx@listbreak - \fi - \blx@listparser}} - -\long\def\blx@listbreak#1&{} - -% <*>{}{} - -\protected\def\blx@imc@entrydata{% - \@ifstar - {\blx@xsanitizeafter{\blx@imc@entrydata@i\blx@saveentry}} - {\blx@xsanitizeafter{\blx@imc@entrydata@i{}}}} - -\long\def\blx@imc@entrydata@i#1#2#3{% - \blx@ifdata{#2} - {\begingroup - #1% - \blx@resetdata - \blx@getdata{#2}% - \blx@entrysetcount - \blx@setoptions@type\abx@field@entrytype - \blx@setoptions@entry - \addtocounter{instcount}\@ne - \blx@execute - \blx@beglangbib#3\blx@endlangbib - \endgroup} - {}} - -\protected\def\blx@imc@entryset#1#2{% - \blx@imc@iffieldundef{entrykey} - {} - {\begingroup - \long\def\blx@entryset@precode{#1}% - \long\def\blx@entryset@postcode{#2}% - \let\finentry\blx@finentry@inset - \let\do\blx@entryset - \blx@imc@docsvfield{entryset}% - \endgroup}} - -\def\blx@entryset#1{% - \blx@ifdata{#1} - {\begingroup - \blx@imc@clearlist{pageref}% - \blx@getdata{#1}% - \blx@setoptions@type\abx@field@entrytype - \def\abx@field@entrysetcount{1}% - \blx@entryset@precode - \blx@driver{\blx@imc@thefield{entrytype}}% - \blx@entryset@postcode - \endgroup} - {}% - \let\do\blx@entryset@i} - -\def\blx@entryset@i#1{% - \blx@ifdata{#1} - {\begingroup - \blx@resetdata - \blx@getdata{#1}% - \blx@entrysetcount - \blx@setoptions@type\abx@field@entrytype - \blx@setoptions@entry - \addtocounter{instcount}\@ne - \blx@execute - \blx@beglangbib - \blx@begunit - \blx@entryset@precode - \blx@driver{\blx@imc@thefield{entrytype}} - \blx@entryset@postcode - \blx@endunit - \blx@endlangbib - \endgroup} - {\blx@nounit}} - -\blx@regimcs{% - \printtext \printfield \printlist \printnames \printfile - \indexfield \indexlist \indexnames \entrydata \entryset} - -%% Localization - -% []{} - -\newrobustcmd*{\blx@imc@bibstring}[2][\@firstofone]{% - \blx@bibstring{#1}{\abx@str}{#2}} - -\newrobustcmd*{\blx@imc@biblstring}[2][\@firstofone]{% - \blx@bibstring{#1}{abx@lstr}{#2}} - -\newrobustcmd*{\blx@imc@bibsstring}[2][\@firstofone]{% - \blx@bibstring{#1}{abx@sstr}{#2}} - -\protected\def\blx@bibstring#1#2#3{% - \blx@begunit - \blx@hyphenreset - \let\bibstring\blx@imc@bibxstring - \let\biblstring\blx@imc@bibxlstring - \let\bibsstring\blx@imc@bibxsstring - \lowercase{\edef\blx@tempa{#3}}% - \ifcsundef{#2@\blx@tempa} - {\blx@warn@nostring\blx@tempa - \blx@endnounit} - {\blx@imc@ifcapital - {#1{\MakeCapital{\csuse{#2@\blx@tempa}}}} - {#1{\csuse{#2@\blx@tempa}}}% - \blx@endunit}} - -% []{} - -\newrobustcmd*{\blx@imc@bibcpstring}[2][\@firstofone]{% - \blx@bibcpstring{#1}{\abx@str}{#2}} - -\newrobustcmd*{\blx@imc@bibcplstring}[2][\@firstofone]{% - \blx@bibcpstring{#1}{abx@lstr}{#2}} - -\newrobustcmd*{\blx@imc@bibcpsstring}[2][\@firstofone]{% - \blx@bibcpstring{#1}{abx@sstr}{#2}} - -\protected\def\blx@bibcpstring#1#2#3{% - \blx@begunit - \blx@hyphenreset - \let\bibstring\blx@imc@bibxstring - \let\biblstring\blx@imc@bibxlstring - \let\bibsstring\blx@imc@bibxsstring - \lowercase{\edef\blx@tempa{#3}}% - \ifcsundef{#2@\blx@tempa} - {\blx@warn@nostring\blx@tempa - \blx@endnounit} - {#1{\MakeCapital{\csuse{#2@\blx@tempa}}}% - \blx@endunit}} - -% []{} - -\newrobustcmd*{\blx@imc@biblcstring}[2][\@firstofone]{% - \blx@biblcstring{#1}{\abx@str}{#2}} - -\newrobustcmd*{\blx@imc@biblclstring}[2][\@firstofone]{% - \blx@biblcstring{#1}{abx@lstr}{#2}} - -\newrobustcmd*{\blx@imc@biblcsstring}[2][\@firstofone]{% - \blx@biblcstring{#1}{abx@sstr}{#2}} - -\protected\def\blx@biblcstring#1#2#3{% - \blx@begunit - \blx@hyphenreset - \let\bibstring\blx@imc@bibxstring - \let\biblstring\blx@imc@bibxlstring - \let\bibsstring\blx@imc@bibxsstring - \lowercase{\edef\blx@tempa{#3}}% - \ifcsundef{#2@\blx@tempa} - {\blx@warn@nostring\blx@tempa - \blx@endnounit} - {#1{\MakeLowercase{\csuse{#2@\blx@tempa}}}% - \blx@endunit}} - -% []{} - -\newrobustcmd*{\blx@imc@bibucstring}[2][\@firstofone]{% - \blx@bibucstring{#1}{\abx@str}{#2}} - -\newrobustcmd*{\blx@imc@bibuclstring}[2][\@firstofone]{% - \blx@bibucstring{#1}{abx@lstr}{#2}} - -\newrobustcmd*{\blx@imc@bibucsstring}[2][\@firstofone]{% - \blx@bibucstring{#1}{abx@sstr}{#2}} - -\protected\def\blx@bibucstring#1#2#3{% - \blx@begunit - \blx@hyphenreset - \let\bibstring\blx@imc@bibxstring - \let\biblstring\blx@imc@bibxlstring - \let\bibsstring\blx@imc@bibxsstring - \lowercase{\edef\blx@tempa{#3}}% - \ifcsundef{#2@\blx@tempa} - {\blx@warn@nostring\blx@tempa - \blx@endnounit} - {#1{\MakeUppercase{\csuse{#2@\blx@tempa}}}% - \blx@endunit}} - -% {} - -\def\blx@imc@bibxstring#1{% - \blx@bibxstring{\abx@str}{#1}} - -\def\blx@imc@bibxlstring#1{% - \blx@bibxstring{abx@lstr}{#1}} - -\def\blx@imc@bibxsstring#1{% - \blx@bibxstring{abx@sstr}{#1}} - -\def\blx@bibxstring#1#2{% - \ifcsundef{#1@#2} - {\protect\blx@warn@nostring{#2}} - {\csuse{#1@#2}}} - -% {}{}{} - -\def\blx@imc@ifbibstring#1{% - \ifcsundef{\abx@str @\detokenize{#1}} - {\@secondoftwo} - {\@firstoftwo}} - -\def\blx@imc@ifbibxstring#1{% - \blx@xsanitizeafter\ifcsundef{\abx@str @#1} - {\@secondoftwo} - {\@firstoftwo}} - -% {}{}{} - -\def\blx@imc@iffieldbibstring#1{% - \blx@imc@iffieldundef{#1} - {\@secondoftwo} - {\ifcsundef{\abx@str @\detokenize\expandafter - \expandafter\expandafter{% - \csname abx@field@#1\endcsname}} - {\@secondoftwo} - {\@firstoftwo}}} - -\blx@regimcs{% - \bibstring \biblstring \bibsstring - \bibxstring \bibxlstring \bibxsstring - \bibcpstring \bibcplstring \bibcpsstring - \biblcstring \biblclstring \biblcsstring - \bibucstring \bibuclstring \bibucsstring - \ifbibstring \ifbibxstring \iffieldbibstring} - -\let\blx@hook@uc\relax -\let\blx@hook@lc\relax - -\AtEndPreamble{% - \toggletrue{blx@tempa}% - \toggletrue{blx@tempb}% - \expandafter\patchcmd\csname MakeUppercase \endcsname - {\protected@edef} - {\blx@hook@uc\protected@edef} - {\togglefalse{blx@tempa}} - {}% - \expandafter\patchcmd\csname MakeLowercase \endcsname - {\protected@edef} - {\blx@hook@lc\protected@edef} - {\togglefalse{blx@tempb}} - {}% - \@ifpackageloaded{textcase} - {\expandafter\patchcmd\csname MakeUppercase \endcsname - {\def\i} - {\blx@hook@uc\def\i} - {\togglefalse{blx@tempa}} - {}% - \expandafter\patchcmd\csname MakeLowercase \endcsname - {\@uclcnotmath{}} - {\@uclcnotmath{\blx@hook@lc}} - {\togglefalse{blx@tempb}} - {}% - \expandafter\patchcmd\csname MakeTextUppercase \endcsname - {\def\i} - {\blx@hook@uc\def\i} - {} - {}% - \expandafter\patchcmd\csname MakeTextLowercase \endcsname - {\@uclcnotmath{}} - {\@uclcnotmath{\blx@hook@lc}} - {} - {}} - {}% - \iftoggle{blx@tempa}{\blx@err@patch{\string\MakeUppercase}}{}% - \iftoggle{blx@tempb}{\blx@err@patch{\string\MakeLowercase}}{}% -} - -\appto\blx@blxinit{% - \def\blx@hook@uc{% - \def\bibstring{\blx@imc@bibucstring}% - \def\biblstring{\blx@imc@bibuclstring}% - \def\bibsstring{\blx@imc@bibucsstring}% - \def\biblcstring{\blx@imc@bibucstring}% - \def\biblclstring{\blx@imc@bibuclstring}% - \def\biblcsstring{\blx@imc@bibucsstring}% - \def\bibcpstring{\blx@imc@bibucstring}% - \def\bibcplstring{\blx@imc@bibuclstring}% - \def\bibcpsstring{\blx@imc@bibucsstring}}% - \def\blx@hook@lc{% - \def\bibstring{\blx@imc@biblcstring}% - \def\biblstring{\blx@imc@biblclstring}% - \def\bibsstring{\blx@imc@biblcsstring}% - \def\bibucstring{\blx@imc@biblcstring}% - \def\bibuclstring{\blx@imc@biblclstring}% - \def\bibucsstring{\blx@imc@biblcsstring}% - \def\bibcpstring{\blx@imc@biblcstring}% - \def\bibcplstring{\blx@imc@biblclstring}% - \def\bibcpsstring{\blx@imc@biblcsstring}}} - -\def\abx@dostrings{% - \do{bibliography}% - \do{references}% - \do{shorthands}% - \do{editor}% - \do{editors}% - \do{compiler}% - \do{compilers}% - \do{redactor}% - \do{redactors}% - \do{reviser}% - \do{revisers}% - \do{founder}% - \do{founders}% - \do{continuator}% - \do{continuators}% - \do{collaborator}% - \do{collaborators}% - \do{translator}% - \do{translators}% - \do{commentator}% - \do{commentators}% - \do{annotator}% - \do{annotators}% - \do{commentary}% - \do{annotations}% - \do{introduction}% - \do{foreword}% - \do{afterword}% - \do{editortr}% - \do{editorstr}% - \do{editorco}% - \do{editorsco}% - \do{editoran}% - \do{editorsan}% - \do{editorin}% - \do{editorsin}% - \do{editorfo}% - \do{editorsfo}% - \do{editoraf}% - \do{editorsaf}% - \do{editortrco}% - \do{editorstrco}% - \do{editortran}% - \do{editorstran}% - \do{editortrin}% - \do{editorstrin}% - \do{editortrfo}% - \do{editorstrfo}% - \do{editortraf}% - \do{editorstraf}% - \do{editorcoin}% - \do{editorscoin}% - \do{editorcofo}% - \do{editorscofo}% - \do{editorcoaf}% - \do{editorscoaf}% - \do{editoranin}% - \do{editorsanin}% - \do{editoranfo}% - \do{editorsanfo}% - \do{editoranaf}% - \do{editorsanaf}% - \do{editortrcoin}% - \do{editorstrcoin}% - \do{editortrcofo}% - \do{editorstrcofo}% - \do{editortrcoaf}% - \do{editorstrcoaf}% - \do{editortranin}% - \do{editorstranin}% - \do{editortranfo}% - \do{editorstranfo}% - \do{editortranaf}% - \do{editorstranaf}% - \do{translatorco}% - \do{translatorsco}% - \do{translatoran}% - \do{translatorsan}% - \do{translatorin}% - \do{translatorsin}% - \do{translatorfo}% - \do{translatorsfo}% - \do{translatoraf}% - \do{translatorsaf}% - \do{translatorcoin}% - \do{translatorscoin}% - \do{translatorcofo}% - \do{translatorscofo}% - \do{translatorcoaf}% - \do{translatorscoaf}% - \do{translatoranin}% - \do{translatorsanin}% - \do{translatoranfo}% - \do{translatorsanfo}% - \do{translatoranaf}% - \do{translatorsanaf}% - \do{byauthor}% - \do{byeditor}% - \do{byeditor}% - \do{bycompiler}% - \do{byredactor}% - \do{byreviser}% - \do{byreviewer}% - \do{byfounder}% - \do{bycontinuator}% - \do{bycollaborator}% - \do{bytranslator}% - \do{bycommentator}% - \do{byannotator}% - \do{withcommentator}% - \do{withannotator}% - \do{withintroduction}% - \do{withforeword}% - \do{withafterword}% - \do{byeditortr}% - \do{byeditorco}% - \do{byeditoran}% - \do{byeditorin}% - \do{byeditorfo}% - \do{byeditoraf}% - \do{byeditortrco}% - \do{byeditortran}% - \do{byeditortrin}% - \do{byeditortrfo}% - \do{byeditortraf}% - \do{byeditorcoin}% - \do{byeditorcofo}% - \do{byeditorcoaf}% - \do{byeditoranin}% - \do{byeditoranfo}% - \do{byeditoranaf}% - \do{byeditortrcoin}% - \do{byeditortrcofo}% - \do{byeditortrcoaf}% - \do{byeditortranin}% - \do{byeditortranfo}% - \do{byeditortranaf}% - \do{bytranslatorco}% - \do{bytranslatoran}% - \do{bytranslatorin}% - \do{bytranslatorfo}% - \do{bytranslatoraf}% - \do{bytranslatorcoin}% - \do{bytranslatorcofo}% - \do{bytranslatorcoaf}% - \do{bytranslatoranin}% - \do{bytranslatoranfo}% - \do{bytranslatoranaf}% - \do{and}% - \do{andothers}% - \do{andmore}% - \do{volume}% - \do{volumes}% - \do{involumes}% - \do{part}% - \do{jourvol}% - \do{jourser}% - \do{newseries}% - \do{oldseries}% - \do{edition}% - \do{reprint}% - \do{reprintof}% - \do{reprintas}% - \do{reprintfrom}% - \do{reviewof}% - \do{translationof}% - \do{translationas}% - \do{translationfrom}% - \do{origpubas}% - \do{origpubin}% - \do{astitle}% - \do{bypublisher}% - \do{page}% - \do{pages}% - \do{column}% - \do{columns}% - \do{line}% - \do{lines}% - \do{nodate}% - \do{verse}% - \do{verses}% - \do{section}% - \do{sections}% - \do{paragraph}% - \do{paragraphs}% - \do{in}% - \do{inseries}% - \do{ofseries}% - \do{book}% - \do{issue}% - \do{number}% - \do{chapter}% - \do{mathesis}% - \do{phdthesis}% - \do{candthesis}% - \do{resreport}% - \do{techreport}% - \do{software}% - \do{datacd}% - \do{audiocd}% - \do{version}% - \do{url}% - \do{urlfrom}% - \do{urlseen}% - \do{file}% - \do{inpreparation}% - \do{submitted}% - \do{inpress}% - \do{prepublished}% - \do{forthcoming}% - \do{library}% - \do{abstract}% - \do{annotation}% - \do{citedas}% - \do{seenote}% - \do{quotedin}% - \do{opcit}% - \do{loccit}% - \do{ibidem}% - \do{idem}% - \do{idemsf}% - \do{idemsm}% - \do{idemsn}% - \do{idempf}% - \do{idempm}% - \do{idempn}% - \do{idempp}% - \do{confer}% - \do{sequens}% - \do{sequentes}% - \do{passim}% - \do{see}% - \do{seealso}% - \do{backrefpage}% - \do{backrefpages}% - \do{thiscite}% - \do{january}% - \do{february}% - \do{march}% - \do{april}% - \do{may}% - \do{june}% - \do{july}% - \do{august}% - \do{september}% - \do{october}% - \do{november}% - \do{december}% - \do{langamerican}% - \do{langbrazilian}% - \do{langcatalan}% - \do{langcroatian}% - \do{langczech}% - \do{langdanish}% - \do{langdutch}% - \do{langenglish}% - \do{langfinnish}% - \do{langfrench}% - \do{langgerman}% - \do{langgreek}% - \do{langitalian}% - \do{langjapanese}% - \do{langlatin}% - \do{langnorwegian}% - \do{langpolish}% - \do{langportuguese}% - \do{langrussian}% - \do{langslovene}% - \do{langspanish}% - \do{langswedish}% - \do{fromamerican}% - \do{frombrazilian}% - \do{fromcatalan}% - \do{fromcroatian}% - \do{fromczech}% - \do{fromdanish}% - \do{fromdutch}% - \do{fromenglish}% - \do{fromfinnish}% - \do{fromfrench}% - \do{fromgerman}% - \do{fromgreek}% - \do{fromitalian}% - \do{fromjapanese}% - \do{fromlatin}% - \do{fromnorwegian}% - \do{frompolish}% - \do{fromportuguese}% - \do{fromrussian}% - \do{fromslovene}% - \do{fromspanish}% - \do{fromswedish}% - \do{countryde}% - \do{countryep}% - \do{countryeu}% - \do{countryfr}% - \do{countryuk}% - \do{countryus}% - \do{patent}% - \do{patentde}% - \do{patenteu}% - \do{patentfr}% - \do{patentuk}% - \do{patentus}% - \do{patreq}% - \do{patreqde}% - \do{patreqeu}% - \do{patreqfr}% - \do{patrequk}% - \do{patrequs}% -} - -\newrobustcmd*{\NewBibliographyString}[1]{% - \forcsvlist\blx@newstring{#1}} - -\def\blx@newstring#1{% - \ifcsundef{KV@blx@lbx@#1} - {\gappto\abx@dostrings{\do{#1}}% - \csgdef{KV@blx@lbx@#1}##1{\blx@defstring{#1}{##1}}} - {}} - -% in *.cbx/bbx/tex: = {}, -% in *.lbx: = {{}{}}, - -\def\do#1{\define@key{blx@lbx}{#1}{\blx@defstring{#1}{##1}}} -\abx@dostrings - -% in *.cbx/bbx/tex: (implicit) -% in *.lbx: inherit = {}, - -\define@key{blx@lbx}{inherit}{% - \blx@lbxinput{#1}{}{\blx@err@nolang{#1}}% - \csuse{abx@strings@#1}} - -\def\blx@cfg@defstring#1#2{% - \csdef{abx@lstr@#1}{#2}% - \csdef{abx@sstr@#1}{#2}} - -\def\blx@lbx@defstring#1#2{% - \blx@lbx@defstring@i{#1}#2} -\def\blx@lbx@defstring@i#1#2#3{% - \csdef{abx@lstr@#1}{#2}% - \csdef{abx@sstr@#1}{#3}} - -% {} - -\def\blx@lbxcheck#1{% - \ifcsdef{blx@lng@#1} - {\expandafter\expandafter\expandafter\IfFileExists - \expandafter\expandafter\expandafter{% - \csname blx@lng@#1\endcsname.lbx} - {} - {\blx@err@nolang{#1}}} - {\IfFileExists{#1.lbx} - {} - {\blx@err@nolang{#1}}}} - -% {}{} - -\newrobustcmd*{\DefineBibliographyExtras}[2]{% - \blx@lbxcheck{#1}% - \csgappto{blx@hook@extras@#1}{% - \blx@defbibextras{#1}{#2}}} -\@onlypreamble\DefineBibliographyExtras - -\newrobustcmd*{\UndefineBibliographyExtras}[2]{% - \blx@lbxcheck{#1}% - \csgappto{blx@hook@noextras@#1}{% - \blx@undefbibextras{#1}{#2}}} -\@onlypreamble\UndefineBibliographyExtras - -\def\blx@defbibextras#1{\csgappto{abx@extras@#1}} -\def\blx@undefbibextras#1{\csgappto{abx@noextras@#1}} - -% {}{} - -\def\blx@letbibextras#1#2{% - \blx@lbxinput{#2}{}{\blx@err@nolang{#2}}% - \global\csletcs{abx@extras@#1}{abx@extras@#2} - \global\csletcs{abx@noextras@#1}{abx@noextras@#2}}% - -% {}{} - -\newrobustcmd*{\DefineBibliographyStrings}[2]{% - \blx@lbxcheck{#1}% - \csgappto{blx@hook@strings@#1}{% - \begingroup - \let\blx@defstring\blx@cfg@defstring - \blx@defbibstrings{#1}{#2}% - \endgroup}} -\@onlypreamble\DefineBibliographyStrings - -\def\blx@defbibstrings#1#2{% - \def\do##1{\csundef{abx@lstr@##1}\csundef{abx@sstr@##1}}% - \abx@dostrings - \csuse{abx@strings@#1}% - \setkeys{blx@lbx}{#2}% - \let\do\blx@defbibstrings@i - \csxdef{abx@strings@#1}{\abx@dostrings}% - \csgappto{abx@strings@#1}{% - \ifcsdef{\abx@str @bibliography} - {\letcs\bibname{\abx@str @bibliography}} - {\let\bibname\@empty}% - \ifcsdef{\abx@str @references} - {\letcs\refname{\abx@str @references}} - {\let\refname\@empty}% - \ifcsdef{\abx@str @shorthands} - {\letcs\biblistname{\abx@str @shorthands}} - {\let\biblistname\@empty}}} - -\def\blx@defbibstrings@i#1{% - \ifcsdef{abx@lstr@#1} - {\def\expandafter\noexpand\csname abx@lstr@#1\endcsname{% - \csexpandonce{abx@lstr@#1}}} - {\undef\expandafter\noexpand\csname abx@lstr@#1\endcsname}% - \ifcsdef{abx@sstr@#1} - {\def\expandafter\noexpand\csname abx@sstr@#1\endcsname{% - \csexpandonce{abx@sstr@#1}}} - {\undef\expandafter\noexpand\csname abx@sstr@#1\endcsname}} - -% {}{} - -\def\blx@letbibstrings#1#2{% - \blx@lbxinput{#2}{}{\blx@err@nolang{#2}}% - \global\csletcs{abx@strings@#1}{abx@strings@#2}}% - -% {}{} - -\newrobustcmd*{\DefineHyphenationExceptions}[2]{% - \ifcsundef{l@#1} - {\blx@warn@nohyph{#1}} - {}% - \csgappto{blx@hook@hyph@#1}{\blx@hyphexcept{#1}{#2}}} -\@onlypreamble\DefineHyphenationExceptions - -\def\blx@hyphexcept#1#2{% - \ifcsundef{l@#1} - {\blx@warn@nohyph{#1}} - {\begingroup - \language\csname l@#1\endcsname\relax - \hyphenation{#2}% - \endgroup}} - -% {}{} - -\newrobustcmd*{\DeclareLanguageMapping}[2]{% - \csgdef{blx@lng@#1}{#2}} -\@onlypreamble\DeclareLanguageMapping - -% {}{}{} - -\def\blx@lbxinput#1{% - \ifcsdef{blx@lng@#1} - {\expandafter\expandafter\expandafter\blx@lbxinput@i - \expandafter\expandafter\expandafter{% - \csname blx@lng@#1\endcsname}{#1}} - {\blx@lbxinput@ii{#1}{#1}{language '#1'}}} - -% {}{} - -\def\blx@lbxinput@i#1#2{% - \global\csundef{blx@lng@#2}% - \IfFileExists{#1.lbx} - {\blx@lbxinput@ii{#2}{#1}{language '#2' -> '#1'}} - {\blx@warning@noline{% - File '#1.lbx' not found!\MessageBreak - Ignoring mapping '#2' -> '#1'}% - \blx@lbxinput{#2}}} - -% {}{}{} - -\def\blx@lbxinput@ii#1#2#3{% - \begingroup - \setbox\@tempboxa=\hbox\bgroup - \aftergroup\endgroup - \blx@inputonce{#2.lbx}{#3} - {\global\cslet{abx@strings@#1}\@empty - \global\cslet{abx@extras@#1}\@empty - \global\cslet{abx@noextras@#1}\@empty - \blx@maplang{#1}{#1}% - \def\InheritBibliographyStrings{% - \blx@letbibstrings{#1}}% - \def\DeclareBibliographyStrings####1{% - \begingroup - \let\blx@defstring\blx@lbx@defstring - \blx@defbibstrings{#1}{####1}% - \endgroup}% - \def\InheritBibliographyExtras{\blx@letbibextras{#1}}% - \def\DeclareBibliographyExtras{\blx@defbibextras{#1}}% - \def\UndeclareBibliographyExtras{\blx@undefbibextras{#1}}% - \def\DeclareHyphenationExceptions{\blx@hyphexcept{#1}}% - \begingroup - \blx@saneccodes - \makeatletter} - {\endgroup - \csuse{blx@hook@strings@#1}% - \csuse{blx@hook@strings@#2}% - \csuse{blx@hook@extras@#1}% - \csuse{blx@hook@extras@#2}% - \csuse{blx@hook@noextras@#1}% - \csuse{blx@hook@noextras@#2}% - \csuse{blx@hook@hyph@#1}% - \csuse{blx@hook@hyph@#2}} - {\aftergroup\@firstoftwo} - {\aftergroup\@secondoftwo}% - \egroup} - -% {} - -\def\blx@langsetup#1{% - \blx@lbxinput{#1} - {\edef\blx@languagename{#1}} - {\blx@warning - {Language '#1' not supported.\MessageBreak - Using fallback language '\blx@languagename'}% - \blx@lbxinput{\blx@languagename} - {\blx@maplang{#1}{\blx@languagename}} - {\blx@err@nolang{\blx@languagename}}}} - -% auxiliary macros - -% {} - -\newrobustcmd*{\mkbibrangeshort}{% - \mkbibrangefull{short}} - -\newrobustcmd*{\mkbibrangelong}{% - \mkbibrangefull{long}} - -\newrobustcmd*{\mkbibrangeterse}{% - \mkbibrangetrunc{short}} - -\newrobustcmd*{\mkbibrangecomp}{% - \mkbibrangetrunc{long}} - -\newrobustcmd*{\mkbibrangeshortextra}{% - \mkbibrangefullextra{short}} - -\newrobustcmd*{\mkbibrangelongextra}{% - \mkbibrangefullextra{long}} - -\newrobustcmd*{\mkbibrangeterseextra}{% - \mkbibrangetruncextra{short}} - -\newrobustcmd*{\mkbibrangecompextra}{% - \mkbibrangetruncextra{long}} - -% {}{} - -\newrobustcmd*{\mkbibrangefull}[2]{% - \iffieldundef{#2year} - {} - {\printtext[#2date]{% - \csuse{mkbibdate#1}{#2year}{#2month}{#2day}% - \iffieldundef{#2endyear} - {} - {\iffieldequalstr{#2endyear}{} - {\mbox{\bibdatedash}} - {\bibdatedash - \csuse{mkbibdate#1}{#2endyear}{#2endmonth}{#2endday}}}}}} - -\newrobustcmd*{\mkbibrangetrunc}[2]{% - \iffieldundef{#2year} - {} - {\printtext[#2date]{% - \iffieldsequal{#2year}{#2endyear} - {\iffieldsequal{#2month}{#2endmonth} - {\csuse{mkbibdate#1}{}{}{#2day}} - {\csuse{mkbibdate#1}{}{#2month}{#2day}}} - {\csuse{mkbibdate#1}{#2year}{#2month}{#2day}}% - \iffieldundef{#2endyear} - {} - {\iffieldequalstr{#2endyear}{} - {\mbox{\bibdatedash}} - {\bibdatedash - \csuse{mkbibdate#1}{#2endyear}{#2endmonth}{#2endday}}}}}} - -\newrobustcmd*{\mkbibrangefullextra}[2]{% - \iffieldundef{#2year} - {} - {\printtext[#2date]{% - \printtext{% - \csuse{mkbibdate#1}{#2year}{#2month}{#2day}}% - \iffieldundef{#2endyear} - {\printfield{extrayear}} - {\iffieldequalstr{#2endyear}{} - {\printfield{extrayear}% - \printtext{\mbox{\bibdatedash}}} - {\printtext{% - \bibdatedash - \csuse{mkbibdate#1}{#2endyear}{#2endmonth}{#2endday}% - \printfield{extrayear}}}}}}} - -\newrobustcmd*{\mkbibrangetruncextra}[2]{% - \iffieldundef{#2year} - {} - {\printtext[#2date]{% - \printtext{% - \iffieldsequal{#2year}{#2endyear} - {\iffieldsequal{#2month}{#2endmonth} - {\csuse{mkbibdate#1}{}{}{#2day}} - {\csuse{mkbibdate#1}{}{#2month}{#2day}}} - {\csuse{mkbibdate#1}{#2year}{#2month}{#2day}}}% - \iffieldundef{#2endyear} - {\printfield{extrayear}} - {\iffieldequalstr{#2endyear}{} - {\printfield{extrayear}% - \printtext{\mbox{\bibdatedash}}} - {\printtext{% - \bibdatedash - \csuse{mkbibdate#1}{#2endyear}{#2endmonth}{#2endday}% - \printfield{extrayear}}}}}}} - -\newrobustcmd*{\mkbibrangeyear}[1]{% - \blx@imc@clearfield{#1month}% - \blx@imc@clearfield{#1day}% - \blx@imc@clearfield{#1endmonth}% - \blx@imc@clearfield{#1endday}% - \iffieldsequal{#1year}{#1endyear} - {\blx@imc@clearfield{#1endyear}} - {}% - \mkbibrangefull{short}{#1}} - -\newrobustcmd*{\mkbibrangeyearextra}[1]{% - \blx@imc@clearfield{#1month}% - \blx@imc@clearfield{#1day}% - \blx@imc@clearfield{#1endmonth}% - \blx@imc@clearfield{#1endday}% - \iffieldsequal{#1year}{#1endyear} - {\blx@imc@clearfield{#1endyear}} - {}% - \mkbibrangefullextra{short}{#1}} - -\expandafter\newrobustcmd -\expandafter*\csname mkbibrangeiso8601\endcsname[1]{% - \iffieldundef{#1year} - {} - {\printtext[#1date]{% - \blx@isodate{#1year}{#1month}{#1day}% - \iffieldundef{#1endyear} - {} - {\addslash\blx@isodate{#1endyear}{#1endmonth}{#1endday}}}}} - -\expandafter\newrobustcmd -\expandafter*\csname mkbibrangeiso8601extra\endcsname[1]{% - \iffieldundef{#1year} - {} - {\printtext[#1date]{% - \blx@isodate[extrayear]{#1year}{#1month}{#1day}% - \iffieldundef{#1endyear} - {} - {\addslash\blx@isodate{#1endyear}{#1endmonth}{#1endday}}}}} - -\newrobustcmd*{\blx@isodate}[4][]{% - \thefield{#2}\ifblank{#1}{}{\printfield{#1}}% - \iffieldundef{#3}{}{\mbox{-}\thefield{#3}}% - \iffieldundef{#4}{}{\mbox{-}\thefield{#4}}} - -\newrobustcmd*{\mkbibdatelong}[3]{} -\newrobustcmd*{\mkbibdateshort}[3]{} -\newrobustcmd*{\bibrangedash}{\textendash} -\newrobustcmd*{\bibdatedash}{\bibrangedash} -\newrobustcmd*{\finalandcomma}{} -\newrobustcmd*{\finalandsemicolon}{} -\newrobustcmd*{\mkbibordinal}[1]{#1} -\newrobustcmd*{\mkbibmascord}{\mkbibordinal} -\newrobustcmd*{\mkbibfemord}{\mkbibordinal} -\newrobustcmd*{\mkbibneutord}{\mkbibordinal} -\newrobustcmd*{\mkbibmonth}[1]{% - \ifcase0#1\relax - \blx@warning@entry{Month out of range or not an integer}% - \or\abx@bibmonth{january}% - \or\abx@bibmonth{february}% - \or\abx@bibmonth{march}% - \or\abx@bibmonth{april}% - \or\abx@bibmonth{may}% - \or\abx@bibmonth{june}% - \or\abx@bibmonth{july}% - \or\abx@bibmonth{august}% - \or\abx@bibmonth{september}% - \or\abx@bibmonth{october}% - \or\abx@bibmonth{november}% - \or\abx@bibmonth{december}% - \else - \blx@warning@entry{Month out of range}#1% - \fi} - -\protected\def\blx@imc@printdate{} -\protected\def\blx@imc@printdateextra{} -\protected\def\blx@imc@printdatelabel{} -\protected\def\blx@imc@printdateextralabel{} -\protected\def\blx@imc@printurldate{} -\protected\def\blx@imc@printeventdate{} -\protected\def\blx@imc@printorigdate{} - -\let\blx@imc@mkdatezeros\@firstofone -\protected\def\blx@imc@stripzeros#1{% - \begingroup - \setbox\@tempboxa=\hbox\bgroup - \aftergroup\endgroup - \abx@hook@xsanitize - \if0#1\relax - \expandafter\@firstoftwo - \else - \expandafter\@secondoftwo - \fi - {\@tempcnta#1\relax - \expandafter\egroup - \number\@tempcnta - \@tempcnta#1\relax} - {\egroup#1}} - -\blx@regimcs{% - \printdate \printdateextra \printdatelabel \printdateextralabel - \printurldate \printeventdate \printorigdate \stripzeros \mkdatezeros} - -% {}{} - -\def\blx@maplang#1#2{% - \csxappto{extras#1}{% - \noexpand\blx@resetpunct - \expandafter\noexpand\csname abx@extras@#2\endcsname - \expandafter\noexpand\csname abx@strings@#2\endcsname}% - \csxappto{noextras#1}{% - \noexpand\blx@resetpunct - \expandafter\noexpand\csname abx@noextras@#2\endcsname}} - -%% babel/polyglossia interface -\def\blx@beglang{\blx@clearlang\begingroup} -\def\blx@endlang{\endgroup} -\let\blx@beglangbib\blx@beglang -\let\blx@endlangbib\blx@endlang -\let\blx@beglangcite\blx@beglang -\let\blx@endlangcite\blx@endlang -\let\blx@hook@endlang\@empty -\let\blx@hook@initlang\@empty -\let\blx@imc@mainlang\@empty -\def\blx@hyphenreset{% - \ifcsundef{l@\blx@languagename} - {} - {\language\csname l@\blx@languagename\endcsname\relax}% - \ifcsundef{\blx@languagename hyphenmins} - {\blx@sethyphenmins\tw@\thr@@} - {\expandafter\expandafter\expandafter\blx@sethyphenmins - \csname\blx@languagename hyphenmins\endcsname}} -\def\blx@sethyphenmins#1#2{% - \lefthyphenmin#1\relax - \righthyphenmin#2\relax} - -\begingroup -\@makeother\# -\gdef\blx@mkautolangbabel{% - \pretocmd\select@language{\blx@langsetup{#1}} - {\ifdef\blx@thelangenv - {\def\blx@beglang{% - \blx@clearlang - \begingroup - \blx@imc@iffieldundef{langid} - {} - {\ifcsundef{l@\abx@field@langid} - {\blx@warn@nohyph{\abx@field@langid}} - {\blx@hook@initlang - \def\blx@endlang{% - \blx@hook@endlang - \csname end\blx@thelangenv\endcsname - \endgroup}% - \iftoggle{blx@autolangbib} - {\let\blx@endlangbib\blx@endlang} - {}% - \iftoggle{blx@autolangcite} - {\let\blx@endlangcite\blx@endlang} - {}% - \csname\blx@thelangenv\expandafter\endcsname - \expandafter{\abx@field@langid}}}}} - {}% - \def\blx@langstrings{}% - \def\blx@imc@mainlang{\select@language{\bbl@main@language}}% - \blx@langsetup\bbl@main@language} - {\blx@err@patch{'babel' package}% - \blx@mknoautolang}} - -\gdef\blx@mkautolangpoly{% - \catcode`\_=11% polyglossia uses "_" as a letter - \pretocmd\select@language{\blx@langsetup{#1}} - {\ifdef\blx@thelangenv - {\def\blx@beglang{% - \blx@clearlang - \begingroup - \blx@imc@iffieldundef{langid} - {} - {\ifcsundef{l@\abx@field@langid} - {\blx@warn@nohyph{\abx@field@langid}} - {\blx@hook@initlang - \def\blx@endlang{% - \blx@hook@endlang - \csname end\blx@thelangenv\endcsname - \endgroup}% - \iftoggle{blx@autolangbib} - {\let\blx@endlangbib\blx@endlang} - {}% - \iftoggle{blx@autolangcite} - {\let\blx@endlangcite\blx@endlang} - {}% - \ifcsstring{blx@thelangenv}{langname} - {\ifdef\abx@field@langidopts - {\csname\abx@field@langid\expandafter\endcsname\expandafter[\abx@field@langidopts]} - {\csname\abx@field@langid\endcsname}} - {\csname\blx@thelangenv\expandafter\endcsname - \expandafter{\abx@field@langid}}% - % These lines are equal to \blx@maplang - \blx@resetpunct - \csuse{abx@extras@\abx@field@langid}% - \csuse{abx@strings@\abx@field@langid}}}}} - {}% - % polyglossia needs this - it doesn't get the - % strings by automatically set for some reason - \def\blx@langstrings{% - \csuse{abx@extras@\languagename}% - \csuse{abx@strings@\languagename}} - \def\blx@imc@mainlang{\select@language{\bbl@main@language}}% - \blx@langsetup\bbl@main@language} - {\blx@err@patch{'polyglossia' package}% - \blx@mknoautolang}% - \catcode`\_=8} -\endgroup - -\def\blx@mknoautolang{% - \blx@lbxinput{\blx@languagename} - {} - {\blx@err@nolang{\blx@languagename}}} - -\blx@regimcs{\mainlang} - -\newrobustcmd*{\DeclareRedundantLanguages}[2]{% - \begingroup - \ifblank{#2} - {\def\do##1{% - \global\csundef{blx@rlm@##1}% - \global\csundef{blx@rlm@lang##1}}} - {\def\do##1{% - \csxdef{blx@rlm@##1}{#2}% - \csxdef{blx@rlm@lang##1}{#2}}}% - \docsvlist{#1}% - \endgroup} - -\def\blx@clearlang{% - \iftoggle{blx@clearlang} - {\iflistundef{language} - {} - {\ifnumgreater{\value{language}}{1} - {} - {\expandafter\blx@clearlang@i\abx@list@language}}} - {}} - -\def\blx@clearlang@i#1{% - \ifcsdef{blx@rlm@#1} - {\expandafter\expandafter\expandafter\forcsvlist - \expandafter\expandafter\expandafter\blx@clearlang@ii - \expandafter\expandafter\expandafter{% - \csname blx@rlm@#1\endcsname}} - {}} - -\def\blx@clearlang@ii#1{% - \ifdefstring\languagename{#1} - {\clearlist{language}} - {}} - -%% Bibtex data interface - -\def\abx@dotypes{% - \do{set}% - \do{article}% - \do{book}% - \do{mvbook}% - \do{booklet}% - \do{collection}% - \do{mvcollection}% - \do{inbook}% - \do{bookinbook}% - \do{incollection}% - \do{inproceedings}% - \do{manual}% - \do{misc}% - \do{online}% - \do{patent}% - \do{periodical}% - \do{proceedings}% - \do{mvproceedings}% - \do{report}% - \do{suppbook}% - \do{suppcollection}% - \do{suppperiodical}% - \do{thesis}% - \do{unpublished}% - \do{artwork}% - \do{audio}% - \do{commentary}% - \do{image}% - \do{inreference}% - \do{jurisdiction}% - \do{legal}% - \do{legislation}% - \do{letter}% - \do{movie}% - \do{music}% - \do{performance}% - \do{reference}% - \do{mvreference}% - \do{review}% - \do{software}% - \do{standard}% - \do{video}% - \do{customa}% - \do{customb}% - \do{customc}% - \do{customd}% - \do{custome}% - \do{customf}% -} - -\def\abx@donames{% - \do{labelname}% - \do{author}% - \do{shortauthor}% - \do{editor}% - \do{editora}% - \do{editorb}% - \do{editorc}% - \do{shorteditor}% - \do{bookauthor}% - \do{translator}% - \do{annotator}% - \do{commentator}% - \do{introduction}% - \do{foreword}% - \do{afterword}% - \do{holder}% - \do{namea}% - \do{nameb}% - \do{namec}% -} - -\def\abx@dolists{% - \do{institution}% - \do{language}% - \do{location}% - \do{organization}% - \do{origlocation}% - \do{origpublisher}% - \do{pageref}% - \do{publisher}% - \do{lista}% - \do{listb}% - \do{listc}% - \do{listd}% - \do{liste}% - \do{listf}% -} - -\def\abx@dofields{% - \do{crossref}% - \do{xref}% - \do{entrykey}% - \do{childentrykey}% - \do{entrytype}% - \do{entrysubtype}% - \do{entryset}% - \do{entrysetcount}% - \do{related}% - \do{relatedtype}% - \do{relatedstring}% - \do{keywords}% - \do{authortype}% - \do{editortype}% - \do{editoratype}% - \do{editorbtype}% - \do{editorctype}% - \do{nameatype}% - \do{namebtype}% - \do{namectype}% - \do{addendum}% - \do{booktitle}% - \do{booksubtitle}% - \do{booktitleaddon}% - \do{chapter}% - \do{doi}% - \do{edition}% - \do{eid}% - \do{eprint}% - \do{eprinttype}% - \do{eprintclass}% - \do{file}% - \do{gender}% - \do{howpublished}% - \do{indextitle}% - \do{indexsorttitle}% - \do{isan}% - \do{isbn}% - \do{ismn}% - \do{isrn}% - \do{issn}% - \do{issue}% - \do{iswc}% - \do{issuetitle}% - \do{issuesubtitle}% - \do{journaltitle}% - \do{journalsubtitle}% - \do{label}% - \do{labelalpha}% - \do{langid}% - \do{extraalpha}% - \do{labelnumber}% - \do{labeltitle}% - \do{labeldate}% - \do{extrayear}% - \do{library}% - \do{localnumber}% - \do{prefixnumber}% - \do{mainsubtitle}% - \do{maintitle}% - \do{maintitleaddon}% - \do{nameaddon}% - \do{namehash}% - \do{fullhash}% - \do{note}% - \do{number}% - \do{day}% - \do{month}% - \do{year}% - \do{endday}% - \do{endmonth}% - \do{endyear}% - \do{origlanguage}% - \do{origtitle}% - \do{origday}% - \do{origmonth}% - \do{origyear}% - \do{origendday}% - \do{origendmonth}% - \do{origendyear}% - \do{reprinttitle}% - \do{pages}% - \do{pagetotal}% - \do{pagination}% - \do{bookpagination}% - \do{part}% - \do{pubstate}% - \do{series}% - \do{shorthand}% - \do{shorthandintro}% - \do{shortjournal}% - \do{shortseries}% - \do{shorttitle}% - \do{sortinit}% - \do{subtitle}% - \do{title}% - \do{titleaddon}% - \do{eventtitle}% - \do{eventday}% - \do{eventmonth}% - \do{eventyear}% - \do{eventendday}% - \do{eventendmonth}% - \do{eventendyear}% - \do{type}% - \do{url}% - \do{urlday}% - \do{urlmonth}% - \do{urlyear}% - \do{urlendday}% - \do{urlendmonth}% - \do{urlendyear}% - \do{venue}% - \do{version}% - \do{volume}% - \do{volumes}% - \do{abstract}% - \do{annotation}% - \do{usera}% - \do{userb}% - \do{userc}% - \do{userd}% - \do{usere}% - \do{userf}% - \do{verba}% - \do{verbb}% - \do{verbc}% -} - -\def\abx@dobooleans{% - \do{singletitle}% -} - -\def\do#1{% - \newcounter{#1}% - \newcounter{saved#1}% - \csedef{the#1}{\noexpand\the\expandonce{\csname c@#1\endcsname}}% - \csedef{thesaved#1}{\noexpand\the\expandonce{\csname c@saved#1\endcsname}}% - \appto\abx@dobooleans{\do{more#1}}} -\abx@donames -\abx@dolists -\def\do#1{\newtoggle{abx@bool@#1}} -\abx@dobooleans - -\protected\def\blx@resetdata{% - \let\blx@saved@do\do - \let\do\blx@imc@clearname - \abx@donames - \let\do\blx@imc@clearlist - \abx@dolists - \let\do\blx@imc@clearfield - \abx@dofields\do{execute}\do{options}% - \def\do##1{\togglefalse{abx@bool@##1}}% - \abx@dobooleans - \let\do\blx@saved@do - \c@citecounter\z@ - \iftoggle{blx@bibliography} - {\c@maxnames\blx@maxbibnames\relax - \c@minnames\blx@minbibnames\relax} - {\c@maxnames\blx@maxcitenames\relax - \c@minnames\blx@mincitenames\relax}% - \c@maxitems\blx@maxitems\relax - \c@minitems\blx@minitems\relax} - -\protected\def\blx@saveentry{% - \let\blx@saved@do\do - \let\do\blx@savename - \abx@donames - \let\do\blx@savelist - \abx@dolists - \let\do\blx@savefield - \abx@dofields\do{execute}\do{options}% - \let\do\blx@savebool - \abx@dobooleans - \c@savedcitecounter\c@citecounter - \let\do\blx@saved@do} - -\protected\def\blx@savename#1{% - \csletcs{etb@tgl@abx@bool@moresaved#1}{etb@tgl@abx@bool@more#1}% - \csletcs{abx@name@saved#1}{abx@name@#1}% - \csname c@saved#1\endcsname\csname c@#1\endcsname} - -\protected\def\blx@savelist#1{% - \csletcs{etb@tgl@abx@bool@moresaved#1}{etb@tgl@abx@bool@more#1}% - \csletcs{abx@list@saved#1}{abx@list@#1}% - \csname c@saved#1\endcsname\csname c@#1\endcsname} - -\protected\def\blx@savefield#1{% - \csletcs{abx@field@saved#1}{abx@field@#1}} - -\protected\def\blx@savebool#1{% - \csletcs{abx@bool@saved#1}{abx@bool@#1}} - -% {} - -\protected\long\def\blx@bbl@preamble#1{% - \gappto\abx@preamble{#1}} - -% {} - -\protected\def\blx@bbl@warn#1{% - \begingroup - \def\item{\MessageBreak-\space}% - \def\break{\MessageBreak\space\space}% - \edef\blx@tempa{% - \ifnum\blx@backend=\blx@backend@biber - Biber - \else - BibTeX - \fi - reported the following issues% - \ifdef\abx@field@entrykey - {\MessageBreak with '\abx@field@entrykey'} - {}% - :#1}% - \blx@warning@noline{\blx@tempa}% - \endgroup} - -% {}{} - -\newrobustcmd{\DeclareFieldInputHandler}[2]{% - \ifblank{#2} - {\csundef{blx@fih@#1}} - {\long\csdef{blx@fih@#1}##1{#2}}} -\@onlypreamble\DeclareFieldInputHandler - -% {}{} - -\newrobustcmd*{\DeclareListInputHandler}[2]{% - \ifblank{#2} - {\csundef{blx@lih@#1}} - {\csdef{blx@lih@#1}##1{#2}}} -\@onlypreamble\DeclareListInputHandler - -% {}{} - -\newrobustcmd*{\DeclareNameInputHandler}[2]{% - \ifblank{#2} - {\csundef{blx@nih@#1}} - {\csdef{blx@nih@#1}##1{#2}}} -\@onlypreamble\DeclareNameInputHandler - -% {}{}{}{} - -\long\def\blx@bbl@addentryfield#1#2#3#4{% - \csxappto{blx@data@#2@#1}{% - \def\expandafter\noexpand\csname abx@field@#3\endcsname{#4}}} - -% {}{} - -\long\def\blx@bbl@addfield#1#2{% - \csxappto\blx@bbl@data{% - \def\expandafter\noexpand\csname abx@field@#1\endcsname{#2}}} - -\protected\long\def\blx@bbl@fielddef#1#2{% - \def\NewValue{#2}% - \ifcsdef{blx@fih@#1} - {\csname blx@fih@#1\endcsname{#2}% - \ifdefvoid\NewValue} - {\@secondoftwo} - {} - {\blx@bbl@addfield{#1}{\expandonce\NewValue}}} - -\protected\long\def\blx@bbl@fieldedef#1#2{% - \edef\NewValue{#2}% - \ifcsdef{blx@fih@#1} - {\csname blx@fih@#1\expandafter - \endcsname\expandafter{\NewValue}% - \ifdefvoid\NewValue} - {\@secondoftwo} - {} - {\blx@bbl@addfield{#1}{\NewValue}}} - -\protected\long\def\blx@bbl@stringdef#1#2{% - \begingroup - \edef\blx@tempa{\endgroup - \blx@bbl@fielddef{#1}{\detokenize{#2}}}% - \blx@tempa} - -% {} - -\protected\def\blx@bbl@verbdef#1{% - \begingroup - \let\verb\blx@bbl@verbadd - \def\blx@tempa{#1}% - \let\NewValue\@empty} - -\protected\def\blx@bbl@verbend{% - \ifcsdef{blx@fih@\blx@tempa} - {\csname blx@fih@\blx@tempa\expandafter - \endcsname\expandafter{\NewValue}% - \ifdefvoid\NewValue} - {\@secondoftwo} - {} - {\blx@bbl@addfield{\blx@tempa}{\NewValue}}% - \endgroup} - -\protected\def\blx@bbl@verbadd{% - \begingroup - \let\do\@makeother - \dospecials - \catcode\endlinechar=12\relax - \blx@bbl@verbadd@i} - -\begingroup -\catcode`\<=12 -\catcode`\>=12 -\uccode`\<=`\ % -\uccode`\>=\endlinechar -\uppercase{\gdef\blx@bbl@verbadd@i<#1>}{% - \endgroup - \edef\NewValue{\NewValue\detokenize{#1}}} -\endgroup - -% {}{} - -\protected\long\def\blx@bbl@cntdef#1#2{% - \csxappto\blx@bbl@data{% - \csname c@#1\endcsname#2\relax}} - -% {} - -\protected\def\blx@bbl@booltrue#1{% - \csgappto\blx@bbl@data{% - \toggletrue{abx@bool@#1}}} - -\protected\def\blx@bbl@boolfalse#1{% - \csgappto\blx@bbl@data{% - \togglefalse{abx@bool@#1}}} - -% {}{} - -\protected\def\blx@bbl@listdef#1#2#3{% - \def\NewCount{#2}% - \def\NewValue{#3}% - \ifcsdef{blx@lih@#1} - {\csname blx@lih@#1\endcsname{#3}% - \ifdefvoid\NewValue} - {\@secondoftwo} - {} - {\csxappto\blx@bbl@data{% - \csname c@#1\endcsname\NewCount\relax - \def\expandafter\noexpand\csname abx@list@#1\endcsname - {\expandonce\NewValue}}}} - - -% {}{}{} - -\protected\def\blx@bbl@namedef#1#2#3#4{% - \def\NewCount{#2}% - \def\NewOption{#3}% - \def\NewValue{#4}% - \ifcsdef{blx@nih@#1} - {\csname blx@nih@#1\endcsname{#4}% - \ifdefvoid\NewValue} - {\@secondoftwo} - {} - {\csxappto\blx@bbl@data{% - \csname c@#1\endcsname\NewCount\relax - \def\expandafter\noexpand\csname abx@name@#1\endcsname - {{\expandonce\NewOption}{\expandonce\NewValue}}}}} - -% {,...} - -\protected\def\blx@bbl@set#1{% - \blx@bbl@fieldedef{entryset}{\detokenize{#1}}% - \csxdef{blx@setp@\the\c@refsection @\abx@field@entrykey}{\detokenize{#1}}% - \begingroup - \blx@tempcnta\z@ - \expandafter\forcsvlist - \expandafter\blx@bbl@set@i - \expandafter{\detokenize{#1}}% - \endgroup} - -\def\blx@bbl@set@i#1{% - \advance\blx@tempcnta\@ne - \csxdef{blx@seti@\the\c@refsection @#1}{\the\blx@tempcnta}} - -% {} - -\protected\def\blx@bbl@inset#1{% - \toggletrue{blx@setonly}% - \blx@bbl@fieldedef{entryset}{\detokenize{#1}}% - \csxdef{blx@setc@\the\c@refsection @\abx@field@entrykey}{\detokenize{#1}}} - -% {} - -\protected\def\blx@bbl@xref#1{% BibTeX only - \ifcsdef{blx@refp@\the\c@refsection @\detokenize{#1}} - {} - {\listcsxadd{blx@refs@\the\c@refsection}{\detokenize{#1}}}% - \listcsxadd{blx@refp@\the\c@refsection @\detokenize{#1}}{\abx@field@entrykey}% - \csxdef{blx@refc@\the\c@refsection @\abx@field@entrykey}{\detokenize{#1}}} - -\def\blx@addxref#1{% BibTeX only - \blx@ifdata{#1} - {\begingroup - \def\do##1{% - \csgappto{blx@data@\the\c@refsection @##1}{% - \def\abx@field@xref{#1}}}% - \dolistcsloop{blx@refp@\the\c@refsection @#1}% - \endgroup} - {}% - \global\csundef{blx@refp@\the\c@refsection @#1}} - -% {,...} - -\protected\def\blx@bbl@keyw#1{% - \iftoggle{blx@skipbib} - {} - {\forcsvlist{\blx@addkeyword{\abx@field@entrykey}}{#1}% - \blx@bbl@fielddef{keywords}{#1}}} - -\def\blx@addkeyword#1#2{% - \listcsxadd{blx@keyw@\the\c@refsection @\detokenize{#2}}{#1}} - -% {} - -\protected\long\def\blx@bbl@options#1{% - \begingroup - \let\blx@tempa\@empty - \forcsvlist\blx@bbl@options@i{#1}% - \edef\blx@tempa{% - \endgroup - \ifx\blx@tempa\@empty - \else - \def\noexpand\abx@field@options{\expandonce\blx@tempa}% - \fi}% - \blx@tempa} - -\long\def\blx@bbl@options@i#1{\blx@bbl@options@ii#1==&} - -\long\def\blx@bbl@options@ii#1=#2=#3&{% - \ifcsundef{KV@blx@opt@ent@#1} - {\blx@warning@noline{% - Ignoring undefined option '#1'\MessageBreak - at entry '\abx@field@entrykey'}} - {\eappto\blx@tempa{% - \ifx\blx@tempa\@empty\else,\fi - \unexpanded{#1}\ifblank{#2}{}{=\unexpanded{#2}}}}} - -% \blx@data@
@ data hook -% key -> data -% \blx@miss@
missing entries (blacklist) -% section -> keys [internal list] -% \blx@sort@
all entries, sorted -% section -> keys [internal list] -% \blx@sbib@
all entries in bibliography, sorted -% section -> keys [internal list] -% \blx@bsee@
seen citations, document body -% section -> keys [internal list] -% \blx@fsee@
seen citations, footnotes -% section -> keys [internal list] -% \blx@type@
@ type hash -% type -> keys [internal list] -% \blx@subt@
@ subtype hash -% subtype -> keys [internal list] -% \blx@segm@
@ segment hash -% segment -> keys [internal list] -% \blx@keyw@
@ keyword hash -% keyword -> keys [internal list] -% \blx@losh@
shorthand hash -% section -> keys [internal list] -% \blx@catg@ category hash, global -% category -> keys [internal list] -% \blx@set@
@ parent -> child mapping (dynamic entry sets) -% key -> key,key,... [csv list] -% \blx@setp@
@ parent -> child mapping (entry sets) -% key -> key,key,... [csv list] -% \blx@setc@
@ child -> parent mapping (entry sets) -% key -> key -% \blx@seti@
@ child -> index mapping (entry sets) -% key -> index -% \blx@pref@
@ pageref hook, temporary -% key -> pages [internal list] -% \blx@refs@
xref hash, temporary -% section -> parents [internal list] -% (BibTeX only) -% \blx@refp@
@ parent -> child mapping (xrefs), temporary -% key -> keys [internal list] -% (BibTeX only) -% \blx@refc@
@ child -> parent mapping (xrefs) -% key -> key [internal list] -% (BibTeX only) - -\def\blx@ifdata#1{% - \ifcsdef{blx@data@\the\c@refsection @#1}} -\let\blx@imc@ifentryinbib\blx@ifdata - -\def\blx@getdata#1{% - \csuse{blx@data@\the\c@refsection @#1}% - \blx@setcitecounter} - -\def\blx@getdata@cite#1{% - \ifcsdef{blx@setc@\the\c@refsection @#1} - {\expandafter\expandafter\expandafter\blx@getdata - \expandafter\expandafter\expandafter{% - \csname blx@setc@\the\c@refsection @#1\endcsname}% - \blx@ifdata{#1} - {\def\abx@field@childentrykey{#1}% - \begingroup - \blx@getdata{#1}% - \edef\blx@tempa{\endgroup - \def\noexpand\abx@field@childentrytype{\abx@field@entrytype}}% - \blx@tempa} - {}} - {\blx@getdata{#1}}% - \ifcsdef{blx@seti@\the\c@refsection @#1} - {\letcs\abx@field@entrysetcount{blx@seti@\the\c@refsection @#1}} - {}} - -\def\blx@execute{% - \blx@imc@thefield{execute}} - -\def\blx@setoptions@entry{% - \blx@imc@iffieldundef{options} - {} - {\begingroup - \edef\blx@tempa{\endgroup - \noexpand\setkeys{blx@opt@ent}{\abx@field@options}}% - \blx@tempa - \blx@checkoptions@entry}} - -\def\blx@setoptions@type#1{% - \ifcsdef{blx@opts@type@#1} - {\begingroup - \edef\blx@tempa{\endgroup - \noexpand\setkeys{blx@opt@typ}{\csuse{blx@opts@type@#1}}}% - \blx@tempa} - {}} - -\def\blx@checkoptions@global{} -\def\blx@checkoptions@type{} -\def\blx@checkoptions@entry{} - -\def\blx@entrysetcount{% - \ifdef\abx@field@entrykey - {\ifcsdef{blx@seti@\the\c@refsection @\abx@field@entrykey} - {\letcs\abx@field@entrysetcount{% - blx@seti@\the\c@refsection @\abx@field@entrykey}} - {}} - {}} - -% {
} - -\def\blx@bbl@refsection#1{% - \begingroup - \c@refsection#1\relax} - -\def\blx@bbl@endrefsection{% - \endgroup - \csnumgdef{blx@labelnumber@\the\c@refsection}{0}% - \iftoggle{blx@reencode}{\blx@reencode}{}} - -% {} - -\protected\def\blx@bbl@missing#1{% - \listcsxadd{blx@miss@\the\c@refsection}{\detokenize{#1}}% - \blx@warning@noline{% - The following entry could not be found\MessageBreak - in the database% - \ifnumgreater\c@refsection\z@ - { (refsection \the\c@refsection)} - {}:\MessageBreak - \detokenize{#1}\MessageBreak - Please verify the spelling and rerun\MessageBreak - LaTeX afterwards}} - -% {}{}{} - -\protected\def\blx@bbl@entry#1#2#3{% - \begingroup - \edef\abx@field@entrykey{\detokenize{#1}}% - \blx@setoptions@type{#2}% - \blx@bbl@options{#3}% - \blx@setoptions@entry - \edef\blx@bbl@data{blx@data@\the\c@refsection @\abx@field@entrykey}% - \csuse\blx@bbl@data - \cslet\blx@bbl@data\@empty - \blx@bbl@addfield{entrykey}{\abx@field@entrykey}% - \blx@bbl@addfield{entrytype}{#2}% - \blx@imc@iffieldundef{options} - {} - {\blx@bbl@fieldedef{options}{\expandonce\abx@field@options}}} - -\protected\def\blx@bbl@endentry{% - \csuse\blx@bbl@data - \ifcsundef{blx@pref@\the\c@refsection @\abx@field@entrykey} - {} - {\blx@addpageref{\abx@field@entrykey}}% - \nottoggle{blx@setonly} - {\listcsxadd{blx@sort@\the\c@refsection}{\abx@field@entrykey}} - {\global\toggletrue{blx@addset}% - \toggletrue{blx@skipbib}% - \toggletrue{blx@skipbiblist}% - \toggletrue{blx@skiplab}}% - \nottoggle{blx@skipbib} - {\listcsxadd{blx@sbib@\the\c@refsection}{\abx@field@entrykey}% - \listcsxadd{blx@type@\the\c@refsection @\abx@field@entrytype}{\abx@field@entrykey}% - \ifdef\abx@field@entrysubtype - {\listcsxadd{blx@subt@\the\c@refsection @\abx@field@entrysubtype}{\abx@field@entrykey}} - {}} - {}% - \nottoggle{blx@skipbiblist} - {\blx@bbl@shorthand} - {}% - \nottoggle{blx@skiplab} - {\iftoggle{blx@labelnumber} - {\blx@bbl@labelnumber} - {}% - \iftoggle{blx@labelalpha} - {\blx@bbl@labelalpha} - {}% - \iftoggle{blx@labeldate} - {\blx@bbl@labeldate} - {}% - \blx@bbl@prefixnumber} - {}% - \ifnumless\blx@backend\blx@backend@biber - {\blx@bbl@labelname} - {}% - \blx@bbl@titles - \blx@bbl@hooks - \endgroup} - -\def\blx@addset{% - \begingroup - \letcs\blx@tempa{blx@sort@\the\c@refsection}% - \global\cslet{blx@sort@\the\c@refsection}\@empty - \forlistloop\blx@addset@i\blx@tempa - \endgroup} - -\def\blx@addset@i#1{% - \listcsgadd{blx@sort@\the\c@refsection}{#1}% - \ifcsdef{blx@setp@\the\c@refsection @#1} - {\expandafter\expandafter\expandafter\forcsvlist - \expandafter\expandafter\expandafter\blx@addset@ii - \expandafter\expandafter\expandafter{% - \csname blx@setp@\the\c@refsection @#1\endcsname}} - {}} - -\def\blx@addset@ii#1{% - \listcsgadd{blx@sort@\the\c@refsection}{#1}} - -\def\blx@bbl@shorthand{% - \ifundef\abx@field@shorthand - {} - {\blx@setlabwidth{\shorthandwidth}{% - \csuse{abx@ffd@*@shorthandwidth}{\abx@field@shorthand}}}} - -\def\blx@bbl@labelnumber{% - \ifdefempty\abx@field@localnumber - {} - {\ifundef\abx@field@shorthand - {\ifdef\abx@field@localnumber - {} - {\csnumgdef{blx@labelnumber@\the\c@refsection}{% - \csuse{blx@labelnumber@\the\c@refsection}+1}% - \edef\abx@field@localnumber{% - \csuse{blx@labelnumber@\the\c@refsection}}}% - \blx@bbl@fieldedef{labelnumber}{\abx@field@localnumber}% - \iftoggle{blx@skipbib} - {} - {\blx@setlabwidth{\labelnumberwidth}{% - \csuse{abx@ffd@*@labelnumberwidth}{% - \ifdef\abx@field@prefixnumber - {\csuse{abx@ffd@*@prefixnumber}{\abx@field@prefixnumber}} - {}% - \abx@field@localnumber}}}} - {\csgappto\blx@bbl@data{% - \let\abx@field@labelnumber\abx@field@shorthand}% - \iftoggle{blx@skipbib} - {} - {\blx@setlabwidth{\labelnumberwidth}{% - \csuse{abx@ffd@*@labelnumberwidth}{\abx@field@shorthand}}}}}} - -\def\blx@bbl@prefixnumber{% - \ifdef\abx@field@prefixnumber - {\blx@bbl@fieldedef{prefixnumber}{\abx@field@prefixnumber}} - {}} - -\def\blx@bbl@labelalpha{% - \ifundef\abx@field@shorthand - {\ifundef\abx@field@labelalpha - {} - {\ifundef\abx@field@extraalpha - {} - {\ifnum\abx@field@extraalpha>\c@maxextraalpha - \global\c@maxextraalpha\abx@field@extraalpha\relax - \fi}% - \iftoggle{blx@skipbib} - {} - {\blx@setlabwidth{\labelalphawidth}{% - \csuse{abx@ffd@*@labelalphawidth}{% - \ifdef\abx@field@prefixnumber - {\csuse{abx@ffd@*@prefixnumber}{\abx@field@prefixnumber}} - {}% - \csuse{abx@ffd@*@labelalpha}{\abx@field@labelalpha}% - \ifundef\abx@field@extraalpha - {} - {\csuse{abx@ffd@*@extraalpha}{\abx@field@extraalpha}}}}}}} - {\csgappto\blx@bbl@data{% - \let\abx@field@labelalpha\abx@field@shorthand}% - \iftoggle{blx@skipbib} - {} - {\blx@setlabwidth{\labelalphawidth}{% - \csuse{abx@ffd@*@labelalphawidth}{\abx@field@shorthand}}}}} - -\def\blx@bbl@labeldate{% - \ifundef\abx@field@extrayear - {} - {\ifnum\abx@field@extrayear>\c@maxextrayear - \global\c@maxextrayear\abx@field@extrayear\relax - \fi}} - -\def\blx@bbl@labelname{% BibTeX only - \iftoggle{blx@useauthor} - {\ifundef\abx@name@shortauthor - {\ifundef\abx@name@author - {\blx@bbl@labelname@i} - {\csgappto\blx@bbl@data{% - \c@labelname\c@author - \let\abx@name@labelname\abx@name@author}% - \iftoggle{abx@bool@moreauthor} - {\csgappto\blx@bbl@data{% - \toggletrue{abx@bool@morelabelname}}} - {}}} - {\csgappto\blx@bbl@data{% - \c@labelname\c@shortauthor - \let\abx@name@labelname\abx@name@shortauthor}% - \iftoggle{abx@bool@moreshortauthor} - {\csgappto\blx@bbl@data{% - \toggletrue{abx@bool@morelabelname}}} - {}}} - {\blx@bbl@labelname@i}} - -\def\blx@bbl@labelname@i{% - \iftoggle{blx@useeditor} - {\ifundef\abx@name@shorteditor - {\ifundef\abx@name@editor - {\blx@bbl@labelname@ii} - {\csgappto\blx@bbl@data{% - \c@labelname\c@editor - \let\abx@name@labelname\abx@name@editor}% - \iftoggle{abx@bool@moreeditor} - {\csgappto\blx@bbl@data{% - \toggletrue{abx@bool@morelabelname}}} - {}}} - {\csgappto\blx@bbl@data{% - \c@labelname\c@shorteditor - \let\abx@name@labelname\abx@name@shorteditor}% - \iftoggle{abx@bool@moreshorteditor} - {\csgappto\blx@bbl@data{% - \toggletrue{abx@bool@morelabelname}}} - {}}} - {\blx@bbl@labelname@ii}} - -\def\blx@bbl@labelname@ii{% - \iftoggle{blx@usetranslator} - {\ifundef\abx@name@translator - {} - {\csgappto\blx@bbl@data{% - \c@labelname\c@translator - \let\abx@name@labelname\abx@name@translator}% - \iftoggle{abx@bool@moretranslator} - {\csgappto\blx@bbl@data{% - \toggletrue{abx@bool@morelabelname}}} - {}}} - {}} - -\def\blx@bbl@titles{% - \ifundef\abx@field@shorttitle - {\csgappto\blx@bbl@data{% - \let\abx@field@labeltitle\abx@field@title}} - {\csgappto\blx@bbl@data{% - \let\abx@field@labeltitle\abx@field@shorttitle}}% - \ifundef\abx@field@indextitle - {\csgappto\blx@bbl@data{% - \let\abx@field@indextitle\abx@field@title}} - {}% - \ifundef\abx@field@indexsorttitle - {\csgappto\blx@bbl@data{% - \let\abx@field@indexsorttitle\abx@field@indextitle}} - {}} - -\def\blx@bbl@hooks{% - \ifcsundef{blx@hook@bblitem@*} - {\ifcsundef{blx@hook@bblitem@\abx@field@entrytype} - {} - {\csuse\blx@bbl@data - \csuse{blx@hook@bblitem@\abx@field@entrytype}}} - {\csuse\blx@bbl@data - \csuse{blx@hook@bblitem@*}% - \csuse{blx@hook@bblitem@\abx@field@entrytype}}} - -\newrobustcmd*{\AtDataInput}[1][*]{\csgappto{blx@hook@bblitem@#1}} -\@onlypreamble\AtDataInput - -\def\blx@setlabwidth#1#2{% - \begingroup - \settowidth{\@tempdima}{\bibfont#2}% - \ifnum\@tempdima>#1% - \global#1\@tempdima - \fi - \endgroup} - -\def\blx@bblstart{% - \let\preamble\blx@bbl@preamble - \let\warn\blx@bbl@thewarn - \let\refsection\blx@bbl@refsection - \let\endrefsection\blx@bbl@endrefsection - \let\entry\blx@bbl@entry - \let\endentry\blx@bbl@endentry - \let\missing\blx@bbl@missing - \let\lossort\blx@bbl@lossort - \let\endlossort\blx@bbl@endlossort - \let\set\blx@bbl@set - \let\inset\blx@bbl@inset - \let\xref\blx@bbl@xref % BibTeX only - \let\keyw\blx@bbl@keyw - \let\name\blx@bbl@namedef - \let\list\blx@bbl@listdef - \let\field\blx@bbl@fielddef - \let\strng\blx@bbl@stringdef - \let\cnt\blx@bbl@cntdef - \let\true\blx@bbl@booltrue - \let\false\blx@bbl@boolfalse - \let\verb\blx@bbl@verbdef - \let\endverb\blx@bbl@verbend} - -\def\blx@bblend{% - \ifcsdef{blx@refs@\the\c@refsection}% BibTeX only - {\begingroup - \let\do\blx@addxref - \dolistcsloop{blx@refs@\the\c@refsection}% - \endgroup - \global\csundef{blx@refs@\the\c@refsection}} - {}% - \iftoggle{blx@addset} - {\blx@addset - \global\togglefalse{blx@addset}} - {}} - -% {}{}{}{} - -\protected\def\blx@aux@number#1#2#3#4{% - \blx@bbl@addentryfield{\detokenize{#2}}{#3}{localnumber}{#4}% - \ifblank{#4} - {} - {\csgdef{blx@labelnumber@#3}{#4}% - \blx@addchecksum{#1}{#4}}} - -\AtEndDocument{% - \def\abx@aux@number#1#2#3#4{% - \ifblank{#4} - {} - {\blx@addchecksum{#1}{#4}}}} - -\def\blx@addlabelnumber{% - \begingroup - \nottoggle{blx@skiplab} - {\iftoggle{blx@labelnumber} - {\ifundef\abx@field@shorthand - {\ifundef\abx@field@localnumber - {\iftoggle{blx@omitnumbers} - {\let\abx@field@localnumber\@empty} - {\csnumgdef{blx@labelnumber@\the\c@refsection}{% - \csuse{blx@labelnumber@\the\c@refsection}+1}% - \edef\abx@field@localnumber{\csuse{blx@labelnumber@\the\c@refsection}}% - \blx@bbl@addentryfield{\abx@field@entrykey}{\the\c@refsection}% - {localnumber}{\abx@field@localnumber}}% - \blx@auxwrite\@mainaux{}{% - \string\abx@aux@number{\the\c@instcount}{\abx@field@entrykey}% - {\the\c@refsection}{\abx@field@localnumber}}} - {}} - {}}% - {}} - {}% - \endgroup} - -\def\blx@addprefixnumber{% - \nottoggle{blx@skiplab} - {\ifdef\blx@prefixnumbers - {\ifundef\abx@field@shorthand - {\edef\abx@field@prefixnumber{\expandonce\blx@prefixnumbers}% - \ifundef\abx@field@prefixnumber - {\blx@bbl@addentryfield{\abx@field@entrykey}{\the\c@refsection}% - {prefixnumber}{\expandonce\abx@field@prefixnumber}} - {}% - \blx@auxwrite\@mainaux{}{% - \string\blx@aux@numprefix{\abx@field@entrykey}% - {\the\c@refsection}{\expandonce\abx@field@prefixnumber}}} - {}} - {}} - {}} - -% {}{}{} - -\protected\def\blx@aux@numprefix#1#2#3{% - \blx@bbl@addentryfield{\detokenize{#1}}{#2}{prefixnumber}{#3}} - -\def\blx@bbl@lossort{% - \begingroup - \def\key##1{\listcsxadd{blx@losh@\the\c@refsection}{\detokenize{##1}}}} -\let\blx@bbl@endlossort\endgroup - -\def\blx@addpageref#1{% - \begingroup - \blx@tempcnta\z@ - \let\blx@tempa\@empty - \def\do##1{% - \appto\blx@tempa{{##1}}% - \advance\blx@tempcnta\@ne}% - \dolistcsloop{blx@pref@\the\c@refsection @#1}% - \edef\blx@tempa{\endgroup\noexpand\blx@bbl@listdef - {pageref}{\the\blx@tempcnta}{\blx@tempa}}% - \blx@tempa} - -%% Data input - -\def\blx@bblinput{% - \begingroup - \iftoggle{blx@reencode} - {\ifdef\inpenc@prehook - {\inpenc@prehook{}% - \inpenc@posthook{}} - {}% - \inputencoding\blx@bibencoding} - {}% - \blx@info@noline{Trying to load bibliographic data..}% - \blx@blxinit - \ifnumequal\blx@backend\blx@backend@biber - {\blx@bblfile@biber} - {\blx@bblfile@bibtex - \blx@bblsecs@bibtex}% - \endgroup - \iftoggle{blx@reencode} - {\ifdef\@enablequotes - {\@enablequotes} - {}} - {}} - -\def\blx@bblfile@biber{% - \blx@secinit - \begingroup - \blx@bblstart - \blx@ifsigned{\jobname}{bbl} - {\InputIfFileExists{\jobname.bbl} - {\blx@info@noline{... file '\jobname.bbl' found}} - {\blx@info@noline{... file '\jobname.bbl' not found}% - \typeout{No file \jobname.bbl.}}} - {}% - \blx@bblend - \endgroup - \csnumgdef{blx@labelnumber@\the\c@refsection}{0}} - -\def\blx@bblfile@bibtex{% - \blx@secinit - \begingroup - \blx@bblstart - \ifnum\c@refsection>\z@ - \edef\blx@auxfile@bibtex{\jobname\the\c@refsection\blxauxsuffix}% - \else - \edef\blx@auxfile@bibtex{\jobname}% - \fi - \blx@ifsigned{\blx@auxfile@bibtex}{bbl} - {\InputIfFileExists{\blx@auxfile@bibtex.bbl} - {\blx@info@noline{... file '\blx@auxfile@bibtex.bbl' found}} - {\blx@info@noline{... file '\blx@auxfile@bibtex.bbl' not found}% - \typeout{No file \blx@auxfile@bibtex.bbl.}}} - {}% - \blx@bblend - \endgroup - \csnumgdef{blx@labelnumber@\the\c@refsection}{0}% - \iftoggle{blx@reencode}{\blx@reencode}{}} - -\def\blx@bblsecs@bibtex{% - \advance\c@refsection\@ne - \ifnum\c@refsection>\blx@maxsection - \else - \blx@bblfile@bibtex - \expandafter\blx@bblsecs@bibtex - \fi} - -\def\blx@reencode{% - \begingroup - \abx@hook@reencode - \let\protect\@unexpandable@protect - \def\do##1{\cslet{abx@name@##1}\relax}% - \abx@donames - \def\do##1{\cslet{abx@list@##1}\relax}% - \abx@dolists - \def\do##1{\cslet{abx@field@##1}\relax}% - \abx@dofields\do{options}% - \long\def\abx@field@execute##1{% - \unexpanded{\abx@field@execute{##1}}}% - \csuse{abx@preamble}% - \def\do##1{% - \csxdef{blx@data@\the\c@refsection @##1}{% - \csuse{blx@data@\the\c@refsection @##1}}}% - \dolistcsloop{blx@sort@\the\c@refsection}% - \endgroup} - -\def\abx@hook@reencode{% - \ifdef\@enablequotes{\@enablequotes}{}% - \def\IeC##1{\unexpanded{\IeC{##1}}}% - \let~\relax -} - -%% Bibliography - -% {}{}[]{} - -\newrobustcmd*{\defbibenvironment}[4]{% - \long\csdef{blx@env@#1}{#2}% - \long\csdef{blx@endenv@#1}{#3}% - \long\csdef{blx@item@#1}{#4}} - -\defbibenvironment{bibliography} - {\list{}{% - \leftmargin\bibhang - \itemindent-\leftmargin - \itemsep\bibitemsep - \parsep\bibparsep}} - {\endlist} - {\item} - -\defbibenvironment{shorthand} - {\list{\thefield{shorthand}}{% - \labelwidth\shorthandwidth - \labelsep\biblabelsep - \leftmargin\labelwidth - \advance\leftmargin\labelsep - \itemsep\bibitemsep - \parsep\bibparsep - \def\makelabel##1{##1\hss}}} - {\endlist} - {\item} - -% {}[]{} - -\newrobustcmd*{\defbibheading}[1]{% - \@ifnextchar[%] - {\blx@defbibheading{blx@head@#1}} - {\blx@defbibheading{blx@head@#1}[\bibname]}} - -\def\blx@defbibheading#1[#2]{% - \csundef{#1}% - \expandafter\newcommand\csname#1\endcsname[1][#2]} - -% {}{} - -\newrobustcmd*{\defbibnote}[1]{% - \long\csdef{blx@note@#1}} - -% {}{} - -\newrobustcmd*{\defbibfilter}[2]{% - \begingroup - \def\blx@flt@error{\csname blx@flt@errortrue\endcsname}% - \let\not\blx@flt@not \let\NOT\not - \let\and\blx@flt@and \let\AND\and - \let\or\blx@flt@or \let\OR\or - \letcs\({blx@flt@(} \letcs\){blx@flt@)}% - \def\section##1{\blx@flt@error}% - \def\segment##1{segment=##1}% - \def\type##1{type=##1}% - \def\subtype##1{subtype=##1}% - \def\keyword##1{keyword={##1}}% - \def\category##1{category={##1}}% - \edef\blx@tempa{\noexpand\blx@defbibfilter{#2}}% - \ifdef\blx@flt@errortrue - {\blx@err@filter} - {\let\the\relax - \let\blx@flt@item\relax - \edef\blx@tempa{\blx@tempa}% - \ifdef\blx@flt@errortrue - {\blx@err@filter} - {\csxdef{blx@filter@#1}{\blx@tempa}}}% - \endgroup} - -\def\blx@defbibfilter#1{% - \blx@defbibfilter@i#1 &} -\def\blx@defbibfilter@i#1 #2&{% - \blx@defbibfilter@ii#1==&% - \ifblank{#2}{}{\blx@defbibfilter@i#2 &}} -\def\blx@defbibfilter@ii#1=#2=#3&{% - \ifblank{#2} - {\ifblank{#1} - {} - {\ifcsdef{blx@flt@#1} - {\csname blx@flt@#1\endcsname} - {\blx@flt@error}}} - {\ifcsdef{blx@flt@#1} - {\csname blx@flt@#1\endcsname{\detokenize{#2}}} - {\blx@flt@error}}} - -\def\blx@flt@and{ and } -\def\blx@flt@or{ or } -\def\blx@flt@not{ not } -\csdef{blx@flt@(}{ ( } -\csdef{blx@flt@)}{ ) } -\def\blx@flt@segment#1{% - test {\xifinlistcs\blx@flt@item{blx@segm@\the\c@refsection @#1}}} -\def\blx@flt@type#1{% - test {\xifinlistcs\blx@flt@item{blx@type@\the\c@refsection @#1}}} -\def\blx@flt@subtype#1{% - test {\xifinlistcs\blx@flt@item{blx@subt@\the\c@refsection @#1}}} -\def\blx@flt@keyword#1{% - test {\xifinlistcs\blx@flt@item{blx@keyw@\the\c@refsection @#1}}} -\def\blx@flt@category#1{% - test {\xifinlistcs\blx@flt@item{blx@catg@#1}}} - -% {}{} - -\newrobustcmd*{\defbibcheck}[2]{% - \csdef{blx@bibcheck@#1}{% - \togglefalse{blx@skipentry}% - \def\skipentry{\toggletrue{blx@skipentry}}% - #2\undef\skipentry}} - -% options - -\define@key{blx@bib}{section}{% - \ifcsundef{blx@sbib@#1} - {\blx@err@nosec{#1}} - {\c@refsection#1\relax - \iftoggle{blx@tempa} - {\letcs\blx@tempa{blx@sbib@\the\c@refsection}} - {\blx@err@secfirst}}} - -\define@key{blx@los}{section}{% - \ifcsundef{blx@sbib@#1} - {\blx@err@nosec{#1}} - {\c@refsection#1\relax - \iftoggle{blx@tempa} - {\letcs\blx@tempa{blx@losh@\the\c@refsection}} - {\blx@err@secfirst}}} - -\define@key{blx@bbg}{section}{% - \ifcsundef{blx@sbib@#1} - {\blx@err@nosec{#1}} - {\c@refsection#1\relax}} - -\define@key{blx@bbc}{section}{% - \ifcsundef{blx@sbib@#1} - {\blx@err@nosec{#1}} - {\c@refsection#1\relax}} - -\define@key{blx@bib}{segment}{\blx@key@segment{#1}} -\define@key{blx@los}{segment}{\blx@key@segment{#1}} - -\def\blx@key@segment#1{% - \ifcsundef{blx@segm@\the\c@refsection @#1} - {\blx@error - {Segment '#1' not found} - {The reference segment '#1' could not be found}} - {\c@refsegment#1\relax - \blx@printbibchecks - \blx@filter\blx@tempa{blx@segm@\the\c@refsection @#1}}} - -\define@key{blx@bib}{type}{\blx@key@type{#1}} -\define@key{blx@los}{type}{\blx@key@type{#1}} - -\def\blx@key@type#1{% - \ifcsundef{blx@type@\the\c@refsection @#1} - {\blx@warning{Type '#1' not found}% - \let\blx@tempa\@empty} - {\blx@printbibchecks - \iftoggle{blx@tempb} - {\togglefalse{blx@tempb}% - \blx@filter\blx@tempa{blx@type@\the\c@refsection @#1}} - {\let\blx@tempa\@empty - \blx@error - {'type' used multiple times} - {When passing multiple filter options, each entry\MessageBreak - must satisfy all conditions (AND conjunction),\MessageBreak - hence some options may not be used twice.\MessageBreak - Use 'filter' and '\string\defbibfilter' with OR conjunctions}}}} - -\define@key{blx@bib}{nottype}{\blx@key@nottype{#1}} -\define@key{blx@los}{nottype}{\blx@key@nottype{#1}} - -\def\blx@key@nottype#1{% - \ifcsundef{blx@type@\the\c@refsection @#1} - {} - {\blx@printbibchecks - \blx@notfilter\blx@tempa{blx@type@\the\c@refsection @#1}}} - -\define@key{blx@bib}{subtype}{\blx@key@subtype{#1}} -\define@key{blx@los}{subtype}{\blx@key@subtype{#1}} - -\def\blx@key@subtype#1{% - \ifcsundef{blx@subt@\the\c@refsection @#1} - {\blx@warning{Subtype '#1' not found}% - \let\blx@tempa\@empty} - {\blx@printbibchecks - \iftoggle{blx@tempb} - {\togglefalse{blx@tempb}% - \blx@filter\blx@tempa{blx@subt@\the\c@refsection @#1}} - {\let\blx@tempa\@empty - \blx@error - {'subtype' used multiple times} - {When passing multiple filter options, each entry\MessageBreak - must satisfy all conditions (AND conjunction),\MessageBreak - hence some options may not be used twice.\MessageBreak - Use 'filter' and '\string\defbibfilter' with OR conjunctions}}}} - -\define@key{blx@bib}{notsubtype}{\blx@key@notsubtype{#1}} -\define@key{blx@los}{notsubtype}{\blx@key@notsubtype{#1}} - -\def\blx@key@notsubtype#1{% - \ifcsundef{blx@subt@\the\c@refsection @#1} - {} - {\blx@printbibchecks - \blx@notfilter\blx@tempa{blx@subt@\the\c@refsection @#1}}} - -\define@key{blx@bib}{keyword}{\blx@key@keyword{#1}} -\define@key{blx@los}{keyword}{\blx@key@keyword{#1}} - -\def\blx@key@keyword#1{% - \ifcsundef{blx@keyw@\the\c@refsection @\detokenize{#1}} - {\blx@warning{Keyword '\detokenize{#1}' not found}% - \let\blx@tempa\@empty} - {\blx@printbibchecks - \blx@filter\blx@tempa{blx@keyw@\the\c@refsection @\detokenize{#1}}}} - -\define@key{blx@bib}{notkeyword}{\blx@key@notkeyword{#1}} -\define@key{blx@los}{notkeyword}{\blx@key@notkeyword{#1}} - -\def\blx@key@notkeyword#1{% - \ifcsundef{blx@keyw@\the\c@refsection @\detokenize{#1}} - {} - {\blx@printbibchecks - \blx@notfilter\blx@tempa{blx@keyw@\the\c@refsection @\detokenize{#1}}}} - -\define@key{blx@bib}{category}{\blx@key@category{#1}} -\define@key{blx@los}{category}{\blx@key@category{#1}} - -\def\blx@key@category#1{% - \ifcsundef{blx@catg@\detokenize{#1}} - {\blx@warning{Category '\detokenize{#1}' not found}% - \let\blx@tempa\@empty} - {\blx@printbibchecks - \blx@filter\blx@tempa{blx@catg@\detokenize{#1}}}} - -\define@key{blx@bib}{notcategory}{\blx@key@notcategory{#1}} -\define@key{blx@los}{notcategory}{\blx@key@notcategory{#1}} - -\def\blx@key@notcategory#1{% - \ifcsundef{blx@catg@#1} - {} - {\blx@printbibchecks - \blx@notfilter\blx@tempa{blx@catg@#1}}} - -\define@key{blx@bib}{filter}{\blx@key@filter{#1}} -\define@key{blx@los}{filter}{\blx@key@filter{#1}} - -\def\blx@key@filter#1{% - \ifcsdef{blx@filter@#1} - {\blx@printbibchecks - \blx@bibfilter\blx@tempa{blx@filter@#1}} - {\let\blx@tempa\@empty - \blx@error - {Filter '#1' not found} - {The filter '#1' could not be found.\MessageBreak - Use \string\defbibfilter\space to define it}}} - -\define@key{blx@bib}{check}{\blx@key@bibcheck{#1}} -\define@key{blx@los}{check}{\blx@key@bibcheck{#1}} - -\def\blx@key@bibcheck#1{% - \ifcsdef{blx@bibcheck@#1} - {\letcs\blx@bibcheck{blx@bibcheck@#1}} - {\let\blx@tempa\@empty - \blx@error - {Check '#1' not found} - {The check '#1' could not be found.\MessageBreak - Use \string\defbibcheck\space to define it}}} - -\define@key{blx@bhd}{heading}{\blx@key@heading{#1}} -\define@key{blx@bib}{heading}{\blx@key@heading{#1}} -\define@key{blx@los}{heading}{\blx@key@heading{#1}} -\define@key{blx@bbs}{heading}{\blx@key@heading{#1}} -\define@key{blx@bbg}{heading}{\blx@key@heading{#1}} - -\def\blx@key@heading#1{% - \ifcsundef{blx@head@#1} - {\blx@error - {Heading '#1' not found} - {The heading '#1' could not be found.\MessageBreak - Use \string\defbibheading\space to define it}} - {\def\blx@theheading{#1}}} - -\define@key{blx@bib}{env}{\blx@key@env{#1}} -\define@key{blx@los}{env}{\blx@key@env{#1}} -\define@key{blx@bbs}{env}{\blx@key@env{#1}} -\define@key{blx@bbg}{env}{\blx@key@env{#1}} -\define@key{blx@bbc}{env}{\blx@key@env{#1}} - -\def\blx@key@env#1{% - \ifcsundef{blx@env@#1} - {\blx@error - {Environment '#1' not found} - {The environment '#1' could not be found.\MessageBreak - Use \string\defbibenvironment\space to define it}} - {\def\blx@theenv{#1}}} - -\define@key{blx@bhd}{title}{\def\blx@thetitle{#1}} -\define@key{blx@bib}{title}{\def\blx@thetitle{#1}} -\define@key{blx@los}{title}{\def\blx@thetitle{#1}} - -\define@key{blx@bib}{prenote}{\blx@key@prenote{#1}} -\define@key{blx@los}{prenote}{\blx@key@prenote{#1}} -\define@key{blx@bbs}{prenote}{\blx@key@prenote{#1}} -\define@key{blx@bbg}{prenote}{\blx@key@prenote{#1}} -\define@key{blx@bbc}{prenote}{\blx@key@prenote{#1}} -\def\blx@key@prenote#1{% - \ifcsundef{blx@note@#1} - {\blx@error - {Note '#1' not found} - {The note '#1' could not be found.\MessageBreak - Use \string\defbibnote\space to define it}} - {\def\blx@theprenote{#1}}} - -\define@key{blx@bib}{postnote}{\blx@key@postnote{#1}} -\define@key{blx@los}{postnote}{\blx@key@postnote{#1}} -\define@key{blx@bbs}{postnote}{\blx@key@postnote{#1}} -\define@key{blx@bbg}{postnote}{\blx@key@postnote{#1}} -\define@key{blx@bbc}{postnote}{\blx@key@postnote{#1}} - -\def\blx@key@postnote#1{% - \ifcsundef{blx@note@#1} - {\blx@error - {Note '#1' not found} - {The note '#1' could not be found.\MessageBreak - Use \string\defbibnote\space to define it}} - {\def\blx@thepostnote{#1}}} - -\define@key{blx@bib}{resetnumbers}[true]{% - \ifstrequal{#1}{true} - {\iftoggle{blx@defernumbers} - {\csnumdef{blx@labelnumber@\the\c@refsection}{0}} - {\blx@warning{% - Option 'resetnumbers' requires 'defernumbers=true'.\MessageBreak - Ignoring 'resetnumbers=true'}}} - {}} - -\define@key{blx@bib}{omitnumbers}[true]{% - \ifstrequal{#1}{true} - {\iftoggle{blx@defernumbers} - {\toggletrue{blx@omitnumbers}} - {\blx@warning{% - Option 'omitnumbers' requires 'defernumbers=true'.\MessageBreak - Ignoring 'omitnumbers=true'}}} - {}} - -\define@key{blx@bib}{prefixnumbers}{% - \def\blx@prefixnumbers{#1}% - \iftoggle{blx@defernumbers} - {\csnumdef{blx@labelnumber@\the\c@refsection}{0}} - {\iftoggle{blx@labelnumber} - {\blx@warning{% - Option 'prefixnumbers' requires global\MessageBreak - 'defernumbers=true'}} - {}}} - -% [] - -\newrobustcmd*{\printbibheading}{% - \begingroup - \edef\on@line{\on@line}% - \@ifnextchar[%] - {\blx@printbibheading} - {\blx@printbibheading[]}} - -\def\blx@printbibheading[#1]{% - \def\blx@theheading{bibliography}% - \let\blx@thetitle\@empty - \blx@safe@actives - \setkeys{blx@bhd}{#1}% - \blx@rest@actives - \blx@langstrings - \blx@bibheading\blx@theheading\blx@thetitle - \endgroup} - -% [] - -\newrobustcmd*{\printbibliography}{% - \begingroup - \edef\on@line{\on@line}% - \@ifnextchar[%] - {\blx@printbibliography} - {\blx@printbibliography[]}} - -\def\blx@printbibliography[#1]{% - \toggletrue{blx@tempa}% - \toggletrue{blx@tempb}% - \letcs\blx@tempa{blx@sbib@\the\c@refsection}% - \def\blx@theheading{bibliography}% - \def\blx@theenv{bibliography}% - \let\blx@theprenote\@empty - \let\blx@thepostnote\@empty - \let\blx@thetitle\@empty - \blx@safe@actives - \setkeys{blx@bib}{#1}% - \blx@rest@actives - \ifdefvoid\blx@tempa - {\blx@warn@bibempty\endgroup} - {\blx@bibliography\blx@tempa}} - -% [] - -\newrobustcmd*{\bibbysection}{% - \begingroup - \ifnum\blx@maxsection=\z@ - \blx@warning{No reference sections found}% - \fi - \edef\on@line{\on@line}% - \@ifnextchar[%] - {\blx@bibbysection} - {\blx@bibbysection[]}} - -\def\blx@bibbysection[#1]{% - \def\blx@theheading{bibliography}% - \def\blx@theenv{bibliography}% - \let\blx@theprenote\@empty - \let\blx@thepostnote\@empty - \let\blx@thetitle\@empty - \c@refsection\z@ - \blx@safe@actives - \setkeys{blx@bbs}{#1}% - \blx@rest@actives - \togglefalse{blx@tempa}% - \blx@refsections} - -\def\blx@refsections{% - \ifcsvoid{blx@sbib@\the\c@refsection} - {} - {\toggletrue{blx@tempa}% - \begingroup - \expandafter\blx@bibliography\csname blx@sbib@\the\c@refsection\endcsname}% - \ifnum\c@refsection<\blx@maxsection - \advance\c@refsection\@ne - \expandafter\blx@refsections - \else - \iftoggle{blx@tempa}{}{\blx@warn@bibempty}% - \endgroup - \fi} - -% [] - -\newrobustcmd*{\bibbysegment}{% - \begingroup - \edef\on@line{\on@line}% - \ifnum\blx@maxsegment=\z@ - \blx@warning{No reference segments found}% - \fi - \@ifnextchar[%] - {\blx@bibbysegment} - {\blx@bibbysegment[]}} - -\def\blx@bibbysegment[#1]{% - \def\blx@theheading{bibliography}% - \def\blx@theenv{bibliography}% - \let\blx@theprenote\@empty - \let\blx@thepostnote\@empty - \let\blx@thetitle\@empty - \c@refsection\z@ - \c@refsegment\@ne - \blx@safe@actives - \setkeys{blx@bbg}{#1}% - \blx@rest@actives - \togglefalse{blx@tempa}% - \blx@refsegments} - -\def\blx@refsegments{% - \ifcsvoid{blx@segm@\the\c@refsection @\the\c@refsegment} - {} - {\toggletrue{blx@tempa}% - \begingroup - \letcs\blx@tempa{blx@sbib@\the\c@refsection}% - \blx@filter\blx@tempa{blx@segm@\the\c@refsection @\the\c@refsegment}% - \blx@bibliography\blx@tempa}% - \ifnum\c@refsegment<\blx@maxsegment - \advance\c@refsegment\@ne - \expandafter\blx@refsegments - \else - \iftoggle{blx@tempa}{}{\blx@warn@bibempty}% - \endgroup - \fi} - -% [] - -\newrobustcmd*{\bibbycategory}{% - \begingroup - \edef\on@line{\on@line}% - \ifx\blx@categories\@empty - \blx@warning{No categories found}% - \fi - \@ifnextchar[%] - {\blx@bibbycategory} - {\blx@bibbycategory[]}} - -\def\blx@bibbycategory[#1]{% - \def\blx@theheading{bibliography}% - \def\blx@theenv{bibliography}% - \let\blx@theprenote\@empty - \let\blx@thepostnote\@empty - \let\blx@thetitle\@empty - \c@refsection\z@ - \blx@safe@actives - \setkeys{blx@bbc}{#1}% - \blx@rest@actives - \togglefalse{blx@tempa}% - \forlistloop\blx@bibcategory\blx@categories - \blx@endbibcategory} - -\def\blx@bibcategory#1{% - \ifcsvoid{blx@catg@#1} - {} - {\toggletrue{blx@tempa}% - \begingroup - \blx@key@heading{#1}% - \letcs\blx@tempa{blx@sbib@\the\c@refsection}% - \blx@filter\blx@tempa{blx@catg@#1}% - \blx@bibliography\blx@tempa}}% - -\def\blx@endbibcategory{% - \iftoggle{blx@tempa}{}{\blx@warn@bibempty}% - \endgroup} - -% {,...} - -\def\blx@bibliography{% - \blx@langstrings - \blx@bibheading\blx@theheading\blx@thetitle - \blx@bibnote\blx@theprenote - \begingroup - \blx@bibinit - \let\@noitemerr\@empty - \let\blx@noitem\blx@warn@bibempty - \ifnum\bibinitsep=\z@ - \let\blx@initsep\relax - \fi - \ifnum\bibnamesep=\z@ - \let\blx@namesep\relax - \fi - \csuse{blx@env@\blx@theenv}% - \csuse{blx@hook@bibinit}% - \csuse{blx@hook@bibinit@next}% - \let\blx@do\blx@bibitem - \let\blx@done\blx@endbibliography - \blx@listloop} - -\def\blx@endbibliography{% - \csuse{blx@endenv@\blx@theenv}% - \blx@noitem - \endgroup - \blx@bibnote\blx@thepostnote - \endgroup} - -\def\blx@bibheading#1#2{% - \begingroup - \edef\blx@tempa{\endgroup - \noexpand\blx@bibheading@i{\expandonce#1}{\expandonce#2}}% - \blx@tempa} - -\def\blx@bibheading@i#1#2{% - \let\newrefsection\relax - \let\newrefsegment\relax - \ifblank{#2} - {\csuse{blx@head@#1}} - {\csuse{blx@head@#1}[#2]}% - \let\newrefsection\blx@newrefsection - \let\newrefsegment\blx@newrefsegment} - -\def\blx@bibnote#1{% - \ifdefempty#1 - {} - {\begingroup - \let\newrefsection\relax - \let\newrefsegment\relax - \noindent - \csuse{blx@note@#1}\par\nobreak - \endgroup}} - -\def\blx@bibinit{% - \iftoggle{blx@citation} - {} - {\toggletrue{blx@bibliography}}% - \blx@blxinit - \blx@resetdata - \csuse{blx@hook@bbxinit}% - \bibsetup\bibfont - \blx@setsfcodes - \csuse{blx@bibsetup}} - -% {} - -\def\blx@bibitem#1{% - \blx@ifdata{#1} - {\begingroup - \blx@getdata{#1}% - \blx@bibcheck - \iftoggle{blx@skipentry}{}{% - \global\let\blx@noitem\@empty - \blx@setoptions@type\abx@field@entrytype - \blx@setoptions@entry - \blx@thelabelnumber - \blx@addprefixnumber - \addtocounter{instcount}\@ne - \csuse{blx@item@\blx@theenv}\relax - \blx@initsep - \blx@namesep - \csuse{blx@hook@bibitem}% - \blx@execute - \blx@initunit - \blx@anchor - \blx@beglangbib - \bibsentence - \blx@pagetracker - \blx@driver\abx@field@entrytype - \blx@postpunct - \blx@endlangbib}% - \endgroup} - {}} - -\let\blx@bibcheck\relax - -\def\blx@initsep{% - \blx@imc@iffieldundef{sortinit} - {} - {\ifnum\c@instcount>\@ne - \blx@imc@iffieldequals{sortinit}\blx@previnit - {} - {\addvspace{\bibinitsep}}% - \fi - \global\let\blx@previnit\abx@field@sortinit}} - -\def\blx@namesep{% - \ifnum\c@instcount>\@ne - \blx@imc@iffieldequals{fullhash}\blx@prevhash - {} - {\addvspace{\bibnamesep}}% - \fi - \global\let\blx@prevhash\abx@field@fullhash} - -\newrobustcmd*{\AtBeginBibliography}{\gappto\blx@hook@bibinit} -\newrobustcmd*{\AtEveryBibitem}{\gappto\blx@hook@bibitem} -\@onlypreamble\AtBeginBibliography -\@onlypreamble\AtEveryBibitem - -\def\blx@imc@UseBibitemHook{\csuse{blx@hook@bibitem}} - -\blx@regimcs{\UseBibitemHook} - -\newrobustcmd*{\AtNextBibliography}{% - \ifundef\blx@hook@bibinit@next - {\gdef\blx@hook@bibinit@next{\global\undef\blx@hook@bibinit@next}} - {}% - \gappto\blx@hook@bibinit@next} - -% page tracker - -\def\blx@pagetracker@context{% - \blx@leavevmode - \ifbool{@filesw} - {\ifbool{pagetracker} - {\protected@write\@mainaux{}{% - \iftoggle{blx@footnote} - {\string\abx@aux@fnpage} - {\string\abx@aux@page}% - {\the\c@instcount}{\noexpand\the\c@page}}} - {}} - {}} - -% {}{} - -\protected\def\blx@aux@page#1#2{% - \csgdef{blx@page@#1}{#2}% - \blx@addpagesum{#1}{#2}} -\protected\def\blx@aux@spread#1#2{% - \ifodd#2\relax - \csxdef{blx@page@#1}{\number\numexpr#2-1}% - \else - \csgdef{blx@page@#1}{#2}% - \fi - \blx@addpagesum{#1}{#2}} - -\protected\def\blx@aux@fnpage#1#2{% - \csgdef{blx@fnpage@#1}{#2}% - \blx@addpagesum{#1}{#2}} -\protected\def\blx@aux@fnspread#1#2{% - \ifodd#2\relax - \csxdef{blx@fnpage@#1}{\number\numexpr#2-1}% - \else - \csgdef{blx@fnpage@#1}{#2}% - \fi - \blx@addpagesum{#1}{#2}} - -\AtEndDocument{% - \def\abx@aux@page#1#2{\blx@addpagesum{#1}{#2}}% - \def\abx@aux@fnpage#1#2{\blx@addpagesum{#1}{#2}}} - -% hyperref interface - -\appto\blx@mkhyperref{% - \let\blx@anchors\@empty - \ifundef\hyper@natanchorstart - {\protected\def\blx@anchor{% - \xifinlist{\the\c@refsection @\abx@field@entrykey}{\blx@anchors} - {} - {\listxadd\blx@anchors{\the\c@refsection @\abx@field@entrykey}% - \hypertarget{cite.\the\c@refsection @\abx@field@entrykey}{}}}} - {\protected\def\blx@anchor{% - \xifinlist{\the\c@refsection @\abx@field@entrykey}{\blx@anchors} - {} - {\listxadd\blx@anchors{\the\c@refsection @\abx@field@entrykey}% - \hyper@natanchorstart{\the\c@refsection @\abx@field@entrykey}% - \hyper@natanchorend}}}} - -\appto\blx@mknohyperref{\let\blx@anchor\relax} - -% List of shorthands - -\newrobustcmd*{\printshorthands}{% - \begingroup - \edef\on@line{\on@line}% - \@ifnextchar[%] - {\blx@printshorthands} - {\blx@printshorthands[]}} - -\def\blx@printshorthands[#1]{% - \toggletrue{blx@tempa}% - \toggletrue{blx@tempb}% - \letcs\blx@tempa{blx@losh@\the\c@refsection}% - \def\blx@theheading{biblist}% - \def\blx@theenv{shorthand}% - \let\blx@theprenote\@empty - \let\blx@thepostnote\@empty - \let\blx@thetitle\@empty - \let\blx@printbibchecks\relax - \blx@safe@actives - \setkeys{blx@los}{#1}% - \blx@rest@actives - \ifdefvoid\blx@tempa - {\blx@warn@losempty\endgroup} - {\blx@shorthands\blx@tempa}} - -\def\blx@printbibchecks{% - \togglefalse{blx@tempa}% - \iftoggle{blx@defernumbers} - {\global\let\blx@printbibchecks\relax} - {\iftoggle{blx@labelnumber} - {\blx@warning@noline{Setting 'defernumbers=true' recommended}} - {\global\let\blx@printbibchecks\relax}}} - -% {,...} - -\def\blx@shorthands{% - \if@twocolumn - \@restonecoltrue\onecolumn - \else - \@restonecolfalse - \fi - \blx@langstrings - \blx@bibheading\blx@theheading\blx@thetitle - \blx@bibnote\blx@theprenote - \begingroup - \blx@bibinit - \let\@noitemerr\@empty - \let\blx@noitem\blx@warn@losempty - \csuse{blx@env@\blx@theenv}% - \csuse{blx@hook@losinit}% - \let\blx@do\blx@lositem - \let\blx@done\blx@endshorthands - \blx@listloop} - -\def\blx@endshorthands{% - \csuse{blx@endenv@\blx@theenv}% - \blx@noitem - \endgroup - \blx@bibnote\blx@thepostnote - \endgroup - \if@restonecol\twocolumn\fi} - -\newrobustcmd*{\AtBeginShorthands}{\gappto\blx@hook@losinit} -\newrobustcmd*{\AtEveryLositem}{\gappto\blx@hook@lositem} -\@onlypreamble\AtBeginShorthands -\@onlypreamble\AtEveryLositem - -% {} - -\def\blx@lositem#1{% - \blx@ifdata{#1} - {\begingroup - \blx@getdata{#1}% - \blx@bibcheck - \iftoggle{blx@skipentry}{}{% - \global\let\blx@noitem\@empty - \blx@setoptions@type\abx@field@entrytype - \blx@setoptions@entry - \addtocounter{instcount}\@ne - \csuse{blx@item@\blx@theenv}\relax - \csuse{blx@hook@lositem}% - \blx@execute - \blx@initunit - \blx@beglangbib - \bibsentence - \blx@pagetracker - \blx@driver{shorthand}% - \blx@postpunct - \blx@endlangbib}% - \endgroup} - {}} - -\DeclareBibliographyDriver{shorthand}{% - \iffieldundef{shorttitle} - {\printfield{title}} - {\printfield{shorttitle}}} - -% Reference sections - -\newrobustcmd*{\newrefsection}{% - \ifnum\c@refsection>\z@ - \endrefsection - \fi - \refsection} -\let\blx@newrefsection\newrefsection - -\newrobustcmd*{\refsection}{% - \begingroup - \edef\on@line{\on@line}% - \ifnum\c@refsection>\z@ - \blx@err@nestenv{refsection}% - \blx@endrefsection - \fi - \ifnum\c@refsegment>\z@ - \blx@err@nestenv{refsection}% - \blx@endrefsegment - \fi - \@ifnextchar[%] - {\blx@refsection} - {\blx@refsection[]}} - -\def\blx@refsection{% - \begingroup - \blx@hook@fileverb - \blx@refsection@i} - -\def\blx@refsection@i[#1]{% - \endgroup - \global\advance\blx@maxsection\@ne - \global\c@refsection\blx@maxsection - \blx@inf@refsec - \blx@secinit - \if@filesw - \blx@auxwrite\@mainaux{}{% - \string\abx@aux@refsection{\the\c@refsection}{\the\c@page}}% - \ifblank{#1} - {} - {\let\blx@bibfiles\@empty - \blx@xsanitizeafter{\forcsvlist\blx@refsection@addfile}{#1}% - \forlistloop{\listadd\blx@bibfiles}\blx@bibfiles@global}% - \ifnum\blx@backend=\blx@backend@biber - \blx@refsection@biber - \else - \blx@refsection@bibtex - \fi - \fi - \blx@info{Setting label 'refsection:\the\c@refsection'}% - \label{refsection:\the\c@refsection}% - \endgroup} - -\def\blx@refsection@addfile#1{% - \ifcsdef{blx@res@labl@#1} - {\blx@refsection@addfile@i{\csuse{blx@res@labl@#1}}} - {\blx@refsection@addfile@i{#1}}} - -\def\blx@refsection@addfile@i#1{% - \ifcsdef{blx@res@loca@#1} - {\listeadd\blx@bibfiles{#1}} - {\listeadd\blx@bibfiles{\blx@stripbib{#1}\detokenize{.bib}}}} - -\def\blx@refsection@biber{% - \blx@regbibfiles\jobname\blx@bibfiles - \begingroup - \let\blx@tempa\@empty - \blx@bibdata\blx@tempa\blx@bibfiles - \blx@auxwrite\blx@auxout - {\let\do\blx@datasource} - {\blx@xml@endsection\blx@nl - \blx@xml@comment{section \the\c@refsection}% - \blx@xml@bibdata{\the\c@refsection}{\blx@tempa}% - \blx@xml@section{\the\c@refsection}}% - \endgroup} - -\def\blx@refsection@bibtex{% - \xdef\blx@auxfile@bibtex{\jobname\the\c@refsection\blxauxsuffix}% - \blx@regbibfiles\blx@auxfile@bibtex\blx@bibfiles - \blx@logreq@inactive - \blx@ifsigned{\blx@auxfile@bibtex}{aux} - {\immediate\openout\blx@auxout\blx@auxfile@bibtex.aux\relax - \global\let\blx@auxout@bibtex\blx@auxout - \blx@auxinit@bibtex\blx@bibfiles} - {}} - -\protected\def\endrefsection{% - \blx@endrefsection - \blx@inf@refsec} - -\def\blx@endrefsection{% - \blx@endrefsegment - \ifnum\blx@backend=\blx@backend@biber - \blx@endrefsection@biber - \else - \blx@endrefsection@bibtex - \fi - \global\c@refsection\z@} - -\def\blx@endrefsection@biber{% - \ifnum\c@refsection>\z@ - \blx@auxwrite\blx@auxout{}{% - \blx@xml@endsection\blx@nl - \blx@xml@comment{section 0 (cont.)}% - \blx@xml@section{0}}% - \fi} - -\def\blx@endrefsection@bibtex{% - \ifx\blx@auxout@bibtex\blx@auxout - \immediate\closeout\blx@auxout - \global\let\blx@auxout@bibtex\@mainaux - \xdef\blx@auxfile@bibtex{\jobname}% - \fi} - -\AtEndDocument{% - \blx@endrefsection - \def\abx@aux@refsection#1#2{\blx@addchecksum{#1}{#2}}} - -\protected\def\abx@aux@refsection#1#2{% - \ifnum#1>\blx@maxsection - \global\blx@maxsection#1\relax - \fi - \blx@addchecksum{#1}{#2}} - -% Reference segments - -\newrobustcmd*{\newrefsegment}{% - \ifnum\c@refsegment>\z@ - \blx@endrefsegment - \fi - \refsegment} -\let\blx@newrefsegment\newrefsegment - -\newrobustcmd*{\refsegment}{% - \ifnum\c@refsegment>\z@ - \blx@err@nestenv{refsegment}% - \blx@endrefsegment - \fi - \global\advance\blx@maxsegment\@ne - \global\c@refsegment\blx@maxsegment - \blx@inf@refseg - \blx@info{Setting label 'refsegment:\the\c@refsection\the\c@refsegment'}% - \label{refsegment:\the\c@refsection\the\c@refsegment}% - \ifcsundef{blx@segm@\the\c@refsection @\the\c@refsegment} - {\global\cslet{blx@segm@\the\c@refsection @\the\c@refsegment}\@empty} - {}} - -\protected\def\endrefsegment{% - \blx@endrefsegment - \blx@inf@refseg} - -\def\blx@endrefsegment{% - \global\c@refsegment\z@} - -% Reference section/segment auto-reset -% we are prepending to the commands so that the resets happen before -% the part title is typeset otherwise \cites in there could be "ibid" -% which makes no sense -\def\blx@refpatch@part#1{% - \ifundef\part - {\blx@err@nodocdiv{part}} - {\toggletrue{blx@tempa}% - \def\do##1{% - \pretocmd##1{#1} - {\togglefalse{blx@tempa}\listbreak} - {}}% - \docsvlist{% - \H@old@part,% hyperref - \NR@part,% nameref - \@part}% latex/koma-script/memoir - \iftoggle{blx@tempa} - {\blx@err@patch{\string\@part}} - {}% - \let\do\noexpand}} - -\def\blx@refpatch@chapter#1{% - \ifundef\chapter - {\blx@err@nodocdiv{chapter}} - {\pretocmd\@makechapterhead{#1} - {} - {\blx@err@patch{\string\@makechapterhead}}}} - -\def\blx@refpatch@sect#1{% - \ifcsundef{#1} - {\blx@err@nodocdiv{#1}\@gobbletwo} - {\blx@refpatch@sect@i}} - -\edef\blx@refpatch@sect@i#1#2{% - \def\noexpand\do##1{% - \pretocmd##1% - {\noexpand\blx@refpatch@sect@ii{#1}{#2}{\string#2}} - {\togglefalse{blx@tempa}\noexpand\listbreak} - {}}% - \noexpand\blx@refpatch@sect@iii} - -\def\blx@refpatch@sect@ii#1#2#3{% - \ifnumequal{#2}{#3}{#1}{}} - -\def\blx@refpatch@sect@iii{% - \toggletrue{blx@tempa}% - \docsvlist{% order does matter: - \H@old@sectm@m,% memoir+hyperref (what a mess...) - \M@sect,% memoir - \H@old@sect,% hyperref - \NR@sect,% nameref - \scr@sect,% koma-script 3.x - \@sect}% latex - \iftoggle{blx@tempa} - {\blx@err@patch{\string\@sect}} - {}% - \let\do\noexpand} - -% Bibliography categories - -\let\blx@categories\@empty - -% {} - -\newrobustcmd*{\DeclareBibliographyCategory}[1]{% - \ifcsundef{blx@catg@#1} - {\global\cslet{blx@catg@#1}\@empty - \listgadd\blx@categories{#1}} - {\blx@error - {Category '#1' already declared} - {The bibliography category '#1'\MessageBreak - has already been declared}}} -\@onlypreamble\DeclareBibliographyCategory - -% {}{,...} - -\newrobustcmd*{\addtocategory}[2]{% - \ifcsundef{blx@catg@#1} - {\blx@error - {Category '#1' not declared} - {Use \string\DeclareBibliographyCategory\space to declare}} - {\AfterPreamble{% - \blx@xsanitizeafter{\forcsvlist{\blx@addtocategory{#1}}}{#2}}}} - -% {}{,...} - -\def\blx@addtocategory#1#2{% - \blx@auxwrite\@mainaux{}{\string\abx@aux@category{#1}{#2}}% - \abx@aux@category{#1}{#2}} - -% {}{,...} - -\protected\def\abx@aux@category#1#2{% - \xifinlistcs{\detokenize{#2}}{blx@catg@#1} - {} - {\listcsxadd{blx@catg@#1}{\detokenize{#2}}}} - -\AtEndDocument{\let\abx@aux@category\@gobbletwo} - -% []{,...} - -\renewrobustcmd*{\bibliography}[1]{% - \begingroup - \def\blx@tempa{file}% - \def\blx@tempb{bibtex}% - \def\blx@tempc{local}% - \blx@xsanitizeafter{\forcsvlist\blx@addbib@legacy}{#1}% - \endgroup} -\@onlypreamble\bibliography - -\def\blx@addbib@legacy#1{% - \begingroup - \edef\blx@tempa{\endgroup - \noexpand\blx@addbib@resource{\blx@stripbib{#1}\detokenize{.bib}}}% - \blx@tempa} - -\def\blx@stripbib#1{% - \expandafter\blx@stripbib@i\detokenize{#1.bib}&} -\edef\blx@stripbib@i{% - \def\noexpand\blx@stripbib@i##1\detokenize{.bib}##2&} -\blx@stripbib@i{#1} - -% []{,...} - -\newrobustcmd*{\addbibresource}{% - \blx@addbib\blx@addbib@resource} -\@onlypreamble\addbibresource - -\newrobustcmd*{\addglobalbib}{% - \blx@addbib\blx@addbib@global} -\@onlypreamble\addglobalbib - -\newrobustcmd*{\addsectionbib}{% - \blx@addbib\blx@addbib@register} -\@onlypreamble\addsectionbib - -\def\blx@addbib#1{% - \@ifnextchar[%] - {\blx@addbib@i{#1}} - {\blx@addbib@i{#1}[]}} - -\def\blx@addbib@i#1[#2]{% - \begingroup - \blx@hook@fileverb - \blx@addbib@ii{#1}{#2}} - -\def\blx@addbib@ii#1#2#3{% - \endgroup - \begingroup - \def\blx@tempa{file}% - \def\blx@tempb{bibtex}% - \def\blx@tempc{local}% - \undef\blx@tempd - \setkeys{blx@addbib}{#2}% - \blx@xsanitizeafter{#1}{#3}% - \endgroup} - -\def\blx@hook@fileverb{% - \let\do\@makeother - \dospecials - \catcode`\\=\z@ - \catcode`\{=\@ne - \catcode`\}=\tw@} - -\define@key{blx@addbib}{type}{\def\blx@tempa{#1}} -\define@key{blx@addbib}{datatype}{\def\blx@tempb{#1}} -\define@key{blx@addbib}{location}{\def\blx@tempc{#1}} -\define@key{blx@addbib}{label}{\edef\blx@tempd{\detokenize{#1}}} - -% \blx@res@type@ resource -> type -% \blx@res@data@ resource -> datatype -% \blx@res@loca@ resource -> datatype -% \blx@res@labl@ label -> resource - -\def\blx@addbib@register#1{% - \csxdef{blx@res@type@#1}{\blx@tempa}% - \csxdef{blx@res@data@#1}{\blx@tempb}% - \csxdef{blx@res@loca@#1}{\blx@tempc}% - \ifdef\blx@tempd - {\csxdef{blx@res@labl@\blx@tempd}{#1}} - {}} - -\def\blx@addbib@resource#1{% - \blx@addbib@register{#1}% - \listgadd\blx@bibfiles{#1}% - \blx@regbibfile\jobname{#1}} - -\def\blx@addbib@global#1{% - \blx@addbib@resource{#1}% - \listgadd\blx@bibfiles@global{#1}} - -\let\blx@bibfiles\@empty -\let\blx@bibfiles@global\@empty - -\def\blx@bibdata#1#2{% - \forlistloop{\blx@bibdata@i{#1}}#2} -\def\blx@bibdata@i#1#2{% - \blx@xmlsanitizeafter{\blx@bibdata@ii{#1}{#2}}{#2}} -\def\blx@bibdata@ii#1#2#3{% - \eappto#1{% - \blx@xml@datasource - {\ifcsdef{blx@res@type@#2} - {\csuse{blx@res@type@#2}} - {file}} - {\ifcsdef{blx@res@data@#2} - {\csuse{blx@res@data@#2}} - {bibtex}} - {#3}}} - -%% Citations - -\newrobustcmd*{\AtEveryCite}{\gappto\blx@hook@cite} -\newrobustcmd*{\AtEveryCitekey}{\gappto\blx@hook@citekey} -\newrobustcmd*{\AtEveryMultiCite}{\gappto\blx@hook@mcite} -\@onlypreamble\AtEveryCite -\@onlypreamble\AtEveryCitekey -\@onlypreamble\AtEveryMultiCite - -\newrobustcmd*{\AtEachCitekey}{% - \iftoggle{blx@citation}{\appto\blx@hook@citekey}{\@gobble}} - -\def\blx@imc@UseEveryCiteHook{\csuse{blx@hook@cite}} -\def\blx@imc@UseEveryCitekeyHook{\csuse{blx@hook@citekey}} -\def\blx@imc@UseEveryMultiCiteHook{\csuse{blx@hook@mcite}} - -\newrobustcmd*{\AtNextCite}{% - \ifundef\blx@hook@cite@next - {\gdef\blx@hook@cite@next{\global\undef\blx@hook@cite@next}} - {}% - \gappto\blx@hook@cite@next} - -\newrobustcmd*{\AtNextCitekey}{% - \ifundef\blx@hook@citekey@next - {\gdef\blx@hook@citekey@next{\global\undef\blx@hook@citekey@next}} - {}% - \gappto\blx@hook@citekey@next} - -\newrobustcmd*{\AtNextMultiCite}{% - \ifundef\blx@hook@mcite@next - {\gdef\blx@hook@mcite@next{\global\undef\blx@hook@mcite@next}} - {}% - \gappto\blx@hook@mcite@next} - -\def\blx@imc@UseNextCiteHook{\csuse{blx@hook@cite@next}} -\def\blx@imc@UseNextCitekeyHook{\csuse{blx@hook@citekey@next}} -\def\blx@imc@UseNextMultiCiteHook{\csuse{blx@hook@mcite@next}} - -\def\blx@imc@DeferNextCitekeyHook{\undef\blx@hook@citekey@next} - -\blx@regimcs{% - \UseEveryCiteHook \UseEveryCitekeyHook \UseEveryMultiCiteHook - \UseNextCiteHook \UseNextCitekeyHook \UseNextMultiCiteHook - \DeferNextCitekeyHook} - -% {