我正在準備論文的第一頁,我希望它如下所示:
Title
Doctoral
2017
Approved by:
因此,我希望所有這些都居中,但只調整“2017”和“批准者”。我嘗試過以下方法,但沒有成功:
\documentclass[12pt]{article}
\begin{document}
\pagenumbering{gobble}
\indent
\begin{center}
\textbf {\large { ESSAYS ON STRATEGIC MANAGEMENT}} \\
\indent by \\
\textbf {\large {\indent JOHN DOE \\
\indent DISSERTATION}} \\
\indent Submitted to the Graduate School \\
\indent of X State University, \\
\indent USA \\
\indent in partial fulfillment of the requirements \\
\indent for the degree of \\
\textbf {\large {\indent DOCTOR OF PHILOSOPHY }} \\
\indent 2017
\end{center}
\begin{multicols}{2}
\vfill\null
\columnbreak
\indent
\small{MAJOR: STRATEGIC MANAGEMENT \\
\indent
Approved By: \vspace{2mm}\\
\indent\rule{8cm}{0.4pt}
\indent Advisor \hspace{50mm} Date} \vspace{4mm}
\indent\rule{8cm}{0.4pt} \\
\indent\rule{8cm}{0.4pt} \\
\indent\rule{8cm}{0.4pt} \\
\indent\rule{8cm}{0.4pt}
\end{multicols}
\end{document}
你能告訴我如何解決這個問題嗎?
答案1
我對你可能想要什麼以及如何實現它有另一個想法。根據我的理解,您希望 2017 年正常居中,但您希望下一行與居中的 2017 年左對齊。
您可以將內容設定\makebox
為您想要正確居中的行的寬度(在本例中為 2017):
\documentclass[12pt]{article}
\begin{document}
\begin{titlepage}
\centering
{\huge Title}\par
\vspace{1cm} % change this to your liking!
{\Large Doctoral}\par
\vspace{1cm} % change this to your liking!
2017\\%
\setbox0\hbox{2017}% this sets a box with content 2017, you can access its width with \wd0
\makebox[\wd0][l]{Approved by: Prof. C. Xavier}
\end{titlepage}
\end{document}
答案2
您可以使用tabular
居中環境內部的環境:
\documentclass[]{report}
\begin{document}
\begin{titlepage}
\centering
{\huge Title}\par
\vspace{1cm} % change this to your liking!
{\Large Doctoral}\par
\vspace{1cm} % change this to your liking!
\begin{tabular}[t]{@{}l@{}}
2017\\
Approved by:
\end{tabular}
\end{titlepage}
\end{document}
但你確定你想要這樣嗎?與名稱一起,空格看起來有點奇怪: