
我需要引用一篇文章,其作者沒有姓氏,只有名字(筆名)。我希望系統將其識別為給定名稱(因為使用多語言和法語選項,姓氏以小寫字母書寫)。我的目標是在標籤或條目中使用普通字母而不是小型大寫字母書寫名字。
我使用 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}