处理我的 LaTeX 项目的一些小问题。
下面我有两个非常简单的段落,其中一个出现错误,另一个则很烦人。在第一个段落中,我收到一条错误消息,提示“段落中 \hbox 未满(不良程度 10000)。我该如何解决此错误?它似乎没有影响任何东西。
其次,尽管我输入了 \hspace,但第二段仍不会缩进,因此它看起来就像没有缩进的段落。我该如何修复它?
代码如下:
\documentclass{article}
\usepackage{pgfplots}
\usepackage{tikz}
\pgfplotsset{compat=1.9}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\usepackage[margin=1in]{geometry}
\usepackage{wrapfig}
\usepackage{lipsum}
\usepackage{xcolor}
\begin{document}
\begin{titlepage}
\hspace{0pt}
\vfill
\begin{center}
\Huge{UNSPCFA Presents}\\
\vspace{1.25mm}
\normalsize{United Nations Special Phenomenon\\ Center for Attribution}\\
\footnotesize{Centre de Ph\`{e}nom\'{e}ne Sp\'{e}cial des\\ Nations Unies pour Paternit\'{e}}\\
\vspace{1.25mm}
\tiny{Copyright \copyright\hspace{1mm}2017 by UNSPCFA\\ All rights reserved for Illuminati corporation,\\ Austin, Texas}\\
\vspace{10mm}
\huge{A Study on Cyclomethylic Molecules\\ and Compounds}\\
\vspace{5mm}
\normalsize{Logan Morales}\\
\normalsize{Alex Kachkine}
\end{center}
\vfill
\hspace{0pt}
\end{titlepage}
\begin{abstract}
When one explores the world and discovers the true nature of organic chemistry and its implications, they must eventually come to terms with the idea that there is no such thing as cyclomethylic or cycloethylic molecules. Now, of course cycloethanes don't exist, because that doesn't make any sense, but traditional organic chemistry classes incorrectly posit that there is no such thing as cyclomethanes. The reality is that there are many cyclomethane molecules, and they participate in activities such as fishing, cow milking, spreading ebola, and many more family-fun activities. Cyclomethanes make up a large number of important compounds that you've probably never heard of, and are essential in many different reactions that you've also probably never heard of. According to Sauerkraut's rule, any conceivable molecule that contains one carbon atom must exist. His logic for years was taken as tomfoolery, and Sauerkraut was shunned away from the scientific community. He had to move to the east side of town instead. Eventually however and purely by coincidence, a UNSPCFA (United Nations Special Phenomenon Center for Attribution) officer dropped a sample of 3,3-diethylpentane into a bucket of whiskey, and an {\textquotedblleft}Achievement Unlocked" message appeared above his head titled {\textquotedblleft}Cyclomethane". The officer preferred to keep his name anonymous in this study in order to keep his name anonymous in this study, but he allowed the incident's data to be obtained by a source preferring to keep their name anonymous in this study. Wikileaks requested to obtain the data, but the source felt it better to allow the information to be revealed on the wiki Wikihow. After copious nights staying up past midnight assessing information from numerous Wikihow pictures, all data were obtained and recorded. In the UNSPCFA, the dedicated scientists who investigate these elusive molecules are members of an elite squad known as the Special Cyclomethyl Unit. This is their study.
\end{abstract}
\tableofcontents
\newpage
\section{Sauerkraut's Rule}
\subsection{Summary}
\hspace{5mm}In organic chemistry, Sauerkraut's rule (also known as Sourcrowt's rool) describes the existence of certain methylic molecules. In organic chemistry, a methylic molecule is a molecule containing a minimum of one carbon, and a maximum of one carbon. Typically methylic molecules contain two to four hydrogens, but they may also contain other elements like bromine, chlorine, and even iodine. Sauerkraut's full hypothesis is {\textquotedblleft}for any molecule containing one carbon that a person of average brain capacity might consider to be possible under exact conditions of the known universe, there must exist that conceived molecule in nature in some form." In modern science, most laymen and scientists alike discussing Sauerkraut's rule (especially in general conversation) abbreviate the hypothesis to {\textquotedblleft}any conceivable molecule that contains one carbon atom must exist, no matter what, even if it's a Monday".\\
\hspace{5mm}Sauerkraut's rule is easily proven by the "Sauerkraut formula" which was developed not by Sauerkraut, but his mother who wrote it on a sticky note on Sauerkraut's lunch bag before work. The formula is as follows:\\
\vspace{2.5mm}
\Large{$\lim_{x\rightarrow\kappa\pi}\int_{x-\delta}^{x (\Delta$T$\lambda^{ex})\frac{\mathrm{d} }{\mathrm{d} x}$}\\
\vspace{2.5mm}
\subsection{Context and Implications}
The rule was formulated by German chemist Wilhelm Borschtheimer Sauerkraut Jr. in 1865.
\end{document}
谢谢!
编辑:原始代码之前的所有代码现在都在这里。
答案1
我做了以下改进:
删除了手动缩进
\hbox
。LaTeX 自动缩进每个段落的第一行(除了章节第一段的第一行)。如果您确实希望每个第一段的第一行也缩进,请使用 titlesec 包进行配置。使用indentfirst
包(按照 Johannes_B 的建议)。长度\parindent
指定段落第一行的缩进距离。用空行(即段落分隔符)替换
\\
(在普通文本中为)。长度指定两个段落之间插入的垂直空间大小。默认情况下(将当前值打印到日志文件)。\newline
\parskip
0.0pt plus 1.0pt
\showthe\parskip
\usepackage[T1]{fontenc}
这样就可以从生成的 pdf 中复制像 è 这样的特殊符号,并且可以用连字符连接包含这些字符的单词。\usepackage{lmodern}
以消除 T1 fontenc 的负面影响(像素化字体和无法从生成的 pdf 中复制连字符)。根据 David Carlisle 的说法,当我使用 T1 fontenc 时,像素化字体可能是因为我没有 type1 cm 字体。所以也许你不需要这个包。使用显示数学(在这种情况下是
equation
环境,但还有更多像gather
或align
)。\enquote
使用csquotes 包定义的命令引用文本。用“.”来强调一个单词,
\emph
而不是用引号括起来。\Huge
类似和的命令\Large
执行不是接受一个论点。它们会更改该组其余部分的字体大小。请注意,应该\\
在组内,正如 egreg 指出的那样。
\documentclass{article}
\usepackage{pgfplots}
\usepackage{tikz}
\pgfplotsset{compat=1.9}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{graphicx}
\usepackage[margin=1in]{geometry}
\usepackage{wrapfig}
\usepackage{lipsum}
\usepackage{xcolor}
\usepackage{csquotes}
\usepackage{amsmath}
\usepackage{indentfirst}
\begin{document}
\begin{titlepage}
\hspace{0pt}
\vfill
\begin{center}
{\Huge UNSPCFA Presents\\}
\vspace{1.25mm}
United Nations Special Phenomenon\\ Center for Attribution\\
{\footnotesize Centre de Ph\'{e}nom\`{e}ne Sp\'{e}cial des\\ Nations Unies pour Paternit\'{e}\\}
\vspace{1.25mm}
{\tiny Copyright \copyright\hspace{1mm}2017 by UNSPCFA\\ All rights reserved for Illuminati corporation,\\ Austin, Texas\\}
\vspace{10mm}
{\huge A Study on Cyclomethylic Molecules\\ and Compounds\\}
\vspace{5mm}
Logan Morales\\
Alex Kachkine
\end{center}
\vfill
\hspace{0pt}
\end{titlepage}
\begin{abstract}
When one explores the world and discovers the true nature of organic chemistry and its implications, they must eventually come to terms with the idea that there is no such thing as cyclomethylic or cycloethylic molecules. Now, of course cycloethanes don't exist, because that doesn't make any sense, but traditional organic chemistry classes incorrectly posit that there is no such thing as cyclomethanes. The reality is that there are many cyclomethane molecules, and they participate in activities such as fishing, cow milking, spreading ebola, and many more family-fun activities. Cyclomethanes make up a large number of important compounds that you've probably never heard of, and are essential in many different reactions that you've also probably never heard of. According to Sauerkraut's rule, any conceivable molecule that contains one carbon atom must exist. His logic for years was taken as tomfoolery, and Sauerkraut was shunned away from the scientific community. He had to move to the east side of town instead. Eventually however and purely by coincidence, a UNSPCFA (United Nations Special Phenomenon Center for Attribution) officer dropped a sample of 3,3-diethylpentane into a bucket of whiskey, and an \enquote{Achievement Unlocked} message appeared above his head titled \enquote{Cyclomethane}. The officer preferred to keep his name anonymous in this study in order to keep his name anonymous in this study, but he allowed the incident's data to be obtained by a source preferring to keep their name anonymous in this study. Wikileaks requested to obtain the data, but the source felt it better to allow the information to be revealed on the wiki Wikihow. After copious nights staying up past midnight assessing information from numerous Wikihow pictures, all data were obtained and recorded. In the UNSPCFA, the dedicated scientists who investigate these elusive molecules are members of an elite squad known as the Special Cyclomethyl Unit. This is their study.
\end{abstract}
\tableofcontents
\newpage
\section{Sauerkraut's Rule}
\subsection{Summary}
In organic chemistry, Sauerkraut's rule (also known as Sourcrowt's rool) describes the existence of certain methylic molecules. In organic chemistry, a methylic molecule is a molecule containing a minimum of one carbon, and a maximum of one carbon. Typically methylic molecules contain two to four hydrogens, but they may also contain other elements like bromine, chlorine, and even iodine. Sauerkraut's full hypothesis is \enquote{for any molecule containing one carbon that a person of average brain capacity might consider to be possible under exact conditions of the known universe, there must exist that conceived molecule in nature in some form.} In modern science, most laymen and scientists alike discussing Sauerkraut's rule (especially in general conversation) abbreviate the hypothesis to \enquote{any conceivable molecule that contains one carbon atom must exist, no matter what, even if it's a Monday}.
Sauerkraut's rule is easily proven by the \emph{Sauerkraut formula} which was developed not by Sauerkraut, but his mother who wrote it on a sticky note on Sauerkraut's lunch bag before work. The formula is as follows:
\begin{equation}
\lim_{x\rightarrow\kappa\pi} \int_{x-\delta}^{x (\Delta\text{T}\lambda^{ex})\frac{\mathrm{d} }{\mathrm{d} x}}
\end{equation}
\subsection{Context and Implications}
The rule was formulated by German chemist Wilhelm Borschtheimer Sauerkraut Jr. in 1865.
\end{document}