summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/biblatex-contrib/biblatex-chicago/latex/chicago-authordate16.bbx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/biblatex-contrib/biblatex-chicago/latex/chicago-authordate16.bbx')
-rw-r--r--macros/latex/contrib/biblatex-contrib/biblatex-chicago/latex/chicago-authordate16.bbx4935
1 files changed, 4935 insertions, 0 deletions
diff --git a/macros/latex/contrib/biblatex-contrib/biblatex-chicago/latex/chicago-authordate16.bbx b/macros/latex/contrib/biblatex-contrib/biblatex-chicago/latex/chicago-authordate16.bbx
new file mode 100644
index 0000000000..e0bde354e9
--- /dev/null
+++ b/macros/latex/contrib/biblatex-contrib/biblatex-chicago/latex/chicago-authordate16.bbx
@@ -0,0 +1,4935 @@
+% This is a biblatex style file, adapted mainly from Lehman's
+% standard.bbx and from chicago-notes.bbx. It provides the
+% reference list formatting for the Chicago author-date style.
+
+\ProvidesFile{chicago-authordate16.bbx}[2020/04/20 v 3.14 biblatex
+bibliography style]
+
+%%%% Initialize and format bibliography and los %%%%
+
+\providetoggle{cms@citejtabb}% Here for Sourcemap declaration
+\providetoggle{cms@bibjtabb}%
+
+\DeclareFieldFormat{shorthandwidth}{#1}
+
+\DeclareFieldFormat{shortjournalwidth}{%
+ \ifthenelse{\ifentrytype{jurisdiction}\OR%
+ \ifentrytype{legal}\OR\ifentrytype{legislation}}%
+ {\textbf{#1}\isdot}%
+ {\mkbibemph{\textbf{#1}}\isdot}}%
+
+\newlength{\lositemsep}
+
+\defbibenvironment{bibliography}% New for 0.9a
+ {\list
+ {}
+ {\setlength{\leftmargin}{\bibhang}%
+ \setlength{\itemindent}{-\leftmargin}%
+ \setlength{\itemsep}{\bibitemsep}%
+ \setlength{\parsep}{\bibparsep}}}
+ {\endlist}
+ {\item}
+
+\defbibenvironment{shorthand}
+ {\list
+ {\printfield[shorthandwidth]{shorthand}}%
+ {\setlength{\labelwidth}{\shorthandwidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\lositemsep}%
+ \setlength{\parsep}{\bibparsep}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}}
+ {\endlist}
+ {\item}
+
+\defbibenvironment{losnotes}
+ {\list
+ {\printfield[shorthandwidth]{shorthand}}%
+ {\footnotesize%
+ \setlength{\labelwidth}{\shorthandwidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{.3\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\lositemsep}%
+ \setlength{\parsep}{\bibparsep}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}}
+ {\endlist}
+ {\item}
+
+\defbibenvironment{losendnotes}
+ {\list
+ {\printfield[shorthandwidth]{shorthand}}%
+ {\enotesize%
+ \setlength{\labelwidth}{\shorthandwidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{.3\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\lositemsep}%
+ \setlength{\parsep}{\bibparsep}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}}
+ {\endlist\nopunct\vspace{-\baselineskip}}% Kludges for endnotes
+ {\item}
+
+\defbibenvironment{shortjournal}%
+ {\list
+ {\printfield[shortjournalwidth]{shortjournal}}%
+ {\setlength{\labelwidth}{\shortjournalwidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{.7\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\lositemsep}%
+ \setlength{\parsep}{\bibparsep}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}}
+ {\endlist}
+ {\item}
+
+\defbibenvironment{sjnotes}%
+ {\list
+ {\printfield[shortjournalwidth]{shortjournal}}%
+ {\footnotesize%
+ \setlength{\labelwidth}{\shortjournalwidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{.3\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\lositemsep}%
+ \setlength{\parsep}{\bibparsep}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}}
+ {\endlist}
+ {\item}
+
+\defbibenvironment{sjendnotes}%
+ {\list
+ {\printfield[shortjournalwidth]{shortjournal}}%
+ {\enotesize%
+ \setlength{\labelwidth}{\shortjournalwidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{.3\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\lositemsep}%
+ \setlength{\parsep}{\bibparsep}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}}
+ {\endlist\nopunct\vspace{-\baselineskip}}
+ {\item}
+
+\defbibcheck{shorthand}{%
+ \iftoggle{cms@los}%
+ {\iffieldundef{shorthand}%
+ {\skipentry}%
+ {\ifcsdef{\strfield{shorthand}}%
+ {\skipentry}%
+ {\savefieldcs{shorthand}{\strfield{shorthand}}}}}%
+ {}}%
+
+\defbibcheck{shortjournal}{% Only one list
+ \iffieldundef{shortjournal}%
+ {\skipentry}%
+ {\ifcsdef{\strfield{shortjournal}=\strfield{journaltitle}}%
+ {\skipentry}%
+ {\savefieldcs{shortjournal}%
+ {\strfield{shortjournal}=\strfield{journaltitle}}}}}%
+
+% \defbibcheck{shortjournal}{% Multiple lists
+% \ifcsdef{cms@shjour}%
+% {\iffieldequals{shortjournal}{\cms@shjour}%
+% {\skipentry}%
+% {\savefield{shortjournal}{\cms@shjour}}}%
+% {\savefield{shortjournal}{\cms@shjour}}}
+
+\AtBeginBibliography{%
+ \togglefalse{cms@headlessnote}}%
+
+\AtEveryBibitem{%
+ \global\csundef{@cmsst}%
+ \iffieldequalstr{pubstate}{reprint}%
+ {\toggletrue{cms@reprint}}%
+ {\togglefalse{cms@reprint}}}%
+
+\AtEveryLositem{%
+ \global\csundef{@cmsst}%
+ \iffieldequalstr{pubstate}{reprint}%
+ {\toggletrue{cms@reprint}}%
+ {\togglefalse{cms@reprint}}}%
+
+\AtEveryBiblistitem{shortjournal}{%
+ \global\csundef{@cmsst}%
+ \ifthenelse{\ifentrytype{jurisdiction}\OR%
+ \ifentrytype{legal}\OR\ifentrytype{legislation}}%
+ {\clearlist{location}}%
+ {}}%
+
+\InitializeBibliographyStyle{%
+ \let\bbx@lasthash\undefined}%
+
+%%%% Bibliography-specific bibstrings %%%%
+
+%% Now in *.lbx %%
+
+%%%% Author, Editor, Translator, and Compiler Macros %%%%
+
+\renewbibmacro*{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}%
+ \ifpunctmark{'}{}{\addhighpenspace}}%
+ \mkbibnamelast{#1}\isdot
+ \ifblank{#2}{}{\addcomma\addlowpenspace\mkbibnamefirst{#2}\isdot}%
+ \ifblank{#4}{}{\addcomma\addlowpenspace\mkbibnameaffix{#4}\isdot}}%
+ {\usebibmacro{name:delim}{#1}%
+ \usebibmacro{name:hook}{#1}%
+ \mkbibnamelast{#1}\isdot%
+ \ifblank{#2#3#4}{}{\addcomma}%
+ \ifblank{#2}{}{\addlowpenspace\mkbibnamefirst{#2}\isdot}%
+ \ifblank{#3}{}{\addlowpenspace\mkbibnameprefix{#3}\isdot}%
+ \ifblank{#4}{}{\addcomma\addlowpenspace\mkbibnameaffix{#4}\isdot}}}
+
+\renewbibmacro*{name:first-last}[4]{%
+ \usebibmacro{name:delim}{#2#3#1}%
+ \usebibmacro{name:hook}{#2#3#1}%
+ \ifblank{#2}{}{\mkbibnamefirst{#2}\isdot\addlowpenspace}%
+ \ifblank{#3}{}{%
+ \mkbibnameprefix{#3}\isdot
+ \ifpunctmark{'}%
+ {}%
+ {\ifuseprefix{\addhighpenspace}{\addlowpenspace}}}%
+ \mkbibnamelast{#1}\isdot
+ \ifblank{#4}{}{%
+ \iftoggle{cms@jrcomma}%
+ {\ifnumeral{#4}%
+ {\addlowpenspace\mkbibnameaffix{#4}\isdot}%
+ {\addcomma\addlowpenspace\mkbibnameaffix{#4}\isdot%
+ \ifboolexpr{%
+ test{\ifnumless{\value{listcount}}{\value{listtotal}}}%
+ and
+ test{\ifnumless{\value{listcount}}{\value{maxnames}}}%
+ }%
+ {\addcomma}%
+ {}}}%
+ {\addlowpenspace\mkbibnameaffix{#4}\isdot}}}%
+
+\@ifpackagelater{biblatex}{2016/03/01}% For biblatex 3.3
+{\renewbibmacro*{name:family-given}[4]{%
+ \ifuseprefix
+ {\usebibmacro{name:delim}{#3#1}%
+ \usebibmacro{name:hook}{#3#1}%
+ \ifdefvoid{#3}{}{%
+ \ifcapital
+ {\mkbibnameprefix{\MakeCapital{#3}}\isdot}%
+ {\mkbibnameprefix{#3}\isdot}%
+ \ifprefchar{}{\bibnamedelimc}}%
+ \mkbibnamefamily{#1}\isdot
+ \ifdefvoid{#2}{}{\revsdnamepunct\bibnamedelimd\mkbibnamegiven{#2}\isdot}%
+ \ifdefvoid{#4}{}{\revsdnamepunct\bibnamedelimd\mkbibnamesuffix{#4}\isdot}}%
+ {\usebibmacro{name:delim}{#1}%
+ \usebibmacro{name:hook}{#1}%
+ \mkbibnamefamily{#1}\isdot
+ \ifboolexpr{%
+ test {\ifdefvoid{#2}}%
+ and
+ test {\ifdefvoid{#3}}%
+ }%
+ {}{\revsdnamepunct}%
+ \ifdefvoid{#2}{}{\bibnamedelimd\mkbibnamegiven{#2}\isdot}%
+ \ifdefvoid{#3}{}{\bibnamedelimd\mkbibnameprefix{#3}\isdot}%
+ \ifdefvoid{#4}{}{\revsdnamepunct\bibnamedelimd\mkbibnamesuffix{#4}\isdot}}}%
+
+\renewbibmacro*{name:given-family}[4]{%
+ \usebibmacro{name:delim}{#2#3#1}%
+ \usebibmacro{name:hook}{#2#3#1}%
+ \ifdefvoid{#2}{}{\mkbibnamegiven{#2}\isdot\bibnamedelimd}%
+ \ifdefvoid{#3}{}{%
+ \mkbibnameprefix{#3}\isdot
+ \ifprefchar
+ {}%
+ {\ifuseprefix{\bibnamedelimc}{\bibnamedelimd}}}%
+ \mkbibnamefamily{#1}\isdot
+ \ifdefvoid{#4}{}{%
+ \iftoggle{cms@jrcomma}%
+ {\ifnumeral{#4}%
+ {\bibnamedelimd\mkbibnamesuffix{#4}\isdot}%
+ {\revsdnamepunct\bibnamedelimd\mkbibnamesuffix{#4}\isdot%
+ \ifboolexpr{% Test needed?
+ test{\ifnumless{\value{listcount}}{\value{listtotal}}}%
+ and
+ test{\ifnumless{\value{listcount}}{\value{maxnames}}}%
+ }%
+ {\revsdnamepunct}%
+ {}}}%
+ {\bibnamedelimd\mkbibnamesuffix{#4}\isdot}}}}{}%
+
+\renewbibmacro*{author/editor}{%
+ \ifboolexpr{%
+ test {\ifuseauthor}%
+ or
+ togl {cms@headlessnote}%
+ }%
+ {\usebibmacro{author}}%
+ {\ifusenamea%
+ {\usebibmacro{pickeditor}}%
+ {\ifuseeditor%
+ {\usebibmacro{moreeditor}}%
+ {\ifusenameb%
+ {\usebibmacro{picktranslator}}%
+ {\ifusetranslator%
+ {\usebibmacro{moretranslator}}%
+ {\ifusenamec%
+ {\usebibmacro{compiler}}%
+ {\let\bbx@lasthash\undefined}}}}}}}%
+
+\renewbibmacro*{author}{%
+ \iftoggle{cms@headlessnote}%
+ {\usebibmacro{justauthor}}%
+ {\usebibmacro{moreauthor}}}
+
+\newbibmacro*{justauthor}{%
+ \ifthenelse{\ifnameundef{author}\OR\NOT\ifuseauthor}%
+ {\let\bbx@lasthash\undefined}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}}%
+ {\printtext{\bibnamedash}%
+ \ifentrytype{customc}%
+ {\newunit}%
+ {\setunit{\addspace}}\printfield{nameaddon}}}%
+ {\iffieldequalstr{authortype}{anon}%
+ {\bibleftbracket\printnames{author}\bibrightbracket%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ {\iffieldequalstr{authortype}{anon?}%
+ {\bibleftbracket\printnames{author}\addquestion\bibrightbracket%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames{author}%
+ \ifentrytype{customc}{}%
+ {\setunit{\addspace}\printfield{nameaddon}}\bibcloseparen%
+ \ifentrytype{customc}%
+ {\newunit\printfield{nameaddon}}%
+ {}}%
+ {\printnames{author}%
+ \ifentrytype{customc}{\newunit}{\setunit{\addspace}}%
+ \printfield{nameaddon}}%
+ \savefield{fullhash}{\bbx@lasthash}}}}}}
+
+\newbibmacro*{moreauthor}{%
+ \ifthenelse{\ifnameundef{author}\OR\NOT\ifuseauthor}%
+ {\usebibmacro{pickeditor}}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}}%
+ {\printtext{\bibnamedash}\setunit{\addspace}\printfield{nameaddon}}}%
+ {\iffieldequalstr{authortype}{anon}%
+ {\bibleftbracket\printnames{author}\bibrightbracket%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ {\iffieldequalstr{authortype}{anon?}%
+ {\bibleftbracket\printnames{author}\addquestion\bibrightbracket%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames{author}%
+ \setunit{\addspace}\printfield{nameaddon}\bibcloseparen}%
+ {\printnames{author}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}}%
+ \savefield{fullhash}{\bbx@lasthash}}}}}}
+
+\newbibmacro*{pickeditor}{%
+ \ifthenelse{\ifnameundef{namea}\OR\NOT\ifusenamea}%
+ {\usebibmacro{moreeditor}}%
+ {\usebibmacro{parteditor}}}
+
+\newbibmacro*{moreeditor}{%
+ \ifthenelse{\ifnameundef{editor}\OR\NOT\ifuseeditor}%
+ {\usebibmacro{picktranslator}}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}\editordelim}%
+ {\printtext{\bibnamedash}\setunit{\addspace}%
+ \printfield{nameaddon}\editordelim}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames{editor}%
+ \setunit{\addspace}\printfield{nameaddon}%
+ \bibcloseparen\editordelim}%
+ {\printnames{editor}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}\editordelim}%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ \usebibmacro{editstrg}}}%
+
+\renewbibmacro*{editor}{%
+ \iftoggle{cms@headlessnote}%
+ {}%
+ {\ifthenelse{\ifnameundef{namea}\OR\NOT\ifusenamea}%
+ {\ifthenelse{\ifnameundef{editor}\OR\NOT\ifuseeditor}%
+ {\usebibmacro{picktranslator}}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}\editordelim}%
+ {\printtext{\bibnamedash}\setunit{\addspace}%
+ \printfield{nameaddon}\editordelim}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames{editor}%
+ \setunit{\addspace}\printfield{nameaddon}%
+ \bibcloseparen\editordelim}%
+ {\printnames{editor}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}\editordelim}%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ \usebibmacro{editstrg}}}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}\nameadelim}%
+ {\printtext{\bibnamedash}\setunit{\addspace}%
+ \printfield{nameaddon}\nameadelim}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames[sortname]{namea}%
+ \setunit{\addspace}\printfield{nameaddon}%
+ \bibcloseparen\nameadelim}%
+ {\printnames[sortname]{namea}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}\nameadelim}%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ \usebibmacro{parteditstrg}}}}
+
+\newbibmacro*{parteditor}{%
+ \ifthenelse{\ifnameundef{namea}\OR\NOT\ifusenamea}%
+ {\usebibmacro{picktranslator}}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}\nameadelim}%
+ {\printtext{\bibnamedash}\setunit{\addcomma}%
+ \printfield{nameaddon}\nameadelim}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames[sortname]{namea}%
+ \setunit{\addspace}\printfield{nameaddon}%
+ \bibcloseparen\nameadelim}%
+ {\printnames[sortname]{namea}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}\nameadelim}%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ \usebibmacro{parteditstrg}}}
+
+\newbibmacro*{picktranslator}{%
+ \ifthenelse{\ifnameundef{nameb}\OR\NOT\ifusenameb}%
+ {\usebibmacro{moretranslator}}%
+ {\usebibmacro{parttranslator}}}
+
+\newbibmacro*{moretranslator}{%
+ \ifthenelse{\ifnameundef{translator}\OR\NOT\ifusetranslator}%
+ {\usebibmacro{compiler}}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}\newcunit}%
+ {\printtext{\bibnamedash}\setunit{\addspace}%
+ \printfield{nameaddon}\newcunit}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames[sortname]{translator}%
+ \setunit{\addspace}\printfield{nameaddon}%
+ \bibcloseparen\newcunit}%
+ {\printnames[sortname]{translator}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}\newcunit}%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ \usebibmacro{transstrg}}}
+
+\newbibmacro*{parttranslator}{%
+ \ifthenelse{\ifnameundef{nameb}\OR\NOT\ifusenameb}%
+ {\usebibmacro{compiler}}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}\newcunit}%
+ {\printtext{\bibnamedash}\setunit{\addspace}%
+ \printfield{nameaddon}\newcunit}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames[sortname]{nameb}%
+ \setunit{\addspace}\printfield{nameaddon}%
+ \bibcloseparen\newcunit}%
+ {\printnames[sortname]{nameb}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}\newcunit}%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ \usebibmacro{parttransstrg}}}
+
+\newbibmacro*{compiler}{%
+ \ifthenelse{\ifnameundef{namec}\OR\NOT\ifusenamec}%
+ {\let\bbx@lasthash\undefined}%
+ {\ifboolexpr{%
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ and
+ not test {\iffirstonpage}%
+ and
+ togl {cms@namedash}%
+ }%
+ {\iffieldundef{nameaddon}%
+ {\printtext{\bibnamedash}\newcunit}%
+ {\printtext{\bibnamedash}\setunit{\addcomma}%
+ \printfield{nameaddon}\newcunit}}%
+ {\iftoggle{cms@authorparens}%
+ {\bibopenparen\printnames[sortname]{namec}%
+ \setunit{\addspace}\printfield{nameaddon}%
+ \bibcloseparen\newcunit}%
+ {\printnames[sortname]{namec}%
+ \setunit{\addspace}%
+ \printfield{nameaddon}\newcunit}%
+ \savefield{fullhash}{\bbx@lasthash}}%
+ \usebibmacro{compilestrg}}}
+
+\renewcommand*{\revsdnamedelim}{\addcomma}
+
+\DeclareNameAlias{author}{sortname}% Needed in 0.9
+\DeclareNameAlias{editor}{sortname}
+\DeclareNameAlias{translator}{sortname}
+
+%%%% Drivers for Bibliography entries and Shorthands %%%%
+
+\DeclareBibliographyDriver{shorthand}{%
+ \iftoggle{cms@los}%
+ {\ifnameundef{labelname}%
+ {\mkbibemph{\bibstring{see}}%
+ \addspace%
+ \usebibmacro{shorthand:label}}%
+ {\mkbibemph{\bibstring{see}}%
+ \addspace%
+ \ifboolexpr{%
+ test {\iffieldequalstr{labelnamesource}{shortauthor}}%
+ and
+ test {\ifentrytype{manual}}%
+ }%
+ {\printnames{\thefield{labelnamesource}}}%
+ {\ifentrytype{customc}%
+ {\clearfield{nameaddon}}%
+ {}%
+ \usebibmacro{author/editor}}}%
+ \finentry}%
+ {\iftoggle{cms@fullshhand}%
+ {\usedriver{\frenchspacing}%
+ {\thefield{entrytype}}%
+ \finentry}%
+ {\ifnameundef{labelname}%
+ {\ifthenelse{\iffieldequalstr{entrysubtype}{magazine}\AND\NOT%
+ \ifentrytype{periodical}}%
+ {\printtext[bibhyperref]{\printfield[journaltitle]{journaltitle}%
+ \newcunit}}%
+ {\ifentrytype{manual}%
+ {\printtext[bibhyperref]{\printlist{organization}\newcunit}}%
+ {}}}%
+ {\ifboolexpr{%
+ test {\iffieldequalstr{labelnamesource}{shortauthor}}%
+ and
+ test {\ifentrytype{manual}}%
+ }%
+ {\printnames{\thefield{labelnamesource}}\newunit}%
+ {\ifentrytype{customc}%
+ {\usebibmacro{justauthor}\setunit{\addspace}}%
+ {\usebibmacro{author/editor}\newunit}}}%
+ \printfield[lostitle]{title}%
+ \finentry}}}
+
+\DeclareBibliographyDriver{shortjournal}{%
+ \iffieldundef{journaltitle}%
+ {\printtext[title]{%
+ \printfield[tnoformat]{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[stnoformat]{subtitle}}%
+ \setunit*{\addspace}%
+ \printlist[periodplace]{location}}%
+ {\printtext[journaltitle]{%
+ \printfield[jtnoformat]{journaltitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[sjtnoformat]{journalsubtitle}}%
+ \setunit*{\addspace}%
+ \printlist[periodplace]{location}}%
+ \finentry}%
+
+\DeclareStyleSourcemap{
+ \maps[datatype=bibtex]{
+ \map{
+ \pertype{periodical}
+ \step[fieldsource=shorttitle, final]
+ \step[fieldset=shortjournal, origfieldval]
+ }
+ \map{
+ \step[fieldsource=pubstate, match={forthcoming}, final]
+ \step[fieldset=year, origfieldval, final]
+ \step[fieldsource=year, match=\regexp{(forthcoming)},
+ replace=\regexp{\\bibstring\{$1\}}]%$
+ \step[fieldset=pubstate, null]
+ }
+ \map{
+ \pertype{article}
+ \pertype{periodical}
+ \pertype{review}
+ \pertype{suppperiodical}
+ \step[fieldsource=entrysubtype, match={newspaper},
+ replace={magazine}]
+ }
+ \map{
+ \pertype{jurisdiction}
+ \pertype{legal}
+ \pertype{legislation}
+ \step[fieldsource=journaltitle, final]
+ \step[fieldset=shortjournal, origfieldval]
+ }
+ \map[overwrite]{
+ \pertype{jurisdiction}
+ \step[fieldsource=shortjournal, match=\regexp{[^\\adddot][a-z]}, final]
+ \step[fieldset=shortjournal, fieldvalue=\addnbspace, append]
+ }
+ \map{
+ \pertype{legislation}
+ \step[fieldsource=title, match=\regexp{Const}, final]
+ \step[fieldset=entrysubtype, fieldvalue=constitution]
+ }
+ \map{
+ \pertype{legislation}
+ \step[fieldsource=entrysubtype, match=\regexp{canada}, final]
+ \step[fieldsource=bookpagination, match={section},
+ replace={canadasection}]
+ \step[fieldsource=pagination, match={section},
+ replace={canadasection}]
+ }
+ \map[overwrite]{
+ \step[fieldsource=subtitle, final]
+ \step[fieldsource=title,
+ match=\regexp{\\(mkbib|en)quote\{.+((\?|\!)\})$},%$
+ final]
+ \step[fieldset=title, fieldvalue=\csgdef{@cmsst}{\@ne}, append]
+ }
+ \map[overwrite]{
+ \step[fieldsource=booksubtitle, final]
+ \step[fieldsource=booktitle,
+ match=\regexp{\\(mkbib|en)quote\{.+((\?|\!)\})$},%$
+ final]
+ \step[fieldset=booktitle, fieldvalue=\csgdef{@cmsst}{\@ne}, append]
+ }
+ \map[overwrite]{
+ \step[fieldsource=issuesubtitle, final]
+ \step[fieldsource=issuetitle,
+ match=\regexp{\\(mkbib|en)quote\{.+((\?|\!)\})$},%$
+ final]
+ \step[fieldset=issuetitle, fieldvalue=\csgdef{@cmsst}{\@ne}, append]
+ }
+ \map[overwrite]{
+ \step[fieldsource=journalsubtitle, final]
+ \step[fieldsource=journaltitle,
+ match=\regexp{\\(mkbib|en)quote\{.+((\?|\!)\})$},%$
+ final]
+ \step[fieldset=journaltitle, fieldvalue=\csgdef{@cmsst}{\@ne}, append]
+ }
+ \map[overwrite]{
+ \step[fieldsource=mainsubtitle, final]
+ \step[fieldsource=maintitle,
+ match=\regexp{\\(mkbib|en)quote\{.+((\?|\!)\})$},%$
+ final]
+ \step[fieldset=maintitle, fieldvalue=\csgdef{@cmsst}{\@ne}, append]
+ }
+ \map[overwrite]{
+ \step[fieldsource=year, match=\regexp{^\\mkbibbrackets\{(.+)\}(.*)$},%$
+ replace=\regexp{[$1]$2}]% Kludge for backward compat.
+ }
+ }
+}%
+
+\DeclareBibliographyDriver{article}{%
+ \iffieldequalstr{entrysubtype}{magazine}%
+ {\usebibmacro{bibindex}%
+ \usebibmacro{mag+news+author}%
+ \newunit\newblock
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \usebibmacro{mag+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \newunit\newblock%
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newunit\newblock%
+ \usebibmacro{bibreprint}%
+ \usebibmacro{issuetitle}%
+ \setunit*{\addcomma\addspace}%
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock% 17th ed. clarifies punctuation
+ \printfield{note}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{mag+news+date}%
+ \newcunit\newblock
+ \usebibmacro{chap+pag}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \ifboolexpr{%
+ togl {cms@related}%
+ and
+ not test {\iffieldequalstr{relatedtype}{reviewof}}%
+ }%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+ {\usebibmacro{bibindex}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef{\bbx@lasthash}{\usebibmacro{mag+news+title}\newunit}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef{\bbx@lasthash}{}{\usebibmacro{mag+news+title}}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit*{\addperiod\addspace}\newblock% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newunit\newblock%
+ \usebibmacro{bibreprint}%
+ \usebibmacro{issuetitle}%
+ \setunit*{\addcomma\addspace}%
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock% 17th ed.
+ \printfield{note}%
+ \setunit*{\addcomma\addspace}\newblock% (changed for 0.7)??
+ \usebibmacro{journal+issue+year+pages}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \ifboolexpr{%
+ togl {cms@related}%
+ and
+ not test {\iffieldequalstr{relatedtype}{reviewof}}%
+ }%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{artwork}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newcunit\newblock
+ \usebibmacro{date}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \printfield{howpublished}%
+ \newunit\newblock
+ \printfield{type}%
+ \newcunit\newblock
+ \printfield{version}%
+ \newcunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{institution+organization}%
+ \setunit*{\addcomma\addspace}\newblock
+ \printlist{location}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{audio}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\ifundef{\bbx@lasthash}}%
+ and
+ not test {\iffieldundef{title}}%
+ }%
+ {\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\ifundef{\bbx@lasthash}}%
+ or
+ test {\iffieldundef{title}}%
+ }%
+ {}{\usebibmacro{italtitle+stitle}}%
+ \newunit\newblock% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newcunit%\setunit{\addperiod\addspace}%
+ \usebibmacro{chapinscore}%
+ \usebibmacro{btitle+bstitle}%
+ \iffieldundef{booktitle}%
+ {\setunit{\addperiod\addspace}}% Fix customc?
+ {\setunit{\addcomma\addspace}}%
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newunit% unit, not cunit?
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{byeditor+others}%
+ \newunit% ??? Editorpunct maybe not right here?
+ \iffieldundef{maintitle}%
+ {}%
+ {\ifthenelse{\iffieldundef{volume}\AND\iffieldundef{part}}%
+ {\ifthenelse{\iffieldundef{title}\AND\iffieldundef{booktitle}}%
+ {\usebibmacro{cms-in:}}%
+ {\bibstring{in}\setunit{\addspace}}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}%
+ {\printfield{volume}%
+ \printfield{part}%
+ \setunit{\addspace}%
+ \bibstring{ofseries}%
+ \setunit{\addspace}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}% Reversed with bibreprint 16th ed. (?)
+ \newunit\newblock
+ \usebibmacro{bibreprint}%\printorigdate%
+ \usebibmacro{publ+loc+year}%
+ \newunit
+ \printfield{type}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isan}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \printfield{ismn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+
+\DeclareBibliographyDriver{book}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit\newblock
+ \iffieldundef{maintitle}%
+ {\iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}}%
+ {}%
+ \newunit\newblock% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\usebibmacro{mtitle+mstitle+vol+part+title+stitle}%
+ \newcunit
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditor+others}%
+ \usebibmacro{editorpunct}%
+ \iftoggle{cms@bookpages}%
+ {}%
+ {\clearfield{pages}}%
+ \printfield{chapter}%
+ \setunit*{\addcomma\addspace}%
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newcunit\newblock
+ \printlist[][-\value{listtotal}]{lista}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{bookinbook}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit\newblock
+ \ifthenelse{\iffieldundef{maintitle}\AND\iffieldundef{booktitle}}%
+ {\iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}}%
+ {}%
+ \newunit\newblock% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \setunit*{\addperiod\addspace}%
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\usebibmacro{mtitle+mstitle+vol+part+btitle+bstitle}%
+ \newcunit
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newcunit
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditor+others}%
+ \newcunit\newblock
+ \printfield{chapter}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{booklet}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit\newblock% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{howpubl+loc+year}%
+ \newunit\newblock
+ \usebibmacro{chap+pag}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{collection}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\usebibmacro{mtitle+mstitle+vol+part+title+stitle}%
+ \usebibmacro{editorpunct}%
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditor+others}%
+ \newunit
+ \usebibmacro{volume+or+volumes}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{customc}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{justauthor}%
+ \iffieldundef{nameaddon}%
+ {\newunit}%
+ {\setunit{\addspace}}%
+ \usebibmacro{italtitle+stitle}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{image}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \setunit*{\addcomma\addspace}% 16th ed. added * (?)
+ \usebibmacro{date}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \printfield{howpublished}%
+ \newunit\newblock
+ \printfield{type}%
+ \newcunit\newblock
+ \printfield{version}%
+ \newcunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{institution+organization}%
+ \setunit*{\addcomma\addspace}\newblock
+ \printlist{location}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{inbook}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \setunit{\addperiod\addspace}% 16th ed.
+ \usebibmacro{byauthor}%
+ \setunit{\addperiod\addspace}%
+ \usebibmacro{part+editor+translator}%
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\setunit{\addperiod\addspace}%
+ \usebibmacro{chapincoll}%
+ \usebibmacro{mtitle+mstitle+vol+part+btitle+bstitle}%
+ \newcunit
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newcunit
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{byeditor+others}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{incollection}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \setunit{\addperiod\addspace}% 16th ed.
+ \usebibmacro{byauthor}%
+ \setunit{\addperiod\addspace}%
+ \usebibmacro{part+editor+translator}%
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\setunit{\addperiod\addspace}% Moved here.
+ \usebibmacro{chapincoll}%
+ \usebibmacro{mtitle+mstitle+vol+part+btitle+bstitle}%
+ \newcunit
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newcunit
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{byeditor+others}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{inproceedings}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \setunit{\addperiod\addspace}% 16th ed.
+ \usebibmacro{byauthor}%
+ \setunit{\addperiod\addspace}%
+ \usebibmacro{part+editor+translator}%
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\setunit{\addperiod\addspace}%
+ \usebibmacro{chapincoll}%
+ \usebibmacro{mtitle+mstitle+vol+part+btitle+bstitle}%
+ \newcunit\newblock
+ \usebibmacro{byeditor+others}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{org+publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{inreference}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{reference+title}%{italtitle+stitle}
+ \newunit\newblock
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifthenelse{\iffieldundef{maintitle}\AND\iffieldundef{booktitle}}%
+ {\iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}}%
+ {}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \setunit*{\addperiod\addspace}% need asterisk?
+ \usebibmacro{mtitle+mstitle+vol+part+btitle+bstitle}%
+ \newcunit
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newcunit
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditor+others}%
+ \newcunit\newblock
+ \printfield{chapter}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newcunit\newblock
+ \printlist[][-\value{listtotal}]{lista}%
+ \newcunit\newblock% \setunit{\addspace}% 16th ed.
+ \ifnameundef{author}%
+ {}%
+ {\printtext{% 16th ed.
+ \bibstring{by}%
+ \addspace%
+ \printnames[byauthor]{author}}}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{jurisdiction}{%
+ \iffieldequalstr{entrysubtype}{square}% FIXME?
+ {\usebibmacro{bibindex}%
+ \usebibmacro{clegis+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{byauthor}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cpart+editor+translator}%
+ \newcunit%
+ \usebibmacro{issuetitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cbyeditor+others}%
+ \setunit{\addcomma\addspace}%
+ \printfield[juridnum]{number}%
+ \newcunit%
+ \iffieldundef{year}%
+ {}%
+ {\printtext[brackets]{%
+ \begingroup% Better ideas?
+ \let\abx@bibmonth\blx@imc@bibsstring%
+ \usebibmacro{date}\endgroup}}%
+ \setunit*{\addspace}%
+ \printfield[jourvol]{volume}%
+ \setunit{\addnbspace}%
+ \iffieldundef{shortjournal}%
+ {}%
+ {\printtext[shortjournal]{%
+ \printfield[jtsnoformat]{shortjournal}}}%
+ \iffieldundef{issue}%
+ {\printfield[jurisdictionser]{series}}%
+ {\setunit{\addspace}%
+ \printfield{issue}}% Better ideas?
+ \usebibmacro{juridpostnote}%
+ \setunit{\addcomma\addspace}%
+ \printfield{note}%
+ \setunit{\addspace}%
+ \printlist{location}%
+ \setunit{\addspace}%
+ \usebibmacro{cms:shorthandintro}%
+ \setunit{\addspace}\newblock
+ \printfield{addendum}%
+ \newcunit\newblock
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \newcunit\newblock
+ \usebibmacro{cite+doi+url}%
+ \newcunit\newblock
+ \usebibmacro{pageref}%
+ \newcunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newcunit}%
+ {}%
+ \usebibmacro{finentry}}
+ {\iffieldequalstr{entrysubtype}{round}% FIXME?
+ {\usebibmacro{bibindex}%
+ \usebibmacro{clegis+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{byauthor}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cpart+editor+translator}%
+ \newcunit%
+ \usebibmacro{issuetitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cbyeditor+others}%
+ \setunit{\addcomma\addspace}%
+ \printfield[juridnum]{number}%
+ \newcunit%
+ \iffieldundef{year}%
+ {}%
+ {\printtext[parens]{%
+ \begingroup% Better ideas?
+ \let\abx@bibmonth\blx@imc@bibsstring%
+ \usebibmacro{date}\endgroup}}%
+ \setunit*{\addspace}%
+ \printfield[jourvol]{volume}%
+ \setunit{\addnbspace}%
+ \iffieldundef{shortjournal}%
+ {}%
+ {\printtext[shortjournal]{%
+ \printfield[jtsnoformat]{shortjournal}}}%
+ \iffieldundef{issue}%
+ {\printfield[jurisdictionser]{series}}%
+ {\setunit{\addspace}%
+ \printfield{issue}}% Better ideas?
+ \usebibmacro{juridpostnote}%
+ \setunit{\addcomma\addspace}%
+ \printfield{note}%
+ \setunit{\addspace}%
+ \printlist{location}%
+ \setunit{\addspace}%
+ \usebibmacro{cms:shorthandintro}%
+ \setunit{\addspace}\newblock
+ \printfield{addendum}%
+ \newcunit\newblock
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \newcunit\newblock
+ \usebibmacro{cite+doi+url}%
+ \newcunit\newblock
+ \usebibmacro{pageref}%
+ \newcunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newcunit}%
+ {}%
+ \usebibmacro{finentry}}
+ {\usebibmacro{bibindex}%
+ \usebibmacro{clegis+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{byauthor}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cpart+editor+translator}%
+ \newcunit%
+ \usebibmacro{issuetitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cbyeditor+others}%
+ \setunit{\addcomma\addspace}%
+ \printfield[juridnum]{number}%
+ \newcunit%
+ \printfield[jourvol]{volume}%
+ \setunit*{\addnbspace}%
+ \iffieldundef{shortjournal}%
+ {}%
+ {\printtext[shortjournal]{%
+ \printfield[jtsnoformat]{shortjournal}}}%
+ \iffieldundef{issue}%
+ {\printfield[jurisdictionser]{series}}%
+ {\setunit{\addspace}%
+ \printfield{issue}}% Better ideas?
+ \setunit{\addspace}%
+ \printlist{origpublisher}%
+ \usebibmacro{juridpostnote}%
+ \setunit{\addcomma\addspace}%
+ \printlist{origlocation}%
+ \setunit{\addcomma\addspace}%
+ \printfield{note}%
+ \setunit{\addspace}%
+ \ifboolexpr{%
+ test {\iffieldundef{year}}%
+ and
+ test {\iflistundef{location}}%
+ }%
+ {}%
+ {\printtext[parens]{%
+ \printlist{location}%
+ \setunit*{\addspace}%
+ \begingroup% Better ideas?
+ \let\abx@bibmonth\blx@imc@bibsstring%
+ \usebibmacro{date}\endgroup}}%
+ \setunit{\addspace}%
+ \usebibmacro{cms:shorthandintro}%
+ \setunit{\addspace}\newblock
+ \printfield{addendum}%
+ \newcunit\newblock
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \newcunit\newblock
+ \usebibmacro{cite+doi+url}%
+ \newcunit\newblock
+ \usebibmacro{pageref}%
+ \newcunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newcunit}%
+ {}%
+ \usebibmacro{finentry}}}}
+
+\DeclareBibliographyDriver{legal}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{author/editor}%
+ \newcunit\newblock
+ \usebibmacro{clegis+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{byauthor}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cpart+editor+translator}%
+ \newcunit%
+ \usebibmacro{issuetitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cbyeditor+others}%
+ \setunit{\addcomma\addspace}%
+ \printfield[juridnum]{number}%
+ \newcunit%
+ \iffieldundef{year}%
+ {}%
+ {\printtext{%
+ \begingroup% Better ideas?
+ \let\abx@bibmonth\blx@imc@bibsstring%
+ \usebibmacro{date}\endgroup}}%
+ \newcunit%\setunit*{\addspace}%
+ \printfield[jourvol]{volume}%
+ \setunit*{\addnbspace}%
+ \iffieldundef{shortjournal}%
+ {}%
+ {\printtext[shortjournal]{%
+ \printfield[jtsnoformat]{shortjournal}}}%
+ \setunit{\addspace}%
+ \printfield{series}%
+ \setunit{\addspace}%
+ \printfield{issue}%
+ \newcunit%
+ \printfield{part}%
+ \newcunit%
+ \printfield{chapter}%
+ \usebibmacro{juridpostnote}%
+ \setunit{\addcomma\addspace}%
+ \printfield{note}%
+ \setunit{\addspace}%
+ \printlist{location}%
+ \setunit{\addspace}%
+ \usebibmacro{cms:shorthandintro}%
+ \setunit{\addspace}\newblock%
+ \printfield{addendum}%
+ \newcunit\newblock
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \newcunit\newblock
+ \usebibmacro{cite+doi+url}%
+ \newcunit\newblock
+ \usebibmacro{pageref}%
+ \newcunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newcunit}%
+ {}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{legislation}{%
+ \iffieldequalstr{entrysubtype}{uk}% FIXME?
+ {\usebibmacro{bibindex}%
+ \usebibmacro{author/editor}%
+ \newcunit\newblock
+ \usebibmacro{clegis+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{byauthor}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cpart+editor+translator}%
+ \newcunit%
+ \usebibmacro{issuetitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cbyeditor+others}%
+ \setunit{\addcomma\addspace}%
+ \printfield[juridnum]{number}%
+ \setunit{\addcomma\addspace}%
+ \printfield{note}%
+ \newcunit%
+ \iffieldundef{year}%
+ {}%
+ {\printtext{%
+ \begingroup% Better ideas?
+ \let\abx@bibmonth\blx@imc@bibsstring%
+ \usebibmacro{date}\endgroup}}%
+ \newcunit%\setunit*{\addspace}%
+ \printfield[jourvol]{volume}%
+ \setunit*{\addnbspace}%
+ \iffieldundef{shortjournal}%
+ {}%
+ {\printtext[shortjournal]{%
+ \printfield[jtsnoformat]{shortjournal}}}%
+ \setunit{\addspace}%
+ \printfield{series}%
+ \setunit{\addspace}%
+ \printfield{issue}%
+ \newcunit%
+ \printfield{part}%
+ \newcunit%
+ \printfield{chapter}%
+ \usebibmacro{juridpostnote}%
+ \setunit{\addspace}%
+ \printlist{location}%
+ \setunit{\addspace}%
+ \usebibmacro{cms:shorthandintro}%
+ \setunit{\addspace}\newblock%
+ \printfield{addendum}%
+ \newcunit\newblock
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \newcunit\newblock
+ \usebibmacro{cite+doi+url}%
+ \newcunit\newblock
+ \usebibmacro{pageref}%
+ \newcunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newcunit}%
+ {}%
+ \usebibmacro{finentry}}
+ {\iffieldequalstr{entrysubtype}{hansard}% FIXME?
+ {\usebibmacro{bibindex}%
+ \usebibmacro{author/editor}%
+ \newcunit\newblock
+ \usebibmacro{clegis+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{byauthor}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cpart+editor+translator}%
+ \newcunit%
+ \usebibmacro{issuetitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cbyeditor+others}%
+ \setunit{\addcomma\addspace}%
+ \printfield[juridnum]{number}%
+ \setunit{\addcomma\addspace}%
+ \printfield{note}%
+ \newcunit%
+ \printfield[jourvol]{volume}%
+ \setunit*{\addnbspace}%
+ \iffieldundef{shortjournal}%
+ {}%
+ {\printtext[shortjournal]{%
+ \printfield[jtsnoformat]{shortjournal}}}%
+ \setunit{\addspace}%
+ \printfield[hansardser]{series}%
+ \setunit{\addspace}%
+ \iffieldundef{year}%
+ {}%
+ {\printtext[parens]{%
+ \begingroup% Better ideas?
+ \let\abx@bibmonth\blx@imc@bibsstring%
+ \usebibmacro{date}\endgroup}}%
+ \usebibmacro{juridpostnote}%
+ \setunit{\addspace}%
+ \printlist{location}%
+ \setunit{\addspace}%
+ \usebibmacro{cms:shorthandintro}%
+ \setunit{\addspace}\newblock%
+ \printfield{addendum}%
+ \newcunit\newblock
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \newcunit\newblock
+ \usebibmacro{cite+doi+url}%
+ \newcunit\newblock
+ \usebibmacro{pageref}%
+ \newcunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newcunit}%
+ {}%
+ \usebibmacro{finentry}}
+ {\usebibmacro{bibindex}%
+ \usebibmacro{author/editor}%
+ \newcunit\newblock
+ \usebibmacro{clegis+news+title}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{byauthor}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cpart+editor+translator}%
+ \newcunit%
+ \usebibmacro{issuetitle}%
+ \setunit{\addcomma\addspace}%
+ \usebibmacro{cbyeditor+others}%
+ \setunit{\addspace}% FIXME?
+ \printfield[juridnum]{number}%
+ \setunit{\addcomma\addspace}%
+ \printfield{note}%
+ \newcunit%
+ \printfield[jourvol]{volume}%
+ \setunit*{\addnbspace}%
+ \iffieldundef{shortjournal}%
+ {}%
+ {\printtext[shortjournal]{%
+ \printfield[jtsnoformat]{shortjournal}}}%
+ \newcunit%
+ \printfield{series}%
+ \setunit{\addspace}%
+ \printfield{issue}%
+ \newcunit%
+ \printfield{part}%
+ \newcunit%
+ \printfield{chapter}%
+ \usebibmacro{juridpostnote}%
+ \setunit{\addspace}%
+ \ifboolexpr{%
+ test {\iffieldundef{year}}%
+ and
+ test {\iffieldundef{usera}}%
+ and
+ test {\iflistundef{location}}%
+ }%
+ {}%
+ {\printtext[parens]{%
+ \printlist{location}%
+ \setunit*{\addspace}%
+ \printfield{usera}%
+ \setunit*{\addspace}%
+ \begingroup% Better ideas?
+ \let\abx@bibmonth\blx@imc@bibsstring%
+ \usebibmacro{date}\endgroup}}%
+ \setunit{\addspace}%
+ \usebibmacro{cms:shorthandintro}%
+ \setunit{\addspace}\newblock%
+ \printfield{addendum}%
+ \newcunit\newblock
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \newcunit\newblock
+ \usebibmacro{cite+doi+url}%
+ \newcunit\newblock
+ \usebibmacro{pageref}%
+ \newcunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newcunit}%
+ {}%
+ \usebibmacro{finentry}}}}
+
+\DeclareBibliographyDriver{letter}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \printtext[title]{%
+ \printfield[noformat]{title}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{titleaddon}%
+ \setunit*{\addcomma\addspace}%
+ \usebibmacro{letter+date}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \newunit\newblock%\bibsentence
+ \usebibmacro{part+editor+translator}%
+ \setunit*{\addperiod\addspace}%
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@crossref}%
+ }%
+ {\usebibmacro{chapincoll}%
+ \usebibmacro{mtitle+mstitle+vol+part+btitle+bstitle}%
+ \newcunit
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newcunit
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{byeditor+others}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\newunit}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\newunit}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{manual}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author+org}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit\newblock
+ \usebibmacro{edition}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \printfield{type}%
+ \newunit
+ \printfield{note}%
+ \newunit\newblock%
+ \usebibmacro{bibreprint}%
+ \usebibmacro{org+publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{misc}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \iffieldundef{entrysubtype}%
+ {\ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}}%
+ {}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \iffieldundef{entrysubtype}%
+ {\ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}}%
+ {\printfield{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[noformat]{subtitle}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{titleaddon}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \newcunit\newblock%
+ \usebibmacro{unpubl+letter+date}}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \printfield{howpublished}%
+ \newunit\newblock
+ \printfield{type}%
+ \newunit\newblock
+ \printfield{version}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{institution+organization}%
+ \setunit*{\addcomma\addspace}\newblock
+ \printlist{location}%
+ \iffieldundef{entrysubtype}%
+ {\newcunit\newblock%
+ \usebibmacro{date}}%
+ {}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{music}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\ifundef{\bbx@lasthash}}%
+ and
+ not test {\iffieldundef{title}}%
+ }%
+ {\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\ifundef{\bbx@lasthash}}%
+ or
+ test {\iffieldundef{title}}%
+ }%
+ {}{\usebibmacro{italtitle+stitle}}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newunit\newblock
+ \usebibmacro{music+eventdate}%\printeventdate
+ \newunit\newblock
+ \usebibmacro{chapinscore}%
+ \usebibmacro{btitle+bstitle}%
+ \iffieldundef{booktitle}%
+ {\newunit}% Fix customc?
+ {\newcunit}%
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newunit% unit, not cunit?
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{byeditor+others}%
+ \newunit% ??? Editorpunct maybe not right here?
+ \iffieldundef{maintitle}%
+ {}%
+ {\ifthenelse{\iffieldundef{volume}\AND\iffieldundef{part}}%
+ {\ifthenelse{\iffieldundef{title}\AND\iffieldundef{booktitle}}%
+ {\usebibmacro{cms-in:}}%
+ {\bibstring{in}\setunit{\addspace}}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}%
+ {\printfield{volume}%
+ \printfield{part}%
+ \setunit{\addspace}%
+ \bibstring{ofseries}%
+ \setunit{\addspace}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{ctitleaddonpunct}%
+ \printfield{maintitleaddon}}}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \printfield{version}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{music+origdate}%\printtext[eventdate]{\printeventdate}%
+ \newunit\newblock
+ \printlist{publisher}%
+ \setunit*{\addcomma\addspace}\newblock
+ \printfield{series}%
+ \setunit{\addspace}%
+ \printfield{number}%
+ \newcunit\newblock
+ \usebibmacro{date}%
+ \newunit
+ \usebibmacro{institution+organization}%
+ \setunit*{\addcomma\addspace}\newblock
+ \printlist{location}%
+ \newcunit\newblock
+ \printfield{type}%
+ \newunit\newblock
+ \usebibmacro{pubstate}% 16th ed -- origdate instead, as above?
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{iswc}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyAlias{mvbook}{book}
+
+\DeclareBibliographyAlias{mvcollection}{collection}
+
+\DeclareBibliographyAlias{mvproceedings}{proceedings}
+
+\DeclareBibliographyAlias{mvreference}{reference}
+
+\DeclareBibliographyDriver{online}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \printlist{organization}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{date}%
+ \newunit\newblock
+ \ifthenelse{\iffieldundef{urlyear}\AND\iffieldundef{urlmonth}}%
+ {}%
+ {\printurldate}% Date fix
+ \newunit\newblock
+ \iftoggle{cms@doionly}%
+ {\iffieldundef{doi}%
+ {}%
+ {\printfield{doi}%
+ \clearfield{url}}}%
+ {\printfield{doi}}%
+ \newunit\newblock%
+ \usebibmacro{eprint}%
+ \newunit\newblock
+ \printfield{url}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{patent}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{author+holder}% + holder?
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmscitesortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \setunit{\addperiod\addspace}%
+ \printfield{note}%
+ \setunit{\addperiod\addspace}%
+ \usebibmacro{bibreprint}%
+ \printfield{type}%
+ \setunit{\addspace}%
+ \printfield{number}%
+ \iflistundef{location}%
+ {}%
+ {\setunit*{\addspace}%
+ \printtext[parens]{%
+ \printlist[][-\value{listtotal}]{location}}}%
+ \newcunit\newblock
+ \printfield{version}%
+ \newcunit\newblock
+ \iftoggle{cms@switchdates}%
+ {\bibstring{patentfiled}%
+ \setunit{\addspace}%
+ \printdate%
+ \setunit{\addcomma\addspace}%
+ \bibstring{and}%
+ \addspace\bibstring{patentissued}\addspace%
+ \printorigdate}%
+ {\iffieldundef{origyear}%
+ {\iffieldundef{year}%
+ {}%
+ {\bibstring{patentfiled}\setunit{\addspace}%
+ \printdate}}%
+ {\bibstring{patentfiled}\setunit{\addspace}%
+ \printorigdate%\usebibmacro{date}%
+ \setunit{\finalandcomma\addspace\bibstring{and}%
+ \addspace\bibstring{patentissued}\addspace}%
+ \usebibmacro{date}}}%
+ \newcunit\newblock
+ \printfield{addendum}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \iftoggle{cms@related}%
+ {\newunit%
+ \usebibmacro{related:init}%
+ \usebibmacro{related}}%
+ {}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{periodical}{%
+ \iffieldequalstr{entrysubtype}{magazine}%
+ {\usebibmacro{bibindex}%
+ \usebibmacro{editor}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\ifundef{\bbx@lasthash}}%
+ and
+ not togl {cms@origpublished}%
+ }%
+ {\ifboolexpr{%
+ togl {cms@bibjtabb}%
+ and
+ test {\ifbibliography}%
+ and
+ not test {\iffieldundef{shorttitle}}%
+ }%
+ {\clearlist{location}\printtext[shorttitle]{%
+ \printfield[tnoformat]{shorttitle}}}%
+ {\printtext[title]{%
+ \printfield[tnoformat]{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[stnoformat]{subtitle}}}%
+ \setunit*{\addspace}%
+ \printlist[periodplace]{location}%
+ \clearlist{location}%
+ \clearfield{shorttitle}%
+ \clearfield{title}%
+ \clearfield{subtitle}%
+ \newunit\newblock}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \usebibmacro{issuetitle}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \newunit\newblock
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \printfield{note}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{periodical+date+issue}%
+ \newcunit\newblock
+ \usebibmacro{chap+pag}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+ {\usebibmacro{bibindex}%
+ \usebibmacro{editor}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\ifundef{\bbx@lasthash}}%
+ and
+ not togl {cms@origpublished}%
+ }%
+ {\ifboolexpr{%
+ togl {cms@bibjtabb}%
+ and
+ test {\ifbibliography}%
+ and
+ not test {\iffieldundef{shorttitle}}%
+ }%
+ {\clearlist{location}\printtext[shorttitle]{%
+ \printfield[tnoformat]{shorttitle}}}%
+ {\printtext[title]{%
+ \printfield[tnoformat]{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[stnoformat]{subtitle}}}%
+ \setunit*{\addspace}%
+ \printlist[periodplace]{location}%
+ \clearlist{location}%
+ \clearfield{shorttitle}%
+ \clearfield{title}%
+ \clearfield{subtitle}%
+ \newunit\newblock}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \usebibmacro{issuetitle}%
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \setunit*{\addperiod\addspace}\newblock% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \printfield{note}%
+ \setunit*{\addcomma\addspace}\newblock% (changed for 0.7)??
+ \usebibmacro{periodical+issue+year+pages}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{proceedings}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newunit\newblock
+ \ifboolexpr{%
+ test {\iffieldundef{crossref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{xref}}%
+ or
+ togl {cms@bookcrossref}%
+ }%
+ {\usebibmacro{mtitle+mstitle+vol+part+title+stitle}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \usebibmacro{volume+or+volumes}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{org+publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{xref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}%
+{\ifboolexpr{% Changed for 16th ed.
+ test {\ifterm}%
+ or
+ test {\ifpunctmark{*}}%
+ }%
+ {\setunit{\addspace\bibsentence}}%
+ {\setunit{\addperiod\addspace}}%
+ \usebibmacro{bibprexref}%
+ \bibxrefcite{\thefield{crossref}}%
+ \usebibmacro{bibpostxref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}}
+
+\DeclareBibliographyDriver{reference}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{reference+title}%{italtitle+stitle}
+ \newunit\newblock
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifthenelse{\iffieldundef{maintitle}\AND\iffieldundef{booktitle}}%
+ {\iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}}%
+ {}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \setunit*{\addperiod\addspace}% need asterisk?
+ \usebibmacro{mtitle+mstitle+vol+part+btitle+bstitle}%
+ \newcunit
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newcunit
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditor+others}%
+ \newcunit\newblock
+ \printfield{chapter}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{report}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \printfield{type}%
+ \newcunit
+ \printfield{series}%
+ \setunit{\addnbspace}%
+ \printfield{number}%
+ \newunit
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{inst+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isrn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{review}{%
+ \usebibmacro{bibindex}%
+ \iffieldequalstr{entrysubtype}{magazine}%
+ {\usebibmacro{mag+news+author}}%
+ {\usebibmacro{author/editor}}%
+ \newunit\newblock
+ \ifundef{\bbx@lasthash}%
+ {\ifboolexpr{%
+ togl {cms@related}%
+ and
+ test {\iffieldequalstr{relatedtype}{reviewof}}%
+ }%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}}%
+ {\printfield{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[noformat]{subtitle}%
+ \newunit}}%
+ {}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef{\bbx@lasthash}%
+ {}%
+ {\ifboolexpr{%
+ togl {cms@related}%
+ and
+ test {\iffieldequalstr{relatedtype}{reviewof}}%
+ }%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}}%
+ {\printfield{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[noformat]{subtitle}}}%
+ \setunit{\ptitleaddonpunct}%
+ \printfield{titleaddon}%
+ \newcunit\newblock
+ \usebibmacro{music+eventdate}% 16th ed.
+ \setunit{\addspace}%
+ \usebibmacro{language+transtitle}%
+ \newunit\newblock%
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \usebibmacro{part+editor+translator}%
+ \newunit\newblock%
+ \usebibmacro{bibreprint}%
+ \usebibmacro{issuetitle}%
+ \setunit*{\addcomma\addspace}%
+ \usebibmacro{byeditor+others}%
+ \usebibmacro{editorpunct}%\newunit\newblock
+ \printfield{note}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iffieldequalstr{entrysubtype}{magazine}%
+ {\usebibmacro{mag+news+date}%
+ \newcunit\newblock
+ \usebibmacro{chap+pag}}%
+ {\usebibmacro{journal+issue+year+pages}}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{issn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \ifboolexpr{%
+ togl {cms@related}%
+ and
+ not test {\iffieldequalstr{relatedtype}{reviewof}}%
+ }%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{suppbook}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{%
+ \usebibmacro{inforaft}%
+ \setunit{\addspace}\newblock
+ \usebibmacro{italtitle+stitle}%
+ \newcunit\newblock
+ \usebibmacro{bybookauthor}%
+ \clearname{bookauthor}%
+ \newunit\newblock}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{%
+ \usebibmacro{inforaft}%
+ \setunit{\addspace}\newblock
+ \usebibmacro{italtitle+stitle}}%
+ \newunit
+ \iffieldundef{maintitle}%
+ {\iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}}%
+ {}%
+ \newcunit
+ \usebibmacro{bybookauthor}%
+ \newcunit\newblock
+ \usebibmacro{chap+pag}%
+ \newunit\newblock
+ \usebibmacro{mtitle+mstitle+vol+part+title+stitle}%
+ \newcunit%
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditor+others}%
+ \newunit
+ \usebibmacro{volume+or+volumes}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isbn}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyAlias{suppcollection}{suppbook}
+
+\DeclareBibliographyAlias{suppperiodical}{review}
+
+\DeclareBibliographyDriver{thesis}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit% 16th ed.
+ \usebibmacro{byauthor}%
+ \setunit{\addperiod\addspace}%
+ \printfield{note}%
+ \setunit{\addperiod\addspace}\newblock%
+ \usebibmacro{bibreprint}%
+ \usebibmacro{type+inst+year}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{unpublished}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{\usebibmacro{italtitle+stitle}}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{\usebibmacro{italtitle+stitle}}%
+ \newunit%usebibmacro{byauthorpunct}% Why does this work? No idea.
+ \usebibmacro{byauthor}% Same in thesis type, as well. 16th ed.
+ \setunit{\addperiod\addspace}%
+ \usebibmacro{byeditor+others}% Fix bug ???
+ \newunit\newblock
+ \usebibmacro{bibreprint}%
+ \printfield{howpublished}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \printfield{note}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \printfield{eventtitle}%
+ \setunit*{\ctitleaddonpunct}\newblock%
+ \printfield{eventtitleaddon}%
+ \setunit*{\addcomma\addspace}%
+ \printfield{venue}%
+ \setunit*{\addcomma\addspace}%
+ \printlist{location}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iffieldundef{eventmonth}%
+ {\usebibmacro{date}}%
+ {\printeventdate}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}
+
+\DeclareBibliographyDriver{video}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{shorthand:author}%
+ \usebibmacro{author/editor}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{%
+ \usebibmacro{video+title}% Simplifies trad style
+ \iffieldundef{booktitle}% Comma after italics, period after quotes
+ {\setunit{\ctitleaddonpunct}}%
+ {\setunit{\ptitleaddonpunct}}%\setunit{\addspace}\newblock%
+ \printfield{titleaddon}%\usebibmacro{title+stitle}%
+ \setunit{\addspace}\newblock%\bibsentence
+ \usebibmacro{language+transtitle}%
+ \newunit\newblock}{}%
+ \usebibmacro{cmsbibsortdate}%
+ \newunit\newblock
+ \ifundef\bbx@lasthash{}{%
+ \usebibmacro{video+title}% Simplifies trad style
+ \iffieldundef{booktitle}% Comma after italics, period after quotes
+ {\setunit{\ctitleaddonpunct}}%
+ {\setunit{\ptitleaddonpunct}}%\setunit{\addspace}\newblock%
+ \printfield{titleaddon}%\usebibmacro{title+stitle}%
+ \setunit{\addspace}\newblock%\bibsentence
+ \usebibmacro{language+transtitle}}%
+ \setunit{\addperiod\addspace}% 16th ed.
+ \usebibmacro{byauthor}%
+ \setunit{\addperiod\addspace}%
+ \usebibmacro{part+editor+translator}%
+ \setunit{\addperiod\addspace}%
+ \usebibmacro{chapinscore}%
+ \usebibmacro{btitle+bstitle}%
+ \iffieldundef{booktitle}%
+ {\setunit{\addperiod\addspace}}% Fix customc?
+ {\setunit{\addcomma\addspace}}%
+ \iffieldundef{edition}%
+ {}%
+ {\usebibmacro{edition}}%
+ \newunit% unit, not cunit?
+ \usebibmacro{bybookauthor}%
+ \usebibmacro{byeditor+others}%
+ \newunit% ??? Editorpunct maybe not right here?
+ \iffieldundef{maintitle}%
+ {}%
+ {\ifthenelse{\iffieldundef{volume}\AND\iffieldundef{part}}%
+ {\ifthenelse{\iffieldundef{title}\AND\iffieldundef{booktitle}}%
+ {\usebibmacro{cms-in:}}%
+ {\bibstring{in}\setunit{\addspace}}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}%
+ {\printfield{volume}%
+ \printfield{part}%
+ \setunit{\addspace}%
+ \bibstring{ofseries}%
+ \setunit{\addspace}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}}%
+ \newcunit\newblock
+ \usebibmacro{volume+pages}%
+ \newunit\newblock
+ \usebibmacro{ser+num}%
+ \newunit\newblock
+ \usebibmacro{music+eventdate}%
+ \newunit\newblock
+ \usebibmacro{origpubl+loc+year}% 16th ed.
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{publ+loc+year}%
+ \newunit\newblock
+ \printfield{type}%
+ \newunit\newblock
+ \usebibmacro{pubstate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \iftoggle{cms@isbn}%
+ {\printfield{isan}}%
+ {}%
+ \setunit*{\addcomma\addspace}\newblock%
+ \usebibmacro{bib+doi+url}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{cms@related}%
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}%
+ \newunit}%
+ {}%
+ \usebibmacro{originally+published+as}%
+ \usebibmacro{finentry}}%
+
+%%%% Other Formatting Macros %%%%
+
+\newbibmacro*{bib+doi+url}{% 16th ed.
+ \ifboolexpr{%
+ not togl {cms@url}%
+ or
+ (
+ test {\iffieldundef{urlyear}}%
+ and
+ test {\iffieldundef{urlmonth}}%
+ )
+ }%
+ {}%
+ {\printurldate}% Date fix
+ \iffieldundef{addendum}%
+ {\newunit\newblock}%
+ {\newcunit\newblock}%
+ \iftoggle{cms@doionly}%
+ {\iffieldundef{doi}%
+ {}%
+ {\printfield{doi}%
+ \setunit*{\addperiod\addspace}\newblock%
+ \clearfield{url}}}%
+ {\ifboolexpr{%
+ togl {cms@doi}%
+ and
+ not test {\iffieldundef{doi}}%
+ }%
+ {\printfield{doi}%
+ \setunit*{\addperiod\addspace}\newblock}%
+ {}}%
+ \ifboolexpr{%
+ togl {cms@eprint}%
+ and
+ not test {\iffieldundef{eprint}}%
+ }%
+ {\usebibmacro{eprint}%
+ \setunit*{\addperiod\addspace}\newblock}%
+ {}%
+ \ifboolexpr{%
+ togl {cms@url}%
+ and
+ not test {\iffieldundef{url}}%
+ }%
+ {\printfield{url}}%
+ {}}%
+
+\newbibmacro*{shorthand:author}{%
+ \ifboolexpr{%
+ test {\iffieldundef{shorthand}}%
+ or
+ not togl {cms@los}%
+ }%
+ {\togglefalse{cms@authorparens}%
+ \global\csundef{cms@shauthor}}%
+ {\ifboolexpr{%
+ ((
+ test {\iffieldequals{fullhash}{\bbx@lasthash}}%
+ or
+ test {\iffieldequals{shorthand}{\cms@shauthor}}%
+ )
+ and
+ togl {cms@namedash}%
+ )
+ and
+ not test {\iffirstonpage}%
+ }%
+ {\togglefalse{cms@authorparens}}%
+ {\toggletrue{cms@authorparens}%
+ \savefield{shorthand}{\cms@shauthor}%
+ \printfield{shorthand}\addspace}}}
+
+\newbibmacro*{shorthand:label}{% Test this
+ \ifthenelse{\iffieldequalstr{entrysubtype}{magazine}\AND\NOT%
+ \ifentrytype{periodical}}% Simplifies .bib creation
+ {\printtext[bibhyperref]{\printfield[journaltitle]{journaltitle}}}%
+ {\ifentrytype{manual}%
+ {\printtext[bibhyperref]{\printlist{organization}}}%
+ {\printtext[bibhyperref]{\printfield[citetitle]{labeltitle}}}}}%
+
+\newbibmacro*{labelyear+extrayear}{%
+ \ifboolexpr{ (
+ test {\ifentrytype{music}}%
+ or
+ test {\ifentrytype{review}}%
+ or
+ test {\ifentrytype{suppperiodical}}%
+ or
+ test {\ifentrytype{video}}%
+ )
+ and
+ togl {cms@avdate}%
+ }%
+ {\usebibmacro{av+labelyear+extrayear}}%
+ {\iftoggle{cms@ordate}%
+ {\usebibmacro{origfirst+labelyear+extrayear}}%
+ {\usebibmacro{standard+labelyear+extrayear}}}}
+
+\protected\def\cmsunspecified#1#2{%
+ \ifboolexpr{%
+ test {\iffieldundef{#2dateunspecified}}%
+ or
+ togl {cms@alwaysrange}%
+ }%
+ {\ifboolexpr{%
+ test {\iffieldundef{#2endyear}}%
+ or
+ test {\iffieldequalstr{#2dateera}{bce}}%
+ or
+ not togl {cms@compyears}%
+ or
+ not test {\iffieldnum{#2year}}%
+ or
+ not test {\iffieldnum{#2endyear}}%
+ or
+ not test {\if@cms@onlyyears{#2}}%
+ }%
+ {\csuse{mkbibdate#1}{#2year}{#2month}{#2day}\cmsdateeraprint{#2year}}%
+ {\cmscompcenturies{#2}%
+ \ifboolexpr{%
+ (
+ test {\if@cms@bracket}%
+ and
+ not test {\if@cms@endbracket}
+ )
+ or
+ (
+ not test {\if@cms@bracket}%
+ and
+ test {\if@cms@endbracket}%
+ )
+ or
+ (
+ test {\if@cms@endcirca}%
+ and
+ not test {\if@cms@circa}%
+ )
+ or
+ not test {\ifnumequal{\cms@tempcnta}{\cms@tempcntb}}%
+ }%
+ {\csuse{mkbibdate#1}{#2year}{}{}\cmsdateeraprint{#2year}}%
+ {\cmsdateeraprintpre{#2year}\cmscompressyears{#2}%
+ \cmsdateeraprint{#2endyear}\clearfield{#2endyear}}}}%
+ {\ifboolexpr{%
+ test {\iffieldequalstr{#2dateunspecified}{yearindecade}}%
+ and
+ test {\ifbibstring{decade}}%
+ and
+ not togl {cms@decaderange}%
+ }%
+ {\cmsmkdecade{#1}{#2}}%
+ {\ifboolexpr{%
+ test {\iffieldequalstr{#2dateunspecified}{yearincentury}}%
+ and
+ test {\ifbibstring{century}}%
+ and
+ not togl {cms@centuryrange}%
+ }%
+ {\cmsmkcentury{#2}}%
+ {\iftoggle{cms@compyears}%
+ {\cmsdateeraprintpre{#2year}\cmscompressyears{#2}%
+ \cmsdateeraprint{#2endyear}\clearfield{#2endyear}}%
+ {\csuse{mkbibdate#1}{#2year}{}{}\cmsdateeraprint{#2year}}}}}}%
+
+\protected\def\cmscompressyears#1{%
+ \def\cms@tempa{\thefield{#1year}--\thefield{#1endyear}}%
+ \edef\cms@tempb{\mkcomprange{\csuse{cms@tempa}}}%
+ \cms@tempb}%
+
+\newcount\cms@tempcnta
+\newcount\cms@tempcntb
+
+\def\cmscompcenturies#1{%
+ \cms@tempcnta=\thefield{#1year}%
+ \divide\cms@tempcnta100
+ \cms@tempcntb=\thefield{#1endyear}%
+ \divide\cms@tempcntb100}
+
+\protected\def\cmsformatextra{%
+ \ifboolexpr{%
+ test {\if@cms@bracket}%
+ and
+ not togl {cms@noyearbrackets}%
+ }%
+ {\usebibmacro{cmsextradate}%
+ \global\boolfalse{cms:extraparens}}%
+ {\ifbool{cms:extraparens}%
+ {\usebibmacro{cmsparensextradate}%
+ \global\boolfalse{cms:extraparens}}%
+ {\usebibmacro{cmsextradate}}}}
+
+\protected\def\cmsformatendextra{%
+ \ifboolexpr{%
+ test {\if@cms@endbracket}%
+ and
+ test {\if@cms@bracket}%
+ and
+ not togl {cms@noyearbrackets}%
+ }%
+ {\usebibmacro{cmsextradate}%
+ \global\boolfalse{cms:extraparens}}%
+ {\ifbool{cms:extraparens}%
+ {\usebibmacro{cmsparensextradate}%
+ \global\boolfalse{cms:extraparens}}%
+ {\usebibmacro{cmsextradate}}}}
+
+\newbibmacro*{cmsextradate}{% For use with some date specs
+ \iffieldundef{extradate}%
+ {}%
+ {\setunit*{}%
+ \printfield{extradate}\clearfield{extradate}}}
+
+\newbibmacro*{cmsparensextradate}{% For use with other date specs
+ \iffieldundef{extradate}%
+ {}%
+ {\setunit*{}%
+ \mkbibparens{\printfield{extradate}}\clearfield{extradate}}}
+
+\protected\def\cmsdateeraprintpre#1{% AD/BC order depends on language
+ \ifdefstring\blx@dateera{astronomical}%
+ {\iffieldnum{#1}%
+ {\begingroup%
+ \let\blx@tempa\@empty%
+ \blx@ifstrendswith{#1}{endyear}%
+ {\blx@stripfromendinto{#1}{endyear}\blx@datetype%
+ \def\blx@tempa{end}}%
+ {\blx@stripfromendinto{#1}{year}\blx@datetype}%
+ \csuse{if\blx@datetype\blx@tempa dateera}{bce}%
+ {\ifnumless{0-\thefield{#1}}{0}%
+ {\printtext{\csuse{bibdateera\blx@tempa prefix}}}%
+ {}}%
+ {}%
+ \endgroup}%
+ {}}%
+ {\ifboolexpr{%
+ test {\ifdefstring\blx@dateera{christian}}%
+ and
+ test {\if@cms@adfirst}%
+ }%
+ {\iffieldnum{#1}%
+ {\begingroup%
+ \let\blx@tempa\@empty%
+ \blx@ifstrendswith{#1}{endyear}%
+ {\blx@stripfromendinto{#1}{endyear}\blx@datetype%
+ \def\blx@tempa{end}}%
+ {\blx@stripfromendinto{#1}{year}\blx@datetype}%
+ \csuse{if\blx@datetype\blx@tempa dateera}{bce}%
+ {\ifdefstring\blx@tempa{end}{}{\global\toggletrue{cms@bc}}}%
+ {\ifnumless{\thefield{#1}}\blx@dateeraauto%
+ {\ifdefstring\blx@tempa{end}%
+ {\iftoggle{cms@bc}%
+ {\printtext{%
+ \bibsstring{\blx@dateera@ce}\printdelim{dateaddelim}}%
+ \global\togglefalse{cms@bc}}%
+ {}}%
+ {\printtext{%
+ \bibsstring{\blx@dateera@ce}\printdelim{dateaddelim}}%
+ \global\togglefalse{cms@bc}}}%
+ {}}%
+ \endgroup}%
+ {}}%
+ {}}}
+
+\protected\def\cmsdateeraprint#1{% AD/BC order depends on language
+ \ifboolexpr{%
+ test {\ifdefstring\blx@dateera{christian}}%
+ and
+ test {\if@cms@adfirst}%
+ }%
+ {\iffieldnum{#1}
+ {\begingroup
+ \let\blx@tempa\@empty
+ \blx@ifstrendswith{#1}{endyear}
+ {\blx@stripfromendinto{#1}{endyear}\blx@datetype
+ \def\blx@tempa{end}}
+ {\blx@stripfromendinto{#1}{year}\blx@datetype}%
+ \csuse{if\blx@datetype\blx@tempa dateera}{bce}%
+ {\ifdefstring\blx@tempa{end}%
+ {\ifnum\numexpr0-\thefield{#1}\relax<\blx@dateeraauto%
+ \printtext{\printdelim{dateeradelim}\midsentence%
+ \bibsstring{\blx@dateera@bce}}%
+ \global\booltrue{cms:extraparens}\relax%
+ \fi}%
+ {\csuse{if\blx@datetype enddateera}{bce}%
+ {}%
+ {\ifnum\numexpr0-\thefield{#1}\relax<\blx@dateeraauto%
+ \printtext{\printdelim{dateeradelim}\midsentence%
+ \bibsstring{\blx@dateera@bce}}%
+ \global\booltrue{cms:extraparens}\relax%
+ \fi}}}%
+ {}%
+ \endgroup}
+ {}}%
+ {\ifboolexpr{%
+ test {\ifdefstring\blx@dateera{secular}}%
+ or
+ (
+ test {\ifdefstring\blx@dateera{christian}}%
+ and
+ not test {\if@cms@adfirst}%
+ )
+ }%
+ {\iffieldnum{#1}%
+ {\begingroup%
+ \let\blx@tempa\@empty%
+ \blx@ifstrendswith{#1}{endyear}%
+ {\blx@stripfromendinto{#1}{endyear}\blx@datetype%
+ \def\blx@tempa{end}}%
+ {\blx@stripfromendinto{#1}{year}\blx@datetype}%
+ \csuse{if\blx@datetype\blx@tempa dateera}{bce}%
+ {\ifdefstring\blx@tempa{end}%
+ {\ifnum\numexpr0-\thefield{#1}\relax<\blx@dateeraauto%
+ \printtext{\printdelim{dateeradelim}\midsentence%
+ \bibsstring{\blx@dateera@bce}}%
+ \global\booltrue{cms:extraparens}\relax%
+ \fi}%
+ {\csuse{if\blx@datetype enddateera}{bce}%
+ {}%
+ {\ifnum\numexpr0-\thefield{#1}\relax<\blx@dateeraauto%
+ \printtext{\printdelim{dateeradelim}\midsentence%
+ \bibsstring{\blx@dateera@bce}}%
+ \global\booltrue{cms:extraparens}\relax%
+ \fi}}}%
+ {\ifdefstring\blx@tempa{end}%
+ {\ifnumless{\thefield{#1}}\blx@dateeraauto%
+ {\printtext{\printdelim{dateeradelim}\midsentence%
+ \bibsstring{\blx@dateera@ce}}%
+ \global\booltrue{cms:extraparens}}%
+ {}}%
+ {\csuse{if\blx@datetype enddateera}{ce}%
+ {}%
+ {\ifnumless{\thefield{#1}}\blx@dateeraauto%
+ {\printtext{\printdelim{dateeradelim}\midsentence%
+ \bibsstring{\blx@dateera@ce}}%
+ \global\booltrue{cms:extraparens}}%
+ {}}}}%
+ \endgroup}%
+ {}}%
+ {}}}
+
+\newrobustcmd*{\cms@datebrackets}{%
+ \iftoggle{cms@nodatebrackets}%
+ {\global\boolfalse{cms:bracket}}%
+ {\global\booltrue{cms:bracket}%
+ \bibopenbracket}}%
+
+\newrobustcmd*{\cms@yearbrackets}{%
+ \iftoggle{cms@noyearbrackets}%
+ {\global\boolfalse{cms:bracket}}%
+ {\global\booltrue{cms:bracket}%
+ \bibopenbracket}}%
+
+\newrobustcmd*{\cms@mkbibrangetrunc}[2]{% DATE FIX
+ \begingroup
+ \blx@metadateinfo{#2}%
+ \clearfield{extradate}%
+ \ifthenelse{\iffieldundef{#2year}\AND\iffieldundef{#2month}\AND%
+ \iffieldundef{#2season}}%
+ {}%
+ {\printtext[#2date]{%
+ \if@cms@bracket%
+ {\cms@datebrackets%
+ \if@cms@circa%
+ {\bibsstring{circa}\printdelim{datecircadelim}}%
+ {}}%
+ {\global\boolfalse{cms:bracket}}%
+ \iffieldundef{#2season}%
+ {\ifdateyearsequal{#2}{#2end}%
+ {\iffieldsequal{#2month}{#2endmonth}%
+ {\csuse{mkbibdate#1}{}{}{#2day}}%
+ {\ifthenelse{\iffieldundef{#2month}\AND\iffieldundef{#2day}}%
+ {\csuse{mkbibdate#1}{#2year}{}{}\cmsdateeraprint{#2endyear}%
+ \clearfield{#2endyear}}% Clear up inheritance problem ???
+ {\csuse{mkbibdate#1}{}{#2month}{#2day}}}}%
+ {\cmsunspecified{#1}{#2}}}%
+ {\ifdateyearsequal{#2}{#2end}%
+ {\ifthenelse{\iffieldundef{#2endseason}\OR%
+ \iffieldsequal{#2season}{#2endseason}}%
+ {\csuse{mkbibseasondate#1}{#2year}{#2season}%
+ \cmsdateeraprint{#2endyear}\clearfield{#2endyear}}%
+ {\csuse{mkbibseasondate#1}{}{#2season}}}%
+ {\csuse{mkbibseasondate#1}{#2year}{#2season}%
+ \cmsdateeraprint{#2year}}}%
+ \if@cms@bracket%
+ {\if@cms@uncertain%
+ {\if@cms@enduncertain%
+ {\iffieldundef{#2endyear}%
+ {\bibdateuncertain}%
+ {}}%
+ {\bibdateuncertain}}%
+ {\if@cms@enduncertain%
+ {\iffieldundef{#2endyear}%
+ {\bibdateuncertain}%
+ {}}%
+ {}}}%
+ {}%
+ \iffieldundef{#2endyear}%
+ {\iffieldundef{#2endmonth}%
+ {\ifthenelse{\iffieldundef{#2endseason}\OR%
+ \iffieldsequal{#2season}{#2endseason}}%
+ {\ifbool{cms:bracket}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}}%
+ {}}%
+ {\bibdaterangesep%
+ \csuse{mkbibseasondate#1}{}{#2endseason}}}%
+ {\bibdaterangesep%
+ \csuse{mkbibdate#1}{}{#2endmonth}{#2endday}}}%
+ {\iffieldequalstr{#2endyear}{}%
+ {\ifbool{cms:bracket}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}}%
+ {}%
+ \mbox{\bibdaterangesep}}%
+ {\ifbool{cms:bracket}%
+ {\if@cms@circa%
+ {\if@cms@endbracket%
+ {\bibdaterangesep}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}%
+ \bibdaterangesep}}%
+ {\if@cms@endcirca%
+ {\bibdaterangesep\bibsstring{circa}\printdelim{datecircadelim}}%
+ {\if@cms@enduncertain%
+ {\bibdaterangesep}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}%
+ \bibdaterangesep}}}}%
+ {\if@cms@endbracket%
+ {\bibdaterangesep%
+ \cms@datebrackets%
+ \if@cms@endcirca%
+ {\if@cms@circa%
+ {}%
+ {\bibsstring{circa}\printdelim{datecircadelim}}}%
+ {}}%
+ {\bibdaterangesep}}%\bibdatedash%
+ \iffieldundef{#2endseason}%
+ {\ifdateyearsequal{#2}{#2end}%
+ {\csuse{mkbibdate#1}{#2year}{#2endmonth}{#2endday}}%
+ {\csuse{mkbibdate#1}{#2endyear}{#2endmonth}{#2endday}}}%
+ {\ifdateyearsequal{#2}{#2end}%
+ {\csuse{mkbibseasondate#1}{#2year}{#2endseason}}%
+ {\csuse{mkbibseasondate#1}{#2endyear}{#2endseason}}}%
+ \ifbool{cms:bracket}%
+ {\if@cms@bracket%
+ {\cmsdateeraprint{#2endyear}%
+ \enddateuncertainprint%
+ \bibclosebracket\global\boolfalse{cms:bracket}}%
+ {\enddateuncertainprint%
+ \bibclosebracket\global\boolfalse{cms:bracket}%
+ \cmsdateeraprint{#2endyear}}}%
+ {\enddateuncertainprint%
+ \cmsdateeraprint{#2endyear}}}}}}%
+ \endgroup}
+
+\newrobustcmd*{\cms@mkbibrangefull}[2]{%
+ \begingroup
+ \blx@metadateinfo{#2}%
+ \clearfield{extradate}%
+ \ifthenelse{\iffieldundef{#2year}\AND\iffieldundef{#2month}\AND%
+ \iffieldundef{#2season}}%
+ {}%
+ {\printtext[#2date]{%
+ \if@cms@bracket%
+ {\cms@datebrackets%
+ \if@cms@circa%
+ {\bibsstring{circa}\printdelim{datecircadelim}}
+ {}}%
+ {\global\boolfalse{cms:bracket}}%
+ \iffieldundef{#2season}%
+ {\csuse{mkbibdate#1}{#2year}{#2month}{#2day}%
+ \ifboolexpr{%
+ test {\ifdateyearsequal{#2}{#2end}}%
+ and
+ test {\iffieldundef{#2month}}%
+ and
+ test {\iffieldundef{#2day}}%
+ }%
+ {\cmsdateeraprint{#2endyear}\clearfield{#2endyear}}%
+ {\cmsdateeraprint{#2year}}}%
+ {\csuse{mkbibseasondate#1}{#2year}{#2season}%
+ \cmsdateeraprint{#2year}}%
+ \if@cms@bracket%
+ {\if@cms@uncertain%
+ {\if@cms@enduncertain%
+ {\iffieldundef{#2endyear}%
+ {\bibdateuncertain}%
+ {}}%
+ {\bibdateuncertain}}%
+ {\if@cms@enduncertain%
+ {\iffieldundef{#2endyear}%
+ {\bibdateuncertain}%
+ {}}%
+ {}}}%
+ {}%
+ \ifthenelse{\iffieldundef{#2endyear}\AND\iffieldundef{#2endmonth}%
+ \AND\iffieldundef{#2endseason}}%
+ {\ifbool{cms:bracket}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}}%
+ {}}%
+ {\iffieldequalstr{#2endyear}{}%
+ {\ifbool{cms:bracket}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}}%
+ {}%
+ \mbox{\bibdaterangesep}}%
+ {\ifbool{cms:bracket}%
+ {\if@cms@circa%
+ {\if@cms@endbracket%
+ {\bibdaterangesep}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}%
+ \bibdaterangesep}}%
+ {\if@cms@endcirca%
+ {\bibdaterangesep\bibsstring{circa}\printdelim{datecircadelim}}%
+ {\if@cms@enduncertain%
+ {\bibdaterangesep}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}%
+ \bibdaterangesep}}}}%
+ {\if@cms@endbracket%
+ {\bibdaterangesep%
+ \cms@datebrackets%
+ \if@cms@endcirca%
+ {\if@cms@circa%
+ {}%
+ {\bibsstring{circa}\printdelim{datecircadelim}}}%
+ {}}%
+ {\bibdaterangesep}}%\bibdaterangesep%
+ \iffieldundef{#2endseason}%
+ {\csuse{mkbibdate#1}{#2endyear}{#2endmonth}{#2endday}}%
+ {\csuse{mkbibseasondate#1}{#2endyear}{#2endseason}}%
+ \ifbool{cms:bracket}%
+ {\if@cms@bracket%
+ {\cmsdateeraprint{#2endyear}%
+ \enddateuncertainprint%
+ \bibclosebracket\global\boolfalse{cms:bracket}}%
+ {\enddateuncertainprint%
+ \bibclosebracket\global\boolfalse{cms:bracket}%
+ \cmsdateeraprint{#2endyear}}}%
+ {\enddateuncertainprint%
+ \cmsdateeraprint{#2endyear}}}}}}%
+ \endgroup}
+
+\newrobustcmd*{\cms@mkyearrangeextra}[3][]{%
+ \global\boolfalse{cms:extraparens}%
+ \begingroup
+ \clearfield{#3month}\clearfield{#3day}\clearfield{#3endmonth}%
+ \clearfield{#3endday}\clearfield{#3season}\clearfield{#3endseason}%
+ \blx@metadateinfo{#3}%
+ \iffieldundef{#3year}
+ {\blx@nounit}%
+ {\printtext{%
+ \if@cms@bracket%
+ {\cms@yearbrackets%
+ \if@cms@circa%
+ {\bibsstring{circa}\printdelim{datecircadelim}}
+ {}}%
+ {\global\boolfalse{cms:bracket}}%
+ \ifdateyearsequal{#3}{#3end}%
+ {\csuse{mkbibdate#2}{#3year}{}{}\cmsdateeraprint{#3endyear}%
+ \clearfield{#3endyear}}%
+ {\ifblank{#1}%
+ {\cmsunspecified{#2}{#3}}%
+ {\csuse{mkbibdate#2}{#3year}{}{}\cmsdateeraprint{#3year}}}%
+ \if@cms@bracket%
+ {\if@cms@uncertain%
+ {\if@cms@enduncertain%
+ {\iffieldundef{#3endyear}%
+ {\global\booltrue{cms:extraparens}%
+ \bibdateuncertain}%
+ {}}%
+ {\ifthenelse{\iffieldundef{#3endyear}\OR%
+ \iffieldequalstr{#3endyear}{}}%
+ {\global\booltrue{cms:extraparens}}%
+ {}%
+ \bibdateuncertain}}%
+ {\if@cms@enduncertain%
+ {\iffieldundef{#3endyear}%
+ {\global\booltrue{cms:extraparens}%
+ \bibdateuncertain}%
+ {}}%
+ {}}}%
+ {}%
+ \iffieldundef{#3endyear}
+ {\ifbool{cms:bracket}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}}%
+ {}%
+ \cmsformatextra}%\usebibmacro{cmsextradate}%
+ {\iffieldequalstr{#3endyear}{}%
+ {\ifbool{cms:bracket}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}}%
+ {}%
+ \cmsformatextra%\usebibmacro{cmsextradate}%
+ \mbox{\bibdaterangesep}}%
+ {\ifbool{cms:bracket}%
+ {\if@cms@circa%
+ {\if@cms@endbracket%
+ {\bibdaterangesep}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}%
+ \bibdaterangesep}}%
+ {\if@cms@endcirca%
+ {\bibdaterangesep\bibsstring{circa}\printdelim{datecircadelim}}%
+ {\if@cms@enduncertain%
+ {\bibdaterangesep}%
+ {\bibclosebracket\global\boolfalse{cms:bracket}%
+ \bibdaterangesep}}}}%
+ {\if@cms@endbracket%
+ {\bibdaterangesep%
+ \cms@yearbrackets%
+ \if@cms@endcirca%
+ {\if@cms@circa%
+ {}%
+ {\bibsstring{circa}\printdelim{datecircadelim}}}%
+ {}}%
+ {\bibdaterangesep}}%
+ \csuse{mkbibdate#2}{#3endyear}{}{}%
+ \ifbool{cms:bracket}%
+ {\if@cms@bracket%
+ {\cmsdateeraprint{#3endyear}%
+ \enddateuncertainprint%
+ \bibclosebracket\global\boolfalse{cms:bracket}}%
+ {\enddateuncertainprint%
+ \bibclosebracket\global\boolfalse{cms:bracket}%
+ \cmsdateeraprint{#3endyear}}}%
+ {\if@cms@enduncertain%
+ {\global\booltrue{cms:extraparens}%
+ \bibdateuncertain}%
+ {}%
+ \cmsdateeraprint{#3endyear}}%
+ \cmsformatendextra}}}}%
+ \endgroup}%
+
+\def\if@cms@adfirst{%
+ \ifboolexpr{%
+ test {\ifdefstring\blx@languagename{american}}%
+ or
+ test {\ifdefstring\blx@languagename{british}}%
+ or
+ test {\ifdefstring\blx@languagename{canadian}}%
+ or
+ test {\ifdefstring\blx@languagename{english}}%
+ or
+ test {\ifdefstring\blx@languagename{UKenglish}}%
+ or
+ test {\ifdefstring\blx@languagename{USenglish}}%
+ or
+ test {\ifdefstring\blx@languagename{australian}}%
+ or
+ test {\ifdefstring\blx@languagename{newzealand}}%
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\def\if@cms@bracket{%
+ \ifboolexpr{%
+ (
+ test {\ifdatecirca}%
+ and
+ togl {blx@datecirca}%
+ )
+ or
+ (
+ test {\ifdateuncertain}%
+ and
+ togl {blx@dateuncertain}%
+ )
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\def\if@cms@endbracket{%
+ \ifboolexpr{%
+ (
+ test {\ifenddatecirca}%
+ and
+ togl {blx@datecirca}%
+ )
+ or
+ (
+ test {\ifenddateuncertain}%
+ and
+ togl {blx@dateuncertain}%
+ )
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\def\if@cms@circa{%
+ \ifboolexpr{%
+ test {\ifdatecirca}%
+ and
+ togl {blx@datecirca}%
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\def\if@cms@uncertain{%
+ \ifboolexpr{%
+ test {\ifdateuncertain}%
+ and
+ togl {blx@dateuncertain}%
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\def\if@cms@endcirca{%
+ \ifboolexpr{%
+ test {\ifenddatecirca}%
+ and
+ togl {blx@datecirca}%
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\def\if@cms@enduncertain{%
+ \ifboolexpr{%
+ test {\ifenddateuncertain}%
+ and
+ togl {blx@dateuncertain}%
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\def\if@cms@onlyyears#1{%
+ \ifboolexpr{%
+ test {\iffieldundef{#1month}}%
+ and
+ test {\iffieldundef{#1endmonth}}%
+ and
+ test {\iffieldundef{#1day}}%
+ and
+ test {\iffieldundef{#1endday}}%
+ }%
+ {\@firstoftwo}%
+ {\@secondoftwo}}
+
+\newbibmacro*{standard+labelyear+extrayear}{%
+ \ifthenelse{\iffieldundef{labelyear}\OR%
+ \iffieldequalstr{labelyear}{nodate}}% or new declaration ???
+ {\ifboolexpr{%
+ test {\ifentrytype{misc}}%
+ or
+ test {\ifentrytype{inreference}}%
+ or
+ test {\ifentrytype{reference}}%
+ or
+ test {\ifentrytype{mvreference}}%
+ or
+ not togl {cms@nodates}}%
+ {}%
+ {\bibstring{nodate}}}%
+ {\iffieldundef{year}%
+ {\iffieldundef{eventyear}%
+ {\iffieldundef{origyear}%
+ {\printurldateextra%
+ \usebibmacro{clear+datefield}{url}}%
+ {\printorigdateextra%
+ \usebibmacro{clear+datefield}{orig}}}%
+ {\printeventdateextra%
+ \usebibmacro{clear+datefield}{event}}}%
+ {\printdateextra%
+ \usebibmacro{clear+datefield}{}}}}%
+
+\newbibmacro*{origfirst+labelyear+extrayear}{%
+ \ifthenelse{\iffieldundef{labelyear}\OR%
+ \iffieldequalstr{labelyear}{nodate}}%
+ {\ifboolexpr{%
+ test {\ifentrytype{misc}}%
+ or
+ test {\ifentrytype{inreference}}%
+ or
+ test {\ifentrytype{reference}}%
+ or
+ test {\ifentrytype{mvreference}}%
+ or
+ not togl {cms@nodates}}%
+ {}%
+ {\bibstring{nodate}}}%
+ {\iffieldundef{origyear}%
+ {\iffieldundef{year}%
+ {\iffieldundef{eventyear}%
+ {\printurldateextra%
+ \usebibmacro{clear+datefield}{url}}%
+ {\printeventdateextra%
+ \usebibmacro{clear+datefield}{event}}}%
+ {\printdateextra%
+ \usebibmacro{clear+datefield}{}}}%
+ {\printorigdateextra%
+ \usebibmacro{clear+datefield}{orig}}}}%
+
+\newbibmacro*{av+labelyear+extrayear}{%
+ \ifthenelse{\iffieldundef{labelyear}\OR%
+ \iffieldequalstr{labelyear}{nodate}}%
+ {\ifboolexpr{%
+ test {\ifentrytype{misc}}%
+ or
+ test {\ifentrytype{inreference}}%
+ or
+ test {\ifentrytype{reference}}%
+ or
+ test {\ifentrytype{mvreference}}%
+ or
+ not togl {cms@nodates}}%
+ {}%
+ {\bibstring{nodate}}}%
+ {\iffieldundef{eventyear}%
+ {\iffieldundef{origyear}%
+ {\iffieldundef{year}%
+ {\printurldateextra%
+ \usebibmacro{clear+datefield}{url}}%
+ {\printdateextra%
+ \usebibmacro{clear+datefield}{}}}%
+ {\printorigdateextra%
+ \usebibmacro{clear+datefield}{orig}}}%
+ {\printeventdateextra%
+ \usebibmacro{clear+datefield}{event}}}}%
+
+\newbibmacro*{clear+datefield}[1]{%
+ \iffieldundef{#1endyear}%
+ {\clearfield{#1year}}%
+ {\ifthenelse{\iffieldundef{#1month}\AND\iffieldundef{#1season}}%
+ {\clearfield{#1year}}%
+ {\ifdateyearsequal{#1}{#1end}%
+ {\clearfield{#1year}\clearfield{#1endyear}}%
+ {}}}}%
+
+\newbibmacro*{cmsbibsortdate}{% Attempt to solve date-related problems
+ \ifboolexpr{%
+ test {\iffieldundef{origyear}}%
+ or
+ not test {\iffieldint{origyear}}%
+ }%
+ {\usebibmacro{cmsbibyear}}%
+ {\iffieldint{year}%
+ {\ifboolexpr{% Needed for date ranges - video type, esp.
+ test {\iffieldundef{endyear}}%
+ or
+ not test {\iffieldnum{endyear}}%
+ }%
+ {\ifthenelse{\thefield{origyear}>\thefield{year}}%
+ {\toggletrue{cms@switchdates}%
+ \usebibmacro{cmsbibyear}}%
+ {\usebibmacro{cmsbibyear}}}%
+ {\ifthenelse{\thefield{origyear}>\thefield{endyear}}%
+ {\toggletrue{cms@switchdates}%
+ \usebibmacro{cmsbibyear}}%
+ {\usebibmacro{cmsbibyear}}}}%
+ {\usebibmacro{cmsbibyear}}}}%
+
+\newbibmacro*{cmsbibyear}{%
+ \iftoggle{cms@origlabel}%
+ {\usebibmacro{origyear+labelyear}}%
+ {\iftoggle{cms@bothlabelnew}%
+ {\usebibmacro{bothyear+oldstyle}}%
+ {\iftoggle{cms@bothlabelold}%
+ {\usebibmacro{bothyear+oldstyle}}%
+ {\usebibmacro{labelyear+extrayear}}}}}%
+
+\newbibmacro*{origyear+labelyear}{%
+ \ifboolexpr{ (
+ test {\ifentrytype{music}}%
+ or
+ test {\ifentrytype{review}}%
+ or
+ test {\ifentrytype{suppperiodical}}%
+ or
+ test {\ifentrytype{video}}%
+ )
+ and
+ togl {cms@avdate}%
+ }%
+ {\usebibmacro{av+labelyear+extrayear}}%
+ {\iftoggle{cms@switchdates}%
+ {\usebibmacro{labelyear+extrayear}}%
+ {\iffieldundef{origyear}%
+ {\iftoggle{cms@ordate}% ???
+ {}%
+ {\clearfield{extradate}}%
+ \usebibmacro{standard+labelyear+extrayear}}%
+ {\iftoggle{cms@ordate}%
+ {\usebibmacro{origfirst+labelyear+extrayear}}%
+ {\clearfield{extradate}%
+ \printorigdateextra%\usebibmacro{origyear+endyear}%
+ \usebibmacro{clear+datefield}{orig}}}}}}%
+
+\newbibmacro*{bothyear+oldstyle}{%
+ \ifboolexpr{ (
+ test {\ifentrytype{music}}%
+ or
+ test {\ifentrytype{review}}%
+ or
+ test {\ifentrytype{suppperiodical}}%
+ or
+ test {\ifentrytype{video}}%
+ )
+ and
+ togl {cms@avdate}%
+ }%
+ {\usebibmacro{av+labelyear+extrayear}}% \clearfield local to \printtext
+ {\iftoggle{cms@switchdates}%
+ {\printtext{%
+ \bibopenparen%
+ \usebibmacro{labelyear+extrayear}%
+ \bibcloseparen%
+ \setunit{\addspace}%
+ \clearfield{extrayear}%
+ \printorigdateextra}% \usebibmacro{origyear+endyear}
+ \usebibmacro{clear+datefield}{}%
+ \usebibmacro{clear+datefield}{orig}}%
+ {\iffieldundef{origyear}%
+ {\iftoggle{cms@ordate}%
+ {}%
+ {\clearfield{extradate}}%
+ \usebibmacro{standard+labelyear+extrayear}}%
+ {\iftoggle{cms@ordate}% ???
+ {\iffieldundef{year}%
+ {\usebibmacro{origfirst+labelyear+extrayear}}%
+ {\printtext{%
+ \bibopenparen%
+ \usebibmacro{origfirst+labelyear+extrayear}%
+ \bibcloseparen%
+ \setunit*{\addspace}%
+ \clearfield{extradate}%
+ \printdateextra}}}% \usebibmacro{year+endyear}
+ {\iffieldundef{year}%
+ {\usebibmacro{origfirst+labelyear+extrayear}}%
+ {\printtext{%
+ \bibopenparen%
+ \clearfield{extradate}%
+ \printorigdateextra%
+ % \usebibmacro{origyear+endyear}%
+ \bibcloseparen%
+ \setunit*{\addspace}%
+ \usebibmacro{standard+labelyear+extrayear}}}}%
+ \usebibmacro{clear+datefield}{orig}%
+ \usebibmacro{clear+datefield}{}}}}}%
+
+\newbibmacro*{pubstate}{%
+ \iftoggle{cms@reprint}%
+ {\iftoggle{cms@switchdates}%
+ {\iffieldundef{year}% Fix for consistency???
+ {}%
+ {\printtext{% 16th ed.
+ \usebibmacro{choosepubstring}%
+ \printdate}}}% Need \addperiod & \nopunct ??
+ {\iffieldundef{origyear}%
+ {}%
+ {\printtext{% 16th ed.
+ \usebibmacro{choosepubstring}%
+ \printorigdate}}}}% Need \addperiod & \nopunct ??
+ {\printfield{pubstate}}}%
+
+\newbibmacro*{choosepubstring}{%
+ \ifthenelse{\ifentrytype{video}\OR%
+ \ifentrytype{music}}%
+ {\bibstring{origreleaseyear}}%
+ {\bibstring{origpubyear}}}%
+
+\newbibmacro*{bibreprint}{%
+ \iftoggle{cms@reprint}%
+ {\iffieldundef{origyear}%
+ {\bibstring{reprint}\newcunit}% 16th ed.
+ {\iftoggle{cms@switchdates}%
+ {\bibstring{reprint}\newcunit}% 16th ed.
+ {}}}%
+ {}}%
+
+\newbibmacro*{volume+pages}{% Volume fix (modified)
+ \ifboolexpr{%
+ test {\iffieldundef{maintitle}}%
+ or
+ togl {cms@vol}%
+ }%
+ {\global\togglefalse{cms@vol}%
+ \ifthenelse{\iffieldundef{volume}\AND\iffieldundef{part}}%
+ {\printfield{pages}%
+ \newunit%
+ \printfield{volumes}}%
+ {\iffieldundef{part}%
+ {\iffieldundef{pages}%
+ {\printfield{volume}}% Still print this w/o part or pages???
+ {\ifthenelse{\iffieldnums{pages}%
+ \AND\iffieldundef{bookpagination}\AND\iffieldnums{volume}}%
+ {\printfield[default]{volume}%
+ \postvolpunct%
+ \printfield{pages}}%
+ {\printfield{volume}%
+ \addcomma\addspace%
+ \printfield{pages}}}}%
+ {\printfield{volume}%
+ \printfield{part}%
+ \newcunit%
+ \printfield{pages}}}}%
+ {\ifboolexpr{%
+ togl {cms@hidevolumes}%
+ and
+ (
+ not test {\iffieldundef{volume}}%
+ or
+ not test {\iffieldundef{part}}%
+ )
+ }%
+ {\printfield{pages}}%
+ {\printfield{pages}%
+ \newunit%
+ \printfield{volumes}}}}%
+
+\newbibmacro*{bibprexref}{% For back references
+ \iflistundef{pageref}{}{\savelist{pageref}{\cbx@incollpgref}}}%
+
+\newbibmacro*{bibpostxref}{% Volume fix
+ \iffieldundef{chapter}%
+ {\iffieldundef{pages}%
+ {\iffieldundef{volume}%
+ {\iffieldundef{part}%
+ {}%
+ {\newcunit\printfield{part}}}%
+ {\ifboolexpr{%
+ test {\ifcsdef{cbx@incollvol}}%
+ and
+ test {\iffieldequalcs{volume}{cbx@incollvol}}%
+ }%
+ {\iffieldundef{part}%
+ {}%
+ {\ifboolexpr{%
+ test {\ifcsdef{cbx@incollpart}}%
+ and
+ test {\iffieldequalcs{part}{cbx@incollpart}}%
+ }%
+ {}%
+ {\newcunit\printfield{part}}}}%
+ {\iffieldundef{part}%
+ {\newcunit\printfield{volume}}%
+ {\newcunit\printfield{volume}\printfield{part}}}}}%
+ {\iffieldundef{volume}%
+ {\iffieldundef{part}%
+ {\newcunit\printfield{pages}}%
+ {\newcunit\printfield{part}\newcunit\printfield{pages}}}%
+ {\ifboolexpr{%
+ test {\ifcsdef{cbx@incollvol}}%
+ and
+ test {\iffieldequalcs{volume}{cbx@incollvol}}%
+ }%
+ {\iffieldundef{part}%
+ {\newcunit\printfield{pages}}%
+ {\ifboolexpr{%
+ test {\ifcsdef{cbx@incollpart}}%
+ and
+ test {\iffieldequalcs{part}{cbx@incollpart}}%
+ }%
+ {\newcunit\printfield{pages}}%
+ {\newcunit\printfield{part}\newcunit\printfield{pages}}}}%
+ {\iffieldundef{part}%
+ {\ifthenelse{\iffieldnums{pages}%
+ \AND\iffieldundef{bookpagination}\AND\iffieldnums{volume}}%
+ {\newcunit\printfield[default]{volume}%
+ \postvolpunct%
+ \printfield{pages}}%
+ {\newcunit\printfield{volume}%
+ \addcomma\addspace%
+ \printfield{pages}}}%
+ {\newcunit\printfield{volume}%
+ \printfield{part}%
+ \newcunit%
+ \printfield{pages}}}}}}%
+ {\newcunit\printfield{chapter}}%
+ \iftoggle{cms@xrefurl}%
+ {\newunit%
+ \usebibmacro{bib+doi+url}}%
+ {}%
+ \ifcsdef{cbx@incollpgref}% Here we print and clear the child's
+ {\restorelist{pageref}{\cbx@incollpgref}% backrefs
+ \newunit%
+ \usebibmacro{pageref}%
+ \global\let\cbx@incollpgref\undefined}%
+ {}}%
+
+\newbibmacro*{volume+or+volumes}{% Volume fix (modified)
+ \iffieldundef{maintitle}%
+ {\ifthenelse{\iffieldundef{volume}\AND\iffieldundef{part}}%
+ {\printfield{volumes}}%
+ {\printfield{volume}%
+ \printfield{part}}}%
+ {\ifboolexpr{%
+ togl {cms@hidevolumes}%
+ and
+ (
+ not test {\iffieldundef{volume}}%
+ or
+ not test {\iffieldundef{part}}%
+ )
+ }%
+ {}%
+ {\printfield{volumes}}}}
+
+\newbibmacro*{mtitle+mstitle+vol+part+title+stitle}{%
+ \iffieldundef{maintitle}%
+ {}%
+ {\ifthenelse{\iffieldundef{volume}\AND\iffieldundef{part}}% Test ???
+ {\iffieldundef{title}%
+ {\usebibmacro{cms-in:}}%
+ {\bibstring{in}\setunit{\addspace}}% Volume-less treatment?
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}%
+ {\printfield{volume}%
+ \printfield{part}%
+ \setunit{\addspace}%
+ \bibstring{ofseries}%
+ \setunit{\addspace}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}}}%
+
+\newbibmacro*{btitle+bstitle}{% InIn fix from N&B
+ \iffieldundef{booktitle}%
+ {}%
+ {\ifthenelse{\ifentrytype{audio}\OR\ifentrytype{music}\OR%
+ \ifentrytype{video}}%
+ {}%
+ {\usebibmacro{cms-in:}}%
+ \printtext{%
+ \printfield{booktitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[booksubtitle]{booksubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{booktitleaddon}%
+ \setunit*{\addcomma\addspace}}}%
+
+\newbibmacro*{mtitle+mstitle+vol+part+btitle+bstitle}{%
+ \usebibmacro{btitle+bstitle}%
+ \iffieldundef{maintitle}%
+ {}%
+ {\ifthenelse{\(\iffieldundef{volume}\AND\iffieldundef{part}\)\OR%
+ \(\iffieldundef{booktitle}\AND\NOT\ifentrytype{bookinbook}\)}%
+ {\usebibmacro{cms-in:}% Volume-less treatment?
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}%
+ \toggletrue{cms@vol}}%
+ {\printfield{volume}%
+ \printfield{part}%
+ \setunit{\addspace}%
+ \bibstring{ofseries}%
+ \setunit{\addspace}%
+ \printtext{%
+ \printfield{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[mainsubtitle]{mainsubtitle}}%
+ \setunit{\ctitleaddonpunct}%
+ \printfield{maintitleaddon}}}}%
+
+\newbibmacro*{cjournal+ser+vol+num}{% Moved to bbx
+ \usebibmacro{journal+sub}%
+ \setunit*{\addspace}%
+ \printlist[periodplace]{location}%
+ \setunit*{\addspace}%
+ \iffieldundef{series}%
+ {}%
+ {\newcunit
+ \printfield[jourser]{series}%
+ \newcunit}%\setunit*{\addspace}?
+ \ifthenelse{\iffieldundef{year}\AND\iffieldundef{month}\AND%
+ \iffieldundef{issue}\AND\iffieldundef{season}}%
+ {\iffieldundef{volume}%
+ {\newcunit%
+ \printfield[journum]{number}%
+ \clearfield{number}%
+ \printunit{\addcomma\addspace}}%
+ {\printfield[jourvol]{volume}%
+ \setunit{\addcomma\addspace}}}%
+ {\printfield[jourvol]{volume}%
+ \newcunit%
+ \printfield[journum]{number}%
+ \clearfield{number}%
+ \setunit{\addcomma\addspace}}% need * here?
+ \printfield{eid}%
+ \newunit}%
+
+\newbibmacro*{journal+issue+year+pages}{%
+ \ifboolexpr{%
+ not togl {cms@numbermonth}%
+ or
+ test {\ifcsstring{blx@dateformat@date}{year}}%
+ }%
+ {\clearfield{month}}%
+ {}%
+ \usebibmacro{cjournal+ser+vol+num}%
+ \setunit{\addspace}%
+ \ifthenelse{\iffieldundef{issue}\AND\iffieldundef{month}%
+ \AND\iffieldundef{number}\AND\iffieldundef{year}\AND%
+ \iffieldundef{season}}% Test year for related entries??
+ {\ifthenelse{\iffieldundef{bookpagination}\AND\NOT\iffieldundef{volume}}%
+ {\setunit{\postvolpunct}}%
+ {\setunit{\addcolon\addspace}}}% This may not be universally correct.
+ {\printtext[parens]{% Perhaps if it's wrong use magazine subtype?
+ \iffieldundef{issue}%
+ {\usebibmacro{date}%
+ \printfield{number}}%
+ {\printfield{issue}%
+ \setunit{\addspace}%
+ \usebibmacro{cmsyear}}}%
+ \setunit{\addcolon\addspace}}%
+ \printfield{pages}}%
+
+\newbibmacro*{periodical+issue+year+pages}{%
+ \ifboolexpr{%
+ not togl {cms@numbermonth}%
+ or
+ test {\ifcsstring{blx@dateformat@date}{year}}%
+ }%
+ {\clearfield{month}}%
+ {}%
+ \usebibmacro{cperiodical+ser+vol+num}%
+ \setunit{\addspace}%
+ \ifthenelse{\iffieldundef{issue}\AND\iffieldundef{month}%
+ \AND\iffieldundef{number}\AND\iffieldundef{year}\AND%
+ \iffieldundef{season}}% See prev. macro
+ {\ifthenelse{\iffieldundef{bookpagination}\AND\NOT\iffieldundef{volume}}%
+ {\setunit{\postvolpunct}}%
+ {\setunit{\addcolon\addspace}}}%
+ {\printtext[parens]{%
+ \iffieldundef{issue}%
+ {\usebibmacro{date}%
+ \printfield{number}}%
+ {\printfield{issue}%
+ \setunit{\addspace}%
+ \usebibmacro{cmsyear}}}%
+ \setunit{\addcolon\addspace}}%
+ \printfield{pages}}%
+
+\newbibmacro*{bycompiler}{%
+ \ifnameundef{namec}%
+ {}%
+ {\bibstring{bycompiler}\addspace
+ \printnames[bycompiler]{namec}}}
+
+\renewbibmacro*{byeditor}{%
+ \ifnameundef{editor}%
+ {}%
+ {\usebibmacro{cbytypestrg}{editor}{editor}%
+ \setunit{\addspace}%
+ \printnames[byeditor]{editor}%
+ \usebibmacro{editorpunct}}%
+ \usebibmacro{byeditorx}}%
+
+\renewbibmacro*{byeditorx}{%
+ \ifnameundef{editora}%
+ {}%
+ {\usebibmacro{cbytypestrg}{editora}{editor}%
+ \setunit{\addspace}%
+ \printnames[byeditora]{editora}%
+ \usebibmacro{editorpunct}}%
+ \ifnameundef{editorb}%
+ {}%
+ {\usebibmacro{cbytypestrg}{editorb}{editor}%
+ \setunit{\addspace}%
+ \printnames[byeditorb]{editorb}%
+ \usebibmacro{editorpunct}}%
+ \ifnameundef{editorc}%
+ {}%
+ {\usebibmacro{cbytypestrg}{editorc}{editor}%
+ \setunit{\addspace}%
+ \printnames[byeditorc]{editorc}%
+ \usebibmacro{editorpunct}}}
+
+\renewbibmacro*{byeditor+others}{%
+ \ifthenelse{\NOT\ifnameundef{editor}\AND
+ \(\iffieldundef{editortype}\OR
+ \iffieldequalstr{editortype}{editor}\)}%
+ {\def\@tempa{byeditor}%
+ \ifnamesequal{editor}{translator}%
+ {\edef\@tempa{\@tempa tr}%
+ \clearname{translator}}%
+ {}%
+ \ifnamesequal{editor}{namec}%
+ {\edef\@tempa{\@tempa cp}%
+ \clearname{namec}}%
+ {}%
+ \ifnamesequal{editor}{commentator}%
+ {\edef\@tempa{\@tempa co}%
+ \clearname{commentator}}%
+ {\ifnamesequal{editor}{annotator}%
+ {\edef\@tempa{\@tempa an}%
+ \clearname{annotator}}%
+ {}}%
+ \ifnamesequal{editor}{introduction}%
+ {\edef\@tempa{\@tempa in}%
+ \clearname{introduction}}%
+ {\ifnamesequal{editor}{foreword}%
+ {\edef\@tempa{\@tempa fo}%
+ \clearname{foreword}}%
+ {\ifnamesequal{editor}{afterword}%
+ {\edef\@tempa{\@tempa af}%
+ \clearname{afterword}}%
+ {}}}%
+ \bibstring{\@tempa}%
+ \setunit{\addspace}%
+ \printnames[byeditor]{editor}%
+ \clearname{editor}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{byeditorx}}%
+ {\usebibmacro{byeditor}}%
+ \usebibmacro{bytranslator+others}}%
+
+\renewbibmacro*{bytranslator+others}{%
+ \ifnameundef{translator}%
+ {}%
+ {\def\@tempa{bytranslator}%
+ \ifnamesequal{translator}{namec}%
+ {\edef\@tempa{\@tempa cp}%
+ \clearname{namec}}%
+ {}%
+ \ifnamesequal{translator}{commentator}%
+ {\edef\@tempa{\@tempa co}%
+ \clearname{commentator}}%
+ {\ifnamesequal{translator}{annotator}%
+ {\edef\@tempa{\@tempa an}%
+ \clearname{annotator}}%
+ {}}%
+ \ifnamesequal{translator}{introduction}%
+ {\edef\@tempa{\@tempa in}%
+ \clearname{introduction}}%
+ {\ifnamesequal{translator}{foreword}%
+ {\edef\@tempa{\@tempa fo}%
+ \clearname{foreword}}%
+ {\ifnamesequal{translator}{afterword}%
+ {\edef\@tempa{\@tempa af}%
+ \clearname{afterword}}%
+ {}}}%
+ \bibstring{\@tempa}\space
+ \printnames[bytranslator]{translator}%
+ \clearname{translator}%
+ \usebibmacro{editorpunct}}%
+ \usebibmacro{bycompiler+others}}%
+
+\newbibmacro*{bycompiler+others}{%
+ \ifnameundef{namec}%
+ {}%
+ {\def\@tempa{bycompiler}%
+ \ifnamesequal{namec}{commentator}%
+ {\edef\@tempa{\@tempa co}%
+ \clearname{commentator}}%
+ {\ifnamesequal{namec}{annotator}%
+ {\edef\@tempa{\@tempa an}%
+ \clearname{annotator}}%
+ {}}%
+ \ifnamesequal{namec}{introduction}%
+ {\edef\@tempa{\@tempa in}%
+ \clearname{introduction}}%
+ {\ifnamesequal{namec}{foreword}%
+ {\edef\@tempa{\@tempa fo}%
+ \clearname{foreword}}%
+ {\ifnamesequal{namec}{afterword}%
+ {\edef\@tempa{\@tempa af}%
+ \clearname{afterword}}%
+ {}}}%
+ \bibstring{\@tempa}\space
+ \printnames[bycompiler]{namec}%
+ \clearname{namec}%
+ \usebibmacro{editorpunct}}%
+ \usebibmacro{byothers}}%
+
+\newbibmacro*{byothers}{% Changed for 0.9
+ \usebibmacro{cbytranslator}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{bycompiler}%
+ \usebibmacro{editorpunct}%
+% \usebibmacro{byredactor}%
+% \usebibmacro{editorpunct}%
+ \usebibmacro{withcommentator}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{withannotator}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{withintroduction}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{withforeword}%
+ \usebibmacro{editorpunct}%
+ \usebibmacro{withafterword}}%
+
+%%%% Related functionality from standard.bbx %%%%
+
+\newcounter{bbx:relatedcount}
+\newcounter{bbx:relatedtotal}
+
+\newbibmacro*{related:init}{%
+ \csundef{bbx:relatedloop}}
+
+\newbibmacro*{begrelated}{\ifcsdef{bbx@lasthash}%
+ {\let\cms@related@hash\bbx@lasthash}{}}%
+\newbibmacro*{endrelated}{\ifcsdef{cms@related@hash}%
+ {\global\let\bbx@lasthash\cms@related@hash%
+ \let\cms@related@hash\undefined}{}}%
+\newbibmacro*{begrelatedloop}{}
+\newbibmacro*{endrelatedloop}{}
+
+\newcommand*{\begrelateddelimmaintitle}{\newunitpunct\par\nobreak}%
+\newcommand*{\begrelateddelimmaintitlenc}{\newunitpunct\par\nobreak}%
+
+\def\ifrelatedloop{%
+ \ifboolexpr{ test {\xifinlistcs{\strfield{entrykey}}{bbx:relatedloop}}%
+ or test {\xifinlistcs{\strfield{clonesourcekey}}{bbx:relatedloop}} }}%
+
+\newbibmacro*{related}{%
+ \ifboolexpr{ test {\iffieldundef{related}} or test {\ifrelatedloop} }%
+ {}%
+ {\ifcsundef{begrelateddelim\strfield{relatedtype}}%
+ {\printunit{\begrelateddelim}}%
+ {\printunit{\csuse{begrelateddelim\strfield{relatedtype}}}}%
+ \usebibmacro{begrelated}%
+ \def\bbx@tempa{}%
+ \setcounter{bbx:relatedtotal}{0}%
+ \def\do##1{%
+ \entrydata{##1}{%
+ \ifrelatedloop%
+ {}%
+ {\stepcounter{bbx:relatedtotal}%
+ \gappto{\bbx@tempa}{##1,}}}}%
+ \docsvfield{related}%
+ \restorefield{related}{\bbx@tempa}%
+ \ifnumgreater{\value{bbx:relatedtotal}}{0}%
+ {\listcsxadd{bbx:relatedloop}{\strfield{entrykey}}%
+ \iffieldundef{clonesourcekey}%
+ {}%
+ {\listcsxadd{bbx:relatedloop}{\strfield{clonesourcekey}}}%
+ \setcounter{bbx:relatedcount}{0}%
+ \def\do{%
+ \stepcounter{bbx:relatedcount}%
+ \ifnumgreater{\value{bbx:relatedcount}}{1}%
+ {\ifcsundef{relateddelim\strfield{relatedtype}}%
+ {\printunit{\relateddelim}}%
+ {\expandafter\expandafter\expandafter\expandafter\expandafter
+ \expandafter\expandafter\printunit
+ \expandafter\expandafter\expandafter\expandafter\expandafter
+ \expandafter\expandafter{%
+ \csuse{relateddelim\strfield{relatedtype}}}}}%
+ {}}%
+ \ifbibmacroundef{related:\strfield{relatedtype}}%
+ {\appto{\do}{\usebibmacro{related:default}}}%
+ {\appto{\do}{\usebibmacro*{related:\strfield{relatedtype}}}}%
+ \iffieldformatundef{related:\strfield{relatedtype}}%
+ {\def\bbx@tempa{related}}%
+ {\def\bbx@tempa{related:\strfield{relatedtype}}}%
+ \iffieldformatundef{relatedstring:\strfield{relatedtype}}%
+ {\def\bbx@tempb{relatedstring:default}}%
+ {\def\bbx@tempb{relatedstring:\strfield{relatedtype}}}%
+ \printtext[\bbx@tempa]{%
+ \usebibmacro{begrelatedloop}%
+ \iffieldundef{relatedstring}%
+ {\ifboolexpr{%
+ test {\ifnumgreater{\value{bbx:relatedtotal}}{1}}%
+ and
+ test {\ifbibxstring{\thefield{relatedtype}s}}%
+ }%
+ {\printtext[\bbx@tempb]{%
+ \bibstring[\mkrelatedstring]{\thefield{relatedtype}s}}}%
+ {\iffieldbibstring{relatedtype}%
+ {\printtext[\bbx@tempb]{%
+ \bibstring[\mkrelatedstring]{\thefield{relatedtype}}}}%
+ {}}}%
+ {\iffieldbibstring{relatedstring}%
+ {\printtext[\bbx@tempb]{%
+ \bibstring[\mkrelatedstring]{\thefield{relatedstring}}}}%
+ {\printfield[\bbx@tempb]{relatedstring}}}%
+ \docsvfield{related}%
+ \usebibmacro{endrelatedloop}}}%
+ {}%
+ \usebibmacro{endrelated}}}%
+
+\NewBibliographyString{%
+ afterwordto,%
+ broadcast,%
+ by,%
+ bychoreographer,%
+ bycompileraf,%
+ bycompileran,%
+ bycompileranaf,%
+ bycompileranfo,%
+ bycompileranin,%
+ bycompilerco,%
+ bycompilercoaf,%
+ bycompilercofo,%
+ bycompilercoin,%
+ bycompilerfo,%
+ bycompilerin,%
+ byconductor,%
+ bydirector,%
+ byeditoralt,%
+ byeditorcp,%
+ byeditorcpaf,%
+ byeditorcpan,%
+ byeditorcpanaf,%
+ byeditorcpanfo,%
+ byeditorcpanin,%
+ byeditorcpco,%
+ byeditorcpcoaf,%
+ byeditorcpcofo,%
+ byeditorcpcoin,%
+ byeditorcpfo,%
+ byeditorcpin,%
+ byeditortrcp,%
+ byeditortrcpaf,%
+ byeditortrcpan,%
+ byeditortrcpanaf,%
+ byeditortrcpanfo,%
+ byeditortrcpanin,%
+ byeditortrcpco,%
+ byeditortrcpcoaf,%
+ byeditortrcpcofo,%
+ byeditortrcpcoin,%
+ byeditortrcpfo,%
+ byeditortrcpin,%
+ bynone,%
+ byproducer,%
+ bytranslatorcp,%
+ bytranslatorcpaf,%
+ bytranslatorcpan,%
+ bytranslatorcpanaf,%
+ bytranslatorcpanfo,%
+ bytranslatorcpanin,%
+ bytranslatorcpco,%
+ bytranslatorcpcoaf,%
+ bytranslatorcpcofo,%
+ bytranslatorcpcoin,%
+ bytranslatorcpfo,%
+ bytranslatorcpin,%
+ canadasection,%
+ canadasections,%
+ cbyannotator,%
+ cbyauthor,%
+ cbychoreographer,%
+ cbycollaborator,%
+ cbycommentator,%
+ cbycompiler,%
+ cbycompileraf,%
+ cbycompileran,%
+ cbycompileranaf,%
+ cbycompileranfo,%
+ cbycompileranin,%
+ cbycompilerco,%
+ cbycompilercoaf,%
+ cbycompilercofo,%
+ cbycompilercoin,%
+ cbycompilerfo,%
+ cbycompilerin,%
+ cbyconductor,%
+ cbycontinuator,%
+ cbydirector,%
+ cbyeditor,%
+ cbyeditoraf,%
+ cbyeditoralt,%
+ cbyeditoran,%
+ cbyeditoranaf,%
+ cbyeditoranfo,%
+ cbyeditoranin,%
+ cbyeditorco,%
+ cbyeditorcoaf,%
+ cbyeditorcofo,%
+ cbyeditorcoin,%
+ cbyeditorcp,%
+ cbyeditorcpaf,%
+ cbyeditorcpan,%
+ cbyeditorcpanaf,%
+ cbyeditorcpanfo,%
+ cbyeditorcpanin,%
+ cbyeditorcpco,%
+ cbyeditorcpcoaf,%
+ cbyeditorcpcofo,%
+ cbyeditorcpcoin,%
+ cbyeditorcpfo,%
+ cbyeditorcpin,%
+ cbyeditorfo,%
+ cbyeditorin,%
+ cbyeditortr,%
+ cbyeditortraf,%
+ cbyeditortran,%
+ cbyeditortranaf,%
+ cbyeditortranfo,%
+ cbyeditortranin,%
+ cbyeditortrco,%
+ cbyeditortrcoaf,%
+ cbyeditortrcofo,%
+ cbyeditortrcoin,%
+ cbyeditortrcp,%
+ cbyeditortrcpaf,%
+ cbyeditortrcpan,%
+ cbyeditortrcpanaf,%
+ cbyeditortrcpanfo,%
+ cbyeditortrcpanin,%
+ cbyeditortrcpco,%
+ cbyeditortrcpcoaf,%
+ cbyeditortrcpcofo,%
+ cbyeditortrcpcoin,%
+ cbyeditortrcpfo,%
+ cbyeditortrcpin,%
+ cbyeditortrfo,%
+ cbyeditortrin,%
+ cbyfounder,%
+ cbynone,%
+ cbyorganizer,%
+ cbyproducer,%
+ cbyredactor,%
+ cbytranslator,%
+ cbytranslatoraf,%
+ cbytranslatoran,%
+ cbytranslatoranaf,%
+ cbytranslatoranfo,%
+ cbytranslatoranin,%
+ cbytranslatorco,%
+ cbytranslatorcoaf,%
+ cbytranslatorcofo,%
+ cbytranslatorcoin,%
+ cbytranslatorcp,%
+ cbytranslatorcpaf,%
+ cbytranslatorcpan,%
+ cbytranslatorcpanaf,%
+ cbytranslatorcpanfo,%
+ cbytranslatorcpanin,%
+ cbytranslatorcpco,%
+ cbytranslatorcpcoaf,%
+ cbytranslatorcpcofo,%
+ cbytranslatorcpcoin,%
+ cbytranslatorcpfo,%
+ cbytranslatorcpin,%
+ cbytranslatorfo,%
+ cbytranslatorin,%
+ century,%
+ cfromamerican,%
+ cfrombrazilian,%
+ cfrombulgarian,%
+ cfromcatalan,%
+ cfromcroatian,%
+ cfromczech,%
+ cfromdanish,%
+ cfromdutch,%
+ cfromenglish,%
+ cfromestonian,%
+ cfromfinnish,%
+ cfromfrench,%
+ cfromgalician,%
+ cfromgerman,%
+ cfromgreek,%
+ cfromitalian,%
+ cfromjapanese,%
+ cfromlatin,%
+ cfromnorwegian,%
+ cfrompolish,%
+ cfromportuguese,%
+ cfromrussian,%
+ cfromslovak,%
+ cfromslovene,%
+ cfromspanish,%
+ cfromswedish,%
+ cfromukrainian,%
+ choreographer,%
+ choreographers,%
+ commenton,%
+ conductor,%
+ conductors,%
+ decade,%
+ director,%
+ directors,%
+ discrecorded,%
+ edamerican,%
+ edbrazilian,%
+ edbulgarian,%
+ edcatalan,%
+ edcroatian,%
+ edczech,%
+ eddanish,%
+ eddutch,%
+ edenglish,%
+ edestonian,%
+ edfinnish,%
+ edfrench,%
+ edgalician,%
+ edgerman,%
+ edgreek,%
+ editalian,%
+ editorcompiler,%
+ editorcompilers,%
+ editortranscompiler,%
+ editortranscompilers,%
+ editortranslator,%
+ editortranslators,%
+ edjapanese,%
+ edlatin,%
+ ednorwegian,%
+ edpolish,%
+ edportuguese,%
+ edrussian,%
+ edslovak,%
+ edslovene,%
+ edspanish,%
+ edswedish,%
+ edukrainian,%
+ forewordto,%
+ hereinafter,%
+ inlang,%
+ introductionto,%
+ none,%
+ nones,%
+ note,%
+ numbers,%
+ of,%
+ on,%
+ origedition,%
+ origpub,%
+ origpublin,%
+ origpubyear,%
+ origpubyearalt,%
+ origreleaseyear,%
+ origshownyear,%
+ partvolume,%
+ patentfiled,%
+ patentissued,%
+ preface,%
+ printed,%
+ producer,%
+ producers,%
+ pseudonym,%
+ review,%
+ revisededition,%
+ selfpublished,%
+ songrecorded,%
+ subsection,%
+ subsections,%
+ subverbis,%
+ subverbo,%
+ supranote,%
+ track,%
+ transcompiler,%
+ transcompilers%
+ }%
+
+\endinput