summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex-apa
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-01-23 23:08:57 +0000
committerKarl Berry <karl@freefriends.org>2012-01-23 23:08:57 +0000
commitfde9f1341f8b60d9193c41e45d1a5a43868f1757 (patch)
tree0df0d096c845dda13d863191b31c3385a6582d78 /Master/texmf-dist/tex/latex/biblatex-apa
parentbe9b9d7b5b951b901de6fe3252a27fcd11d9557b (diff)
biblatex-apa (23jan12)
git-svn-id: svn://tug.org/texlive/trunk@25183 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/biblatex-apa')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/american-apa.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/apa.bbx64
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/apa.cbx54
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/brazilian-apa.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/dutch-apa.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/french-apa.lbx3
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/german-apa.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/greek-apa.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/ngerman-apa.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-apa/spanish-apa.lbx3
10 files changed, 91 insertions, 45 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/american-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/american-apa.lbx
index 8049eb3fdef..69eb0f5457c 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/american-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/american-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{american-apa.lbx}
\InheritBibliographyExtras{american}
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/apa.bbx b/Master/texmf-dist/tex/latex/biblatex-apa/apa.bbx
index 2101b40c9a8..d1a813d4377 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/apa.bbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/apa.bbx
@@ -1,4 +1,4 @@
-%% apa.bbx v4.2
+%% apa.bbx v4.3
%% Copyright 2011 Philip Kime
%%
%% This work may be distributed and/or modified under the
@@ -28,6 +28,17 @@
\ProvidesFile{apa.bbx}
\RequireBiber[1]
\RequireBibliographyStyle{standard}
+\urlstyle{rm} % APA examples all have URLs in same font as text
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Used to join citations/references to
+% extrayear
+
+\newcommand{\apashortdash}{-}
+
+%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Allow variable max authors/editors limit
@@ -153,10 +164,43 @@
% (APA 6.16) uses year postfix to disambiguate multiple items in same year
% (APA 6.10) Never reference anything not cited
% (APA 6.25) author initials only
-% (APA 6.25) sorting is nyt
+% (APA 6.25) sorting is nyt but we need to account for PUBSTATE which comes
+% after all normal cites for the same author
+
+\DeclareSortingScheme{apa}{
+ \sort{
+ \field{presort}
+ }
+ \sort[final]{
+ \field{sortkey}
+ }
+ \sort{
+ \name{sortname}
+ \name{author}
+ \name{editor}
+ \name{translator}
+ \field{sorttitle}
+ \field{title}
+ }
+ \sort{
+ \field{sortyear}
+ \field{year}
+ \field{pubstate}
+ }
+ \sort{
+ \field{sorttitle}
+ \field{title}
+ }
+ \sort{
+ \field[padside=left,padwidth=4,padchar=0]{volume}
+ \literal{0000}
+ }
+}
+
+\DeclareLabelyear{pubstate,year,eventyear,origyear,urlyear}
\ExecuteBibliographyOptions{labelyear=true,%
- sorting=nyt,%
+ sorting=apa,%
pagetracker=true,%
firstinits=true,%
useprefix=true,%
@@ -324,8 +368,14 @@
\iffieldundef{labelyear}
{\iffieldundef{origyear}
{\printtext[parens]{\usebibmacro{noyear}}}
- {\printtext[yearorunkyear]{\printfield[noformat]{origyear}}}}
- {\printtext[yearorunkyear]{\printdateextra}}}
+ {\printtext[yearorunkyear]{\printfield[noformat]{origyear}}}}%
+ {\ifthenelse{\iffieldequalstr{labelyear}{inpress}\OR\iffieldequalstr{labelyear}{in press}}
+ {\printtext[parens]{\biblcstring{inpress}%
+ \iffieldundef{extrayear}
+ {\setunit{\relax}}
+ {\setunit{\apashortdash}}%
+ \printfield{extrayear}}}
+ {\printtext[yearorunkyear]{\printdateextra}}}}
\DeclareFieldFormat{yearorunkyear}{%
\ifthenelse{\iffieldequalstr{usere}{unkdate}\OR\iffieldequalstr{usere}{unkauthdate}}
@@ -1087,8 +1137,6 @@
\setunit{\bibpagespunct}%
\printfield{pages}%
\newunit\newblock
- \printfield{pubstate}%
- \newunit\newblock
\printfield{note}%
\newunit\newblock
\usebibmacro{doi+eprint+url}%
@@ -1345,8 +1393,6 @@
\newunit\newblock
\printfield{note}%
\newunit\newblock
- \usebibmacro{date}%
- \newunit\newblock
\usebibmacro{doi+eprint+url}%
\newunit\newblock
\printfield{addendum}%
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/apa.cbx b/Master/texmf-dist/tex/latex/biblatex-apa/apa.cbx
index 6aecd4fdf1f..7b3ac3e965a 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/apa.cbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/apa.cbx
@@ -1,4 +1,4 @@
-%% apa.cbx v4.2
+%% apa.cbx v4.3
%% Copyright 2011 Philip Kime
%%
%% This work may be distributed and/or modified under the
@@ -124,7 +124,12 @@
{\usebibmacro{labelname:doname}{#1}{#2}{#3}{#4}{#5}{#6}{#7}{#8}}%
{}%
\ifnumcomp{\value{listcount}}{=}{\cbx@min + 1}% first past ul is et al
- {\andothersdelim\bibstring{andothers}}%
+ % but enforce plurality of et al - only truncate here if there is at
+ % least one more element after the current potential truncation point
+ % so that "et al" covers at least two elements.
+ {\ifnumcomp{\value{listcount}}{<}{\value{listtotal}}
+ {\andothersdelim\bibstring{andothers}}
+ {\usebibmacro{labelname:doname}{#1}{#2}{#3}{#4}{#5}{#6}{#7}{#8}}}%
{}%
\ifnumcomp{\value{listcount}}{>}{\cbx@min + 1}% nothing thereafter
{\relax}%
@@ -165,14 +170,12 @@
{\setunit{\compcitedelim}%
\usebibmacro{cite:plabelyear+extrayear}}%
% Single cite
- {\ifthenelse{\ifnameundef{labelname}\OR\equal{\thefield{entrytype}}{patent}}
+ {\ifthenelse{\ifnameundef{labelname}\OR\iffieldequalstr{entrytype}{patent}}
% No author/editor
{\usebibmacro{cite:noname}%
\setunit{\nameyeardelim}%
- \iffieldundef{labelyear}
- {\usebibmacro{cite:noyear}}
- {\usebibmacro{cite:plabelyear+extrayear}%
- \savefield{namehash}{\cbx@lasthash}}}
+ \usebibmacro{cite:plabelyear+extrayear}%
+ \savefield{namehash}{\cbx@lasthash}}
% Normal cite
{\ifnameundef{shortauthor}
{\printnames[labelname][-\value{listtotal}]{labelname}}
@@ -180,10 +183,8 @@
{\printnames{shortauthor}}
{\printnames[labelname][-\value{listtotal}]{author}\addspace\printnames[sabrackets]{shortauthor}}}%
\setunit{\nameyeardelim}%
- \iffieldundef{labelyear}
- {\usebibmacro{cite:noyear}}
- {\usebibmacro{cite:plabelyear+extrayear}%
- \savefield{namehash}{\cbx@lasthash}}}}%
+ \usebibmacro{cite:plabelyear+extrayear}%
+ \savefield{namehash}{\cbx@lasthash}}}%
\setunit{\multicitedelim}}
\newbibmacro*{textcite}{%
@@ -192,7 +193,7 @@
{\setunit{\compcitedelim}%
\usebibmacro{cite:plabelyear+extrayear}}
% Single cite
- {\ifthenelse{\ifnameundef{labelname}\OR\equal{\thefield{entrytype}}{patent}}
+ {\ifthenelse{\ifnameundef{labelname}\OR\iffieldequalstr{entrytype}{patent}}
% No author/editor or patent
{\iffieldundef{shorthand}%
% Cite using title
@@ -222,10 +223,8 @@
{\ifciteseen
{}
{\printnames{shortauthor}\setunit{\nameyeardelim}}}%
- \iffieldundef{labelyear}%
- {\usebibmacro{cite:noyear}}
% Actual year printing
- {\usebibmacro{cite:plabelyear+extrayear}}%
+ \usebibmacro{cite:plabelyear+extrayear}%
\savefield{namehash}{\cbx@lasthash}}}%
\setunit{%
\ifbool{cbx:parens}
@@ -234,20 +233,18 @@
% multicitedelim semi-colon doesn't make much sense for textcites
\compcitedelim}}
-\newcommand{\apashortdash}{-}
-
\newbibmacro*{cite:plabelyear+extrayear}{%
\iffieldundef{labelyear}
- {}
- {\printtext[bibhyperref]{%
- \printfield[noformat]{origyear}\setunit*{\addslash}%
- \printfield{labelyear}%
- \iffieldequalstr{labelyear}{in press}
- {\iffieldundef{extrayear}
- {\setunit{\relax}}
- {\setunit{\apashortdash}}%
- \printfield{extrayear}}
- {\printfield{extrayear}}}}}%
+ {\usebibmacro{cite:noyear}}
+ {\ifthenelse{\iffieldequalstr{labelyear}{inpress}\OR\iffieldequalstr{labelyear}{in press}}
+ {\printtext[bibhyperref]{\bibxstring{inpress}%
+ \iffieldundef{extrayear}
+ {}
+ {\apashortdash}%
+ \printfield{extrayear}}}
+ {\printtext[bibhyperref]{%
+ \printfield[noformat]{origyear}\setunit*{\addslash}%
+ \printfield{labelyear}\printfield{extrayear}}}}}%
\newbibmacro*{cite:shorthand}{%
\ifciteseen
@@ -278,6 +275,7 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% (APA 6.22) Fall back to "n.d." for citations without dates
% Strings defined in apa.bbx
+% (APA 6.16) "in press" for PUBSTATE "inpress"
\newbibmacro*{cite:noyear}{%
\ifnameundef{shortauthor}
@@ -285,7 +283,7 @@
{\ifciteseen
{}
{\printnames{shortauthor}\setunit{\nameyeardelim}}}%
- \printtext[bibhyperref]{\biblcstring{nodate}}}
+ \printtext[bibhyperref]{\biblcstring{nodate}}}
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/brazilian-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/brazilian-apa.lbx
index 8f1161dd22f..390bed25f2b 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/brazilian-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/brazilian-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{brazilian-apa.lbx}
\InheritBibliographyExtras{brazilian}
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/dutch-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/dutch-apa.lbx
index e7e22552a40..a4e007561a5 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/dutch-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/dutch-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{dutch-apa.lbx}
\InheritBibliographyExtras{dutch}
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/french-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/french-apa.lbx
index bba50efb8e4..27b2f4fe17e 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/french-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/french-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{french-apa.lbx}
\InheritBibliographyExtras{french}
@@ -24,6 +24,7 @@
\DeclareBibliographyStrings{%
inherit = {french},
+ inpress = {{sous presse}{sous presse}},% remove when biblatex has it
january = {{janvier}{janvier}},
february = {{f\'evrier}{f\'evrier}},
march = {{mars}{mars}},
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/german-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/german-apa.lbx
index 536f2ed5a72..9335699464a 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/german-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/german-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{german-apa.lbx}
\InheritBibliographyExtras{german}
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/greek-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/greek-apa.lbx
index 5019b4c4818..682f338aaca 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/greek-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/greek-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{greek-apa.lbx}
\InheritBibliographyExtras{greek}
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/ngerman-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/ngerman-apa.lbx
index 6b58d6f196e..fc836917b8d 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/ngerman-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/ngerman-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{ngerman-apa.lbx}
\InheritBibliographyExtras{ngerman}
diff --git a/Master/texmf-dist/tex/latex/biblatex-apa/spanish-apa.lbx b/Master/texmf-dist/tex/latex/biblatex-apa/spanish-apa.lbx
index 4cc2f3b9678..9a8a54ac3cb 100644
--- a/Master/texmf-dist/tex/latex/biblatex-apa/spanish-apa.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-apa/spanish-apa.lbx
@@ -1,4 +1,4 @@
-% v4.2
+% v4.3
\ProvidesFile{spanish-apa.lbx}
\InheritBibliographyExtras{spanish}
@@ -26,6 +26,7 @@
\DeclareBibliographyStrings{%
inherit = {spanish},
+ inpress = {{en prensa}{en prensa}},% remove when biblatex has it
january = {{enero}{enero}},
february = {{febrero}{febrero}},
march = {{marzo}{marzo}},