Context Selectors and SGML

This sort of came to my mind this moring.

CSS allows context distinctinos such as

UL UL LI
P B I
...

I find it kind of interesting that CSS let's one distinguish 
presentation based on this type of context model and that SGML itself 
doesn't make any distinction above a single level of context -- ie:
UL UL LI
is treated the same as:
UL LI
and
P OL UL UL UL UL LI

It's only the browsers display that has added this extra meaning.

Now I suppose this could have gone to the html list as well, but are 
there any markup languages that truly distinguish content based on 
context -- this would help solve problems like <INPUT> outside of a 
<FORM>.

It'd also sort of allow things such as:
Property: display
Value: variant
Where it's variant such that if an inline element is allowed then 
it's inline, otherwise it's block-level.

This would provide a better quoting mechanism, consider:

<P>And then Bert said <Q>Inline quoting would be good</Q>, but Chris 
was quick to retort:</P>

<!-- note we're at block-level now-->

<Q>I can't image the headache that would give to the browser 
implementators!</Q>

__
| Mortar: Advanced Web Development <http://bigpic.com/mortar/>
| Neil St.Laurent  neil@bigpic.com
| Big Picture Multimedia

Received on Monday, 18 August 1997 08:07:17 UTC