summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex-bath
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2021-02-25 22:08:09 +0000
committerKarl Berry <karl@freefriends.org>2021-02-25 22:08:09 +0000
commitcdd9d4309a4a9370d445bd69b5c1e571d9b8c874 (patch)
treefa9ee863ef115f504a38322ebbbbf233a8350062 /Master/texmf-dist/tex/latex/biblatex-bath
parentfdb01e60ee1ca3ff5f15ddea4165603702a3907c (diff)
biblatex-bath (25feb21)
git-svn-id: svn://tug.org/texlive/trunk@57924 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/biblatex-bath')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx217
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-bath/bath.cbx4
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-bath/bath.dbx4
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-bath/british-bath.lbx4
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-bath/english-bath.lbx4
5 files changed, 188 insertions, 45 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx b/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx
index 0929ccbd5c0..55010a018fa 100644
--- a/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx
+++ b/Master/texmf-dist/tex/latex/biblatex-bath/bath.bbx
@@ -13,7 +13,7 @@
%% See: http://www.latex-project.org/lppl.txt
%% ----------------------------------------------------------------
%%
-\def\Version{2020/01/16 v3.2}
+\def\Version{2021/02/25 v4.0}
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesFile{bath.bbx}
[\Version\space Biblography style as recommended by the University of Bath Library]
@@ -26,11 +26,12 @@
\DeclareLanguageMapping{english}{english-bath}
\DeclareLanguageMapping{british}{british-bath}
}
+
\RequireBibliographyStyle{authoryear}
\ExecuteBibliographyOptions{%
maxcitenames=3,maxbibnames=9999,isbn=false,giveninits=true,dashed=false,
- alldates=comp,labeldate=year}
-\ExecuteBibliographyOptions[audio,video,music,movie]{%
+ alldates=comp,labeldate=year,labelalpha=true}
+\ExecuteBibliographyOptions[reference,audio,video,music,movie]{%
useeditor=false}
\NewBibliographyString{%
online, hours, at, unpublished, legalchapter,
@@ -274,6 +275,15 @@
[patent,thesis]%
{title}{\mkbibemph{#1}}
\DeclareFieldFormat
+ [reference,mvreference]%
+ {title}{\ifnameundef{author}{#1}{\mkbibemph{#1}}}
+\DeclareFieldFormat
+ [inreference]%
+ {title}{\ifnameundef{author}{\mkbibemph{#1}}{#1}}
+\DeclareFieldFormat
+ [inreference]%
+ {booktitle}{\ifnameundef{author}{#1}{\mkbibemph{#1}}}
+\DeclareFieldFormat
[unpublished]%
{title}{\iffieldundef{booktitle}{\mkbibemph{#1}}{#1}}
@@ -380,20 +390,37 @@
\renewcommand*{\subtitlepunct}{\addcolon\space}
+\DeclareLabeltitle[inreference]{%
+ \field{shorttitle}
+ \field{booktitle}
+ \field{title}
+}
\providetoggle{bbx:labelistitle}
\renewbibmacro*{labeltitle}{%
\iffieldundef{label}{%
\ifboolexpr{
- test {\iffieldundef{title}}
+ test {\ifentrytype{inreference}}
and
- test {\iffieldundef{subtitle}}
- }{}{%
- \printtext[title]{%
- \printfield[sentencecase]{title}%
- \setunit{\subtitlepunct}%
- \printfield[midsentencecase]{subtitle}}%
- \clearfield{title}\clearfield{subtitle}%
- \toggletrue{bbx:labelistitle}}%
+ not test {\iffieldundef{booktitle}}
+ }{%
+ \printtext[booktitle]{%
+ \printfield[sentencecase]{booktitle}%
+ \setunit{\booksubtitlepunct}%
+ \printfield[midsentencecase]{booksubtitle}}%
+ \clearfield{booktitle}\clearfield{booksubtitle}%
+ }{%
+ \ifboolexpr{
+ test {\iffieldundef{title}}
+ and
+ test {\iffieldundef{subtitle}}
+ }{}{%
+ \printtext[title]{%
+ \printfield[sentencecase]{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[midsentencecase]{subtitle}}%
+ \clearfield{title}\clearfield{subtitle}%
+ \toggletrue{bbx:labelistitle}}%
+ }%
}{%
\printfield{label}%
}%
@@ -650,11 +677,7 @@
\renewbibmacro*{date+extrayear}{\usebibmacro{date+extradate}}%
}
\renewbibmacro*{issue+date}{%
- \ifboolexpr{
- test {\iffieldundef{issue}}
- and
- test {\iffieldundef{month}}
- }{}{%
+ \iffieldundef{issue}{}{%
\ifboolexpr{(
test {\iffieldundef{volume}}
and
@@ -669,9 +692,9 @@
\printfield{issue}%
}%
}
- \setunit{\addcomma\space}%
- \printdate
}%
+ \setunit{\addcomma\space}%
+ \printdate
\newunit
}%
}%
@@ -776,6 +799,50 @@
\iffieldundef{#2year} {\mknoyeardaterangetrunc{#1}{#2}}%
}{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangetruncextra@i}}%
\fi
+\DeclareFieldFormat{extraalpha}{%
+ \iffieldnums{labelyear}
+ {\mknumalph{#1}}
+ {\mkbibparens{\mknumalph{#1}}}}
+\DeclareLabelalphaTemplate{
+ \labelelement{
+ \field{label}
+ \field{labelname}
+ \field{labeltitle}
+ }
+ \labelelement{
+ \field{labelyear}
+ }
+}
+\xpatchcmd{\mkdaterangefullextra}{%
+ \printfield{extradate}%
+}{%
+ \printfield{extraalpha}%
+}{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangefullextra once}}%
+\xpatchcmd{\mkdaterangefullextra}{%
+ \printfield{extradate}%
+}{%
+ \printfield{extraalpha}%
+}{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangefullextra twice}}%
+\xpatchcmd{\mkdaterangefullextra}{%
+ \printfield{extradate}%
+}{%
+ \printfield{extraalpha}%
+}{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangefullextra thrice}}%
+\xpatchcmd{\mkdaterangetruncextra@i}{%
+ \printfield{extradate}%
+}{%
+ \printfield{extraalpha}%
+}{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangetruncextra@i once}}%
+\xpatchcmd{\mkdaterangetruncextra@i}{%
+ \printfield{extradate}%
+}{%
+ \printfield{extraalpha}%
+}{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangetruncextra@i twice}}%
+\xpatchcmd{\mkdaterangetruncextra@i}{%
+ \printfield{extradate}%
+}{%
+ \printfield{extraalpha}%
+}{}{\wlog{WARNING: biblatex-bath failed to patch mkdaterangetruncextra@i thrice}}%
\DeclareFieldFormat{version}{\mkbibparens{\biblcsstring{version}#1}}
\DeclareFieldFormat{type}{\ifbibstring{#1}{\biblstring{#1}}{#1}}
@@ -826,6 +893,11 @@
\DeclareFieldFormat{url}{\bibsentence\bibstring{urlfrom}\addcolon\space\url{#1}}
\DeclareFieldFormat{doi}{\bibsentence\bibstring{urlfrom}\addcolon\space\url{https://doi.org/#1}}
\DeclareFieldFormat{urldate}{\mkbibbrackets{\bibstring{urlseen}\space#1}}
+\renewbibmacro*{url}{%
+ \iffieldundef{doi}%
+ {\printfield{url}}%
+ {\printfield{doi}}%
+}
\renewbibmacro*{doi+eprint+url}{%
\iftoggle{bbx:eprint}
{\usebibmacro{eprint}}
@@ -838,13 +910,16 @@
\iftoggle{bbx:doi}
{\printfield{doi}}
{}%
-}{}{}{\wlog{WARNING: biblatex-bath failed to remove extra DOI from online driver}}
-
-\renewbibmacro*{url}{%
- \iffieldundef{doi}%
- {\printfield{url}}%
- {\printfield{doi}}%
-}
+ \newunit\newblock
+ \iftoggle{bbx:eprint}
+ {\usebibmacro{eprint}}
+ {}%
+ \newunit\newblock
+ \usebibmacro{url+urldate}%
+}{%
+ \toggletrue{bbx:url}%
+ \usebibmacro{doi+eprint+url}%
+}{}{}
\xpatchbibdriver{article}{%
\usebibmacro{in:}\usebibmacro{journal+issuetitle}%
@@ -896,7 +971,7 @@
}{%
\setunit{\addcomma\space}%
\usebibmacro{series+number}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch book driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch book driver (series+number)}}
\xpatchbibdriver{collection}{%
\newunit\newblock
@@ -904,7 +979,7 @@
}{%
\setunit{\addcomma\space}%
\usebibmacro{series+number}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch collection driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch collection driver (series+number)}}
\xpatchbibdriver{inbook}{%
\newunit\newblock
@@ -912,7 +987,7 @@
}{%
\setunit{\addcomma\space}%
\usebibmacro{series+number}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch inbook driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch inbook driver (series+number)}}
\xpatchbibdriver{incollection}{%
\newunit\newblock
@@ -920,7 +995,7 @@
}{%
\setunit{\addcomma\space}%
\usebibmacro{series+number}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch incollection driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch incollection driver (series+number)}}
\xpatchbibdriver{inproceedings}{%
\newunit\newblock
@@ -928,7 +1003,7 @@
}{%
\setunit{\addcomma\space}%
\usebibmacro{series+number}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch inproceedings driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch inproceedings driver (series+number)}}
\xpatchbibdriver{proceedings}{%
\newunit\newblock
@@ -936,7 +1011,7 @@
}{%
\setunit{\addcomma\space}%
\usebibmacro{series+number}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch proceedings driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch proceedings driver (series+number)}}
\xpatchbibdriver{incollection}{%
\usebibmacro{in:}%
@@ -949,7 +1024,7 @@
\newunit\newblock
\usebibmacro{maintitle+booktitle}%
\usebibmacro{byeditor+others}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch incollection driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch incollection driver (bookeditor)}}
\xpatchbibdriver{inproceedings}{%
\usebibmacro{in:}%
@@ -966,7 +1041,64 @@
\usebibmacro{byeditor+others}%
\newunit
\usebibmacro{event+venue+date}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch inproceedings driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch inproceedings driver (bookeditor)}}
+
+\DeclareBibliographyDriver{inreference}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{begentry}%
+ \usebibmacro{author/translator+others}%
+ \setunit{\printdelim{nametitledelim}}\newblock
+ \ifnameundef{author}{}{\usebibmacro{title}%
+ \newunit}%
+ \printlist{language}%
+ \newunit\newblock
+ \usebibmacro{byauthor}%
+ \newunit\newblock
+ \ifboolexpr{
+ test {\iffieldundef{maintitle}}
+ and
+ test {\iffieldundef{booktitle}}
+ }{}{%
+ \ifnameundef{editor}{}{\usebibmacro{in:}}%
+ \usebibmacro{bookeditor}%
+ \newunit\newblock
+ \usebibmacro{maintitle+booktitle}}%
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \printfield{edition}%
+ \newunit
+ \iffieldundef{maintitle}
+ {\printfield{volume}%
+ \printfield{part}}
+ {}%
+ \newunit
+ \ifnameundef{author}{\usebibmacro{title}%
+ \newunit}{}%
+ \printfield{volumes}%
+ \newunit\newblock
+ \usebibmacro{series+number}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{publisher+location+date}%
+ \newunit\newblock
+ \usebibmacro{chapter+pages}%
+ \newunit\newblock
+ \iftoggle{bbx:isbn}
+ {\printfield{isbn}}
+ {}%
+ \newunit\newblock
+ \usebibmacro{doi+eprint+url}%
+ \newunit\newblock
+ \usebibmacro{addendum+pubstate}%
+ \setunit{\bibpagerefpunct}\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \iftoggle{bbx:related}
+ {\usebibmacro{related:init}%
+ \usebibmacro{related}}
+ {}%
+ \usebibmacro{finentry}}
\xpatchbibdriver{dataset}{%
\printlist{organization}%
@@ -976,7 +1108,7 @@
\usebibmacro{library}%
\newunit\newblock
\usebibmacro{organization+location+date}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch dataset driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch dataset driver (publisher)}}
\xpatchbibdriver{online}{%
\printlist{organization}%
@@ -986,7 +1118,7 @@
\usebibmacro{library}%
\newunit\newblock
\usebibmacro{organization+location+date}%
-}{}{\wlog{WARNING: biblatex-bath failed to patch online driver}}
+}{}{\wlog{WARNING: biblatex-bath failed to patch online driver (publisher)}}
\DeclareFieldFormat{forceparens}{(#1)}
\newbibmacro{series+type+number}{%
@@ -1586,7 +1718,18 @@
\DeclareBibliographyAlias{standard}{manual}
+\DeclareStyleSourcemap{%
+ \maps[datatype=bibtex]{%
+ \map{%
+ \pertype{inreference}
+ \step[notfield=author, final]
+ \step[fieldsource=booktitle]
+ \step[fieldset=sorttitle, origfieldval]
+ }%
+ }%
+}%
+
%%
-%% Copyright (C) 2020 by University of Bath
+%% Copyright (C) 2016-2021 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 5b95e4a16d3..4e4059c70ce 100644
--- a/Master/texmf-dist/tex/latex/biblatex-bath/bath.cbx
+++ b/Master/texmf-dist/tex/latex/biblatex-bath/bath.cbx
@@ -13,7 +13,7 @@
%% See: http://www.latex-project.org/lppl.txt
%% ----------------------------------------------------------------
%%
-\def\Version{2020/01/16 v3.2}
+\def\Version{2021/02/25 v4.0}
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesFile{bath.cbx}
[\Version\space Citation style as recommended by the University of Bath Library]
@@ -37,6 +37,6 @@
}{}{\wlog{WARNING: biblatex-bath failed to patch cite:label}}
%%
-%% Copyright (C) 2020 by University of Bath
+%% Copyright (C) 2016-2021 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 36b8d2bf9a4..618d06026c4 100644
--- a/Master/texmf-dist/tex/latex/biblatex-bath/bath.dbx
+++ b/Master/texmf-dist/tex/latex/biblatex-bath/bath.dbx
@@ -13,13 +13,13 @@
%% See: http://www.latex-project.org/lppl.txt
%% ----------------------------------------------------------------
%%
-\def\Version{2020/01/16 v3.2}
+\def\Version{2021/02/25 v4.0}
\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) 2020 by University of Bath
+%% Copyright (C) 2016-2021 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 c454f632c74..08b9d31b1c8 100644
--- a/Master/texmf-dist/tex/latex/biblatex-bath/british-bath.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-bath/british-bath.lbx
@@ -13,7 +13,7 @@
%% See: http://www.latex-project.org/lppl.txt
%% ----------------------------------------------------------------
%%
-\def\Version{2020/01/16 v3.2}
+\def\Version{2021/02/25 v4.0}
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesFile{british-bath.lbx}
[\Version\space British English conventions required by the biblatex-bath style]
@@ -40,6 +40,6 @@
}
%%
-%% Copyright (C) 2020 by University of Bath
+%% Copyright (C) 2016-2021 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 611f070c694..77c5003f83d 100644
--- a/Master/texmf-dist/tex/latex/biblatex-bath/english-bath.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-bath/english-bath.lbx
@@ -13,7 +13,7 @@
%% See: http://www.latex-project.org/lppl.txt
%% ----------------------------------------------------------------
%%
-\def\Version{2020/01/16 v3.2}
+\def\Version{2021/02/25 v4.0}
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesFile{english-bath.lbx}
[\Version\space Generic English conventions required by the biblatex-bath style]
@@ -63,6 +63,6 @@
}
%%
-%% Copyright (C) 2020 by University of Bath
+%% Copyright (C) 2016-2021 by University of Bath
%%
%% End of file `english-bath.lbx'.