nested lists, xml example dtd? anyone?

Richard Light richard at
Tue Jan 13 09:51:48 GMT 1998

In message <34BB1CE9.FBFDDCCD at>, Glenn R Kronschnabl
<grk at> writes
>Can someone pls e-mail me an example XML
>dtd that has nested lists?  I have a simple dtd
>that I am trying to use, but I keep getting an extra
>newline (or 2) after a (nested) list using jade (rtf).  I would like
>something as simple as:
>  <item>item1</item>
>  <item>item2</item>
>  <item>
>       <list>
>           <item>item1</item>
>           <item>item2</item>
>       </list>
>   </item>
>  <item>item3</item>
>This appears in rtf (but also shows up as extra paragraphs
>in the fot and in nsgmls) as:
>* item1
>* item2
>   * item1
>   * item2
>   <extra newline>
>* item3
><extra newline>

If Jade is outputting extra paragraphs, it is because you have asked it
to, not because of spaces or newlines in the document itself.  

I would guess that the extra 'newlines' (paragraphs) are probably
appearing because you have <item> within <item>.  If you simply put:

(element item
  (make paragraph

then each <item> will produce a paragraph flow object, and you are
effectively asking Jade to produce nested paragraphs.  Of course, RTF,
having a pretty flat model for the document, can't do that, and probably
generates an extra paragraph instead.

>when I put this thru jade without a DTD, I get a whole
>lotta extra space and newlines.  With docbook3 and
>itemizedlists, there is no extra whitespace.  So, I assume
>that a proper DTD is the way to slurp up the unwanted
>whitespace.  Correct?

If you use (process-children-trim) rather than (process-children), a
DSSSL engine will chuck out all leading and trailing space from each
element - this might allow you need to deal with your well-formed input
'as is', rather than having to write a DTD.

Do you know there is a DSSSL list (dssslist at

Hope this helps,

Richard Light.

Richard Light
SGML/XML and Museum Information Consultancy
richard at

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at
Archived as:
To (un)subscribe, mailto:majordomo at the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at

More information about the Xml-dev mailing list