%% %% This is file `oxyear.cbx', %% generated with the docstrip utility. %% %% The original source files were: %% %% oxref.dtx (with options: `cbx,y') %% ---------------------------------------------------------------- %% 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{2021/01/18 v2.2} \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesFile{oxyear.cbx} [\Version\space Author-year citation style inspired by the Oxford Guide to Style] \RequireCitationStyle{authoryear-comp} \ExecuteBibliographyOptions{uniquename=init} \renewbibmacro*{cite:labeldate+extradate}{% \ifboolexpr{ test {\iffieldundef{labelyear}} or ( test {\iffieldequalstr{labeldatesource}{nodate}} and togl {blx@ox@nonodate} ) }{}{\printtext[bibhyperref]{\printlabeldateextra}}} \xpatchbibmacro{cite}{% \printnames{labelname}% }{% \ifboolexpr{ test {\iffieldequalstr{labelnamesource}{author}} and togl {blx@ox@autoanon} and test {\iffieldequals{rawauthor}{\oxrefanon}} }{% \iftoggle{blx@ox@abbranon}{\bibcpsstring{anon}}{\bibcplstring{anon}}% }{% \printnames{labelname}% }% }{}{\wlog{WARNING: biblatex-oxref (oxyear) failed to patch cite}} \DeclareDelimFormat{nameyeardelim}{% \iflabeldateisanydate {\addspace}% {\addcomma\space}} \DeclareDelimFormat{nonameyeardelim}{% \iflabeldateisanydate {\addspace}% {\addcomma\space}} \renewcommand*{\multicitedelim}{\addsemicolon\space} \renewcommand*{\compcitedelim}{\addsemicolon\space} \renewcommand*{\postnotedelim}{\addcolon\space} \RequirePackage{etoolbox} \RequirePackage{xpatch} \providetoggle{blx@ox@autoanon} \providetoggle{blx@ox@abbranon} \xpatchbibmacro{textcite}{% \printnames{labelname}% }{% \ifboolexpr{ test {\iffieldequalstr{labelnamesource}{author}} and togl {blx@ox@autoanon} and test {\iffieldequals{rawauthor}{\oxrefanon}} }{% \iftoggle{blx@ox@abbranon}{\bibcpsstring{anon}}{\bibcplstring{anon}}% }{% \printnames{labelname}% }% }{}{\wlog{WARNING: biblatex-oxref failed to patch textcite}} %% %% Copyright (C) 2016–2021 Alex Ball %% %% End of file `oxyear.cbx'.