[texhax] LaTeX: Automatic \noindent after list

Ross Moore ross at ics.mq.edu.au
Thu May 22 13:14:45 CEST 2003



On Thu, 22 May 2003, Wolfgang Plaschg wrote:

> But when you type...
>
> %LaTeX-Code Start
> \begin{itemiz}
> \item this
> \item that
> \end{itemize}
>
> This line shouldn't be indented, but it is...
> %LaTeX-Code End
>
> ...you'll get an indented paragraph.
> Im very impressed how the \chapter{..}
> command produces no-indented paragraphs
> and wonder if i could program something
> similar, which i couldn't.
>
> What's the magic?

\ignorespaces

This command must occur as the *last* token in the expansion of the
macro occurring before the appropriate place in your text stream.

e.g.  you could try a hack, something like (in the preamble):

\let\realenditemize\enditemize
\renewcommand{\enditemize}{\realenditemize\ignorespaces}


Hope this helps,

	Ross Moore




More information about the texhax mailing list