One of the benefits of getting into a methodical mood is that little 
annoyances become intolerable. While working on the VR3 plugin, I wanted to 
compare docstrings as well as code.  In the process, the following pattern 
emerged.

1. @file viewrendered.py now starts off as follows:

'''
<< vr3 docstring >>
'''

Aha: the docstring won't be colored all green!

2. The << vr3 docstring >> node contains just:

@language rest
@wrap
@others

This is great stuff. The "interior" of the docstring is colored using 
markdown/rST.

3. Oh good. The long docstring can be split.  Here are the children of the 
<< vr3 docstring >> node.  Note that no section names are required.

- vr3 docstring: intro
- vr3 docstring: commands
- vr3 docstring: rendering rST
- vr3 docstring: rendering markdown
- vr3 docstring: special renderings
- vr3 docstring: settings
- vr3 docstring: to do
- vr3 docstring: acknowledgements

For the first time, we can see the organization of the large docstring.

*Summary*

The only drawback is that the actual external file contains sentinel lines 
separating the parts of the docstring.  In practice, it's no big deal, 
especially if each child starts with a blank line.

Splitting the docstring allowed me to carefully compare the VR and VR2 
docstrings, using a variant of the technique described earlier.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.

Reply via email to