我的论文中没有标题页

我的论文中没有标题页

嗨,在此之前,我使用的是旧版本(2005)Tex。我昨天更新到最新版本Texmaker并尝试编译我的论文,但不知何故PDF生成的文件不包含我的标题页。我知道这个问题已经被问过,我也读过与我的问题相关的其他帖子,甚至尝试了编码,但标题页仍然没有出现。这是标题页的编码:

\documentclass[12pt,a4paper,twoside]{report}
\setlength{\textwidth}{16cm}
\setlength{\oddsidemargin}{0pt}
\setlength{\evensidemargin}{0pt}
\setlength{\parskip}{3mm}
\setlength{\parindent}{0mm}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\graphicspath{{images/}}
\usepackage{setspace}
%\usepackage{biblatex}
%\usepackage{url}
\usepackage{epsfig}
\usepackage{filecontents}
\usepackage{xparse,nameref}
%\usepackage{hyperref}
\usepackage{mathrsfs}
\usepackage[nokeyprefix]{refstyle}
\usepackage{mathtools}
\usepackage{thmtools}
\usepackage{enumerate}% http://ctan.org/pkg/enumerate
\usepackage{enumitem}
\usepackage{thm-restate}
\usepackage{cleveref}
\usepackage{amsmath}
\usepackage{url}
\usepackage{amsthm}
\DeclareMathOperator{\lcm}{lcm}
\DeclareMathOperator{\ord}{ord}
\usepackage{cellspace}
\setlength\cellspacetoplimit{4pt}
\setlength\cellspacebottomlimit{4pt}
\usepackage{booktabs}
\setlength\defaultaddspace{2ex}
\usepackage{graphicx}
\usepackage{array}
\usepackage{tabularx,ragged2e,booktabs,caption}
\usepackage[figuresleft]{rotating}
\usepackage{rotating}
\newcolumntype{C}{>{\Centering\arraybackslash}X}
\newcommand\swb{{\scriptstyle\Box}} % "small white box"
\usepackage{mathtools}
\usepackage{tikz}
\usetikzlibrary{positioning}
\usetikzlibrary{arrows}
\setcounter{secnumdepth}{3}
\usetikzlibrary{shapes.multipart}
\usepackage{tabu}
\usepackage{amssymb,bm}
\usepackage{framed}
\usepackage{upgreek} %use uptau greek letter
\usepackage{comment} %choose parts not to compile
\usepackage{tikz}
\tikzset{mynode/.style={fill=white,text=black,font=\tiny,inner sep=1pt}}
\usepackage[toc,page]{appendix}
\addtolength{\topmargin}{-.875in}
\newenvironment{numberlists}[1][3\parindent] %for long numberlist command
 {\begin{list}{}{%
   \leftmargin=#1\relax
   \rightmargin=\leftmargin
   \itemsep=\jot
   \parsep=0pt
   \partopsep=0pt
   \labelsep=0pt}}
 {\end{list}}
\newcommand\numlist[2]{%
  \item[]\makebox[0pt][r]{$#1=\lbrack$}%
  \begingroup
  \begingroup\lccode`~=`,\lowercase{\endgroup\def~}{\mathcomma\penalty0 }%
  \mathcode`,="8000
  \thinmuskip=6mu plus 6mu minus 2mu
  $#2\rbrack$%
  \endgroup
}
\mathchardef\mathcomma=\mathcode`, %end of numberlist command
\setlength{\oddsidemargin}{-1in}   \setlength{\evensidemargin}{-1in}
\addtolength{\oddsidemargin}{25mm}\addtolength{\evensidemargin}{20mm}
\setlength{\marginparwidth}{40pt} \setlength{\marginparsep}{10pt}
\setlength{\topmargin}{-5mm}      \setlength{\headsep}{0.5in}
\setlength{\textheight}{227mm}    \setlength{\textwidth}{165mm}
\renewcommand\floatpagefraction{0.8} %   Default = 0.5
\usepackage{listings}
\usepackage{color}
\definecolor{dkgreen}{rgb}{0,0.6,0}
\definecolor{gray}{rgb}{0.5,0.5,0.5}
\definecolor{mauve}{rgb}{0.58,0,0.82}
\lstset{
  language=Java,
  aboveskip=3mm,
  belowskip=3mm,
  showstringspaces=false,
  columns=flexible,
  basicstyle={\small\ttfamily},
  numbers=none,
  numberstyle=\tiny\color{gray},
  keywordstyle=\color{blue},
  commentstyle=\color{dkgreen},
  stringstyle=\color{mauve},
  breaklines=true,
  breakatwhitespace=true,
  tabsize=3
}
\usepackage{atbegshi}% http://ctan.org/pkg/atbegshi
\AtBeginDocument{\AtBeginShipoutNext{\AtBeginShipoutDiscard}}

\allowdisplaybreaks % allow page breaks
\begin{document}
\begin{titlepage}
\begin{center}
\includegraphics[width=0.70\textwidth]{logo} \\[2cm]

{ \large \bfseries Perfect Triangles : Rational points on Elliptic Curves }\\
Shahrina Ismail \\
\{Candidate's academic degrees\} \\[7cm]
{\em A thesis submitted for the degree of Doctor of Philosophy at\\
The University of Queensland in 2016} \\
School of Mathematics and Physics

\end{center}
\end{titlepage}

\pagenumbering{roman}

\theoremstyle{definition}

\begin{abstract}
here...
\end{abstract}

\tableofcontents

\listoffigures

\listoftables

\newpage
\pagenumbering{arabic}
\onehalfspacing
\chapter{Introduction}
\input{chapters/Introduction}

\onehalfspacing
\chapter{Background and Methodology}\label{chap:2}
\input{chapters/chapter2}


\onehalfspacing
\chapter{Values of $\delta(\mu)$}\label{chap:3}
\input{chapters/chapter3}

\end{document}

答案1

第一页无法显示的问题似乎是由于位于序言最末尾附近的以下指令引起的:

\AtBeginDocument{\AtBeginShipoutNext{\AtBeginShipoutDiscard}}

此指令的目的是什么?如果您将其注释掉(或直接删除...),则标题页材料将毫无问题地显示出来。

我忍不住要说,文档的序言很乱。很抱歉不得不这么直白,但这是无法掩盖的。有些包被加载了不止一次,有些包的加载顺序可能有问题(例如,hyperref应该cleveref在序言的末尾加载),有些包相互冲突(例如,加载enumerateenumitem但并非两者兼而有之),一些设置指令重复或冗余(例如,为什么有 3 条指令来设置 的值\oddsidemargin?),其他设置指令可以(可能应该)大大简化,并且某些指令(例如上面显示的指令)的用途是一个谜,说得客气一点。总之,您可能需要努力掌握序言。您将会遇到更少的意外,而这些意外促使您首先发布此查询。

相关内容