4
votes

I am using the Lyx document processor for LaTeX.

I need to use the Paragraph environment (because I have Subsubsubsections), and I want the paragraphs to appear in the Table of Contents.

I managed to get the Paragraph to appear in the TOC by changing the Document Settings. However, the text right after the title does NOT start in a new line.

I sort of fixed this by inserting ERT (LaTeX code) \newline.

However, now I have a problem because the page number for the paragraphs in the table of contents is also being shown on the next line! (Instead of to the right of the page, under the other page numbers.)

So how do I get the paragraph's body text to start from a new line, without affecting the TOC?

Thank you.

1
I don't think this will work without tinkering with TeX commands. What you could do is use the report class, then you have Chapter as additional level on top. Works fine for the TOC, but the chapter headings are very large in the text.vaettchen
@vaettchen I am using the report class and am in fact using Chapters.. Any other ideas? I wouldn't mind entering some TeX commands if that's what necessary, I'm just not familiar with LaTeX in general.Rachel
You'll probably find that moving this question to TeX.SX (tex.stackexchange.com) will get you a broad choice of answers.Brent.Longborough
Thanks for the suggestion @Brent.Longborough. Can I move the question myself?Rachel
I just flagged it for the moderators, asking them to move it for you.Brent.Longborough

1 Answers

8
votes

To get new lines after paragraphs, you need to re-define the paragraph command.

Go to

Document -> Settings -> Latex Preamble

and add

\renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
   {-3.25ex\@plus -1ex \@minus -.2ex}%
   {1.5ex \@plus .2ex}%
   {\normalfont\normalsize\bfseries}}

Src: http://www.latex-community.org/forum/viewtopic.php?f=5&t=1383

Modify the second and third lines to increase or decrease the space before and after the paragraph title.

For additional information about \@startsection (in case you need more tweaks) http://infohost.nmt.edu/tcc/help/pubs/nmtthesis/old/annotated/at.startsection.html