在 biblatex 中,此欄位volumes
可用於指示多卷作品中的捲數。但是,我如何表明多卷作品具有例如 8 個編號卷加上一個補充的未編號卷(例如索引)?
理想情況下,我想輸出格式為「8 卷,1 個索引」、「8 卷,1 個附錄」或「8 卷,1 個補充卷」的參考文獻。
答案1
您可以重新定義卷的格式以列印文字,除非它是數字。像這樣的東西:
\documentclass{article}
\usepackage{biblatex}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@mvbook{mvbook1,
author = {AuthorA},
title = {Title 1},
volumes = {8 vols\adddot, 1 supplementary vol\adddot},
location = {Location},
publisher = {Publisher},
date = {2017}
}
@mvbook{mvbook2,
author = {AuthorB},
title = {Title 2},
volumes = {7},
location = {Location},
publisher = {Publisher},
date = {2017}
}
\end{filecontents}
\addbibresource{\jobname.bib}
\pagestyle{empty}
\DeclareFieldFormat{volumes}{%
\ifnumeral{#1}
{#1 \bibstring{volumes}}
{#1}}
\begin{document}
\nocite{*}
\printbibliography
\end{document}