[Doc-SIG] controlling sections levels

David Goodger goodger@users.sourceforge.net
Wed, 30 Oct 2002 08:19:13 -0500


Albert Ting wrote:
> How does one control the number of html levels to output?  html.py defaults
> to 6, but if I use the core.publish_string() function, I'm only getting 3.

It depends on how many levels of sections you have in your document.  You'll
need 6 section levels, plus document title (and maybe subtitle) to get all
the way to H6.  See http://docutils.sf.net/FAQ.html#html-writer .

> Also, is there a way to auto number the titles/chapters/sections?

See 
http://docutils.sf.net/spec/rst/directives.html#automatic-section-numbering

-- 
David Goodger  <goodger@users.sourceforge.net>  Open-source projects:
  - Python Docutils: http://docutils.sourceforge.net/
    (includes reStructuredText: http://docutils.sf.net/rst.html)
  - The Go Tools Project: http://gotools.sourceforge.net/