调整本地目录的字体大小

调整本地目录的字体大小

我的最低工作示例:

\documentclass{article}
\usepackage{appendix}
\usepackage{etoc}

\begin{document}

\section{My First Section}
\section{My Second Section}

\begin{appendices}
\section{My First Appendix}
\localtableofcontents
\subsection{My First Subsection}
\subsection{My Second Subsection}

\section{My Second Appendix}
\localtableofcontents
\subsection{My First Subsection}
\subsection{My Second Subsection}
\end{appendices}

\end{document}

结果:

在此处输入图片描述

现在我想调整“内容”标题的字体大小。

答案1

实现这一目标的一种方法是采用\etocsettocstyle

\documentclass{article}
\usepackage{appendix}
\usepackage{etoc}
\makeatletter
    \etocsettocstyle
    {\section *{\Huge\contentsname%
% FOLLOWING TWO LINES OPTIONAL DEPENDING ON YOUR NEED
%                \@mkboth {\MakeUppercase \contentsname}
%                         {\MakeUppercase \contentsname}%
    }}
    {}%
\def\etocstandarddisplaystyle{\etocarticlestyle}
\makeatother
\begin{document}
\section{My First Section}
\section{My Second Section}

\begin{appendices}
\section{My First Appendix}
\localtableofcontents
\subsection{My First Subsection}
\subsection{My Second Subsection}

\section{My Second Appendix}
\localtableofcontents
\subsection{My First Subsection}
\subsection{My Second Subsection}
\end{appendices}

\end{document}

在此处输入图片描述

相关内容