On Tue, 21 Sep 2004 16:59:47 +0000, peters <pe****@holger-peters.de>
wrote:
I'm using CSS, HTML and XML for some time. I've always asked myself why
CSS is not an XML format. What are the reasons? Is it historical?
Well, the exact answer to that may not be so easy to find but one very
simple reason may be that the work on what would eventually become XML
had just barely started when CSS1 got close to its final state in 1996.
A couple of other points of interest can be found in the book "Cascading
Style Sheets - Designing for the web" by Håkon Vium Lie and Bert Bos,
first published in 1997.
There we can quote the following, in the foreword by Robert Cailliau at
CERN...
"I followed the CSS effort from its inception - mostly over cups
of coffee with Håkon at CERN - and I've always had one concern:
is it possible to create a powerful enough style sheet language
without ending up with a programming language?"
....and in the preface of the same book, from Håkon and Bert...
"CSS uses common desktop publishing terminology that you probably
know from before"
That last quote seems to indicate that the CSS syntax was chosen to
allow for an easy adoption by a web community that was already "in deep
shit" by its use of HTML as a command language to tweak www pages into
display (as encouraged by Mosaic, and later Netscape, of that time),
instead of using it as the syntactic markup language it was originally
designed to be (well, there's some limits to that as a truth too, but
let's not get picky :-).
It's not like the world did not already have a styling language
available at the time. DSSSL[1] was already defined, as a full sized
style and transformation language for applications of SGML.
There where other styling languages in use too at the time, for
applications of SGML, and you can find links to info on some of them in
the m-FAQ for this NG.
Now we are close to 8 years later, from where CSS1 first became a
recommendation and during that time XML, and a few applications of it,
have matured into a usable state.
Most especially, when the XSL project once started it was soon found
that a styling language written in XML was of limited use for the
emerging XML community, except for one of the modules that came out of
the original XSL project.
XSL-T (T for transformation) came to be the same for applications of XML
as DSSSL already was for applications of SGML.
XSL-T shares the characteristics of DSSSL in the sense that even XSL-T
is a fully Turing Complete programming language, but it also shares
another part with DSSSL, the learning curve is steep for the average www
author.
So; CSS is what it is because it is meant to be simple for all to learn
and understand with less effort, as compared to another definition
approach.
So far CSS standard developments has also withstood all attempts to let
CSS be converted into a programming language (i.e. to have procedural
constructs included in the syntax).
The lack of such constructs in CSS is what makes it safe and secure for
www use, as compared to an implemented scripting language interpreter in
a UA, that allows for execution of an externally picked up "program"
directly in a users browsing environment.
In all honesty though; the absolute majority of scripts that are in
circulation on the www today are there to be annoying, but not really
designed to destructive, to a user.
But naturally we do have one "sinner" who could not hold back on an
attempt of their own in the "CSS with procedures" area.
MS-IE[3] supports (with bugs of course) something that goes by the name
of BECSS[2].
[1] DSSSL - Document Style Semantics and Specification Language.
A fully Turing complete programming language that in it self is
defined as an application of SGML; i.e. a DSSSL program is governed
by its own DTD and can be validated just like any other piece of
SGML based markup.
DSSSL can be used to style and transform valid instances of HTML
too, but at the cost of a very steep learning curve.
[2] BECSS - BEhavioral Cascading Style Sheets
Read all about it, here ... and then forget about it...
<http://www.w3.org/TR/1999/WD-becss-19990804>
...also read any and all threads of comments on lists.
This may be as good start as any...
<http://lists.w3.org/Archives/Public/www-style/1999Sep/0112.html>
[3] MS-IE - MicroSoft Internet Explorer
As per MS claims, a very important component of the MS-Windows
operating system. A fact that came as a shock to MS to when
they internally discovered that it was too much true.
Make no mistake here now. In order to keep a latest version of
MS-IE running for free on old systems, they had to include so
many updates to those old op-systems that it started to be a
threat to the real source of revenue for MS, namely the sale of
new operating systems.
Hence, the quality updates of MS-IE was stopped some years back
and from that time only security related updates has been allowed.
--
Rex