对齐章节编号和多行章节标题

对齐章节编号和多行章节标题

我有很长的部分标题,乳胶将它们渲染成这样

21. Very very very very very very
    very very very very very very
    very very very very very very
    Long section title example

This is the text below title.

但我想在渲染它们时不考虑左边的数字偏移,就像这样:

21. Very very very very very very
very very very very very very
very very very very very very
Long section title example

This is the text below title.

我该怎么做?谢谢!

梅威瑟:

\documentclass{report}

\begin{document}
\section{Very very very very very very
 very very very very very
 very very very very very
 section title example}
\end{document}

答案1

您可以借助该sectsty软件包实现您的排版目标。

在此处输入图片描述

\documentclass{report}
\usepackage{sectsty}
\sectionfont{\parindent0pt\nohang\raggedright}

\begin{document}
\setcounter{chapter}{2} % just for this example

\section{An example of a very very very very very very
    very very very very very very
    very very very very very very
    long section title}

This is some text below the section header.

This is some more text below the section header.
\end{document}

相关内容