为给定格式创建 Latex 模板:行距和列表缩进问题

为给定格式创建 Latex 模板:行距和列表缩进问题

我正在尝试编写一个 Latex 模板,格式如下图所示。图中只给出了垂直间距,1 = 0.1 英寸。我编写了部分代码,但无法完成。我正在尝试使用空间中心标题但给出的间距超过 0.2 英寸。此外,嵌套列表未正确缩进。

在此处输入图片描述

\documentclass[12pt]{article}
% Change font to Helvetica which is same as Arial.
\usepackage{helvet}
\renewcommand{\familydefault}{\sfdefault}

% Set margin of the paper. % Set top and bottom margins
\usepackage[a4paper,
    left = 1.5in, right = 0.5in, top = 0.5in, bottom = 0.5in]{geometry}

% Define a new command
\newcommand{\CentreHeading}[1]{\begin{center} \begin{large} 
\MakeUppercase{\textbf{#1}} \end{large} \end{center}} % Space of 2 units 
below Centre Heading.
\newcommand{\SideHeading}[1]{\noindent\textbf{#1}} % Space of 2 units below 
         Side Heading.
\usepackage{titlecaps}
\newcommand{\ParaHeading}[1]{\titlecap{\textbf{#1}}}
\newcommand{\SubparaHeading}[1]{\titlecap{\textbf{#1}}}

% Define top level numbering.
\usepackage{enumitem}
\setlist[enumerate]{wide, topsep = 0mm, partopsep = 0mm, parsep = 0in, 
 itemsep = 0.16666in, labelindent = 0pt, leftmargin = 0in, labelsep = 0.5in}
 \newenvironment{mylist} { \begin{enumerate} }{ \end{enumerate} }

\begin{document}
\CentreHeading{Something for centre heading}
\SideHeading{Observations}
\begin{mylist}
    \item This is the first line of first itemize list and should be 1. Please ignore all the other text in this line. This is all garbage. 
    \item This is the second line of first itemize list and should be 2. Please ignore all the other text in this line. This is all garbage.
    \begin{mylist}
        \item This is the first line of second (nested) itemize list and should be a. Please ignore all the other text in this line. This is all garbage.
        \item This is the second line of second (nested) itemize list and should be b. Please ignore all the other text in this line. This is all garbage.
    \end{mylist}
    \item This is the third line of first itemize list and should be c. Please ignore all the other text in this line. This is all garbage.
\end{mylist}
\end{document}

答案1

\documentclass[10pt]{article}
\usepackage{times}
\usepackage{geometry}
\geometry{margin=1in}
\usepackage{enumerate}

\begin{document}

\begin{center}
{\bf{\large} CENTER HEADING}
\end{center}\\
\section{Paragraph Heading}
% You can write all the text here
\subsection{Sub Paragraph Heading}% you can replace it
% put your text here.
\subsubsection{ Sub Sub paragraph heading} % you can replace it
% enter your text here

\end{document}

%如果您想要用 代替1.1,则将其替换为%%\subsubsection*{a. Tex}。这里您不需要包。

答案2

\documentclass[10pt]{article}
\usepackage{times}
\usepackage{geometry}
\geometry{margin=1in}
\usepackage{enumerate}

\begin{document}

\begin{center}
{\bf{\large} CENTER HEADING}
\end{center}

\section{Paragraph Heading}
% You can write all the text here
 The nonlinear Schrodinger equation is a most important equation governing many physics phenomena. It has thus been studied in many previous papers. The present authors adopt a somewhat new approach  by using two different averaged complex potentials.  I think that this approach is interesting, and that the present manuscript thus deserves to be published.

\subsection{Sub Paragraph Heading}% you can replace it
% put your text here.
However, above eq. (24) which describes the Gibbon potential I think that the readers would like to see a reference, as (24) is not familiar to most readers. In addition, I suggest that the flowing minor misprints are corrected:
\subsubsection{ Sub Sub paragraph heading} % you can replace it
% enter your text here
Thanks for the  comments.  Corrections suggested  are incorporated in the revised manuscript. We have also changed the title and additional text is added. There was a sign mistake in the potential which we have corrected. Regarding the Stenflo and Gibbons potentials, the exact references are given.  The page number 1735 is corrected to 1733.
\section*{(2) Paragraph heading}

We agree that many may not know the potential form therefore we have added exact location of references for these two potentials.
\begin{center}
Something for center heading
\end{center}
\section*{Observations}
\section*{First list}
\begin{enumerate}
    \item This is the first line of first itemize list and should be 1. Please ignore all the other text in this line. This is all garbage. 
    \item This is the second line of first itemize list and should be 2. Please ignore all the other text in this line. This is all garbage.
\end{enumerate}  
\section*{Second  
    \begin{enumerate}
        \item This is the first line of second (nested) itemize list and should be a. Please ignore all the other text in this line. This is all garbage.
        \item This is the second line of second (nested) itemize list and should be b. Please ignore all the other text in this line. This is all garbage.
    \end{enumerate}
    \begin{enumerate}
    \item This is the third line of first itemize list and should be c. Please ignore all the other text in this line. This is all garbage.
\end{enumerate}
\end{document}

这是一份简单的文档。我在其中添加了文本,您可以删除它。您不需要额外的编码。最后我添加了星号作为示例。请测试一下。

相关内容