根据以下不工作例如,我需要在我的文档中添加“附录列表”:
\documentclass[doublespaced,12pt]{ut-thesis}
\usepackage[english]{babel}
\usepackage[toc,page,titletoc]{appendix}
\degree{A}
\department{B}
\gradyear{C}
\author{D}
\title{E}
\setcounter{tocdepth}{2}
\makeatletter
\@openrightfalse
\makeatother
\begin{document}
\begin{preliminary}
\maketitle
\begin{abstract}
\addcontentsline{toc}{chapter}{Abstract}
F
\end{abstract}
\begin{acknowledgements}
\addcontentsline{toc}{chapter}{Acknowledgements}
G
\end{acknowledgements}
\cleardoublepage
\phantomsection
\addtocontents{toc}{chapter}{List of Appendices}
\newpage
\addcontentsline{toc}{chapter}{Contents}
\tableofcontents
\end{preliminary}
\begin{appendices}
\input{app}
\end{appendices}
\end{document}
就像app.tex
是:
\chapter{Procedures}
\leavevmode
The implemented procedures of ...
但我不知道以下抛出的错误:
出了点问题——可能缺少 \item。...entsline {chapter}{Contents}{v}{section*.3}
错误编译后的内容ut-thesis.toc
如下:
\select@language {english}
\contentsline {chapter}{Abstract}{ii}{section*.1}
\contentsline {chapter}{Acknowledgements}{iii}{section*.2}
chapter
\contentsline {chapter}{Contents}{v}{section*.3}
\contentsline {chapter}{Appendices}{1}{section*.5}
\contentsline {chapter}{Appendix \numberline {A}Procedures}{2}{Appendix.a.A}
答案1
\addtocontents{toc}{chapter}{List of Appendices}
是错误的。应该是
\addcontentsline{toc}{chapter}{List of Appendices}