居中文本与散文之间的间距

居中文本与散文之间的间距

我有一些左对齐的文本,后面跟着一些居中的文本,后面跟着一段左对齐的散文。如何让左对齐文本行和居中的文本(以及居中的文本和长散文段)之间的间距等于双倍行距段落的行间距?

以下是我现在在 TeXworks 中的内容。居中文本上方和下方的空间不等于双倍行距散文行之间的空间,但我希望它等于:

\documentclass[12pt]{article}
\usepackage[margin=1in, left=1.25in, right=1.25in]{geometry}
\usepackage{fancyhdr}
\pagestyle{fancy}
\renewcommand{\headrulewidth}{0pt}
\rhead{Name \thepage}
\cfoot{}
\usepackage{setspace}
\doublespacing
\usepackage{geometry}

\begin{document}

\noindent This is My Name\\
This is Another Part\\
This is Another Part\\
This is the Date
\pagebreak[0]
\begin{center}
Title of Work
\end{center}

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla bibendum dignissim arcu, faucibus condimentum ex pulvinar a. Integer vehicula lacus quis molestie vestibulum. Quisque sed ligula in erat faucibus aliquet. Phasellus volutpat luctus nisl nec semper. 

\end{document}

答案1

像这样?

\documentclass[12pt]{article}
\usepackage[margin=1in, left=1.25in, right=1.25in,headheight=15pt]{geometry}
\usepackage{fancyhdr}
\pagestyle{fancy}
\renewcommand{\headrulewidth}{0pt}
\rhead{Name \thepage}
\cfoot{}
\usepackage{setspace}
\doublespacing
\usepackage{geometry}

\begin{document}

\noindent This is My Name\\
This is Another Part\\
This is Another Part\\
This is the Date
\pagebreak[0]

\begingroup
\centering
Title of Work\par       %% \par needed here very badly
\endgroup

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla bibendum dignissim arcu, faucibus condimentum ex pulvinar a. Integer vehicula lacus quis molestie vestibulum. Quisque sed ligula in erat faucibus aliquet. Phasellus volutpat luctus nisl nec semper.

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla bibendum dignissim arcu, faucibus condimentum ex pulvinar a. Integer vehicula lacus quis molestie vestibulum. Quisque sed ligula in erat faucibus aliquet. Phasellus volutpat luctus nisl nec semper.

\end{document}

在此处输入图片描述

相关内容