Estou lidando com um problema relacionado à referência e citação de fontes no estilo APA.
Aqui está meu código de exemplo:
\documentclass[a4paper,
12pt,
bibtotoc,
liststotoc,
pointlessnumbers
]{scrartcl}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{textcomp}
\usepackage[american,ngerman]{babel}
\usepackage[babel=true]{csquotes}
\usepackage[style=apa,backend=biber, doi=false, url=false]{biblatex}
\DeclareLanguageMapping{ngerman}{ngerman-apa}
\DefineBibliographyStrings{ngerman}{andothers={et\ \addabbrvspace al\adddot}}
\renewcommand\finalandcomma{\addcomma}
\usepackage{filecontents}
\begin{filecontents}{literatur.bib}
@article{DroitVolet2007,
author = {Droit-Volet, S. and Meck, W. H.},
year = {2007},
title = {{H}ow emotions colour our perception of time},
pages = {504--513},
volume = {11},
number = {12},
issn = {13646613},
journal = {Trends in Cognitive Sciences},
doi = {10.1016/j.tics.2007.09.008 Titel anhand dieser DOI in Citavi-Projekt übernehmen
}
@article{Gibbon1984,
author = {Gibbon, J. and Church, R. M. and Meck, W. H.},
year = {1984},
title = {{S}calar timing in memory},
pages = {52--77},
volume = {423},
issn = {0077-8923},
journal = {Annals of the New York Academy of Sciences}
}
}
\end{filecontents}
\bibliography{literatur}
\begin{document}
There is no comma in this citation \parencite{DroitVolet2007}, but the comma is missing in the references.
For more than two authors there has to be a comma in front of & \parencite{Gibbon1984}.
\printbibliography
\end{document}
O látex perde uma vírgula antes de & na seção de referência, quando há apenas dois autores. A citação no texto é totalmente adequada para dois autores, mas a entrada nas referências deve ficar assim: Droit-Volet, S., & Meck, WH (2007). ....
Para mais de dois autores, também deve haver uma vírgula antes de & nas citações de texto.
Enquanto procurava uma solução, tentei corrigi-la usando
\renewcommand*{\finalnamedelim}{%
\finalandcomma
\addspace
\bibstring{and}%
\space
}
ou
\renewcommand\finalandcomma{\addcomma}
Mas infelizmente nenhuma dessas soluções funcionou no meu caso ...
Ajuda ou qualquer conselho seria muito apreciado.
Muitas felicidades, Fernando
Responder1
Por alguma razão biblatex-apa
redefine \finalnamedelim
o \AtBeginBibliography
gancho.
Portanto teremos que fazer o mesmo para substituir a configuração; além disso, redefinimos o \finalandcomma
no \AtBeginDocument
gancho
\AtBeginDocument{\renewcommand\finalandcomma{\addcomma}}
\AtBeginBibliography{%
\renewcommand*{\finalnamedelim}{%
\ifthenelse{\value{listcount}>\maxprtauth}
{}
{\finalandcomma\addspace\&\space}}}
Isso sempre imprime o \finalandcomma
(normalmente só é impresso se houver mais de dois autores).
MWE
\documentclass{scrartcl}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[american,ngerman]{babel}
\usepackage{csquotes}
\usepackage{xpatch}
\usepackage[style=apa,backend=biber, doi=false, url=false]{biblatex}
\DeclareLanguageMapping{ngerman}{ngerman-apa}
\DefineBibliographyStrings{ngerman}{andothers={et\addabbrvspace al\adddot}}
\AtBeginDocument{\renewcommand\finalandcomma{\addcomma}}
\AtBeginBibliography{%
\renewcommand*{\finalnamedelim}{%
\ifthenelse{\value{listcount}>\maxprtauth}
{}
{\finalandcomma\addspace\&\space}}}
\addbibresource{biblatex-examples.bib}
\begin{document}
There is no comma in this citation \parencite{baez/article}, but the comma is missing in the reference.
\printbibliography
\end{document}
Responder2
Suprima o \renewcommand{\finalandcomma}{\addcomma}
(no estilo apa, \finalendcomma imprime um e comercial e você deseja mantê-lo). Substitua-o pelo seguinte em seu preâmbulo:
\usepackage{xpatch}
\xpatchnameformat{apaauthor}{%
{\ifmorenames{\andothersdelim\bibstring{andothers}}{}}{}}%
{%
{\ifmorenames{\andothersdelim\bibstring{andothers}}{}}{\addcomma\space}}%
{}{}%