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.

How could I get subsections, subsubsections, paragraphs, and subparagraphs (which I'll call "sections" from now on) that look like the one in this PDF file ?

In this PDF example, the indentation between one level of section and the next is too much, but the important point I would like to keep is that the name of the section (actually only its numbering) is detached to the left and the section content consists of one block to the right.

I guess there are some minipages involved, but i'm not sure how to use them to get the right result.

Thanks in advance !

share|improve this question
3  
Welcome to TeX.SE! This can probably be done using the titlesec package; something that sounds quite similar: How can I align section titles and list environments in the left margin? –  cmhughes Dec 20 '12 at 23:08
    
This looks like one giant iterated enumerate environment. You can certainly use enumitem to get the spacings and the numbering as desired. And probably also the decoration of the first level titles. –  jfbu Dec 21 '12 at 14:25
    
... however the table of contents will then need to be created in some other way. –  jfbu Dec 21 '12 at 14:27
    
I've read the whole doc of titlesec, and apparently nothing seems to be able to do what i want... (since i'm a latex beginner, it's fairly likely that i missed something obvious). In the topic you mentionned, @cmhughes the use of \llap is a good idea, so the only thing i now need is the capability to indent a whole paragraph and not only its first line. –  Silverspur Dec 21 '12 at 14:58
    
@jfbu , maybe i could do this with a giant enum, but i have a whole bunch of \label + \ref throughout the document and i don't know at all how to have a reference to an enum item (with the corresponding numbering). –  Silverspur Dec 21 '12 at 14:59

1 Answer 1

Using enumitem will get you some way towards your goal. One would have to add some extra coding to get automatically a TOC though.

\documentclass[12pt]{article}
\usepackage{enumitem}
\newlist{legal}{enumerate}{10}
\setlist[legal]{label*=\arabic*.}
\begin{document}

\begin{legal}
\item Rule 1
  \begin{legal}
  \item Subrule
    \begin{legal}
      \item a
      \item \label{hello}b
      \item c
    \end{legal}
  \item Subrule 
    \begin{legal}
      \item a
      \item b
      \item \label{world}c
    \end{legal}
  \end{legal}
\item Rule 2
  \begin{legal}
  \item Subrule
    \begin{legal}
      \item a
      \item b
      \item c
    \end{legal}
  \item Subrule 
    \begin{legal}
      \item a
      \item b
      \item c
    \end{legal}
  \end{legal}
\end{legal}

the hello label has number \ref{hello}

the world label has number \ref{world}
\end{document}

legal list

share|improve this answer

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.