我想在我的 中包含一张图片List of Abbreviations
。到目前为止,我已经:
\documentclass[11pt, letterpaper, twoside, openright]{book}
\usepackage{graphicx} % images
\usepackage{hyperref}
\usepackage[acronym, nonumberlist, nopostdot, shortcuts, style=tree]{glossaries}
\setglossarystyle{alttree}
\glssetwidest{}
\glssetwidest[1]{loooooongest}
\renewcommand*{\acronymname}{List of Abbreviations}
\renewcommand*{\glsclearpage}{}
\newglossaryentry{software}{name={{Computer Software and Languages}}, description={\nopostdesc}, sort={Computer}}
\glsenablehyper
\makeglossaries
\newacronym[parent=software, sort={smurf}]{smurf}{\textsc{Smurf}}{Sub-Millimetre User Reduction Facility}
\begin{document}
\printglossary[type=\acronymtype, title={List of Abbreviations}]
\mbox{}\\
Some reference to \acs{smurf}
\end{document}
输出结果如下:
但是,我想在缩写列表中包含一个数字,因此我使用以下命令替换该newacronym
命令:
\newacronym[parent=software, sort={smurf}]{smurf}{\textsc{Smurf}}{Sub-Millimetre User Reduction Facility (\includegraphics{./figs/smurf_400x400.eps})}
但是,我收到以下错误:
! Undefined control sequence.
\in@ #1#2->\begingroup \def \in@@
##1#1{}\toks@ \expandafter {\in@@ #2{}{}#1...
l.18 ...ncludegraphics{./figs/smurf_400x400.eps})}
?
如能得到任何关于解决该问题的帮助,我们将不胜感激。
谢谢!
答案1
\includegraphics
是一个脆弱的命令,在任何情况下使用时都需要受到保护扩展的词汇表字段(long
在这种情况下)。
\newacronym[parent=software, sort={smurf}]{smurf}{\textsc{Smurf}}
{Sub-Millimetre User Reduction Facility
(\protect\includegraphics{./figs/smurf_400x400.eps})}