我无法修复文档中的重叠文本。我不确定如何添加空格(以及是否应该这样做)。将章节和节标题放在不同的页面(例如奇数页和偶数页)是个好主意,但我不知道该怎么做。
最后的图像显示了这个问题。
这平均能量损失重现我在图像中上传的内容:
\documentclass[12pt,twoside]{report}
\usepackage[headheight=18pt,a4paper, width=150mm, top=25mm, bottom=25mm, bindingoffset=6mm, headsep=18pt]{geometry}
\usepackage[spanish]{babel}
\usepackage[utf8]{inputenc}
\usepackage[activate={true,nocompatibility},final,tracking=true,kerning=true,spacing=true,factor=1100,stretch=10,shrink=10]{microtype}
\usepackage{fancyhdr}
\pagestyle{fancy}
\setlength\parskip{1em plus 10pt}
\renewcommand{\headrulewidth}{0.4pt}
\renewcommand{\footrulewidth}{0.4pt}
\emergencystretch=1em
\usepackage{titlesec}
\titleformat{\section}
{\normalfont\Large\bfseries}{\thesection}{1em}{}
\titlespacing{\chapter}{0pt}{50pt}{0pt}
\titlespacing{\section}{0pt}{50pt}{1.3ex plus .2ex}
\begin{document}
\chapter{Estado del arte}
foo
\section{Consideraciones termodinámica}
foo
foo
foo
foo
foo
foo
foo
foo
foo
foo
foo
foo
foo
foo
foo
fo
fo
fo
fi+
fo
fo
\end{document}
答案1
这里是新页面样式的代码,使用titlesec
带有选项的工具pagestyles
来代替fancyhdr
:
\documentclass[12pt,twoside, spanish]{report}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[headheight=18pt, a4paper, width=150mm, top=25mm, bottom=25mm, bindingoffset=6mm, headsep=18pt]{geometry}
\usepackage{babel}
\usepackage[activate={true,nocompatibility},final,tracking=true,kerning=true,spacing=true,factor=1100,stretch=10,shrink=10]{microtype}
\usepackage{lipsum}
\usepackage[pagestyles]{titlesec}
\titleformat{\section}
{\normalfont\Large\bfseries}{\thesection}{1em}{}
\titlespacing{\chapter}{0pt}{50pt}{0pt}
\titlespacing{\section}{0pt}{50pt}{1.3ex plus .2ex}
\newpagestyle{mystyle}{%
\headrule\footrule
\sethead[\small\itshape\thesection.\enspace\MakeUppercase{\sectiontitle}][][]{}{\small\itshape\MakeUppercase{\chaptername~\thechapter.\enspace \chaptertitle}}{}
\setfoot{}{\thepage}{}
}
\pagestyle{mystyle}
\begin{document}
\chapter{Estado del arte}
\lipsum[1]
\section{Consideraciones termodinámica}
\lipsum[2-12]
\end{document}