对于论文,需要两个标题页,但在我的代码中页面布局不一致。问题出在页面底部。代码部分是:它是 cls 文件。
更新:问题出在\newenvironment
命令上。当我只留下 1 页时,一切正常。当我尝试制作 2 页或更多页时,第一页正常,但其余页面则不行。顶部边距正常,但底部边距不好(
\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{minimovka}[2000/07/21 v1.0 final disser class]
\LoadClass[a4paper]{report}
\RequirePackage{ifthen}
%\RequirePackage{fancy}
%\input{defs.tex}
%\pagestyle{fancy}
%\LoadClass{caption2}
\renewcommand{\normalsize}{\fontsize{12}{18}\selectfont}
\setlength{\topmargin}{-0.62in}
\setlength{\oddsidemargin}{0.38in}
\setlength{\evensidemargin}{0.38in}
\setlength{\headheight}{0.4in}
\setlength{\headsep}{0.2in}
\setlength{\footskip}{0.4in}
\setlength{\textwidth}{5.98in} \setlength{\textheight}{9.37in}
\setlength{\parindent}{0.4in}
\newcommand{\affiliation}[2]{\newcommand{\@affiliation}
{\fontsize{16}{19}\begin{center}\bf #1\\ \bf #2\end{center}}}
%\newcommand{\UDK}[1]{\newcommand{\@UDK}{UDK #1}}
%\newcommand{\CODESPEC}[2]{\newcommand{\@CODESPEC}{#1\,-\,#2}}
\newcommand{\Distitle}[1]{\newcommand{\@Distitle}
{\fontsize{14}{14}\begin{center}\bf #1 \end{center}}}
\newcommand{\Subdistitle}[1]{\newcommand{\@Subdistitle}
{\fontsize{12}{12}\begin{center} #1 \end{center}}}
%{\fontsize{14}{28}\begin{center}\bf #1\end{center}}}
\newcommand{\Year}[1]{\newcommand{\@Year}
{\fontsize{12}{12} \bf #1}}
\newcommand{\Disauthor}[1]{\newcommand{\@Disauthor}
{\fontsize{12}{12} \bf #1}}
\newcommand{\Studprogram}[1]{\newcommand{\@Studprogram}
{ #1}}
\newcommand{\Studspec}[1]{\newcommand{\@Studspec}
{ #1}}
\newcommand{\Chair}[1]{\newcommand{\@Chair}
{ #1}}
\newcommand{\Supervisor}[1]{\newcommand{\@Supervisor}
{ #1}}
\newcommand{\Consulter}[1]{\newcommand{\@Consulter}
{ #1}}
\newcommand{\City}[1]{\newcommand{\@City}
{\fontsize{12}{12} \bf #1}}
\newenvironment{front}
{\pagestyle{fancy}\fancyhf{}
\renewcommand{\headrulewidth}{0.0pt}
\renewcommand{\footrulewidth}{0.0pt}
\setlength{\topmargin}{-0.21in}
\setlength\evensidemargin{-0.21in}
\setlength\oddsidemargin{-0.21in}
\setlength{\textheight}{10.68in}
\setlength{\textwidth}{6.8in}
\setlength{\headheight}{0.0in}
\setlength{\headsep}{0.0in}
\setlength{\topskip}{0.0in}
\setlength{\footskip}{0.0in}
\setlength{\parskip}{0.0in}
}
%defines title page layout
\renewcommand{\maketitle}
{%
\begin{front}
%\normalsize
\@affiliation
\vspace{2in}
\@Distitle
\vspace{1in}
\@Subdistitle
\vfill
\begin{flushleft}
\@Year\\ \@Disauthor
\end{flushleft}
%second page
\newpage
\@affiliation
\vspace{1.5in}
\@Distitle
\vspace{1in}
{\bf \@Subdistitle}
\vspace{1in}
{\fontsize {11}{17}
\begin{flushleft}
\begin{tabular}{l l}
Studied program: & \@Studprogram\\
Studied specialization: & \@Studspec\\
Chair: & \@Chair\\
Scientific supervisor: & \@Supervisor\\
Consulter: & \@Consulter\\
\end{tabular}
\end{flushleft}
}
\vfill
\begin{flushleft}
\@City, \@Year\\ \@Disauthor
\end{flushleft}
\pagebreak
\end{front}}
答案1
好的,伙计们。这个问题是通过使用/package{geometry}
\usepackage[a4paper]{geometry}
\geometry{width = 5.91in, height = 9.33in, left = 1.38in, top = 0.98in}
%\def\newcommand\mygeometry{\newgeometry{width = 6in, height = 6in, left = 1.29in, top = 0.99in}}
\newenvironment{front}
{%---title page layouts
\newgeometry{width = 6.69in, height = 10.68in, left = 0.79in, top = 0.79in}
}
{\newgeometry{width = 5.91in, height = 9.33in, left = 1.38in, top = 0.98in}}
\newcommand{\makesecondtitle}
{
\begin{front}1st title page \pagebreak second page
\end{front}
}