![如何处理按字母顺序排列的 citestyle 中超过 3 位作者的两个单词姓氏](https://linux22.com/image/412318/%E5%A6%82%E4%BD%95%E5%A4%84%E7%90%86%E6%8C%89%E5%AD%97%E6%AF%8D%E9%A1%BA%E5%BA%8F%E6%8E%92%E5%88%97%E7%9A%84%20citestyle%20%E4%B8%AD%E8%B6%85%E8%BF%87%203%20%E4%BD%8D%E4%BD%9C%E8%80%85%E7%9A%84%E4%B8%A4%E4%B8%AA%E5%8D%95%E8%AF%8D%E5%A7%93%E6%B0%8F.png)
在我的工作中,我想引用一篇有三位以上作者的论文,但其中一位作者的姓氏由两个单词组成,如下例所示:
\documentclass[11pt,a4paper]{article}
\usepackage[style=alphabetic,backend=biber,citestyle=alphabetic]{biblatex}
\addbibresource{\jobname.bib}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@article{key,
author = {Obama, Barack and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
year = {2002},
title = {Title},
publisher = {Publisher},
}
@article{key2,
author = {De Gaulle, Charles and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
year = {2001},
title = {Title},
publisher = {Publisher},
}
\end{filecontents}
\begin{document}
\cite{key}
\cite{key2}
\printbibliography
\end{document}
姓氏“De Gaulle”的前三个字母是“De”。除了布局混乱之外,还可能存在问题,因为有了这个空间,引用就变得容易被破坏:
是否有任何常见的建议来处理此问题? 我也尝试在现有出版物中找到同一篇论文的字母顺序引用示例,但似乎使用数字引用样式非常常见。
答案1
根据作者的风格和国家惯例,可以这样写
author = {de Gaulle, Charles},
代替 author = {De Gaulle, Charles},
。
如果名称前缀以小写字母开头,biblatex
则将其识别为名称前缀并使用不同的规则。
\documentclass[11pt,a4paper]{article}
\usepackage[style=alphabetic, backend=biber]{biblatex}
\begin{filecontents}{\jobname.bib}
@article{key,
author = {Obama, Barack and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
year = {2002},
title = {Title},
publisher = {Publisher},
}
@article{key2,
author = {de Gaulle, Charles and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
year = {2001},
title = {Title},
publisher = {Publisher},
}
\end{filecontents}
\addbibresource{\jobname.bib}
\begin{document}
\autocite{key,key2}
\printbibliography
\end{document}
如果您使用该选项useprefix=true,
,即
\usepackage[style=alphabetic, backend=biber, useprefix=true,]{biblatex}
你得到
如果这里不适合使用名称前缀,你可以biblatex
至少用 来忽略标签生成时的空格\DeclareNolabel
。默认设置\nolabel{\regexp{[\p{P}\p{S}\p{C}]+}}
只忽略标点符号和控制字符。我们可以通过添加 来忽略空格\p{Z}
。
\documentclass[11pt,a4paper]{article}
\usepackage[style=alphabetic, backend=biber]{biblatex}
\DeclareNolabel{
\nolabel{\regexp{[\p{P}\p{S}\p{C}\p{Z}]+}}
}
\begin{filecontents}{\jobname.bib}
@article{key,
author = {Obama, Barack and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
year = {2002},
title = {Title},
publisher = {Publisher},
}
@article{key2,
author = {De Gaulle, Charles and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
year = {2001},
title = {Title},
publisher = {Publisher},
}
\end{filecontents}
\addbibresource{\jobname.bib}
\begin{document}
\autocite{key,key2}
\printbibliography
\end{document}
如果这些选项都不适合您,您仍然可以使用以下方法在本地覆盖标签的名称部分label
\documentclass[11pt,a4paper]{article}
\usepackage[style=alphabetic, backend=biber]{biblatex}
\begin{filecontents}{\jobname.bib}
@article{key,
author = {Obama, Barack and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
year = {2002},
title = {Title},
publisher = {Publisher},
}
@article{key2,
author = {De Gaulle, Charles and Author, Alpha and Buthor, Beta and Cuthor, Gamma},
label = {Gaul},
year = {2001},
title = {Title},
publisher = {Publisher},
}
\end{filecontents}
\addbibresource{\jobname.bib}
\begin{document}
\autocite{key,key2}
\printbibliography
\end{document}