大寫索引 標題帶有 fncychap

大寫索引 標題帶有 fncychap

您好,我正在使用 LyX 並在序言中使用 \usepackage[Lenny]{fncychap} 。

目錄或索引清單的標題是小寫的,但我希望它是大寫的。

我必須寫什麼命令才能做我想做的事?

答案1

使用tocloft包:

\documentclass{book}

\usepackage[Lenny]{fncychap}
\usepackage{tocloft}

%\renewcommand{\contentsname}{Table of contents} % change "Contents" to "Table of Contents"
\renewcommand{\cfttoctitlefont}{\center\hfill\large\bfseries\MakeUppercase} % change toc title to upper case
\renewcommand{\cftaftertoctitle}{\hfill}
%\renewcommand{\cftchapfont}{\scshape} %For uppercase TOC entries

\begin{document}
\tableofcontents
\chapter{Foo1}
Some text.

\chapter{Foo2}
Some text.

\end{document}

相關內容