The document is book
class and the Appendix is added by:
...
\backmatter
\appendix
\chpater{Appendix A}
...
\chpater{Appendix B}
...
Using fancyhdr
:
\usepackage[]{fancyhdr}
\pagestyle{fancy}
\fancyhf{}
\fancyhead{}
\renewcommand{\sectionmark}[1]{\markright{\thesection ~ \ #1}}
\renewcommand{\chaptermark}[1]{\markboth{ \chaptername\ \thechapter ~ \ #1}{}}
%head setting
\fancyhead[LE]{\textcolor{black} {\thepage}}
\fancyhead[RE]{\textcolor{black} {\itshape \nouppercase \leftmark}}%higher level \scshape \MakeUppercase
\fancyhead[LO]{\textcolor{black} {\itshape \nouppercase \rightmark}}
\fancyhead[RO]{\textcolor{black} {\thepage}} %odd page
The chapter-mark is expected to be re-defined like Chapter 2 State of the art
, However, the \chaptername
will appear in Appendix heading.
So how to solve this issue?
Best Answer
Add a test for the
mainmatter
switch to the definition of\chaptermark
.