同一文档中存在两种不同风格的书目

同一文档中存在两种不同风格的书目

使用时biblatex,假设我设置了两个单独的参考书目,我该如何为它们分配不同的样式,例如,一个是编号,另一个是作者年份格式或类似的东西。

\documentclass{article}

\usepackage[defernumbers=true]{biblatex}

\DeclareBibliographyCategory{cited}
\AtEveryCitekey{\addtocategory{cited}{\thefield{entrykey}}}

\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@misc{A01,
  author = {Author, A.},
  year = {2001},
  title = {Alpha},
}

@misc{B02,
  author = {Buthor, B.},
  year = {2002},
  title = {Bravo},
}

@misc{C03,
  author = {Cuthor, C.},
  year = {2003},
  title = {Charlie},
}
\end{filecontents}

\bibliography{\jobname}

\begin{document}

\nocite{*}

\cite{A01,B02}

\printbibliography[title={References},category=cited]

\printbibliography[title={Further Reading},notcategory=cited]

\end{document}

答案1

好问题。:-) 一方面,手册第 3.6.2 节biblatex提到

将数字子书目与使用不同方案(例如,作者-标题或作者-年份)的一个或多个子书目混合。

另一方面,根据第 3.1.1 节stylebibstylecitestyle是加载时选项,即,它们必须在biblatex加载时指定,并且不能在 的可选参数中使用\printbibliography

我有一个可能有点黑客的解决方案。biblatex使用numeric样式(默认行为)或alphabetic样式加载。定义一个新的书目环境,该环境仅复制在和中找到nolabelbib的定义(即不打印标签的环境)。切换到此环境以获取“进一步阅读”(子)书目。结果应该与样式相等。bibliographyauthortitle.bbxauthoryear.bbxauthortitle

\documentclass{article}

\usepackage{biblatex}

\DeclareBibliographyCategory{cited}
\AtEveryCitekey{\addtocategory{cited}{\thefield{entrykey}}}

% The following definition is copied from authortitle.bbx/authoryear.bbx
\defbibenvironment{nolabelbib}
  {\list
     {}
     {\setlength{\leftmargin}{\bibhang}%
      \setlength{\itemindent}{-\leftmargin}%
      \setlength{\itemsep}{\bibitemsep}%
      \setlength{\parsep}{\bibparsep}}}
  {\endlist}
  {\item}

\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@misc{A01,
  author = {Author, A.},
  year = {2001},
  title = {Alpha},
}
@misc{B02,
  author = {Buthor, B.},
  year = {2002},
  title = {Bravo},
}
@misc{C03,
  author = {Cuthor, C.},
  year = {2003},
  title = {Charlie},
}
\end{filecontents}

\addbibresource{\jobname.bib}

\nocite{*}

\begin{document}

Some text \autocite{A01,B02}.

\printbibliography[title={References},category=cited]

\printbibliography[env=nolabelbib,title={Further Reading},notcategory=cited]

\end{document}

在此处输入图片描述

答案2

您可能还想查看multibib图书馆:

http://www.bakoma-tex.com/doc/latex/multibib/multibib.pdf

相关内容