Hi folks,
if one were to say, think of writing something like a book (or a
paper) using sphinx and plots generated from python scripts, the plot
directive would be extremely useful. But as best as I can tell, it
generates at the end of the day 'image' directives, where as for
including figures in latex-produced PDF with captions and labels one
can later refer to, the plain sphinx 'figure' directive appears to be
more appropriate. As we can read here:
http://docutils.sourceforge.net/docs/ref/rst/directives.html#images
Their signatures are:
Image
Directive Type: "image"
Doctree Element: image
Directive Arguments: One, required (image URI).
Directive Options: Possible.
Directive Content: None.
Figure
Directive Type: "figure"
Doctree Elements: figure, image, caption, legend
Directive Arguments: One, required (image URI).
Directive Options: Possible.
Directive Content: Interpreted as the figure caption and an optional legend.
A key difference is that image takes no content, while figure accepts
content and uses it for the figure caption.
Would it be possible/sensible to switch the plot directive to be a
superset of 'figure' instead of 'image'?
Before I dive into the code too far, I figured I'd ask the experts.
Thanks!
f