為附錄建立與章節結構類似的表格

為附錄建立與章節結構類似的表格

我希望我的附錄遵循與章節相同的形式,也就是說,我希望附錄的形式與我的章節相同,例如「附錄 A」。我的章節看起來像這樣:

在此輸入影像描述

我很確定以下程式碼行可以下結論:

\pagestyle{fancy}
\fancyhf{}
\renewcommand{\chaptermark}[1]{\markboth{\chaptername\ \thechapter.\ #1}{}}

我只是想知道你們中的 LaTeX 專家是否能找到一種快速處理此問題的方法?我查了一下,但看起來並沒有很多人使用與我想要的相同的附錄格式。

答案1

像這樣?

\documentclass{book}
\usepackage{lipsum}
\usepackage{fancyhdr}
\usepackage[Lenny]{fncychap}
\usepackage{appendix}
\pagestyle{fancy}
\fancyhf{}
\renewcommand{\chaptermark}[1]{\markboth{\chaptername\ \thechapter.\ #1}{}}

\begin{document}
\chapter{A}
\begin{appendices} 

  \chapter{Title of this appendix}\label{apx:f}

  \section{An appendix section}

\end{appendices}
\end{document}

在此輸入影像描述

相關內容