biblatex:删除参考文献中作者名字后的逗号

biblatex:删除参考文献中作者名字后的逗号

我在用着biblatex-apa

\documentclass[man]{apa7}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\usepackage[style=apa,sortcites=true,sorting=nyt,backend=biber]{biblatex}

\DeclareLanguageMapping{american}{american-apa}
\addbibresource{y_bibliography.bib}

\begin{document}
\parencite{1} \newline
\parencite{2}

\printbibliography
\end{document}

y_bibliography.bib看起来像这样

@article{hanson2014business,
  title={Business student moral influencers: Unseen opportunities for development?},
  author={Hanson, William R and Moore, Jeffrey R},
  journal={Academy of Management Learning \& Education},
  volume={13},
  number={4},
  pages={525--546},
  year={2014},
  publisher={Academy of Management Briarcliff Manor, NY}
}

@article{hoornweg2011cities,
  title={Cities and greenhouse gas emissions: moving forward},
  author={Hoornweg, Daniel and Sugar, Lorraine and Trejos G{\'o}mez, Claudia Lorena},
  journal={Environment and urbanization},
  volume={23},
  number={1},
  pages={207--227},
  year={2011},
  publisher={SAGE Publications Sage UK: London, England}
}

我编译的pdf文档中的参考文献如下所示。

Hanson, WR 和 Moore, JR (2014)。商学院学生道德影响者:看不见的发展机遇?管理学习与教育学院,13(4),525–546。

Hoornweg, D.、Sugar, L. 和 Trejos Gómez, CL (2011)。城市和温室气体排放:前进。环境与城市化,23(1),207–227。

我想删除倒数第二个作者姓名首字母后面(“and”之前)和期刊名称后面的逗号,以便参考文献显示如下

Hanson, WR 和 Moore, JR (2014)。商学院学生道德影响者:看不见的发展机遇?管理学习与教育学院 13(4),525–546。

Hoornweg, D.、Sugar, L. 和 Trejos Gómez, CL (2011)。城市和温室气体排放:前进。环境与城市化 23(1),207–227。

答案1

在 的当前版本中biblatex-apa,“and” 之前的逗号要么由牛津逗号 ( \finalnamdelim) 生成,要么由内部宏 生成\apablx@ifrevnameappcomma。如果要删除逗号,则需要禁用这两个功能。

journal+issuetitle通过弄乱宏并转换\setunit*{\addcomma\addspace}为,可以轻松地将期刊名称后的逗号转换为空格\setunit*{\addspace}

\documentclass[american]{article}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage{csquotes}

\usepackage[backend=biber, style=apa]{biblatex}

\makeatletter
\renewcommand*{\apablx@ifrevnameappcomma}[2]{#2}
\makeatother

\DefineBibliographyExtras{american}{%
  \let\finalandcomma=\empty
}

\renewbibmacro*{journal+issuetitle}{%
  \usebibmacro{journal}%
  \setunit*{\addspace}%
  \printfield{volume}%
  \printfield{number}%
  \setunit{\addcomma\addspace}%
  \printfield{eid}%
  \newunit\newblock
  \usebibmacro{issuename}%
  \newunit}

\begin{filecontents}{\jobname.bib}
@article{hanson2014business,
  title   = {Business Student Moral Influencers: Unseen Opportunities for Development?},
  author  = {Hanson, William R. and Moore, Jeffrey R.},
  journal = {Academy of Management Learning \& Education},
  volume  = {13},
  number  = {4},
  pages   = {525--546},
  year    = {2014},
}
@article{hoornweg2011cities,
  title   = {Cities and Greenhouse Gas Emissions: Moving Forward},
  author  = {Hoornweg, Daniel and Sugar, Lorraine and Trejos Gómez, Claudia Lorena},
  journal = {Environment and urbanization},
  volume  = {23},
  number  = {1},
  pages   = {207--227},
  year    = {2011},
}
\end{filecontents}
\addbibresource{\jobname.bib}
\addbibresource{biblatex-examples.bib}

\begin{document}
Lorem \autocite{hanson2014business,hoornweg2011cities}

\printbibliography
\end{document}

Hanson, WR & Moore, JR (2014). 商学院学生道德影响因素:未见的发展机遇?管理学院学习与教育 13(4), 525–546。Hoornweg, D., Sugar, L. & Trejos Gómez, CL (2011). 城市与温室气体排放:前进。环境与城市化 23(1), 207–227。

相关内容