[texhax] Line spacing of \section{} elements

E. Krishnan ekmath at asianetindia.com
Sat Aug 27 06:19:22 CEST 2005


On Fri, 26 Aug 2005, Don MacQueen wrote:

> In a document that starts with
>       \documentclass[11pt,landscape,legalpaper]{article}
> I am using \section{} and \subsection{}.
> I would like to let them have normal vertical spacing, 
> the same as regular text in the document has. Or, more accurately, 
> I'd like them to use the same parskip as the rest of the document 


Include these line in your preamble:

 \makeatletter
\renewcommand{\section}{%
    \@startsection%
    {section}{1}{0pt}{0pt}{0.001pt}{\Large\bfseries}}
\renewcommand{\subsection}{%
    \@startsection%
    {subsection}{2}{0pt}{0pt}{0.001pt}{\Large\bfseries}}
\makeatother

This will make the \section and \subsection leave the usual \parskip 
*before* the heading, but leave a vertical space 0.001 point more than 
the usual \parskip *after* the heading. But that doesn't matter, does it?

Problem is, if we set the second skip to 0, we get a run-in heading.
-- 
Krishnan



More information about the texhax mailing list