\documentclass[12pt]{report}
\begin{document}
\tableofcontents
\chapter{Introduction}
\chapter{Main chapter one}
\section{Background}
\section{Methods}
\section{Results}
\section{Conclusion}
\chapter{Main chapter two}
\section{Background}
\section{Methods}
\section{Results}
\section{Conclusion}
\chapter{Main chapter three}
\section{Background}
\section{Methods}
\section{Results}
\section{Conclusion}
\chapter{Conclusion}
\end{document}目录默认样式如图:
这里想让section所在的目录增加些空白距离,并能使其均匀地分散在页面上。这里使用tocloft包提供的命令:\cftbeforeXskip 这里的X可以用chap, sec等来替代,表示章,节的上部距离。
如:
\usepackage{tocloft}
\setlength{\cftbeforesecskip}{10pt}得到的是:
感觉好像section变得比较稀疏,但是章和节部分显得不那么层次分明,可以用下面的命令来简单调整:
\usepackage{tocloft}
\renewcommand{\cftchapafterpnum}{\vspace{10pt}}得到如下图:
选自:texblog.org


发表评论 取消回复