BibLatex verbose-ibid 每次更改参考后都进行完整引用

BibLatex verbose-ibid 每次更改参考后都进行完整引用

是否可以在更改参考文献后始终引用完整来源,而不是使用简短版本姓氏、头衔verbose-ibid 提供什么?我找到了其他人的问题。如果有帮助的话,似乎可以cite:short使用重写\renewbibmacro*{cite:short}。是否可以只替换cite:shortcite:long/full或无论它可能被称为什么?

我当前的设置:\usepackage[backend=biber,citestyle=verbose-ibid,natbib=true,bibstyle=authoryear]{biblatex}

最小工作示例:

\documentclass{article}
\usepackage[backend=biber,citestyle=verbose-ibid,natbib=true,bibstyle=authoryear]{biblatex}
\addbibresource{\jobname.bib}
\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@book{key1,
  author = {Author, A.},
  year = {2001},
  title = {Title},
  publisher = {Publisher},
}
@book{key2,
    author = {Author, B.},
    year = {2002},
    title = {Title 2},
    publisher = {Publisher 2},
}
\end{filecontents}

\begin{document}

Lorem ipsum dolor sit amet \footcite{key1}, consectetur adipiscing elit \footcite{key1}, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua \footcite{key2}. Ut enim ad minim veniam \footcite{key2}, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat \footcite{key1}.

\printbibliography

\end{document}

我基本上想要的是,脚注 5 是“A. 作者 (2001)。标题。出版商。”而不是“作者,标题。”

答案1

您可以重新定义bibmacro来代替cite使用:cite:fullcite:short

\renewbibmacro*{cite}{%
  \usebibmacro{cite:citepages}%
  \global\togglefalse{cbx:loccit}%
  \ifciteseen
    {\iffieldundef{shorthand}
       {\ifboolexpr{
          test {\ifciteibid}
          and
          not test {\iffirstonpage}
        }
          {\usebibmacro{cite:ibid}}
          {\usebibmacro{cite:full}}}
       {\usebibmacro{cite:shorthand}}}
    {\usebibmacro{cite:full}}}

完整的 MWE:

\documentclass{article}
\usepackage[backend=biber,citestyle=verbose-ibid,natbib=true,bibstyle=authoryear]{biblatex}
\addbibresource{\jobname.bib}
\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@book{key1,
  author = {Author, A.},
  year = {2001},
  title = {Title},
  publisher = {Publisher},
}
@book{key2,
    author = {Author, B.},
    year = {2002},
    title = {Title 2},
    publisher = {Publisher 2},
}
\end{filecontents}

\renewbibmacro*{cite}{%
  \usebibmacro{cite:citepages}%
  \global\togglefalse{cbx:loccit}%
  \ifciteseen
    {\iffieldundef{shorthand}
       {\ifboolexpr{
          test {\ifciteibid}
          and
          not test {\iffirstonpage}
        }
          {\usebibmacro{cite:ibid}}
          {\usebibmacro{cite:full}}}
       {\usebibmacro{cite:shorthand}}}
    {\usebibmacro{cite:full}}}

\begin{document}

Lorem ipsum dolor sit amet \footcite{key1}, consectetur adipiscing elit \footcite{key1}, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua \footcite{key2}. Ut enim ad minim veniam \footcite{key2}, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat \footcite{key1}.

\printbibliography

\end{document}

在此处输入图片描述

答案2

\letbibmacro{cite:short}{cite:full}

我们可以使用\letbibmacrocite:short执行什么cite:full操作。这使用,因此它会在执行时复制\let的定义。请参阅cite:full\letbibmacro\let 和 \def 之间有什么区别?

cite:full如果您希望在执行时拥有 的定义cite:short,即使用 处理分配\def,请使用

\renewbibmacro*{cite:short}{\usebibmacro{cite:full}}

反而。

相关内容