Just want to point out that HTMLplus's content model could be further
simplified.
Definitions like these in the DTD:
<!ELEMENT LI - O (P|%text;)+>
<!ELEMENT DD - O (P|QUOTE|UL|OL|%text;)+ -- definition text -- >
are convenient because the presence of "%text;" lets one, for example,
start a list item without requiring a <P>. Like this:
<UL>
<LI> alfalfa <P> basil
</UL>
This is great back when <P> was a separator. But now that <P> is
a container in HTMLplus, this becomes kinda messy (IMHO), because
it allows one to write this (does not require <P> for first text):
<UL>
<LI> alfalfa <P>basil</P> clover
</UL>
which maps to this ESIS (what SGML parsers generate):
(UL
(LI
-alfalfa
(P
-basil
)P
-clover
)LI
)UL
I think this is a bit "messy" because I think <LI> should just be a
container of other containers. A bit pedantic, debatable, and may not
be a good thing for HTML backward compatibility concerns... But I'd
suggest that perhaps such container definitions should be simplified.
In case of <LI>, to:
<!ELEMENT LI - O (P)+>
In this simpler definition one would *have* to write the SGML this way:
<UL>
<LI> <P>alfalfa <P>basil <P>clover
</UL>
And the ESIS would have to look more regular:
(UL
(LI
(P
-alfalfa
)P
(P
-basil
)P
(P
-clover
)P
)LI
)UL
In other DTDs that I've checked out (DTDs in SGML books, DocBook, CALS
(from what I heard), and other random DTDs), the simpler content model
is used.
As browser implementor I can deal with either DTD models, but I prefer
the simpler model. As simple filter/translation program implementor, I
would really prefer the simpler model. As document writer I might perfer
the currently more complex DTD model (or "simpler" from user's POV)
because it saves me a few key strokes, and because it looks like the
original HTML.
Just thought I bring this up before HTMLplus gets cast in concrete.
-Pei Pei Y. Wei
O'Reilly & Associates
[email protected]