minipage 环境插入空白页和页脚不会关闭

minipage 环境插入空白页和页脚不会关闭

这是我的第一篇帖子,所以希望我的格式正确。我到处搜索,似乎找不到问题的答案。下面您将找到我的文本文件的最小示例。我有两个问题。

1:Latex 在我正在创建的节标题页之前插入了一个空白页\minipage。我该如何删除这个空白页?

2:我似乎无法关闭第二节标题页(第 2 节)上的页脚。我用过,\thispagestyle{empty}但似乎不起作用。任何帮助都将不胜感激。谢谢

\documentclass[hidelinks]{article}
\usepackage{multirow}
\usepackage{helvet}
\renewcommand*{\familydefault}{\sfdefault}
%\usepackage{fontspec}
%\setmainfont[Mapping=text-tex]{Calibri}
\usepackage{colortbl}
\usepackage[total={6.5in,9in},top=1.1in, left=1.05in, includefoot]{geometry} %SPECIFIES PRINTABLE AREA AND MARGINS
\usepackage{graphicx} %NEEDED FOR IMAGES
\usepackage{hyperref} %NEEDED FOR HYPERLINKS
%\hypersetup{
        %pdfborder = {0,0,0}}
\usepackage{pdfpages}
\usepackage{colortbl, xcolor, array} 
\usepackage{makecell}
\usepackage{longtable} %NEEDED FOR TABLES SPANNING MULTIPLE PAGES
\usepackage{fancyhdr} %NEEDED FOR NUMBERING PAGES ON RIGHT AND INCLUDING TOWN NAME IN FOOTER
\usepackage{wasysym}
\usepackage{rotating}
\makeatletter

\makeatother


\usepackage{geometry}
\usepackage{tikz}
\usepackage{lscape}
%\AddToShipoutPicture{%
  %\AtTextCenter{%
  %  \makebox[0pt]{%
    %  \scalebox{9}{%
     %   \rotatebox[origin=c]{45}{%
      %    \color[gray]{.8}\normalfont Draft}}}}}

\setlength{\parindent}{0in}



\newcommand{\client}{Town } 

\newcommand{\jobno}{xxxxx-x} 

\newcommand{\toclink}{\hyperref[toc]{Go to Contents}}

\usepackage{colortbl}
\definecolor{SEE}{rgb}{0.44,.65,.82}


\begin{document}
\pagestyle{empty}
%\thispagestyle{empty} %TURN OFF PAGE NUMBER FOR TOC PAGE
\begin{center}
\tableofcontents \label{toc}
\end{center}
\listoftables
%\thispagestyle{empty} %TURN OFF PAGE NUMBER FOR TOC PAGE
%\thispagestyle{empty}
\newgeometry{top=0.0cm,left=18cm}
\begin{minipage}{0.3\textwidth}
\rotatebox{-90}{\colorbox{SEE}{\makebox[1.5\textheight]{\rule{0pt}{32\textwidth}\textcolor{white}{\LARGE \textbf{\hspace{1cm}Section 1: Some Text}} \hfill}}}
%\thispagestyle{empty}
\end{minipage}
%\thispagestyle{empty}
\restoregeometry

\pagenumbering{arabic} %TURN PAGE NUMBERING BACK ON
\fancyhf{}
\renewcommand{\headrulewidth}{0pt} %GETS RID OF LINE ABOVE SECTION TYPICAL TO FANCYHDR
\pagestyle{fancy} %CREATES SPECIAL RULE FOR PAGE NUMBERING
\fancyfoot[C]{J/N \jobno - \client O \& M Manual \hspace{27mm} \textit{\toclink} \hfill \thepage} %THE RULE - TOWN NAME SPCC ON LEFT, PAGE NUMBER ON RIGHT

\fancypagestyle{firststyle}{ \fancyhf{} \fancyfoot[C]{\client SWPPP \hfill \thepage}} %SETS FIRST PAGE AFTER TOC TO BE LIKE THE REST
%\draftwatermarkoff
%\includepdf[pages=-]{Test.pdf}
    %\draftwatermarkon


\newpage
\begin{center}
\section{Operation and Maintenance Manual Introduction} 
\end{center}
my text here    
\newpage
\thispagestyle{empty}
\newgeometry{top=0.0cm,left=18cm}
\begin{minipage}{0.3\textwidth}
\rotatebox{-90}{\colorbox{SEE}{\makebox[1.5\textheight]{\rule{0pt}{32\textwidth}\textcolor{white}{\LARGE \textbf{\hspace{1cm}Section 2: Some Text}} \hfill}}}
\end{minipage}
\restoregeometry
\end{document}

答案1

将其集成到部分命令中的版本:

在此处输入图片描述

\documentclass[hidelinks]{article}
\usepackage{multirow}
\usepackage{helvet}
\renewcommand*{\familydefault}{\sfdefault}
%\usepackage{fontspec}
%\setmainfont[Mapping=text-tex]{Calibri}
\usepackage{colortbl}
\usepackage[total={6.5in,9in},top=1.1in, left=1.05in, includefoot]{geometry} %SPECIFIES PRINTABLE AREA AND MARGINS
\usepackage{graphicx} %NEEDED FOR IMAGES
\usepackage{hyperref} %NEEDED FOR HYPERLINKS
%\hypersetup{
        %pdfborder = {0,0,0}}
\usepackage{pdfpages}
\usepackage{colortbl, xcolor, array} 
\usepackage{makecell}
\usepackage{longtable} %NEEDED FOR TABLES SPANNING MULTIPLE PAGES
\usepackage{fancyhdr} %NEEDED FOR NUMBERING PAGES ON RIGHT AND INCLUDING TOWN NAME IN FOOTER
\usepackage{wasysym}
\usepackage{rotating}
\makeatletter

\makeatother


\usepackage{geometry}
\usepackage{tikz}
\usepackage{lscape}
%\AddToShipoutPicture{%
  %\AtTextCenter{%
  %  \makebox[0pt]{%
    %  \scalebox{9}{%
     %   \rotatebox[origin=c]{45}{%
      %    \color[gray]{.8}\normalfont Draft}}}}}

\setlength{\parindent}{0in}



\newcommand{\client}{Town } 

\newcommand{\jobno}{xxxxx-x} 

\newcommand{\toclink}{\hyperref[toc]{Go to Contents}}

\usepackage{colortbl}
\definecolor{SEE}{rgb}{0.44,.65,.82}

\newcommand\mysection[1]{%
\clearpage
\stepcounter{section}%
\setlength{\unitlength}{1in}%
\hspace*{\fill}\begin{picture}(0,0)%
\put(0,1.3){\rotatebox{-90}{\colorbox{SEE}{\makebox(11,3)[lb]{\textcolor{white}{\LARGE \textbf{\hspace{1cm}\ifnum\value{section}>0 Section \thesection\fi\quad #1}}}}}}%
\end{picture}%
\newpage
\addtocounter{section}{-1}%
\section{#1}}

\begin{document}

%\thispagestyle{empty} %TURN OFF PAGE NUMBER FOR TOC PAGE

\tableofcontents \label{toc}

\listoftables
%\thispagestyle{empty} %TURN OFF PAGE NUMBER FOR TOC PAGE
%\thispagestyle{empty}


\pagenumbering{arabic} %TURN PAGE NUMBERING BACK ON
\fancyhf{}
\renewcommand{\headrulewidth}{0pt} %GETS RID OF LINE ABOVE SECTION TYPICAL TO FANCYHDR
\pagestyle{fancy} %CREATES SPECIAL RULE FOR PAGE NUMBERING
\fancyfoot[C]{J/N \jobno - \client O \& M Manual \hspace{27mm} \textit{\toclink} \hfill \thepage} %THE RULE - TOWN NAME SPCC ON LEFT, PAGE NUMBER ON RIGHT


\fancypagestyle{firststyle}{ \fancyhf{} \fancyfoot[C]{\client SWPPP \hfill \thepage}} %SETS FIRST PAGE AFTER TOC TO BE LIKE THE REST
%\draftwatermarkoff
%\includepdf[pages=-]{Test.pdf}
    %\draftwatermarkon



\mysection{Operation and Maintenance Manual Introduction} 

my text here    


xxx


\end{document}

原来的

在此处输入图片描述

\documentclass[hidelinks]{article}
\usepackage{multirow}
\usepackage{helvet}
\renewcommand*{\familydefault}{\sfdefault}
%\usepackage{fontspec}
%\setmainfont[Mapping=text-tex]{Calibri}
\usepackage{colortbl}
\usepackage[total={6.5in,9in},top=1.1in, left=1.05in, includefoot]{geometry} %SPECIFIES PRINTABLE AREA AND MARGINS
\usepackage{graphicx} %NEEDED FOR IMAGES
\usepackage{hyperref} %NEEDED FOR HYPERLINKS
%\hypersetup{
        %pdfborder = {0,0,0}}
\usepackage{pdfpages}
\usepackage{colortbl, xcolor, array} 
\usepackage{makecell}
\usepackage{longtable} %NEEDED FOR TABLES SPANNING MULTIPLE PAGES
\usepackage{fancyhdr} %NEEDED FOR NUMBERING PAGES ON RIGHT AND INCLUDING TOWN NAME IN FOOTER
\usepackage{wasysym}
\usepackage{rotating}
\makeatletter

\makeatother


\usepackage{geometry}
\usepackage{tikz}
\usepackage{lscape}
%\AddToShipoutPicture{%
  %\AtTextCenter{%
  %  \makebox[0pt]{%
    %  \scalebox{9}{%
     %   \rotatebox[origin=c]{45}{%
      %    \color[gray]{.8}\normalfont Draft}}}}}

\setlength{\parindent}{0in}



\newcommand{\client}{Town } 

\newcommand{\jobno}{xxxxx-x} 

\newcommand{\toclink}{\hyperref[toc]{Go to Contents}}

\usepackage{colortbl}
\definecolor{SEE}{rgb}{0.44,.65,.82}


\begin{document}

%\thispagestyle{empty} %TURN OFF PAGE NUMBER FOR TOC PAGE

\tableofcontents \label{toc}

\listoftables
%\thispagestyle{empty} %TURN OFF PAGE NUMBER FOR TOC PAGE
%\thispagestyle{empty}


\pagenumbering{arabic} %TURN PAGE NUMBERING BACK ON
\fancyhf{}
\renewcommand{\headrulewidth}{0pt} %GETS RID OF LINE ABOVE SECTION TYPICAL TO FANCYHDR
\pagestyle{fancy} %CREATES SPECIAL RULE FOR PAGE NUMBERING
\fancyfoot[C]{J/N \jobno - \client O \& M Manual \hspace{27mm} \textit{\toclink} \hfill \thepage} %THE RULE - TOWN NAME SPCC ON LEFT, PAGE NUMBER ON RIGHT
\fancyfoot[R]{\setlength{\unitlength}{1in}%
\begin{picture}(0,0)%
\put(0,10.1){\rotatebox{-90}{\colorbox{SEE}{\makebox(11,3)[lb]{\textcolor{white}{\LARGE \textbf{\hspace{1cm}\ifnum\value{section}>0 Section \thesection\fi}}}}}}%
\end{picture}}

\fancypagestyle{firststyle}{ \fancyhf{} \fancyfoot[C]{\client SWPPP \hfill \thepage}} %SETS FIRST PAGE AFTER TOC TO BE LIKE THE REST
%\draftwatermarkoff
%\includepdf[pages=-]{Test.pdf}
    %\draftwatermarkon


\newpage

\section{Operation and Maintenance Manual Introduction} 

my text here    
\newpage
\thispagestyle{empty}

xxx


\end{document}

相关内容