我需要引用一个条目,其作者没有姓氏,只有名字(假名)。我希望系统将其识别为名字(因为在多语和法语选项中,姓氏是用小写字母书写的)。我的目标是在标签或条目中用普通字母而不是小写字母书写名字。
我使用 biblatex,但我猜测可能存在针对常规 biblio 使用的解决方案?
我已经尝试过这两件事:
@book{one,
author={{}, William}, % Results in [ , William]
author={William}, % Results in [WILLIAM]
...
}
但在第一种情况下,标签为空且列表显示逗号;在第二种情况下,假定该名称是姓氏。
你知道该如何进行吗?
\documentclass{article}
\usepackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@book{test,
title={Le petit prince},
author={de Saint-Exup{\'e}ry, Antoine},
year={1943},
}
@book{one,
author = {William},
title = {First try},
year = {2001},
}
@book{two,
author = {{}, William},
title = {Second try},
year = {2001},
}
\end{filecontents*}
\usepackage{polyglossia}
\setmainlanguage{french}
\usepackage[
backend=biber,
style=authoryear,
sorting=anyt,
labelalpha,
]{biblatex}
\addbibresource{\jobname.bib}
\DeclareNameAlias{sortname}{family-given}
\begin{document}
Look at book [\cite{one}] ! And book [\cite{two}]!
And look at book [\cite{test}]!
\printbibliography
\end{document}
答案1
改编自https://tex.stackexchange.com/a/429110/263192
\documentclass{article}
\begin{filecontents*}[overwrite]{\jobname.bib}
@book{test,
title={Le petit prince},
author={de Saint-Exup{\'e}ry, Antoine},
year={1943},
}
@book{three,
author = {William},
author+an = {=pseudonym},
title = {Third try},
year = {2022},
}
\end{filecontents*}
\usepackage{polyglossia}
\setmainlanguage{french}
\usepackage[
backend=biber,
style=authoryear,
sorting=anyt,
labelalpha,
]{biblatex}
\addbibresource{\jobname.bib}
\renewcommand*{\mkbibnamefamily}[1]{%
\iffieldannotation{pseudonym}
{#1}
{\textsc{#1}}
}
\DefineBibliographyExtras{french}{\restorecommand\mkbibnamefamily}
\DeclareNameAlias{sortname}{family-given}
\begin{document}
[\cite{test}]
[\cite{three}]
\printbibliography
\end{document}