From: David A. <da...@bo...> - 2002-12-16 23:18:53
|
When I format the following as HTML with the current CVS --- * User Guided wrapping * Require minimal user intervention * But intervention must be possible when needed --- It looks like: --- * User Guided wrapping * Require minimal user intervention * But intervention must be possible when needed --- Is that to be expected? Why the CR after the initial bullet? The command I used was: python /src/docutils/tools/html.py --embed-stylesheet -gdts fu.txt fu.html Thanks, -- David Abrahams da...@bo... * http://www.boost-consulting.com Boost support, enhancements, training, and commercial distribution |
From: David G. <go...@py...> - 2002-12-17 02:55:16
|
David Abrahams wrote: > When I format the following as HTML with the current CVS > > --- > * User Guided wrapping > * Require minimal user intervention > * But intervention must be possible when needed > --- > > It looks like: > > --- > * > User Guided wrapping > * Require minimal user intervention > * But intervention must be possible when needed > --- > > Is that to be expected? Pretty much. The indentation of nested lists is critical. It's informative to see how the parser interprets this input. I use the command:: python tools/quicktest.py And feed the above as input to stdin, this is what comes out (wrapped a bit):: <document source="<stdin>"> <bullet_list bullet="*"> <list_item> <definition_list> <definition_list_item> <term> User Guided wrapping <definition> <bullet_list bullet="*"> <list_item> <paragraph> Require minimal user intervention <list_item> <paragraph> But intervention must be possible when needed You've got a bullet list item containing a definition list item containing a bullet list in the definition. Reduce the indentation of lines 2 & 3 by one space each and I think you'll get what you want. > Why the CR after the initial bullet? That I can't tell you. What browser? What stylesheet? > The command I used was: > > python /src/docutils/tools/html.py --embed-stylesheet -gdts \ > fu.txt fu.html Was the stylesheet successfully embedded? Please check. -- David Goodger <go...@py...> 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/ |
From: David A. <da...@bo...> - 2002-12-17 04:21:38
|
David Goodger <go...@py...> writes: > David Abrahams wrote: >> When I format the following as HTML with the current CVS >> >> --- >> * User Guided wrapping >> * Require minimal user intervention >> * But intervention must be possible when needed >> --- >> >> It looks like: >> >> --- >> * >> User Guided wrapping >> * Require minimal user intervention >> * But intervention must be possible when needed >> --- >> >> Is that to be expected? > > Pretty much. The indentation of nested lists is critical. It's informative > to see how the parser interprets this input. I use the command:: > > python tools/quicktest.py > > And feed the above as input to stdin, this is what comes out > (wrapped a bit):: > > <document source="<stdin>"> > <bullet_list bullet="*"> > <list_item> > <definition_list> > <definition_list_item> > <term> > User Guided wrapping > <definition> > <bullet_list bullet="*"> > <list_item> > <paragraph> > Require minimal user > intervention > <list_item> > <paragraph> > But intervention must be > possible when needed > > You've got a bullet list item containing a definition list item > containing a bullet list in the definition. Reduce the indentation of > lines 2 & 3 by one space each and I think you'll get what you want. Ouch, that didn't work: quicktest.py results: <document source="<stdin>"> <bullet_list bullet="*"> <list_item> <paragraph> User Guided wrapping * Require minimal user intervention * But intervention must be possible when needed -- HTML snippet: <div class="document"> <ul class="simple"> <li>User Guided wrapping * Require minimal user intervention * But intervention must be possible when needed</li> </ul> </div> >> Why the CR after the initial bullet? > > That I can't tell you. What browser? IE6 > What stylesheet? The one from your tools/ subdirectory >> The command I used was: >> >> python /src/docutils/tools/html.py --embed-stylesheet -gdts \ >> fu.txt fu.html > > Was the stylesheet successfully embedded? Please check. Yup. -- David Abrahams da...@bo... * http://www.boost-consulting.com Boost support, enhancements, training, and commercial distribution |
From: David G. <go...@py...> - 2002-12-17 05:03:22
|
David Abrahams wrote: > Ouch, that didn't work: Forgot to mention that the nested list requires a blank line before & after. Only blank lines between items are optional. If you haven't read the Primer, please do: <http://docutils.sf.net/docs/rst/quickstart.html#lists>. If you have read it, maybe you should read it again. ;) -- David Goodger <go...@py...> 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/ |
From: Beni C. <cb...@te...> - 2002-12-17 13:00:06
|
On 2002-12-16, David Goodger wrote: > <document source="<stdin>"> > <bullet_list bullet="*"> > Never thought that the bullet is recorded of the DOM. doctree.html confirms that and notes that it may be ignored in processing. What's the implication? Is it ignored currently? Will it? Are there any guidelines in choosing bullets when writing rST? -- Beni Cherniavsky <cb...@tx...> |
From: David G. <go...@py...> - 2002-12-18 00:55:50
|
Beni Cherniavsky wrote: >> <document source="<stdin>"> >> <bullet_list bullet="*"> > > Never thought that the bullet is recorded of the DOM. doctree.html > confirms that and notes that it may be ignored in processing. > What's the implication? It's just stored there to help round-trip conversion. From PEP 258: The DTD retains all information necessary to reconstruct the original input text, or a reasonable facsimile thereof. > Is it ignored currently? Yes. I don't think it's used for anything now. > Will it? It may be used for text-output Writers, such as the one Stephan Diebel reported on here a few days ago. > Are there any guidelines in choosing bullets when writing rST? Not really. I like * for first-level, and - for lower levels. But that's just me. -- David Goodger <go...@py...> 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/ |