summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex/cbx/authoryear.cbx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/biblatex/cbx/authoryear.cbx')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex/cbx/authoryear.cbx120
1 files changed, 120 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex/cbx/authoryear.cbx b/Master/texmf-dist/tex/latex/biblatex/cbx/authoryear.cbx
new file mode 100644
index 00000000000..3358f6fe91a
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/biblatex/cbx/authoryear.cbx
@@ -0,0 +1,120 @@
+% $Id: authoryear.cbx,v 0.9 2010/02/14 15:42:33 lehman beta $
+
+\ProvidesFile{authoryear.cbx}
+[\abx@cbxid $Id: authoryear.cbx,v 0.9 2010/02/14 15:42:33 lehman beta $]
+
+\ExecuteBibliographyOptions{labelyear,uniquename,autocite=inline}
+\newbool{cbx:parens}
+
+\newbibmacro*{cite}{%
+ \iffieldundef{shorthand}
+ {\ifthenelse{\ifnameundef{labelname}\OR\iffieldundef{labelyear}}
+ {\usebibmacro{cite:label}%
+ \setunit{\addspace}}
+ {\printnames{labelname}%
+ \setunit{\nameyeardelim}}%
+ \usebibmacro{cite:labelyear+extrayear}}
+ {\usebibmacro{cite:shorthand}}}
+
+\newbibmacro*{citeyear}{%
+ \iffieldundef{shorthand}
+ {\iffieldundef{labelyear}
+ {\usebibmacro{cite:label}}
+ {\usebibmacro{cite:labelyear+extrayear}}}
+ {\usebibmacro{cite:shorthand}}}
+
+\newbibmacro*{textcite}{%
+ \ifnameundef{labelname}
+ {\iffieldundef{shorthand}
+ {\usebibmacro{cite:label}%
+ \setunit{%
+ \global\booltrue{cbx:parens}%
+ \addspace\bibleftparen}%
+ \usebibmacro{cite:labelyear+extrayear}}
+ {\usebibmacro{cite:shorthand}}}
+ {\printnames{labelname}%
+ \setunit{%
+ \global\booltrue{cbx:parens}%
+ \addspace\bibleftparen}%
+ \iffieldundef{shorthand}
+ {\iffieldundef{labelyear}
+ {\usebibmacro{cite:label}}
+ {\usebibmacro{cite:labelyear+extrayear}}}
+ {\usebibmacro{cite:shorthand}}}}
+
+\newbibmacro*{cite:shorthand}{%
+ \printtext[bibhyperref]{\printfield{shorthand}}}
+
+\newbibmacro*{cite:label}{%
+ \iffieldundef{label}
+ {\printtext[bibhyperref]{\printfield[citetitle]{labeltitle}}}
+ {\printtext[bibhyperref]{\printfield{label}}}}
+
+\newbibmacro*{cite:labelyear+extrayear}{%
+ \iffieldundef{labelyear}
+ {}
+ {\printtext[bibhyperref]{%
+ \printfield{labelyear}%
+ \printfield{extrayear}}}}
+
+\DeclareCiteCommand{\cite}
+ {\usebibmacro{prenote}}
+ {\usebibmacro{citeindex}%
+ \usebibmacro{cite}}
+ {\multicitedelim}
+ {\usebibmacro{postnote}}
+
+\DeclareCiteCommand*{\cite}
+ {\usebibmacro{prenote}}
+ {\usebibmacro{citeindex}%
+ \usebibmacro{citeyear}}
+ {\multicitedelim}
+ {\usebibmacro{postnote}}
+
+\DeclareCiteCommand{\parencite}[\mkbibparens]
+ {\usebibmacro{prenote}}
+ {\usebibmacro{citeindex}%
+ \usebibmacro{cite}}
+ {\multicitedelim}
+ {\usebibmacro{postnote}}
+
+\DeclareCiteCommand*{\parencite}[\mkbibparens]
+ {\usebibmacro{prenote}}
+ {\usebibmacro{citeindex}%
+ \usebibmacro{citeyear}}
+ {\multicitedelim}
+ {\usebibmacro{postnote}}
+
+\DeclareCiteCommand{\footcite}[\mkbibfootnote]
+ {\usebibmacro{prenote}}
+ {\usebibmacro{citeindex}%
+ \usebibmacro{cite}}
+ {\multicitedelim}
+ {\usebibmacro{postnote}}
+
+\DeclareCiteCommand{\footcitetext}[\mkbibfootnotetext]
+ {\usebibmacro{prenote}}
+ {\usebibmacro{citeindex}%
+ \usebibmacro{cite}}
+ {\multicitedelim}
+ {\usebibmacro{postnote}}
+
+\DeclareCiteCommand{\textcite}
+ {\boolfalse{cbx:parens}%
+ \usebibmacro{prenote}}
+ {\usebibmacro{citeindex}%
+ \usebibmacro{textcite}}
+ {\ifbool{cbx:parens}
+ {\bibrightparen\global\boolfalse{cbx:parens}}
+ {}%
+ \multicitedelim}
+ {\iffieldundef{postnote}
+ {\ifbool{cbx:parens}
+ {\bibrightparen}
+ {}}
+ {\ifbool{cbx:parens}
+ {\postnotedelim}
+ {\addspace\bibleftparen}%
+ \printfield{postnote}\bibrightparen}}
+
+\endinput