我正在使用\superfullcite{}
解释这里。据我了解(恐怕不多),它基本上是\footfullcite{}
只作为脚注出现一次的,即使被引用多次。我非常喜欢这个,因为它允许我(使用\AtEveryCiteKey{\clearfield{...}}
)将(小)引文放入页脚(或 tufte 的边距)并在末尾有(完整的、长的)引文。
但是,它使用numeric-comp
,我更希望我的引文链接像[XYZ99]
这样,(我猜应该是alphabetic
)这样,不存在隐含的数字顺序,按字母顺序排序时会弄乱。但如果一个人只阅读参考书目。
我不太清楚该怎么做。基本上只差更改一下标签,但我不确定该怎么做。
- 继续使用
numeric-comp
并sorting=true
以某种方式修改标签? - 开始使用
alphabetic
并尝试\superfullcite{}
工作?
MWE 就是这个
% !TEX TS-program = pdflatex
% !TEX encoding = UTF-8 Unicode
%\documentclass[a4paper, nobib, notoc, symmetric, marginals=raggedouter, justified]{tufte-book} %
%\morefloats
%\morefloats
\documentclass{article}
\usepackage{csquotes}
\usepackage{hyphenat}
\usepackage[american]{babel}
\usepackage[block=nbpar, firstinits=false, backref=true, maxcitenames=1, maxbibnames=99, isbn=false, doi=false, url=false, eprint=false, style=numeric-comp, backend=biber, sorting=none, citetracker=true, defernumbers=true]{biblatex}
\bibliography{biblatex-examples}
%%=====
\makeatletter
\DeclareCiteCommand{\notefullcite}[\mkbibbrackets]
{\usebibmacro{cite:init}%
\usebibmacro{prenote}}
{\usebibmacro{citeindex}%
\usebibmacro{notefullcite}%
\usebibmacro{cite:comp}}
{}
{\usebibmacro{cite:dump}%
\usebibmacro{postnote}}
\newbibmacro*{notefullcite}{%
\ifciteseen
{}
{\footnotetext[\thefield{labelnumber}]{%
\usedriver{}{\thefield{entrytype}}.}}}
% Declare superfullcite and remap it to cite
\DeclareCiteCommand{\superfullcite}[\cbx@superscript]%
{\usebibmacro{cite:init}%
\let\multicitedelim=\supercitedelim
\iffieldundef{prenote}
{}
{\BibliographyWarning{Ignoring prenote argument}}%
\iffieldundef{postnote}
{}
{\BibliographyWarning{Ignoring postnote argument}}}
{\usebibmacro{citeindex}%
\usebibmacro{superfullcite}%
\usebibmacro{cite:comp}}
{}
{\usebibmacro{cite:dump}}
\newbibmacro*{superfullcite}{%
\ifciteseen
{}
{\xappto\cbx@citehook{%
\noexpand\footnotetext[\thefield{labelnumber}]{%
\fullcite{\thefield{entrykey}}.}}}}
\newrobustcmd{\cbx@superscript}[1]{%
\mkbibsuperscript{#1}%
\cbx@citehook
\global\let\cbx@citehook=\empty}
\let\cbx@citehook=\empty
\makeatother
%\renewcommand{\cite}[1]{\superfullcite{#1}} %remap \superfullcite to \cite
\begin{document}
Some filler text \notefullcite{cotton}, then some more text
\notefullcite{hammond}. Perhaps some more text and the same
citation again \notefullcite{hammond}. Yet another one
\notefullcite{knuth:ct:a}. Now all again
\notefullcite{cotton,hammond,knuth:ct:a}.
Some filler text,\superfullcite{augustine} then some more
text.\superfullcite{companion} Perhaps some more text and the
same citation again.\superfullcite{companion} Yet another
one.\superfullcite{kastenholz} Now all
again.\superfullcite{augustine,companion,kastenholz}
\printbibliography
\end{document}
如您所见,我使用了sorting=none
但无法将样式更改为字母,因为cite:init
和类似的宏不起作用。有人可以详细说明这些是做什么的吗?搜索 biblatex 文档没有找到任何结果。
答案1
我们可以定义一个新命令\sfcite
,打印标准引用并\footfullcite
在第一次出现引用时添加,即带有完整书目条目的脚注。
\DeclareCiteCommand{\sfcite}[\mkbibbrackets]
{\usebibmacro{prenote}}
{\usebibmacro{citeindex}%
\usebibmacro{cite}%
\ifciteseen
{}
{\footfullcite{\thefield{entrykey}}}}
{\multicitedelim}
{\usebibmacro{postnote}}
(上面的定义旨在与 一起使用alphabetic
,但是如果删除 ,它[\mkbibbrackets]
可以与许多其他标准样式一起使用。基本思想是在定义\ifciteseen{}{\footfullcite{\thefield{entrykey}}}
后添加块。)\usebibmacro{cite}
平均能量损失
\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[style=alphabetic,backend=biber,citetracker=constrict]{biblatex}
\usepackage[colorlinks=true]{hyperref}
\addbibresource{biblatex-examples.bib}
\DeclareCiteCommand{\sfcite}[\mkbibbrackets]
{\usebibmacro{prenote}}
{\usebibmacro{citeindex}%
\usebibmacro{cite}%
\ifciteseen
{}
{\footfullcite{\thefield{entrykey}}}}
{\multicitedelim}
{\usebibmacro{postnote}}
\begin{document}
Lorem \sfcite{wilde} ipsum \sfcite{cicero} dolor \sfcite{wilde} sit
\sfcite{geer} amet \sfcite{knuth:ct:a,knuth:ct:b}.
Cite again \sfcite{geer} and \sfcite{cicero}.
\end{document}