假设我想将 amsrefs 中“参考文献”列表中的项目标签设置为粗体(或内联数字 - 我在整个文档中都设置了旧式数字)。我可以\cite
通过重新定义 来在文本中的引文(通过 获得)中执行此操作\citeform
;但如何对参考文献列表执行此操作?
答案1
您可以通过重新定义来更改标签\BibLabel
;作为参考,这里是原始定义(如中所示amsref.sty
):
\newcommand{\BibLabel}{%
\hfill
\Hy@raisedlink{\hyper@anchorstart{cite.\CurrentBib}\hyper@anchorend}%
[\thebib]%
}
在下面的例子中,我使用包中的\BibLabel
辅助命令()进行了修补,以便标签以粗体旧式数字显示:\patchcmd
etoolbox
\biblistlabelfont
\documentclass{amsart}
\usepackage{amsrefs}
\usepackage{etoolbox}
\newcommand{\biblistlabelfont}{%
\normalfont
\bfseries\footnotesize
}
\patchcmd{\BibLabel}{\thebib}{\biblistlabelfont\oldstylenums{\thebib}}{}{}
\begin{document}
\cite{lamport}
\cite{knuth}
\cite{patashnik}
\begin{bibdiv}
\begin{biblist}
\bib{knuth}{book}{
author={Knuth, Donald~E.},
title={{TeX} and {M}etafont, {N}ew {D}irections in {T}ypesetting},
publisher={American Mathematical Society and Digital Press},
address={Stanford},
date={1979},
}
\bib{lamport}{book}{
author={Lamport, Leslie},
title={{LaTeX}: {A} {D}ocument {P}reparation {S}ystem},
edition={Second},
publisher={Addison-Wesley},
address={Reading, Massachusetts},
date={1994},
}
\bib{patashnik}{misc}{
author={Patashnik, Oren},
title={{BibTeX}ing. {D}ocumentation for {G}eneral {BibTeX} {U}sers},
how={Electronic document accompanying BibTeX distribution},
date={1988},
}
\end{biblist}
\end{bibdiv}
\end{document}