书目标题和图表列表与页眉重叠

书目标题和图表列表与页眉重叠

我目前在尝试修复章节标题与文档标题重叠的问题时遇到了问题。参见下图

在此处输入图片描述

在此处输入图片描述

问题是这种情况只发生在(参考书目、图片列表、表格列表等)上,但不会影响我的章节标题部分。我一直在尝试解决这个问题,但我无论如何也想不出解决办法。

例如,这个就很好!

在此处输入图片描述

代码中唯一与参考书目相关的部分是

% -------------------------------------------------------------
% BIBLIOGRAPHY (DATABASE)
% -------------------------------------------------------------
\printbibliography

我尝试查找是否有任何参数\printbibliography可以增加顶部页面边距的垂直间距,但我找不到任何东西。如果能指导我如何解决这个问题,我将不胜感激!

我尝试添加 vspace 并尝试将其进一步向下推,但没有任何效果 :(

编辑:如何解决章节标题与页眉重叠的问题?

这是一个应该可以工作的 MWE

\documentclass[11pt,                                          % Main text font size
%               a4paper,                                       % Paper size
               %openright,                                     % Chapters start on odd pages (right)
               twoside]{report}                               % Print two-sided, LaTeX 'report' template

\usepackage[a4paper,                                          % Paper size
            top = 20mm,                                       % Top margin
            bottom = 20mm,                                    % Bottom margin
            left = 20mm,                                      % Left margin
            right = 20mm]{geometry}                           % Right margin

\usepackage{cmbright}                                         % SS font - Comment this line for LaTeX base font
\renewcommand{\familydefault}{\sfdefault}                      % comment to revert to Comptuter Modern
\usepackage{pdfpages}
\usepackage[utf8]{inputenc}                                   % Includes letters with accents
\usepackage[T1]{fontenc}                                      % 8-bit encoding with 256 glyphs
\usepackage[colorlinks=true, allcolors=black]{hyperref}       % Hyper-references in PDF (e.g. urlcolor=blue)
\usepackage{fancyhdr}                                         % Headers and footers
\usepackage[english]{babel}                                   % Babel and language definitions
\usepackage[page,toc,titletoc,title]{appendix}                % Include appendixes
\usepackage{lipsum}                                           % Generate automatic text - Lorem Ipsum
\usepackage{caption}                                          % Manage captions in floats
\usepackage[sorting=none]{biblatex}
\addbibresource{reference.bib}

\usepackage{titlesec} % for customizing chapter titles
\usepackage{fancyhdr} % for customizing header/footer

\titleformat{\chapter}[display]
{\normalfont\huge\bfseries}{}{0pt}{\Huge}

\titlespacing*{\chapter}{0pt}{-50pt}{30pt}

\pagestyle{fancy}
\fancyhf{} % clear all header and footer fields
\fancyhead[L]{\nouppercase{\leftmark}} % chapter name in the left of header
\fancyfoot[C]{\thepage} % page number in the center of footer
\renewcommand{\headrulewidth}{0.4pt} % add a line under the header
\renewcommand{\footrulewidth}{0pt} % remove the line under the footer

\captionsetup[table]{skip=6pt}                                % Gap between captions and tables
\graphicspath{{Images/}}                                      % Path to folder where pictures are stored

\fancyfoot[LO,RE]{\theAuthor}                                 % Footer left-odd and right-even: author name

\begin{document}                                              % Start document


% -------------------------------------------------------------
% LINE UNDER CHAPTER TITLES ON EVERY PAGE
% -------------------------------------------------------------
\makeatletter
\patchcmd{\@makechapterhead}{\vspace*{50\p@}}{\vspace*{50\p@}\hrule\vspace{5pt}}{}{}
\patchcmd{\@makeschapterhead}{\vspace*{50\p@}}{\vspace*{50\p@}\hrule\vspace{5pt}}{}{}
\pagestyle{fancy}
\fancyhf{}
\fancyhead[LE,RO]{\slshape\nouppercase{\leftmark}}
\fancyfoot[C]{\thepage}
\fancyhead[R]{\textit{Interim Report}}
\renewcommand{\headrulewidth}{0.4pt}
\makeatother

% -------------------------------------------------------------
% ARABIC PAGE NUMBERS
% -------------------------------------------------------------
\clearpage
\pagenumbering{arabic}
\fancypagestyle{plain}{%
    \fancyhf{} % clear all header and footer fields
    \fancyhead[L]{\nouppercase{\leftmark}} % chapter name in the left of header
    \fancyfoot[C]{\thepage} % page number in the center of footer
    \fancyhead[R]{\textit{Interim Report}}
    \renewcommand{\headrulewidth}{0.4pt} % add a line under the header
    \renewcommand{\footrulewidth}{0pt} % remove the line under the footer
}

% -------------------------------------------------------------
% Chapters
% -------------------------------------------------------------
\chapter{First chapter}

\section{First section}

\lipsum[1-2] \cite{example-citation}

\begin{figure}[!htbp]
    \centering
    \includegraphics[width=0.5\linewidth]{Images/simply-supported-beam.png}
    \caption{Enter Caption}
    \label{fig:enter-label}
\end{figure}

\printbibliography

\listoffigures                                                % Add list of figures

\end{document}

具有以下references.bib文件

 @misc{example-citation, 
    title={Quadcopter Dynamics},
    url={https://uk.mathworks.com/help/supportpkg/parrot/ug/quadcopter-dynamics.html},
    journal={Quadcopter Dynamics - MATLAB & Simulink - MathWorks United Kingdom}
}

答案1

printbibliography在解决我面临的问题之前添加以下内容

\titlespacing*{\chapter}{0pt}{-30pt}{30pt}

\printbibliography

\listoffigures     

然而,我仍然想理解的是,为什么章节可以正常工作,但当涉及到参考书目时,它就不起作用,需要不同的配置

相关内容