Re: CSS-Tranformation mechanism and modularizing CSS

> Of course, Bert failed to mention XSL, which is quite similar to the
> XML-ized version of your idea:  http://www.w3.org/Style/XSL/

Ehm, no. I have to disagree with this.

- CSS and XSL have 2 ways of transforming a document, 
which are almost complementairy:
XSLT generates really transforms one XML document into
another. The most usefull way is to generate a structured 
and readable document from a (dull and unordered) data source.
It is therefore more complicated (less straight forward)
and *static*. It is also a lot more powerfull.
CSS is dynamic, and very straight forward because it
just adds properties of elements in an already nicely
structured document.

- XML is just a form of defining structured data, 
and does not imply some kind of functionality to
it's content.

It's therefore *very wrong* to say that an XML version
of (whatever kind of) CSS is similar to XSL. 


I think an XML version of CSS is still very attractive.
Because extending CSS has over time introduced a lot of
characters with a special meaning, which is starting to
be confusing. An XML version of CSS will need less
special characters, because of it's natural way of
defining structure. (To make my XML version a bit less
radical, I kept the CSS-selector-style, and in doing
so even introduced a new special character. That was
obviously not the best way to XML-ize CSS)


I also want to mention something more about dynamic vs.
static transformation: CSS (and my suggestions) are
dynamic, where XSL and STTS are static.

XSL and STTS have to be static, because they
generate a new document tree. They also have limits
in XML, because the results need to conform to an
DTD or Schema.

CSS is dynamic, because it adds attributes (or better:
properties) to elements on the fly. It does not alter
the document tree. (That's why the DOM adds all the
CSS properties not directly to an element, but to the
style property of an element.)

This makes CSS a lot more valuable for the web,
because everybody loves mouseovers etc., and nobody 
cares about DTD's or Schema's (definately not the 
people with an artistic background).

CSS has a 'loose' binding of the properties to elements.
So if we want to make a separate CSST, there has to be
some way to define that a property may become a real
attribute of an element. This is critical for properties
like html:onmouseover.


Well, it was a pleasure to let all my thoughts run free, 
now please let me now what you think.

Sjoerd Visscher

Received on Tuesday, 28 September 1999 16:26:58 UTC