I have a document which requires many levels of sectioning. I have sections, subsections and subsubsections, but require one more level below that. I can't change the sections to be parts and move everything up a level, as this document will eventually be included in another document which has parts/chapters already.
I see that the \paragraph
command is used for defining the section level below subsubsection, but that doesn't produce headings in the same way that subsection and subsubsection do. Is there any way to either (1) change the \paragraph
command so that it works like subsubsection but just adds another number – ie. 1.2.3.4 or (2) create a \subsubsubsection
command to do the same thing?
Best Answer
You can use the
titlesec
package to change the way\paragraph
formats the titles and set thesecnumdepth
counter to four to obtain numbering for the paragraphs:If you want to define a new sectioning command, you can take a look at Defining custom sectioning commands.
If you want to define a fresh new sectional unit below
\subsubsection
, but above\paragraph
, then you will have to do considerably more work: a new counter has to be created and its representation has to be appropriately defined; the sectional units\paragraph
and\subparagraph
will also have to be redefined, as well as they corresponding\l@...
commands (controlling how the will be typeset in the ToC if thetocdepth
value is increased); also, the toclevel (for eventual bookmarks) will have to be considered.Here's an example showing how to obtain this new sectional unit giving you now the option to use
\part
,\section
,\subsection
,\subsubsection
,\subsubsubsection
,\paragraph
, and\subparagraph
: