diff options
author | Karl Berry <karl@freefriends.org> | 2021-11-10 21:18:29 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2021-11-10 21:18:29 +0000 |
commit | ef6f808cdbbfe2db39a020ec1f9607ea2c366d04 (patch) | |
tree | 7f91a94b0667615b78a547efdb3c62527662c5c0 /Master/texmf-dist/tex/latex/windycity | |
parent | 0fa96dfaeccecfef0e70e06b5dee5fa4f9c47481 (diff) |
windycity (10nov21)
git-svn-id: svn://tug.org/texlive/trunk@61021 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/windycity')
4 files changed, 469 insertions, 275 deletions
diff --git a/Master/texmf-dist/tex/latex/windycity/american-windycity.lbx b/Master/texmf-dist/tex/latex/windycity/american-windycity.lbx index 3f4e5ff0137..36e0169e790 100644 --- a/Master/texmf-dist/tex/latex/windycity/american-windycity.lbx +++ b/Master/texmf-dist/tex/latex/windycity/american-windycity.lbx @@ -1,4 +1,4 @@ -% Last modified: Wed 07 Jul 2021 05:45:54 PM CDT +% Last modified: Tue 09 Nov 2021 07:45:43 PM CST % Permission is granted to copy, distribute and/or modify this % software under the terms of the LaTeX Project Public License (LPPL), @@ -11,7 +11,7 @@ % implied warranties of merchantability and fitness for a particular % purpose. -\ProvidesFile{american-windycity.lbx}[2021/07/07 Windy City +\ProvidesFile{american-windycity.lbx}[2021/11/09 Windy City localization module for biblatex] \InheritBibliographyExtras{american} \InheritBibliographyStrings{american} diff --git a/Master/texmf-dist/tex/latex/windycity/windycity.bbx b/Master/texmf-dist/tex/latex/windycity/windycity.bbx index f7679dc8adb..6537e4c13dd 100644 --- a/Master/texmf-dist/tex/latex/windycity/windycity.bbx +++ b/Master/texmf-dist/tex/latex/windycity/windycity.bbx @@ -1,4 +1,4 @@ -% Last modified: Wed 07 Jul 2021 05:45:49 PM CDT +% Last modified: Tue 09 Nov 2021 07:46:28 PM CST % Permission is granted to copy, distribute and/or modify this % software under the terms of the LaTeX Project Public License (LPPL), @@ -11,7 +11,7 @@ % implied warranties of merchantability and fitness for a particular % purpose. -\ProvidesFile{windycity.bbx}[2021/07/07 Windy City bibliography style +\ProvidesFile{windycity.bbx}[2021/11/09 Windy City bibliography style for biblatex] \@ifpackagelater{biblatex}{2019/08/17} {} @@ -128,7 +128,10 @@ \providetoggle{shortlinks} \DeclareBiblatexOption{global}[boolean]{shortlinks}[true]{% - \settoggle{shortlinks}{#1}}% + \ifstrequal{#1}{true} + {\toggletrue{shortlinks}% + \AtBeginBibliography{\togglefalse{shortlinks}}} + {}} \providetoggle{skipdate} \DeclareBiblatexOption{entry}[boolean]{skipdate}[true]{% @@ -180,7 +183,8 @@ \settoggle{url}{#1}} % For setting 'minbibnames' and such, see CMOS, 17th ed., 14.76 and -% 15.29. +% 15.29. For 'citetracker' and 'loccittracker', 'constrict' is too +% strict but seems to work well for 'ibidtracker'. \ExecuteBibliographyOptions{% abbreviate=true, @@ -198,7 +202,7 @@ idemtracker=false, indexing=true, labeldateparts=true, - loccittracker=constrict, + loccittracker=context, minbibnames=7, maxbibnames=10, mincitenames=1, @@ -312,8 +316,8 @@ \field{volume} \literal{0}}} -% When 'journal', 'journaltitle', 'organization', or 'blogtitle' goes -% in the author's position. +% When 'journal', 'journaltitle', 'organization', 'blogtitle' or +% 'collection' goes in the author's position. \DeclareStyleSourcemap{ \maps[datatype=bibtex]{ @@ -392,6 +396,19 @@ } } } +\DeclareStyleSourcemap{ + \maps[datatype=bibtex]{ + \map[overwrite=false]{ + \pertype{unpublished} + \step[notfield=author, final] + \step[fieldsource=collection] + \step[fieldset=sortname, origfieldval] + \step[fieldsource=sortname, + match=\regexp{(.+)}, + replace=\regexp{{$1}}] + } + } +} % Save the entry key of every editor, translator, and title. @@ -522,6 +539,7 @@ \providetoggle{cbx:first} \providetoggle{cbx:idem} \providetoggle{cbx:short} +\providetoggle{cbx:skipdate} \providetoggle{collection} \providetoggle{collection:bk} @@ -682,13 +700,18 @@ \DeclareFieldFormat{journaltitleaddon}{\mkbibbrackets{#1}} \DeclareFieldFormat{titleaddon}{\mkbibbrackets{#1}} -\DeclareFieldFormat[article,incollection,online,reference,review] +\DeclareFieldFormat[article,incollection,online,reference,review,thesis] {title}{\mkbibquote{#1}} -\DeclareFieldFormat[article,incollection,online,reference,review] +\DeclareFieldFormat[article,incollection,online,reference,review,thesis] {labeltitle}{\mkbibquote{#1}} -\DeclareIndexFieldFormat[article,incollection,online,reference,review] +\DeclareIndexFieldFormat[article,incollection,online,reference,review,thesis] {indextitle}{\usebibmacro{index:title}{\index}{\mkbibquote{#1}}} +\DeclareFieldFormat[letter,misc,patent]{title}{#1} +\DeclareFieldFormat[letter,misc,patent]{labeltitle}{#1} +\DeclareIndexFieldFormat[letter,misc,patent] + {indextitle}{\usebibmacro{index:title}{\index}{#1}} + \DeclareFieldAlias[inbook]{title}{title} \DeclareFieldAlias[inbook]{labeltitle}{labeltitle} \DeclareIndexFieldAlias[inbook]{indextitle}{indextitle} @@ -696,20 +719,18 @@ \DeclareFieldFormat{chapter}{\bibstring{chapter}\space #1} \DeclareFieldFormat{issuetitle}{\ifcapital{\MakeCapital{#1}}{#1}} -\DeclareFieldFormat[letter,misc,patent]{title}{#1} -\DeclareFieldFormat[letter,misc,patent]{labeltitle}{#1} -\DeclareFieldFormat[thesis,unpublished]{title}{% - \iftoggle{bibliography} - {\mkbibquote{#1}}% - {\iftoggle{cbx:short} - {\mkbibquote{#1}}% - {\mkbibquote{#1}\nopunct}}} -\DeclareFieldFormat[thesis]{labeltitle}{% - \iftoggle{bibliography} + +\DeclareFieldFormat[unpublished] + {title}{\usebibmacro{unpublished:format}{#1}} +\DeclareFieldFormat[unpublished] + {labeltitle}{\usebibmacro{unpublished:format}{#1}} +\DeclareIndexFieldFormat[unpublished] + {indextitle}{\usebibmacro{index:title}{\index}{% Macro below won't work here + \iffieldundef{collection}{\mkbibquote{#1}}{#1}}} +\newbibmacro*{unpublished:format}[1]{% + \iffieldundef{collection} {\mkbibquote{#1}}% - {\iftoggle{cbx:short} - {\mkbibquote{#1}}% - {\mkbibquote{#1}\nopunct}}} + {#1}}% %%%%%%%%%%%%%%%%%%%%%%%%%%% %% Other Field Formats %% @@ -797,9 +818,6 @@ \DeclareBibliographyAlias{cite:inbook}{cite:incollection} \DeclareBibliographyAlias{cite:letter}{cite:incollection} -\DeclareBibliographyAlias{unpublished}{thesis} -\DeclareBibliographyAlias{cite:unpublished}{cite:thesis} - %%%%%%%%%%%%%%%%%%%%%%%%% %% Author's Position %% %%%%%%%%%%%%%%%%%%%%%%%%% @@ -817,6 +835,7 @@ {\usebibmacro{editors:a}% \ifnameundef{\cbx@namelist} {\toggletrue{noauth}% + \usebibmacro{unpublished:collection}% \usebibmacro{authpos+deflabel}}% {\usebibmacro{addplus+etc}% \usebibmacro{namehash+etc}}} @@ -835,32 +854,38 @@ {} {\ifboolexpr{ togl {collection:ib} and togl {swapvol}} - {\usebibmacro{author+namelist}{bookauthor}}% + {\usebibmacro{shortnames}{bookauthor}}% {\ifnameundef{author} - {\usebibmacro{author+namelist}{bookauthor}}% - {\usebibmacro{author+namelist}{author}}}}} + {\usebibmacro{shortnames}{bookauthor}% + \usebibmacro{test:authortypes}{bookauthor}}% + {\usebibmacro{shortnames}{author}% + \usebibmacro{test:authortypes}{author}}}}} -\newbibmacro*{author+namelist}[1]{% +\newbibmacro*{shortnames}[1]{% \ifboolexpr{ test {\ifnameundef{short#1}} or togl {cbx:first} or togl {bibliography}} {\renewcommand*{\cbx@namelist}{#1}}% - {\renewcommand*{\cbx@namelist}{short#1}}% - \usebibmacro{author+type}{#1}}% + {\renewcommand*{\cbx@namelist}{short#1}}} -\newbibmacro*{author+type}[1]{% +\newbibmacro*{test:authortypes}[1]{% \iffieldundef{#1type} {} - {\iffieldequalstr{#1type}{anon} + {\let\authtypes\empty + \forcsvfield{\listadd\authtypes}{#1type}% + \usebibmacro{types:shared}{\authtypes}}} + +\newbibmacro*{types:shared}[1]{% + \ifinlist{anon}{#1} + {\renewcommand*{\anona}{\bibopenbracket}% + \renewcommand*{\anonb}{\bibclosebracket}}% + {\ifinlist{anon?}{#1} {\renewcommand*{\anona}{\bibopenbracket}% - \renewcommand*{\anonb}{\bibclosebracket}}% - {\iffieldequalstr{#1type}{anon?} - {\renewcommand*{\anona}{\bibopenbracket}% - \renewcommand*{\anonb}{\addquestion\bibclosebracket}}% - {\ifboolexpr{ test {\iffieldequalstr{#1type}{pseudo}} - and not togl {cbx:short}} - {\renewcommand*{\anonb}{\space\mkbibbrackets{\bibstring{pseudo}}}} - {}}}}} + \renewcommand*{\anonb}{\addquestion\bibclosebracket}}% + {\ifboolexpr{ test {\ifinlist{pseudo}{#1}} + and not togl {cbx:short}} + {\renewcommand*{\anonb}{\space\mkbibbrackets{\bibstring{pseudo}}}} + {}}}} \newbibmacro*{namehash+etc}{% \usebibmacro{printnames+etc}% @@ -871,6 +896,19 @@ \newunit}% {\setunit{\addcomma\space}}} +\newbibmacro*{unpublished:collection}{% + \ifboolexpr{ test {\iffieldundef{collection}} + and test {\iffieldundef{shortcollection}}} + {} + {\ifboolexpr{ togl {cbx:short} + and not test {\iffieldundef{shortcollection}}} + {\iftoggle{shortlinks} + {\printtext[bibhyperref]{\printfield{shortcollection}}} + {\printfield{shortcollection}}} + {\iftoggle{shortlinks} + {\printtext[bibhyperref]{\printfield{collection}}} + {\printfield{collection}}}}} + \newbibmacro*{supplement}{% \ifnameundef{afterword} {\ifnameundef{foreword} @@ -1156,26 +1194,30 @@ % Macros common to 'editors:a', 'editors:b', and 'editors:c'. \newbibmacro*{edcombos:a}{% - \renewcommand*{\cbx@namelist}{\xeditor}% + \usebibmacro{shortnames}{\xeditor}% \ifnamesequal{\xeditor}{\yeditor} {\clearname{\yeditor}% \toggletrue{notrans}% \usebibmacro{edcombos:b}{\edtypes}{edtrans}% \iftoggle{atleastone} - {} - {\usebibmacro{edcombos:b}{\transtypes}{edtrans}}} - {\usebibmacro{edcombos:c}}} + {\usebibmacro{types:shared}{\edtypes}}% + {\usebibmacro{edcombos:b}{\transtypes}{edtrans}% + \usebibmacro{types:shared}{\transtypes}}} + {\usebibmacro{edcombos:c}% + \usebibmacro{types:shared}{\edtypes}}} \newbibmacro*{transcombos:a}{% - \renewcommand*{\cbx@namelist}{\yeditor}% + \usebibmacro{shortnames}{\yeditor}% \ifnamesequal{\xeditor}{\yeditor} {\clearname{\xeditor}% \toggletrue{noed}% \usebibmacro{transcombos:b}{\edtypes}{transed}% \iftoggle{atleastone} - {} - {\usebibmacro{transcombos:b}{\transtypes}{transed}}} - {\usebibmacro{transcombos:c}}} + {\usebibmacro{types:shared}{\edtypes}}% + {\usebibmacro{transcombos:b}{\transtypes}{transed}% + \usebibmacro{types:shared}{\transtypes}}} + {\usebibmacro{transcombos:c}% + \usebibmacro{types:shared}{\transtypes}}} \newbibmacro*{edcombos:b}[2]{% \togglefalse{atleastone}% @@ -1303,7 +1345,7 @@ {\usebibmacro{printnames}}% \usebibmacro{handle}% \usebibmacro{nameaddon}% - \usebibmacro{newauth+journallocation}% + \usebibmacro{newauth+location}% \usebibmacro{a:labeldate+extradate}% \usebibmacro{clearnames+empty}}% @@ -1351,11 +1393,11 @@ {\printfield[brackets]{nameaddon}% \clearfield{nameaddon}}}} -\newbibmacro*{newauth+journallocation}{% +\newbibmacro*{newauth+location}{% \iftoggle{newauth} {\ifboolexpr{ test {\ifentrytype{article}} and togl {bibliography}} - {\usebibmacro{journallocation}% + {\usebibmacro{article:location}% \newunit}% {}} {}} @@ -1601,14 +1643,17 @@ {\iffieldundef{pubstate} {\usebibmacro{labeldate+date}{#1}}% {\iffieldequalstr{pubstate}{preprint} - {\bibstring{preprint}}% + {\newunit + \bibstring{preprint}% + \setunit{\space}}% {\iffieldequalstr{pubstate}{prepub} {\newunit% necessary if no 'date' \bibstring{prepub}% \setunit{\addcomma\space}% \printdate}% {\iffieldequalstr{pubstate}{working} - {\bibstring{working}% + {\newunit + \bibstring{working}% \setunit{\addcomma\space}}% {\ifstrequal{#1}{parens} {\printtext[parens]{\printfield{pubstate}}} @@ -1711,6 +1756,26 @@ {} {\textendash\printfield{endorigyear}}}} +\newbibmacro*{year+month+day}{% + \iffieldundef{year} + {} + {\iffieldundef{month} + {\usebibmacro{reflist+year+day}% + \printdate}% + {\printdate}}} + +\newbibmacro*{year+month+day+old}{% + \iffieldundef{year} + {} + {\ifboolexpr{ togl {reflist} + and togl {bibliography} + and test {\iffieldundef{month}}} + {} + {\iffieldundef{month} + {\usebibmacro{reflist+year+day}% + \printdate}% + {\printdate}}}} + % For reference lists. \newbibmacro*{a:labeldate+extradate}{% @@ -1765,6 +1830,14 @@ %% Locations %% %%%%%%%%%%%%%%%%% +\newbibmacro*{article:location}{% + \iflistundef{location} + {} + {\nopunct\setunit{\space}% + \printtext[parens]{% + \printlist{location}}}% + \clearlist{location}}% + \newbibmacro*{loc+pub+year}{% \usebibmacro{loc+pub}{1}% \ifnumgreater{\value{publisher}}{1} @@ -1775,11 +1848,11 @@ \usebibmacro{year+bookyear}}% \newbibmacro*{loc+pub}[1]{% - \usebibmacro{location}{#1}% + \usebibmacro{location:a}{#1}% \setunit{\addcolon\space}% \printlist[publisher][#1-#1]{publisher}}% -\newbibmacro*{location}[1]{% +\newbibmacro*{location:a}[1]{% \ifboolexpr{ test {\iflistundef{location}} and test {\iffieldundef{howpublished}} and test {\iffieldundef{url}} @@ -1787,6 +1860,12 @@ {\bibstring{noplace}}% {\printlist[location][#1-#1]{location}}} +\newbibmacro*{location:b}{% + \iflistundef{location} + {} + {\printlist{location}% + \setunit{\addcomma\space}}} + \newbibmacro*{origlocation}{% \iflistundef{origlocation} {} @@ -1795,79 +1874,14 @@ {\setunit{\addcomma\space}}% {\setunit{\addcolon\space}}}} -%%%%%%%%%%%%%%%%%%%%%%%%%%%% -%% Bibliography Drivers %% -%%%%%%%%%%%%%%%%%%%%%%%%%%%% - -\DeclareBibliographyDriver{shorthand}{% - \usedriver - {\DeclareNameAlias{author}{sortname}}% - {\thefield{entrytype}}% - \iftoggle{annotate} - {\global\togglefalse{annotate}% - \usebibmacro{pageref+finentry}% - \global\toggletrue{annotate}}% - {\usebibmacro{pageref+finentry}}} - -\DeclareBibliographyDriver{article}{% - \usebibmacro{bibindex}% - \usebibmacro{newauth}% - \usebibmacro{author+title+etc}% - \usebibmacro{articles}% - \usebibmacro{colon+pages+etc}% - \usebibmacro{doi+finentry+etc}}% - -\DeclareBibliographyDriver{book}{% - \usebibmacro{bibindex}% - \usebibmacro{author+collection+etc}% - \usebibmacro{doi+finentry+etc}}% - -\DeclareBibliographyDriver{incollection}{% - \usebibmacro{bibindex}% - \usebibmacro{author+incollection+etc}% - \usebibmacro{crossref+incollections}% - \usebibmacro{doi+finentry+etc}}% - -\DeclareBibliographyDriver{misc}{% - \usebibmacro{bibindex}% - \usebibmacro{author+bookauthor+etc}% - \usebibmacro{title+labeldate}% - \newunit - \printfield{userb}% - \usebibmacro{doi+finentry+etc}}% - -\DeclareBibliographyDriver{online}{% - \usebibmacro{bibindex}% - \usebibmacro{newauth}% - \usebibmacro{author+title+etc}% - \newunit - \usebibmacro{websites}% - \usebibmacro{issue+month+etc}{}% - \usebibmacro{doi+finentry+etc}}% - -\DeclareBibliographyDriver{patent}{% - \usebibmacro{bibindex}% - \usebibmacro{author+title+etc}% - \newunit - \printfield{number}% - \newunit - \printfield{addendum}% - \usebibmacro{pageref+finentry}}% - -\DeclareBibliographyDriver{review}{% - \usebibmacro{bibindex}% - \usebibmacro{newauth}% - \usebibmacro{reviews}% - \usebibmacro{articles}% - \usebibmacro{colon+pages+etc}% - \usebibmacro{doi+finentry+etc}}% - -\DeclareBibliographyDriver{thesis}{% - \usebibmacro{bibindex}% - \usebibmacro{author+title+etc}% - \newunit - \usebibmacro{inst+loc+date}% - \usebibmacro{doi+finentry+etc}}% +\newbibmacro*{institution+venue}{% + \ifboolexpr{ test {\iflistundef{institution}} + and test {\iflistundef{venue}}} + {} + {\iflistundef{institution} + {\printfield{venue}}% + {\printlist{institution}}% + \setunit{\addcomma\space}}} %%%%%%%%%%%%%%%%%%%%%%%%%% %% Second Tier Macros %% @@ -1894,12 +1908,14 @@ \usebibmacro{editors:b}}% \newbibmacro*{articles}{% - \newunit + \iftoggle{newauth} + {\printunit{\newunitpunct}}% + {\newunit}% \usebibmacro{part}% \usebibmacro{issuetitle}% \usebibmacro{title+titleaddon}{journal}% - \usebibmacro{journallocation}% - \usebibmacro{journalseries}% + \usebibmacro{article:series}% + \usebibmacro{article:location}% \usebibmacro{volume}% \iftoggle{newauth} {\newunit}% @@ -1951,14 +1967,14 @@ \toggletrue{edshift}% \usebibmacro{byauthor}% \usebibmacro{editors:b}% - \usebibmacro{volumes+bookseries+etc}{}}% - {\usebibmacro{title+labeldate}{}% + \usebibmacro{volumes+series+etc}{}}% + {\usebibmacro{title+labeldate}% \usebibmacro{byauthor}% \iffieldundef{maintitle} {\usebibmacro{note+edition+etc}% - \usebibmacro{volumes+bookseries+etc}{}}% + \usebibmacro{volumes+series+etc}{}}% {\usebibmacro{editors:b}% - \usebibmacro{volumes+bookseries+etc}{}% + \usebibmacro{volumes+series+etc}{}% \usebibmacro{maintitle+note+etc}}} \usebibmacro{date+loc+etc}% \usebibmacro{origtitle}}% @@ -2036,23 +2052,68 @@ \toggletrue{edshift}% \usebibmacro{editors:b}}% -\newbibmacro*{inst+loc+date}{% - \usebibmacro{thesis+type}% - \ifboolexpr{ test {\iflistundef{institution}} - and test {\iflistundef{venue}}} - {} - {\iflistundef{institution} - {\printfield{venue}}% - {\printlist{institution}}% +\newbibmacro*{thesis:type+pubstate}{% + \ifentrytype{mathesis} + {\bibstring{mathesis}% \setunit{\addcomma\space}}% - \iflistundef{location} + {\ifentrytype{phdthesis} + {\bibstring{phdthesis}% + \setunit{\addcomma\space}}% + {\iffieldundef{type} + {\usebibmacro{pubstate}{}}% + {\iffieldbibstring{type} + {\bibstring{\thefield{type}}} + {\printfield{type}}% + \setunit{\addcomma\space}}}}} + +\newbibmacro*{inst+loc+date}{% + \usebibmacro{institution+venue}% + \usebibmacro{location:b}% + \usebibmacro{year+month+day}}% + +\newbibmacro*{type+typeaddon}{% + \iffieldundef{type} {} - {\printlist{location}% - \setunit{\addcomma\space}}% - \iffieldundef{month} - {\usebibmacro{reflist+year+day}}% + {\newunit + \printfield{type}% + \iffieldundef{typeaddon} + {\setunit{\addcomma\space}}% + {\iffieldstart{typeaddon}{,} + {} + {\setunit{\space}}% + \printfield{typeaddon}% + \setunit{\space}}}} + +\newbibmacro*{unpublished:series}{% + \iffieldundef{series} {} - \printdate}% + {\newunit + \usebibmacro{series+seriesaddon}% + \iffieldundef{collection} + {\setunit{\addcomma\space}}% + {\newunit}}} + +\newbibmacro*{manuscripts}{% + \iffieldundef{title} + {\toggletrue{skipdate}% + \usebibmacro{author+bookauthor+etc}% + \usebibmacro{type+typeaddon}}% + {\usebibmacro{author+bookauthor+etc}% + \usebibmacro{title+titleaddon}{}% + \usebibmacro{type+typeaddon}% + \setunit{\addcomma\space}% + \ifboolexpr{ togl {reflist} + and test {\iffieldundef{month}}} + {} + {\iffieldundef{year} + {\printlabeldate}% for 'n.d.' + {\printdate + \clearfield{year}}} + \iffieldundef{type} + {\newunit + \usebibmacro{unpublished:collection}}% + {}} + \usebibmacro{unpublished:note+etc}}% %%%%%%%%%%%%%%%%%%%%%%%%% %% Third Tier Macros %% @@ -2082,35 +2143,19 @@ \setunit{\addcomma\space}% \clearfield{part}}} -\newbibmacro*{journallocation}{% - \iflistundef{location} - {} - {\nopunct\setunit{\space}% - \printtext[parens]{% - \printlist{location}}}% - \clearlist{location}}% - -\newbibmacro*{journalseries}{% +\newbibmacro*{article:series}{% \iffieldundef{series} {} {\iftoggle{newauth} - {\newunit - \printfield{series}}% - {\setunit{\addcomma\space}% - \printfield{series}}% - \isdot\addcomma - \usebibmacro{seriesaddon}% - \usebibmacro{editors:c}{series}% - \newunit}}% + {\newunit}% + {\setunit{\addcomma\space}}% + \usebibmacro{series+seriesaddon}}} \newbibmacro*{volume}{% \iffieldundef{volume} {} - {\ifboolexpr{ togl {bibliography} - and togl {newauth}} - {\printfield[noformat]{volume}}% - {\setunit{\space}% - \printfield[noformat]{volume}}}} + {\setunit{\space}% + \printfield[noformat]{volume}}} % On how to format the issue number of periodicals, see CMOS, 17th % ed., 14.171 and 15.47. @@ -2237,12 +2282,12 @@ \setunit{\addcomma\space}\bibstring{by}\space}}% {\renewcommand*{\pluga}{\newunit\bibstring{by}\space}}% \renewcommand*{\cbx@namelist}{author}% - \usebibmacro{author+type}{author}% + \usebibmacro{test:authortypes}{author}% \usebibmacro{printnames+etc}}} -\newbibmacro*{volumes+bookseries+etc}[1]{% +\newbibmacro*{volumes+series+etc}[1]{% \usebibmacro{volumes}% - \usebibmacro{bookseries}% + \usebibmacro{book:series}% \usebibmacro{pages}% \usebibmacro{volume+number+etc}{#1}% \usebibmacro{book:number}% @@ -2297,7 +2342,7 @@ {\renewcommand*{\pluga}{% \setunit{\addcomma\space}\bibstring{by}\space}% \renewcommand*{\cbx@namelist}{bookauthor}% - \usebibmacro{author+type}{bookauthor}% + \usebibmacro{test:authortypes}{bookauthor}% \usebibmacro{printnames+etc}% \usebibmacro{pages}}} @@ -2322,9 +2367,9 @@ \usebibmacro{note+edition+etc}% \iffieldundef{volume} {\iffieldundef{bookvolume}% - {\usebibmacro{volumes+bookseries+etc}{bookbook}}% - {\usebibmacro{volumes+bookseries+etc}{book}}} - {\usebibmacro{volumes+bookseries+etc}{}}}} + {\usebibmacro{volumes+series+etc}{bookbook}}% + {\usebibmacro{volumes+series+etc}{book}}} + {\usebibmacro{volumes+series+etc}{}}}} \usebibmacro{date+loc+etc}% \usebibmacro{origtitle}}% @@ -2349,19 +2394,40 @@ \togglefalse{edshift}}% {}}} -\newbibmacro*{thesis+type}{% - \ifentrytype{mathesis} - {\bibstring{mathesis}% - \setunit{\addcomma\space}}% - {\ifentrytype{phdthesis} - {\bibstring{phdthesis}% - \setunit{\addcomma\space}}% - {\iffieldundef{type} - {\usebibmacro{pubstate}{}}% - {\iffieldbibstring{type} - {\bibstring{\thefield{type}}} - {\printfield{type}}% - \setunit{\addcomma\space}}}}} +% Thanks to David Fussner's biblatex-chicago for pointing me to this +% command by Philipp Lehman. Source: +% https://groups.google.com/forum/#!topic/comp.text.tex/kG003fkZK1I + +\newrobustcmd*{\iffieldstart}[2]{% + \iffieldundef{#1} + {\@secondoftwo}% originally '\@gobbletwo' + {\begingroup + \edef\@tempa{% + \long\def\noexpand\iffieldstart@i####1\detokenize{#2}####2}% + \@tempa\@nil{\endgroup\ifblank{##1}}% + \savefield*{#1}{\@tempa}% + \expandafter\iffieldstart@i\detokenize + \expandafter\expandafter\expandafter{% + \expandafter\@tempa\detokenize{#2}}\@nil}}% + +\newbibmacro*{series+seriesaddon}{% + \printfield{series}% + \usebibmacro{seriesaddon}% + \ifterm + {\printunit{\isdot\addcomma\space}}% + {\setunit{\addcomma\space}}% + \usebibmacro{editors:c}{series}}% + +\newbibmacro*{unpublished:note+etc}{% + \ifboolexpr{ test {\ifentrytype{unpublished}} + and not test {\iffieldundef{collection}}} + {\usebibmacro{note}% + \usebibmacro{editors:b}% + \usebibmacro{unpublished:series}% + \usebibmacro{unpublished:volume}% + \newunit + \usebibmacro{inst+loc+date}}% + {}} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Fourth and Higher Tier Macros %% @@ -2410,21 +2476,12 @@ \printfield{volumes}% \clearfield{volumes}}}} -\newbibmacro*{bookseries}{% +\newbibmacro*{book:series}{% \iffieldundef{series} {} {\usebibmacro{pages}% \newunit - \printfield{series}% - \usebibmacro{seriesaddon}% - \usebibmacro{editors:c}{series}}} - -\newbibmacro*{seriesaddon}{% - \iffieldundef{seriesaddon} - {} - {\addcomma\space - \printfield{seriesaddon}% - \isdot\addcomma}}% + \usebibmacro{series+seriesaddon}}} \newbibmacro*{swapvol+pages}{% \ifboolexpr{ togl {collection} @@ -2491,7 +2548,7 @@ \iftoggle{swapvol} {\usebibmacro{note}% \usebibmacro{edition}{}% - \usebibmacro{volumes+bookseries+etc}{}% + \usebibmacro{volumes+series+etc}{}% \usebibmacro{title+titleaddon}{}% \toggletrue{edshift}% \usebibmacro{byauthor}% @@ -2500,7 +2557,7 @@ \toggletrue{edshift}% \usebibmacro{booktitle}% \usebibmacro{note+edition+etc}% - \usebibmacro{volumes+bookseries+etc}{}}} + \usebibmacro{volumes+series+etc}{}}} \newbibmacro*{incollections:ic}{% \iftoggle{swapvol} @@ -2509,7 +2566,7 @@ {\usebibmacro{bookbooktitle}{}% \toggletrue{edshift}% \usebibmacro{note+edition+etc}}% - \usebibmacro{volumes+bookseries+etc}{book}% + \usebibmacro{volumes+series+etc}{book}% \toggletrue{edshift}% \usebibmacro{booktitle}% \usebibmacro{editors:b}}% @@ -2522,6 +2579,107 @@ {\usebibmacro{bookbooktitle}{}% \toggletrue{edshift}% \usebibmacro{note+edition+etc}}% - \usebibmacro{volumes+bookseries+etc}{book}}} + \usebibmacro{volumes+series+etc}{book}}} + +\newbibmacro*{seriesaddon}{% + \iffieldundef{seriesaddon} + {} + {\ifterm + {\printunit{\isdot\addcomma\space}}% + {\setunit{\addcomma\space}}% + \printfield{seriesaddon}}} + +\newbibmacro*{unpublished:volume}{% + \iffieldundef{volume} + {} + {\printfield{volume}% + \newunit}}% + +%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%% Bibliography Drivers %% +%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\DeclareBibliographyDriver{shorthand}{% + \usedriver + {\DeclareNameAlias{author}{sortname}}% + {\thefield{entrytype}}% + \iftoggle{annotate} + {\global\togglefalse{annotate}% + \usebibmacro{pageref+finentry}% + \global\toggletrue{annotate}}% + {\usebibmacro{pageref+finentry}}} + +\DeclareBibliographyDriver{article}{% + \usebibmacro{bibindex}% + \usebibmacro{newauth}% + \usebibmacro{author+title+etc}% + \usebibmacro{articles}% + \usebibmacro{colon+pages+etc}% + \usebibmacro{doi+finentry+etc}}% + +\DeclareBibliographyDriver{book}{% + \usebibmacro{bibindex}% + \usebibmacro{author+collection+etc}% + \usebibmacro{doi+finentry+etc}}% + +\DeclareBibliographyDriver{incollection}{% + \usebibmacro{bibindex}% + \usebibmacro{author+incollection+etc}% + \usebibmacro{crossref+incollections}% + \usebibmacro{doi+finentry+etc}}% + +\DeclareBibliographyDriver{misc}{% + \usebibmacro{bibindex}% + \usebibmacro{author+bookauthor+etc}% + \usebibmacro{title+labeldate}% + \newunit + \printfield{userb}% + \usebibmacro{doi+finentry+etc}}% + +\DeclareBibliographyDriver{online}{% + \usebibmacro{bibindex}% + \usebibmacro{newauth}% + \usebibmacro{author+title+etc}% + \newunit + \usebibmacro{websites}% + \usebibmacro{issue+month+etc}{}% + \usebibmacro{doi+finentry+etc}}% + +\DeclareBibliographyDriver{patent}{% + \usebibmacro{bibindex}% + \usebibmacro{author+title+etc}% + \newunit + \printfield{number}% + \newunit + \printfield{addendum}% + \usebibmacro{pageref+finentry}}% + +\DeclareBibliographyDriver{review}{% + \usebibmacro{bibindex}% + \usebibmacro{newauth}% + \usebibmacro{reviews}% + \usebibmacro{articles}% + \usebibmacro{colon+pages+etc}% + \usebibmacro{doi+finentry+etc}}% + +\DeclareBibliographyDriver{thesis}{% + \usebibmacro{bibindex}% + \usebibmacro{author+title+etc}% + \newunit + \usebibmacro{thesis:type+pubstate}% + \usebibmacro{inst+loc+date}% + \usebibmacro{doi+finentry+etc}}% + +\DeclareBibliographyDriver{unpublished}{% + \usebibmacro{bibindex}% + \iffieldundef{collection} + {\usebibmacro{author+title+etc}% + \newunit + \usebibmacro{type+typeaddon}% + \usebibmacro{pubstate}{}% + \usebibmacro{unpublished:series}% + \usebibmacro{inst+loc+date}}% + {\usebibmacro{manuscripts}}% + \usebibmacro{doi+finentry+etc}}% \endinput diff --git a/Master/texmf-dist/tex/latex/windycity/windycity.cbx b/Master/texmf-dist/tex/latex/windycity/windycity.cbx index f6bbabfb262..85d4ad37f21 100644 --- a/Master/texmf-dist/tex/latex/windycity/windycity.cbx +++ b/Master/texmf-dist/tex/latex/windycity/windycity.cbx @@ -1,4 +1,4 @@ -% Last modified: Wed 07 Jul 2021 05:45:51 PM CDT +% Last modified: Tue 09 Nov 2021 07:46:18 PM CST % Permission is granted to copy, distribute and/or modify this % software under the terms of the LaTeX Project Public License (LPPL), @@ -11,7 +11,7 @@ % implied warranties of merchantability and fitness for a particular % purpose. -\ProvidesFile{windycity.cbx}[2021/07/07 Windy City citation style for +\ProvidesFile{windycity.cbx}[2021/11/09 Windy City citation style for biblatex] \@ifpackagelater{biblatex}{2019/08/17} {} @@ -168,8 +168,17 @@ {\multicitedelim}% {\usebibmacro{cite:postnote}}% +\DeclareCiteCommand{\parenauth}[\mkbibparens] + {\usebibmacro{prenote}}% + {\usebibmacro{citeindex}% + \toggletrue{cbx:skipdate}% + \usebibmacro{parencite}}% + {\multicitedelim}% + {\usebibmacro{postnote}}% + \DeclareMultiCiteCommand{\idemcites}{\idemcite}{\multicitedelim}% -\DeclareMultiCiteCommand{\footidemcites}[\mkbibfootnote]{\footidemcite}{\multicitedelim} +\DeclareMultiCiteCommand{\footidemcites}[\mkbibfootnote]{\footidemcite}{\multicitedelim}% +\DeclareMultiCiteCommand{\parenauths}[\mkbibparens]{\parenauth}{\multicitedelim}% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Parenthetical Citations %% @@ -189,16 +198,18 @@ \usebibmacro{parencite:multicite}}} \newbibmacro*{parencite:date}{% - \ifboolexpr{ test {\ifentrytype{online}} - and test {\iffieldundef{year}}} - {\newunit - \usebibmacro{pubstate}{}}% - {\usebibmacro{parencite:origyear}% - \iffieldnums{labelyear} - {}% needs '%' - {\newunit}% - \usebibmacro{labeldate+endyear}% - \printfield{extradate}}} + \iftoggle{cbx:skipdate} + {} + {\ifboolexpr{ test {\ifentrytype{online}} + and test {\iffieldundef{year}}} + {\newunit + \usebibmacro{pubstate}{}}% + {\usebibmacro{parencite:origyear}% + \iffieldnums{labelyear} + {}% needs '%' + {\newunit}% + \usebibmacro{labeldate+endyear}% + \printfield{extradate}}}} \newbibmacro*{parencite:origyear}{% \iffieldundef{origyear} @@ -249,7 +260,7 @@ and test {\ifnameundef{foreword}} and test {\ifnameundef{introduction}} and test {\ifnameundef{preface}}} - {\usebibmacro{author+bookauthor+etc}}% + {\usebibmacro{collection+author+etc}}% {\usebibmacro{supplement}}}}} %%%%%%%%%%%%%%%%%%%%%%%%%% @@ -269,6 +280,7 @@ \usebibmacro{savefields}}% \newbibmacro*{cite:seen}{% + \usebibmacro{test:loccit}% \iffieldundef{shorthand} {\ifboolexpr{ test \ifciteibid and togl {short} @@ -282,12 +294,22 @@ {\printfield{shorthand}% \usebibmacro{cite:volume}}}} +\newbibmacro*{test:loccit}{% + \ifboolexpr{ togl {ibidpage} + and test \ifciteibid + and test \ifloccit + and not test \iffirstonpage} + {\global\toggletrue{ibid:loccit}}% + {}} + \newbibmacro*{cite:ibid}{% \iftoggle{ibid} {\iftoggle{shortlinks} {\printtext[bibhyperref]{% - \usebibmacro{cite:ibid+loccit}}} - {\usebibmacro{cite:ibid+loccit}}} + \bibcpstring{ibidem}% + \usebibmacro{cite:volume}}} + {\bibcpstring{ibidem}% + \usebibmacro{cite:volume}}} {\global\toggletrue{cbx:short}% \ifentrytype{review} {\usebibmacro{ibid:review}}% @@ -296,13 +318,6 @@ \usebibmacro{cite:author+title+etc}}} {\usebibmacro{cite:author+title+etc}}}}} -\newbibmacro*{cite:ibid+loccit}{% - \bibcpstring{ibidem}% - \ifboolexpr{ togl {ibidpage} - and test \ifloccit} - {\global\toggletrue{ibid:loccit}}% - {\usebibmacro{cite:volume}}} - \newbibmacro*{ibid:review}{% \ifnameundef{author} {\bibcpstring{reviewnoauth}% @@ -316,17 +331,14 @@ \iftoggle{noauth} {\usebibmacro{shorttitle+shortlinks}}% {}% needs '%' - \ifboolexpr{ togl {ibidpage} - and test \ifloccit} - {\global\toggletrue{ibid:loccit}}% - {\usebibmacro{cite:volume}}} + \usebibmacro{cite:volume}}% \newbibmacro*{cite:short}{% \global\toggletrue{cbx:short}% - \usebibmacro{short:multicite}% + \usebibmacro{test:multicite}% \ifentrytype{review} {\usebibmacro{short:review}}% - {\usebibmacro{author+bookauthor+etc}% + {\usebibmacro{collection+author+etc}% \usebibmacro{shorttitle+shortlinks}% \ifboolexpr{ togl {ibidpage} and test \ifloccit @@ -334,7 +346,7 @@ {\global\toggletrue{ibid:loccit}}% {\usebibmacro{cite:volume}}}} -\newbibmacro*{short:multicite}{% +\newbibmacro*{test:multicite}{% \ifboolexpr{ test {\iffieldequals{namehash}{\bbx@lasthash}} and togl {multicite} and togl {short}} @@ -355,39 +367,31 @@ \setunit{\space}% \usebibmacro{shorttitle}{book}}% {\usebibmacro{author+bookauthor+etc}% - \usebibmacro{shorttitle+shortlinks}}}} - \usebibmacro{cite:volume}}% + \usebibmacro{shorttitle+shortlinks}}}}} + +\newbibmacro*{collection+author+etc}{% + \ifboolexpr{ test {\ifentrytype{unpublished}} + and test {\iffieldundef{title}} + and not test {\iffieldundef{collection}}} + {\usebibmacro{unpublished:collection}}% + {\usebibmacro{author+bookauthor+etc}}} \newbibmacro*{cite:volume}{% - \usebibmacro{cite:punctuation}% - \iftoggle{swapvol} - {\ifboolexpr{ togl {collection:bk} - or togl {collection:ib}} - {\usebibmacro{volume+page}}% - {}} - {}} + \iftoggle{ibid:loccit} + {} + {\usebibmacro{cite:punctuation}% + \iftoggle{swapvol} + {\ifboolexpr{ togl {collection:bk} + or togl {collection:ib}} + {\usebibmacro{volume+page}}% + {}} + {}}} \newbibmacro*{cite:punctuation}{% \iffieldstart{postnote}{;} {} {\newunit}}% -% Thanks to David Fussner's biblatex-chicago for pointing me to this -% command by Philipp Lehman. Source: -% https://groups.google.com/forum/#!topic/comp.text.tex/kG003fkZK1I - -\newrobustcmd*{\iffieldstart}[2]{% - \iffieldundef{#1} - {\@secondoftwo}% originally '\@gobbletwo' - {\begingroup - \edef\@tempa{% - \long\def\noexpand\iffieldstart@i####1\detokenize{#2}####2}% - \@tempa\@nil{\endgroup\ifblank{##1}}% - \savefield*{#1}{\@tempa}% - \expandafter\iffieldstart@i\detokenize - \expandafter\expandafter\expandafter{% - \expandafter\@tempa\detokenize{#2}}\@nil}}% - \newbibmacro*{volume+page}{% \iffieldundef{volume} {} @@ -494,9 +498,11 @@ \ifboolexpr{ test {\iffieldundef{postnote}} and test {\iffieldundef{pages}} and test {\iffieldundef{url}}} - {\usebibmacro{doi+url+etc}}% + {\usebibmacro{unpublished:note+etc}% + \usebibmacro{doi+url+etc}}% {\usebibmacro{cite:pages}% \usebibmacro{postnote}% + \usebibmacro{unpublished:note+etc}% \usebibmacro{doi+url+etc}}} % If the postnote is empty, print the page ranges of journal and @@ -619,7 +625,33 @@ \DeclareBibliographyDriver{cite:thesis}{% \usebibmacro{author+title+etc}% \setunit{\addspace}% not '\setunit{\space}' - \printtext[parens]{\usebibmacro{inst+loc+date}}% + \printtext[parens]{% + \usebibmacro{thesis:type+pubstate}% + \usebibmacro{inst+loc+date}}% + \newunit}% + +\DeclareBibliographyDriver{cite:unpublished}{% + \iffieldundef{collection} + {\usebibmacro{author+title+etc}% + \setunit{\addspace}% not '\setunit{\space}' + \printtext[parens]{% + \iffieldundef{type} + {\usebibmacro{pubstate}{}}% + {\printfield{type}% + \setunit{\addcomma\space}}% + \usebibmacro{unpublished:series}% + \usebibmacro{inst+loc+date}}} + {\usebibmacro{collection+author+etc}% + \iffieldundef{title} + {} + {\usebibmacro{title+titleaddon}{}% + \setunit{\addcomma\space}% + \iffieldundef{year} + {\printlabeldate}% for 'n.d.' + {\printdate + \global\clearfield{year}}% needs '\global' + \newunit + \usebibmacro{unpublished:collection}}}% needs '%' \newunit}% \endinput diff --git a/Master/texmf-dist/tex/latex/windycity/windycity.dbx b/Master/texmf-dist/tex/latex/windycity/windycity.dbx index 26e92086ca3..0f61210ff0f 100644 --- a/Master/texmf-dist/tex/latex/windycity/windycity.dbx +++ b/Master/texmf-dist/tex/latex/windycity/windycity.dbx @@ -1,5 +1,11 @@ -\ProvidesFile{windycity.dbx}[2021/07/07 Windy City data model file for - biblatex] +\ProvidesFile{windycity.dbx}[2021/11/09 Windy City data model file for biblatex] +\DeclareDatamodelFields[type=field,datatype=key]{% + booktitlekey, + bookbooktitlekey, + titlekey, + translatortype, + translatoratype, + translatorbtype} \DeclareDatamodelFields[type=field,datatype=literal]{% blogsubtitle, blogtitle, @@ -10,9 +16,8 @@ bookbooktitleaddon, bookvolume, bookbookvolume, - booktitlekey, - bookbooktitlekey, bookyear, + collection, editoraddon, editoraaddon, endbookyear, @@ -20,14 +25,13 @@ seriesaddon, shortblog, shortbooktitle, + shortcollection, shortmaintitle, shortorganization, - titlekey, - translatortype, - translatoratype, - translatorbtype} + typeaddon} \DeclareDatamodelFields[type=list,datatype=name]{% preface, shortbookauthor, + shorttranslator, translatora, translatorb} |