Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I need a lower heading level than subsubsection and hence I am turning towards \paragraph. I am happy with not having it numbered but I do want it to stand on a line of it's own and be italic. I have tried the following:

\documentclass{memoir}
\usepackage{lipsum}
\begin{document}

\setparaheadstyle{\itshape}
\let\origparagraph\paragraph
\renewcommand*{\paragraph}{%
\origparagraph{#1} \\ 
}

\paragraph{Lorem ipsum}
\lipsum[1-2]

\end{document}

which sadly gives me:

! Illegal parameter number in definition of \paragraph.
<to be read again> 
                   1
l.9 }

So clearly I can't renew the \paragraph command quite in that way. How should I do it?

share|improve this question
add comment

2 Answers

up vote 6 down vote accepted
\setparaheadstyle{\normalsize\itshape}
\setafterparaskip{1ex}

Choose the value that suits you; if you want no vertical space use 1sp instead of 0pt as a positive value (even the smallest one) forces a line break.

You probably already know that to number paragraphs you have to say

\setsecnumdepth{paragraph}

which corresponds to the traditional LaTeX

\setcounter{secnumdepth}{4}

If you don't want an indented paragraph just after the title, say also

\setbeforeparaskip{-\beforeparaskip}

which suppresses the indentation, keeping the same vertical spacing before the title.

share|improve this answer
4  
or the memoir way: \setsecnumdepth{paragraph} –  daleif Nov 11 '11 at 11:48
    
And if I don't want to have an indentation directly after the headline? –  jonalv Nov 11 '11 at 12:30
add comment

For what is worth, you must indicate that you're expecting a value, so you have to write \renewcommand*\paragraph[1]{re-definition} this [1] means that you're expecting a value, which you call with #1.

See the wikibook on LaTeX for more details.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.