如何使用 verbose-trad1 首次使用简写

如何使用 verbose-trad1 首次使用简写

我使用biblatex、Biber 和style=verbose-trad1来处理我的 LaTeX 文档。但是,当使用速记时,我希望第一次不打印完整标题,而是让速记缩写也出现在脚注中。

这个问题已经解决了verbose 这里已经,但是在将样式更改为时不起作用verbose-trad1

所以我想说的是

临界值

代替

康德 1968 年(以下简称 KpV)

第一次出现。

知道如何解决这个问题吗?

\documentclass{article}

\usepackage[style=verbose-trad1]{biblatex}

% Original definition
% \newbibmacro*{cite}{%
%   \usebibmacro{cite:citepages}%
%   \ifciteseen
%     {\iffieldundef{shorthand}
%        {\usebibmacro{cite:short}}
%        {\usebibmacro{cite:shorthand}}}
%     {\usebibmacro{cite:full}}}

\renewbibmacro*{cite}{%
  \usebibmacro{cite:citepages}%
  \iffieldundef{shorthand}
    {\ifciteseen
       {\usebibmacro{cite:short}}
       {\usebibmacro{cite:full}}}
    {\usebibmacro{cite:shorthand}}}

\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@misc{A01,
  author = {Author, A.},
  year = {2001},
  title = {Alpha},
}
@misc{Kan68,
  shorthand = {KpV},
  author = {Kant, Immanuel},
  year = {1968},
  title = {Kritik der praktischen Vernunft},
}
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}

\null\vfill% just for the example

Some text.\autocite{Kan68}

Some text.\autocite{Kan68}

Some text.\autocite{A01}

Some text.\autocite{A01}

\printshorthands

\printbibliography

\end{document}

答案1

你可以尝试这个重新定义

\renewbibmacro*{cite}{%
  \usebibmacro{cite:citepages}%
  \global\togglefalse{cbx:loccit}%
  \bibhypertarget{cite\the\value{instcount}}{%
    \iffieldundef{shorthand}
      {\ifciteseen
         {\ifciteibid
            {\usebibmacro{cite:ibid}}
            {\ifthenelse{\ifciteidem\AND\NOT\boolean{cbx:noidem}}
               {\usebibmacro{cite:idem}%
                \usebibmacro{cite:title}}
               {\ifnameundef{labelname}
                  {\usebibmacro{cite:title}}
                  {\usebibmacro{cite:name}%
                   \ifopcit
                     {\ifloccit
                {\usebibmacro{cite:loccit}}
                {\usebibmacro{cite:opcit}}}
                     {\usebibmacro{cite:title}}}}}%
          \usebibmacro{cite:save}}
         {\usebibmacro{cite:full}%
       \usebibmacro{cite:save}}}
      {\usebibmacro{cite:shorthand}}}}

我们总是首先使用速记法(而不是完整引用)。实际上,我们将检查的顺序交换为shorthand\ifciteseen

平均能量损失

\documentclass{article}
\usepackage[style=verbose-trad1]{biblatex}

\renewbibmacro*{cite}{%
  \usebibmacro{cite:citepages}%
  \global\togglefalse{cbx:loccit}%
  \bibhypertarget{cite\the\value{instcount}}{%
    \iffieldundef{shorthand}
      {\ifciteseen
         {\ifciteibid
            {\usebibmacro{cite:ibid}}
            {\ifthenelse{\ifciteidem\AND\NOT\boolean{cbx:noidem}}
               {\usebibmacro{cite:idem}%
                \usebibmacro{cite:title}}
               {\ifnameundef{labelname}
                  {\usebibmacro{cite:title}}
                  {\usebibmacro{cite:name}%
                   \ifopcit
                     {\ifloccit
                {\usebibmacro{cite:loccit}}
                {\usebibmacro{cite:opcit}}}
                     {\usebibmacro{cite:title}}}}}%
          \usebibmacro{cite:save}}
         {\usebibmacro{cite:full}%
       \usebibmacro{cite:save}}}
      {\usebibmacro{cite:shorthand}}}}

\addbibresource{biblatex-examples.bib}

\begin{document}
Some text.\autocite{kant:kpv}

Some text.\autocite{kant:kpv}

Some text.\autocite{worman}

Some text.\autocite{worman}

\printshorthands
\printbibliography
\end{document}

在此处输入图片描述

相关内容