summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex-oxref/oxalph.bbx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/biblatex-oxref/oxalph.bbx')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-oxref/oxalph.bbx128
1 files changed, 128 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-oxref/oxalph.bbx b/Master/texmf-dist/tex/latex/biblatex-oxref/oxalph.bbx
new file mode 100644
index 00000000000..d9163d0dd3a
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/biblatex-oxref/oxalph.bbx
@@ -0,0 +1,128 @@
+%%
+%% This is file `oxalph.bbx',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% oxref.dtx (with options: `bbx,a')
+%% ----------------------------------------------------------------
+%% biblatex-oxref --- Biblatex styles inspired by the Oxford Guide to Style
+%% Author: Alex Ball
+%% E-mail: a.j.ball@bath.ac.uk
+%% License: Released under the LaTeX Project Public License v1.3c or later
+%% See: http://www.latex-project.org/lppl.txt
+%% ----------------------------------------------------------------
+%%
+\def\Version{2017/11/18 v0.11}
+\NeedsTeXFormat{LaTeX2e}[1999/12/01]
+\ProvidesFile{oxalph.bbx}
+ [\Version\space Alphabetic bibliography style inspired by the Oxford Guide to Style]
+\RequireBibliographyStyle{oxyear}
+\xpatchcmd{\bbx@opt@mergedate@maximum}{%
+ \printdateextra
+}{%
+ \printdate
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@maximum}{%
+ \csuse{print\thefield{labeldatesource}dateextra}
+}{%
+ \csuse{print\thefield{labeldatesource}date}
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@maximum}{%
+ \printlabeldateextra
+}{%
+ \printlabeldate
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@compact}{%
+ \csuse{print\thefield{labeldatesource}dateextra}
+}{%
+ \csuse{print\thefield{labeldatesource}date}
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@compact}{%
+ \printlabeldateextra
+}{%
+ \printlabeldate
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@year}{%
+ \printlabeldateextra
+}{%
+ \printlabeldate
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@basic}{%
+ \printlabeldateextra
+}{%
+ \printlabeldate
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@minimum}{%
+ \printlabeldateextra
+}{%
+ \printlabeldate
+}{}{}
+\xpatchcmd{\bbx@opt@mergedate@false}{%
+ \printlabeldateextra
+}{%
+ \printlabeldate
+}{}{}
+\ExecuteBibliographyOptions{mergedate}
+
+\ExecuteBibliographyOptions{labelalpha,sorting=anyt}
+
+\DeclareFieldFormat{labelalphawidth}{\mkbibbrackets{#1}}
+\DeclareFieldFormat{shorthandwidth}{\mkbibbrackets{#1}}
+
+\defbibenvironment{bibliography}
+ {\list
+ {\printtext[labelalphawidth]{%
+ \printfield{labelprefix}%
+\printfield{labelalpha}%
+ \printfield{extraalpha}}}
+ {\setlength{\labelwidth}{\labelalphawidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\bibitemsep}%
+ \setlength{\parsep}{\bibparsep}}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}
+ {\endlist}
+ {\item}
+
+\defbibenvironment{shorthand}
+ {\list
+ {\printfield[shorthandwidth]{shorthand}}
+ {\setlength{\labelwidth}{\shorthandwidth}%
+ \setlength{\leftmargin}{\labelwidth}%
+ \setlength{\labelsep}{\biblabelsep}%
+ \addtolength{\leftmargin}{\labelsep}%
+ \setlength{\itemsep}{\bibitemsep}%
+ \setlength{\parsep}{\bibparsep}%
+ \renewcommand*{\makelabel}[1]{##1\hss}}}
+ {\endlist}
+ {\item}
+\DeclareStyleSourcemap{%
+ \maps[datatype=bibtex]{%
+ \map[overwrite=false]{%
+ \step[fieldsource=title, final]
+ \step[fieldset=shortlabeltitle, origfieldval]
+ \step[fieldsource=subtitle]
+ \step[fieldset=shortlabeltitle, origfieldval, append=true]
+ \step[fieldsource=shortlabeltitle,
+ match=\regexp{[^\p{Lu}]},
+ replace=\regexp{}]
+}}}
+\DeclareLabelalphaTemplate{%
+ \labelelement{
+ \field[final]{shorthand}
+ \field{label}
+ \field[strwidth=3,strside=left,ifnames=1]{labelname}
+ \field[strwidth=1,strside=left]{labelname}
+ \field[strwidth=3,strside=left]{shortlabeltitle}
+ \field[strwidth=4,strside=left]{labeltitle}
+ }
+ \labelelement{
+ \field[strwidth=2,strside=right]{labelyear}
+ }
+}
+%%
+%% Copyright (C) 2016 Alex Ball
+%%
+%% End of file `oxalph.bbx'.