diff options
author | Karl Berry <karl@freefriends.org> | 2020-01-16 21:57:10 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2020-01-16 21:57:10 +0000 |
commit | 3cf7754225744a63df15eeaa639c79bf0a7a8d1b (patch) | |
tree | 6c941619f311d9132127dcd22adb780cc80a1a84 /Master/texmf-dist/tex | |
parent | 742d002c8282ce3cca5713d900745182c68b3a89 (diff) |
biblatex-bath (16jan20)
git-svn-id: svn://tug.org/texlive/trunk@53424 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
5 files changed, 108 insertions, 36 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx b/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx index c3ceb7ee218..0929ccbd5c0 100644 --- a/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx +++ b/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx @@ -13,6 +13,10 @@ %% See: http://www.latex-project.org/lppl.txt %% ---------------------------------------------------------------- %% +\def\Version{2020/01/16 v3.2} +\NeedsTeXFormat{LaTeX2e}[1999/12/01] +\ProvidesFile{bath.bbx} + [\Version\space Biblography style as recommended by the University of Bath Library] \RequirePackage{xpatch} \RequirePackage{xstring} \RequirePackage{etoolbox} @@ -276,6 +280,8 @@ \newtoggle{bbx:onlineshown} \newbibmacro*{isonline}{% \ifboolexpr{( + test {\iffieldundef{doi}} + and test {\iffieldundef{url}} and not test {\ifentrytype{online}} @@ -294,35 +300,47 @@ }} \renewbibmacro*{title}{% - \printtext{% + \ifboolexpr{ + test {\iffieldundef{title}} + and + test {\iffieldundef{subtitle}} + }{}{% + \printtext[title]{% + \printfield[sentencecase]{title}% + \setunit{\subtitlepunct}% + \printfield[midsentencecase]{subtitle}% + \setunit{\addspace}% + }% + \printfield{version}% + \clearfield{version}% + \setunit*{\addspace}% + \printfield{titleaddon}% \ifboolexpr{ - test {\iffieldundef{title}} + test {\iffieldundef{journaltitle}} and - test {\iffieldundef{subtitle}} - }{}{% - \printtext[title]{% - \printfield[sentencecase]{title}% - \setunit{\subtitlepunct}% - \printfield[midsentencecase]{subtitle}% - \setunit{\addspace}% - }% - \printfield{version}% - \clearfield{version}% + test {\iffieldundef{booktitle}} + and + test {\iffieldundef{library}} + and + not test {\ifentrytype{software}} + and ( + test {\iffieldundef{type}} + or + test {\nottoggle{bbx:labelistitle}} + or + not ( + test {\ifentrytype{audio}} + or + test {\ifentrytype{video}} + or + test {\ifentrytype{music}} + or + test {\ifentrytype{movie}} + )) + }{% \setunit*{\addspace}% - \printfield{titleaddon}% - \ifboolexpr{ - test {\iffieldundef{journaltitle}} - and - test {\iffieldundef{booktitle}} - and - test {\iffieldundef{library}} - and - not test {\ifentrytype{software}} - }{% - \setunit*{\addspace}% - \usebibmacro{isonline}% - }{}% - }% + \usebibmacro{isonline}% + }{}% }% } @@ -399,6 +417,18 @@ test {\ifentrytype{image}} ) and not test {\ifentrytype{software}} + and ( + test {\iffieldundef{type}} + or + not ( + test {\ifentrytype{audio}} + or + test {\ifentrytype{video}} + or + test {\ifentrytype{music}} + or + test {\ifentrytype{movie}} + )) }{% \setunit*{\addspace}% \usebibmacro{isonline}% @@ -437,7 +467,7 @@ } \DeclareDelimFormat{nameyeardelim}{\addcomma\space} -\DeclareDelimFormat*[parencite,bib,biblist]{nameyeardelim}{\addcomma\space} +\DeclareDelimFormat[parencite,bib,biblist]{nameyeardelim}{\addcomma\space} \newcommand{\dononameyeardelim}{% \ifentrytype{legislation}{% \addspace @@ -480,7 +510,7 @@ ) and togl {bbx:labelistitle} }{\addspace}{\addcomma\space}} -\DeclareDelimFormat*[bib,biblist]{nametitledelim}{% +\DeclareDelimFormat[bib,biblist]{nametitledelim}{% \ifboolexpr{ ( test {\ifentrytype{jurisdiction}} @@ -747,7 +777,7 @@ }{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangetruncextra@i}}% \fi -\DeclareFieldFormat{version}{\mkbibparens{\bibstring{version}#1}} +\DeclareFieldFormat{version}{\mkbibparens{\biblcsstring{version}#1}} \DeclareFieldFormat{type}{\ifbibstring{#1}{\biblstring{#1}}{#1}} \renewbibmacro*{event+venue+date}{% \printfield{eventtitle}% @@ -804,6 +834,12 @@ \iftoggle{bbx:url} {\usebibmacro{url+urldate}} {}} +\xpatchbibdriver{online}{% + \iftoggle{bbx:doi} + {\printfield{doi}} + {}% +}{}{}{\wlog{WARNING: biblatex-bath failed to remove extra DOI from online driver}} + \renewbibmacro*{url}{% \iffieldundef{doi}% {\printfield{url}}% @@ -932,8 +968,20 @@ \usebibmacro{event+venue+date}% }{}{\wlog{WARNING: biblatex-bath failed to patch inproceedings driver}} +\xpatchbibdriver{dataset}{% + \printlist{organization}% + \newunit + \usebibmacro{publisher+location+date}% +}{% + \usebibmacro{library}% + \newunit\newblock + \usebibmacro{organization+location+date}% +}{}{\wlog{WARNING: biblatex-bath failed to patch dataset driver}} + \xpatchbibdriver{online}{% \printlist{organization}% + \newunit\newblock + \usebibmacro{date}% }{% \usebibmacro{library}% \newunit\newblock @@ -1054,6 +1102,15 @@ }} \ExecuteBibliographyOptions[standard]{useeditor=false} +\newbibmacro*{type+online}{% + \printfield{type}% + \ifboolexpr{ + test {\iffieldundef{type}} + or + test {\nottoggle{bbx:labelistitle}} + }{}{% + \setunit{\addspace}% + \usebibmacro{isonline}}} \DeclareBibliographyDriver{audio}{% \usebibmacro{bibindex}% \usebibmacro{begentry}% @@ -1063,7 +1120,7 @@ \newunit \printlist{language}% \newunit\newblock - \printfield{type}% + \usebibmacro{type+online}% \newunit\newblock \usebibmacro{byauthor}[given-family:full]% \newunit\newblock @@ -1528,9 +1585,8 @@ \usebibmacro{finentry}} \DeclareBibliographyAlias{standard}{manual} -\DeclareBibliographyAlias{dataset}{online} %% -%% Copyright (C) 2019 by University of Bath +%% Copyright (C) 2020 by University of Bath %% %% End of file `bath.bbx'. diff --git a/Master/texmf-dist/tex/latex/biblatex-bath/bath.cbx b/Master/texmf-dist/tex/latex/biblatex-bath/bath.cbx index d0dd7fe3828..5b95e4a16d3 100644 --- a/Master/texmf-dist/tex/latex/biblatex-bath/bath.cbx +++ b/Master/texmf-dist/tex/latex/biblatex-bath/bath.cbx @@ -13,6 +13,10 @@ %% See: http://www.latex-project.org/lppl.txt %% ---------------------------------------------------------------- %% +\def\Version{2020/01/16 v3.2} +\NeedsTeXFormat{LaTeX2e}[1999/12/01] +\ProvidesFile{bath.cbx} + [\Version\space Citation style as recommended by the University of Bath Library] \RequireCitationStyle{authoryear-comp} \ExecuteBibliographyOptions{uniquename=init} \renewcommand*{\compcitedelim}{\addsemicolon\space} @@ -33,6 +37,6 @@ }{}{\wlog{WARNING: biblatex-bath failed to patch cite:label}} %% -%% Copyright (C) 2019 by University of Bath +%% Copyright (C) 2020 by University of Bath %% %% End of file `bath.cbx'. diff --git a/Master/texmf-dist/tex/latex/biblatex-bath/bath.dbx b/Master/texmf-dist/tex/latex/biblatex-bath/bath.dbx index f1b12033bf0..36b8d2bf9a4 100644 --- a/Master/texmf-dist/tex/latex/biblatex-bath/bath.dbx +++ b/Master/texmf-dist/tex/latex/biblatex-bath/bath.dbx @@ -13,9 +13,13 @@ %% See: http://www.latex-project.org/lppl.txt %% ---------------------------------------------------------------- %% +\def\Version{2020/01/16 v3.2} +\NeedsTeXFormat{LaTeX2e}[1999/12/01] +\ProvidesFile{bath.dbx} + [\Version\space Data model required by the biblatex-bath style] \DeclareDatamodelConstant[type=list]{nameparts}{prefix,family,suffix,given,cjk} %% -%% Copyright (C) 2019 by University of Bath +%% Copyright (C) 2020 by University of Bath %% %% End of file `bath.dbx'. diff --git a/Master/texmf-dist/tex/latex/biblatex-bath/british-bath.lbx b/Master/texmf-dist/tex/latex/biblatex-bath/british-bath.lbx index 7d339af9162..c454f632c74 100644 --- a/Master/texmf-dist/tex/latex/biblatex-bath/british-bath.lbx +++ b/Master/texmf-dist/tex/latex/biblatex-bath/british-bath.lbx @@ -13,6 +13,10 @@ %% See: http://www.latex-project.org/lppl.txt %% ---------------------------------------------------------------- %% +\def\Version{2020/01/16 v3.2} +\NeedsTeXFormat{LaTeX2e}[1999/12/01] +\ProvidesFile{british-bath.lbx} + [\Version\space British English conventions required by the biblatex-bath style] \InheritBibliographyExtras{british} \DeclareBibliographyExtras{% \protected\def\mkbibdatelong#1#2#3{% @@ -36,6 +40,6 @@ } %% -%% Copyright (C) 2019 by University of Bath +%% Copyright (C) 2020 by University of Bath %% %% End of file `british-bath.lbx'. diff --git a/Master/texmf-dist/tex/latex/biblatex-bath/english-bath.lbx b/Master/texmf-dist/tex/latex/biblatex-bath/english-bath.lbx index 05a7aad1ad9..611f070c694 100644 --- a/Master/texmf-dist/tex/latex/biblatex-bath/english-bath.lbx +++ b/Master/texmf-dist/tex/latex/biblatex-bath/english-bath.lbx @@ -13,6 +13,10 @@ %% See: http://www.latex-project.org/lppl.txt %% ---------------------------------------------------------------- %% +\def\Version{2020/01/16 v3.2} +\NeedsTeXFormat{LaTeX2e}[1999/12/01] +\ProvidesFile{english-bath.lbx} + [\Version\space Generic English conventions required by the biblatex-bath style] \InheritBibliographyExtras{english} \DeclareBibliographyStrings {inherit = {english} @@ -59,6 +63,6 @@ } %% -%% Copyright (C) 2019 by University of Bath +%% Copyright (C) 2020 by University of Bath %% %% End of file `english-bath.lbx'. |