我尝试在报告中输入第二部分并将其置于中心,但每当我将其置于中心时,总会缺少一些东西。
\documentclass[12pt, a4paper]{report}
\usepackage[margin=1in]{geometry}
\usepackage{amsmath, amssymb, amsfonts}
\usepackage{fancyhdr}
\usepackage{hyphenat}
\pagestyle{fancy}
\fancyhead{}
\fancyfoot{}
\fancyhead[R]{Enzymatic Synthesis of Emollient Esters}
\fancyfoot[R]{\thepage}
\fancyfoot[L]{Dept. of Chemical Eng., SCOE}
\renewcommand{\headrulewidth}{0pt}
\usepackage{mathptmx}
\usepackage{graphicx}
\usepackage{float}
\parindent 0ex
\setlength{\parskip}{1em}
\renewcommand{\baselinestretch}{1.5}
\begin{document}
\begin{center}
\section{ \textbf{ INTRODUCTION}}
\end{center}
\begin{center}
\section{LITERATURE STUDY}\
\end{center}
\end{document}
答案1
简单来说titlesec
:
\documentclass[12pt, a4paper]{report}
\usepackage[margin=1in]{geometry}
\usepackage{amsmath, amssymb, amsfonts}
\usepackage{fancyhdr}
\usepackage{hyphenat}
\pagestyle{fancy}
\fancyhead{}
\fancyfoot{}
\fancyhead[R]{Enzymatic Synthesis of Emollient Esters}
\fancyfoot[R]{\thepage}
\fancyfoot[L]{Dept. of Chemical Eng., SCOE}
\renewcommand{\headrulewidth}{0pt}
\usepackage{mathptmx}
\usepackage{graphicx}
\usepackage{float}
\parindent 0ex
\setlength{\parskip}{1em}
\renewcommand{\baselinestretch}{1.5}
\usepackage[center]{titlesec}
\usepackage{lipsum}
\begin{document}
\chapter{SOME CHAPTER}
\lipsum[1]
\section{INTRODUCTION}
\lipsum[2-4]
\section{LITERATURE STUDY}
\lipsum[5-7]
\end{document}