摘要后插入不需要的空白页

摘要后插入不需要的空白页

我正在使用报告样式创建论文文档,但遇到了一个问题,LaTeX 想要在我的摘要后插入一个额外的空白页。我希望摘要为一页,并在下一页上紧接着“致谢”部分。

如果我删除一行文本,我会注意到空白页消失了,所以我猜测该页面已接近满页,这就是它尝试插入新页面的原因,但由于寡妇/孤儿保护,它会将所有文本保留在一页上。

我尝试使用 \nopagebreak 选项,但该选项会在下一页上放置一行文本(同时删除空白页),这不符合我的格式准则。我搜索了本网站和其他地方,但未找到解决方案。如能得到任何帮助,我将不胜感激!

\documentclass[12pt]{report}
\usepackage[english]{babel}
\usepackage[toc,page]{appendix}
\usepackage[letterpaper, left=1.5in, right=1in, top=1in, bottom=1in, includefoot]{geometry}
\usepackage{titlesec}
\usepackage{amsmath}
\usepackage{mathrsfs}
\DeclareMathOperator{\sinc}{sinc}
\usepackage{siunitx}
\usepackage{rotating}
\usepackage{graphicx}
\graphicspath{{./figures/}}
\usepackage[section]{placeins}
\usepackage[space]{grffile}
\usepackage{todonotes}
\usepackage{amssymb}
\usepackage{lipsum}
%\usepackage{sectsty}
\usepackage{setspace}
%\allsectionsfont{\singlespacing}
\usepackage{standalone}
\usepackage{tikz}
\usetikzlibrary{dsp,chains,external,fit,arrows,calc,math}
\def\th{30}
\tikzmath{\ps = 90 - \th;}
\usepackage{circuitikz}
\usepackage{multirow}
\usepackage{subfig}
\usepackage{url}

% Guidelines - no less than 2 lines of a paragraph to be widowed/orphaned
\usepackage[defaultlines=2,all]{nowidow}

\pdfminorversion=7



% Table titles on top of table
\usepackage{float}
\floatstyle{plaintop}
\restylefloat{table}

% Chapters should be roman, no bold, centered upper case
\renewcommand{\thechapter}{\Roman{chapter}}
\renewcommand{\thesection}{\arabic{chapter}.\arabic{section}}
\renewcommand{\thefigure}{\arabic{chapter}.\arabic{figure}}
\renewcommand{\theequation}{\arabic{chapter}.\arabic{equation}}
\renewcommand{\thetable}{\arabic{chapter}.\arabic{table}}
\renewcommand{\appendixpagename}{\textnormal{APPENDICES}}
\renewcommand{\appendixtocname}{APPENDICES}
\addto\captionsenglish{% Replace "english" with the language you use
    \renewcommand{\contentsname}%
    {TABLE OF CONTENTS}%
    \renewcommand{\listfigurename}{LIST OF FIGURES}
    \renewcommand{\listtablename}{LIST OF TABLES}
}


\titleformat{\chapter}[display]
    {}
    {\centering\MakeUppercase{\chaptertitlename} \thechapter}
    {2ex}
    {\centering}

\titleformat{\section}
    {\normalfont}
    {\thesection}
    {2ex}
    {}

\titleformat{\subsection}
    {\normalfont}
    {\thesubsection}
    {2ex}
    {}



\begin{document}
\singlespacing
\pagenumbering{roman}

\newpage
\doublespacing
\renewcommand{\abstractname}{\textnormal{ABSTRACT}}
\begin{abstract}
    \thispagestyle{plain}
    \setcounter{page}{3}
    \lipsum[1]

    \lipsum[2]

    more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page more text to fill up the whole page  
\end{abstract}

\setcounter{page}{4}
\chapter*{DEDICATION}
\vspace*{2in}
\begin{center}
    \textit{Dedicated to blah blah blah}
\end{center}
\vspace*{\fill}
\clearpage

\end{document}

答案1

观察抽象环境,我们会发现它以

\par\vfil\null\endtitlepage

因此,可以修补摘要环境,以摆脱\null创建空白页的内容。但请注意,如果您的摘要较短,这会改变外观。因此,如果需要,只需使用它即可。

添加

\usepackage{etoolbox} % provides \patchcmd
\patchcmd{\endabstract}{\null}{}{}{} % replaces \null with third argument (empty)

将其从你的序言中删除\null

相关内容