\thechapter가 포함된 멋진 헤더에는 \appendix 뒤에 "Chapter"가 계속 표시됩니다. "부록"을 표시해야 합니다.

\thechapter가 포함된 멋진 헤더에는 \appendix 뒤에 "Chapter"가 계속 표시됩니다. "부록"을 표시해야 합니다.

장과 부록이 있습니다. 나는 사용하고 있지 않습니다 \part. 내 헤더는 다음과 같이 정의됩니다.

\fancyhead[RO,LE]{\textsf{\footnotesize \thechapter--\thepage}}

장에서 부록(다음 \appendix)으로 이동한 후 부록 제목은 괜찮지만 헤더에 "부록 A: 어쩌구"가 아니라 "장 A: 어쩌구"라고 표시됩니다.

답변1

여기에 해결책이 있습니다.

명령은 \@chapapp첫 번째 장으로 확장되고 사용 후 부록으로 확장됩니다. \appendix여기에서 사용할 수 있습니다. \renewcommand{\chaptermark}[1]{\markboth{\@chapapp{} \thechapter:\ #1}{}}

\documentclass{book}
\usepackage{blindtext}


\usepackage{fancyhdr}
\renewcommand{\chaptermark}[1]{% 
\markboth{\@chapapp{} \thechapter:\ #1}{}} 
\fancyhead{} 
\makeatletter
\fancyhead[RO,LE]{\textsf{\footnotesize \thechapter--\thepage}} 
\fancyhead[LO,RE]{\textsf{\footnotesize \leftmark}}
\makeatother
\pagestyle{fancy}

\begin{document}
\blinddocument
\appendix 
\blinddocument 
\end{document}

관련 정보