不带作者姓名的括号引用(\parencite*{})在 biblatex-chicago 中无法使用 [notes] 样式

不带作者姓名的括号引用(\parencite*{})在 biblatex-chicago 中无法使用 [notes] 样式

我使用的是biblatex-chicago注释样式。有时我想\parencite*在脚注中使用命令,以便产生如下效果:

托马斯·S·库恩(哥白尼革命:西方思想发展中的行星天文学[1957;马萨诸塞州剑桥:哈佛大学出版社,1995])写道……

该软件包的文档中biblatex-chicago没有提到这种情况(使用注释样式时括号内引用而没有作者),但在该biblatex软件包的文档中,有提到\parencite*(第 80 页):

所有 author-year 和 author-title 样式均提供此命令。它与常规\parencite命令类似,但仅分别打印年份或标题。

但是,我无法让它与注释样式配合使用biblatex-chicago。相反,即使我使用命令的星号 (*) 选项,我也会得到带有作者姓名的完整引文。这是一个最小的工作示例(我使用 XeLaTeX 编译),说明了这个问题:

\documentclass[utf8,12pt,letterpaper]{article}
\usepackage[notes,strict,isbn=false,backend=biber,bibencoding=utf8,hyperref=true]{biblatex-chicago}

\addbibresource{bibliography.bib}

\begin{document} 

Thomas S.\ Kuhn \parencite*{Kuhn19571995TheCopernicanRevolution} wrote that\ldots

\end{document}

存在的内容bibliography.bib

@book{Kuhn19571995TheCopernicanRevolution,
author = {Kuhn, {Thomas S.}},
title = {The Copernican Revolution},
subtitle = {Planetary Astronomy in the Development of Western Thought},
publisher = {Harvard University Press},
address = {Cambridge, Mass.},
date = {1995},
origdate = {1957}
}

生成的 PDF 如下所示:

enter image description here

有任何想法吗?

答案1

biblatex-chicago\cite*命令关闭同上-跟踪器(参见文档第 4.3.2biblatex-chicago)而在标准biblatex样式中\cite*,其行为恰恰符合您的预期(参见文档第 3.7.2biblatex)。

注意::这里的解决方案相当粗糙 - 尤其是针对 fullcite 的解决方案 - 也许您可以联系维护人员并请他合并此功能,同时小心使用此解决方案。

为了实现您期望的行为,我们需要对biblatex-chicago样式进行大量修改。

biblatex-chicago.stychicago-notes.bbx和复制chicago-notes.cbx到可以找到它们的位置latex,并将它们分别重命名为biblatex-chicago-na.stychicago-notes-na.bbxchicago-notes-na.cbx


首先,我们修改一下biblatex-chicago-na.sty。只需添加

\DeclareOption{notes-na}{\def\cms@style{notesna}}

之后\DeclareOption{notes}{\def\cms@style{notes}}(l.21)。

然后加

\def\cms@notesna{%
  \RequirePackage[style=chicago-notes-na]{biblatex}%
  \ExecuteBibliographyOptions{%
    pagetracker=true,autocite=footnote,abbreviate=false,alldates=comp,
    citetracker=true,ibidtracker=constrict,usetranslator=true,
    usecompiler=true,loccittracker=constrict,dateabbrev=false,
    maxbibnames=10,minbibnames=7,sorting=\cms@choose,sortcase=false}}

到第 68 行,位于块之后的某处\def\cms@notesna{......}


我们现在修改chicago-notes-na.cbx。添加

\newbibmacro*{cite:noauth}{%
   \ifciteseen%
     {\iffieldundef{shorthand}%
        {\ifthenelse{\ifciteibid\AND\NOT\iffirstonpage}%
           {\usebibmacro{cite:noauth:ibid}}%
           {\global\toggletrue{cms@shortnote}%
             \global\togglefalse{cms@fullnote}%
             \usebibmacro{cite:noauth:short}%
            \usebibmacro{cite:save}}}%
        {\iftoggle{cms@shorthandibid}%
          {\ifthenelse{\ifciteibid\AND\NOT\iffirstonpage}%
            {\usebibmacro{cite:noauth:ibid}}%
            {\usebibmacro{cite:shorthand}%
              \usebibmacro{cite:save}}}%
          {\usebibmacro{cite:shorthand}%
            \usebibmacro{cite:save}}}}%
     {\iftoggle{cms@allshort}%
       {\global\toggletrue{cms@shortnote}%
         \global\togglefalse{cms@fullnote}%
         \global\toggletrue{cms@printshhand}%
         \usebibmacro{cite:noauth:short}%
         \usebibmacro{cite:save}}%
       {\global\toggletrue{cms@fullnote}%
         \global\togglefalse{cms@shortnote}%
         \usebibmacro{cite:noauth:full}%
         \usebibmacro{cite:save}}}}%

在块 from 之后\newbibmacro*{cite}{...}(大约 260 行)。

最后,添加以下代码块。

\newbibmacro*{cite:noauth:full}{%
  \begingroup
  \renewbibmacro{author/editor}{}%
  \printtext[bibhypertarget]{%
    \usedriver
      {\DeclareNameAlias{sortname}{default}\frenchspacing}
      {cite:\thefield{entrytype}}%
   \iffieldundef{shorthand}
     {}%
     {\usebibmacro{cms:shorthandintro}}}%
  \endgroup}

\newbibmacro*{cite:noauth:short}{%
  \ifboolexpr{%
    togl {cms@allshort}%
    or
    test {\ifbibliography}
  }%
  {\printtext[bibhyperref]{%
    \printfield[citetitle]{labeltitle}}}%
  {\printtext[bibhyperlink]{%
    \printfield[citetitle]{labeltitle}}}}%:\thefield{entrytype}?

\newbibmacro*{cite:noauth:ibid}{%
  \iftoggle{cms@noibid}
  {\global\toggletrue{cms@shortnote}%
    \global\togglefalse{cms@fullnote}%
    \usebibmacro{cite:noauth:short}%
    \usebibmacro{cite:save}}%
  {\iftoggle{cms@allshort}%
    {\printtext[bibhyperref]{%
        \bibstring[\mkibid]{ibidem}}}%
    {\printtext[bibhyperlink]{%
        \bibstring[\mkibid]{ibidem}}}%
    \ifloccit
    {\global\toggletrue{cms@loccit}}%
    {}}}

\DeclareCiteCommand{\parencitena}[\mkbibparens]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:noauth}}
  {\multicitedelim}
  {\usebibmacro{cite:postnote}}

您还应该将宏更改newbibmacro*{cite:ibid}为(我添加了两个s,因此ibidem%中没有虚假的空格)\parencite

\newbibmacro*{cite:ibid}{%
  \iftoggle{cms@noibid}
  {\global\toggletrue{cms@shortnote}%
    \global\togglefalse{cms@fullnote}%
    \usebibmacro{cite:short}%
    \usebibmacro{cite:save}}%
  {\iftoggle{cms@allshort}%
    {\printtext[bibhyperref]{%
        \bibstring[\mkibid]{ibidem}}}%
    {\printtext[bibhyperlink]{%
        \bibstring[\mkibid]{ibidem}}}%
    \ifloccit
    {\global\toggletrue{cms@loccit}}%
    {}}}

然后,您像这样使用修改后的样式\usepackage[notes-na,strict,isbn=false,backend=biber,bibencoding=utf8,hyperref=true]{biblatex-chicago-na},新命令是\parencitena{...}


平均能量损失

\documentclass[american]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage[autopunct=true]{csquotes}
\usepackage[notes-na,strict,isbn=false,backend=biber,bibencoding=utf8,hyperref=true]{biblatex-chicago-na}
\addbibresource{\jobname.bib}

\begin{filecontents}{\jobname.bib}
@book{KuhnCopRev,
  author    = {Thomas S. Kuhn},
  title     = {The Copernican Revolution},
  subtitle  = {Planetary Astronomy in the Development of Western Thought},
  publisher = {Harvard University Press},
  address   = {Cambridge, Mass.},
  date      = {1995},
  origdate  = {1957}
}
@article{testart,
  author        = {Arnold Uthor and William Riter},
  %author        = {Arnold Uthor and William Riter and Rita Esearcher and Steven C. Ientist and Stuart T. Udent and Peter R. Ofessor and Lewis E. C. Turer},
  title         = {A Very Interesting Article},
  journal       = {Journal of Articles},
  volume        = {7},
  number        = {3},
  page          = {1-5},
  date          = {2010},
}
@book{testbook,
  author        = {Walter Ordsmith},
  editor        = {Eddie Ditor},
  title         = {The Work},
  subtitle      = {Subtitle},
  date          = {1983},
}
@online{testonline,
  author        = {Bernie Logger},
  title         = {A Very Opinionated Blog Post},
  url           = {http://example.com},
  year          = {2013},
}
\end{filecontents}

\begin{document}
  Thomas S. Kuhn \parencitena{KuhnCopRev} told us that \ldots
  \nocite{*}
  \printbibliography
\end{document}

enter image description here

相关内容