页面标题错误

页面标题错误

我将“表格列表”标题作为右页标题。我该如何修复?

    \documentclass[10pt,cleardoublepage=empty,twoside]{book}

\makeatletter
\def\ps@headings{%
    \let\@oddfoot\@empty
    \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
    \let\@mkboth\markboth
    \def\chaptermark##1{%
      \markright {{%                                    %%% original \MakeUppercase
        \ifnum \c@secnumdepth >\m@ne
            \@chapapp\ \thechapter. \ %
        \fi
        ##1}}}}
\makeatother
\pagestyle{headings}
\usepackage{setspace}
\usepackage{array}
\usepackage{amsmath}
\usepackage{fixltx2e}
\usepackage{covington}
\usepackage[danish,english]{babel}
\usepackage{tipa}
\usepackage{pslatex}
\usepackage{float}
\usepackage{graphicx}
\usepackage{titlesec}
\usepackage{amssymb}
\usepackage{typearea} 

\newcolumntype{L}[1]{>{\raggedright\arraybackslash}p{#1}}%per allineamento a sx delle colonne
\renewcommand{\bibname}{References} 
\usepackage{caption}
\usepackage[bitstream-charter]{mathdesign}
\usepackage[T1]{fontenc} 
\usepackage{morefloats}
\usepackage{booktabs}
\usepackage[bottom,norule]{footmisc}
\setlength\belowcaptionskip{1\baselineskip} 
\usepackage[hidelinks]{hyperref} 
\usepackage{bookmark}

\begin{document}
\frontmatter
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat
\cleardoublepage
\pagenumbering{roman}
\tableofcontents
 \addcontentsline{file}{sec_unit}{entry}
 \addcontentsline{toc}{chapter}{\bibname}
\listoffigures
\listoftables

\mainmatter
\pagenumbering{arabic}  

\chapter{Lorem}
\section{lorem ipsum dolor sit amet}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.


\chapter{Ipsum}
\section{dolor sit amet lorem ipsum}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
\end{document}

答案1

这是一种可以满足您需求的方法。我删除了许多软件包;您可以随意添加它们,但请考虑以下事实:

  • pslatex已经过时了,你还会加载mathdesign
  • amssymb不能沿mathdesign
  • IPA 字体与 Computer Modern 或 Times 兼容,并且与 Charter 完全不混合

这是一个骨架文档。

\documentclass[10pt,cleardoublepage=empty,twoside]{book}
\usepackage{fixltx2e}
\usepackage[T1]{fontenc} 
\usepackage[danish,english]{babel}
\usepackage[bitstream-charter]{mathdesign}

%\usepackage{emptypage} % uncomment for getting really empty pages

\usepackage{fancyhdr}
\pagestyle{fancy}
\renewcommand{\headrulewidth}{0pt}
\fancyhf{}
\fancyhead[LO]{\slshape\nouppercase{\rightmark}}
\fancyhead[RE]{\slshape\nouppercase{\leftmark}}
\fancyhead[RO,LE]{\thepage}

%%% Add your packages

\usepackage[hidelinks]{hyperref} 
\usepackage{bookmark}

\usepackage{kantlipsum} % just to produce mock text

\begin{document}
\frontmatter

\thispagestyle{empty}
A Frontispiece?


\tableofcontents
\listoffigures
\listoftables

\mainmatter

\chapter{Lorem}
\section{lorem ipsum dolor sit amet}

\kant

\chapter{Ipsum}
\section{dolor sit amet lorem ipsum}

\kant

\end{document}

相关内容