|
From: Aahz <aa...@py...> - 2002-08-04 20:26:03
|
On Sun, Aug 04, 2002, David Goodger wrote: > Aahz wrote: >> >> Now, how do I add a new directive? (For index tags.) > > Take a look at docutils/parsers/rst/directives/images.py for relevant > examples. If you could show us some concrete examples of what you want, it > would be easier to advise. After a quick skim of images.py: So, in other words, in order to add a new directive, I'm going to have to understand how the state machine works? > In the index, combined with other entries, it might look like this:: > > statement syntax > expression statements ..... 56 > assignment ................ 57 > simple statements ......... 58 > compound statements ....... 60 Note that currently I don't care about reST generating the actual index; I'm only interested in emitting index tags for OpenOffice. That goes double because OpenOffice will be converted to Word and thence to Frame before the index gets generated. (Yes, I'm ignoring your questions about requirements for now; I'm more interested in hacking up something which gives minimal results.) -- Aahz (aa...@py...) <*> http://www.pythoncraft.com/ Project Vote Smart: http://www.vote-smart.org/ |