W3C home > Mailing lists > Public > www-style@w3.org > May 1996

Re: Why is CSS not an SGML app?

From: Bert Bos <Bert.Bos@sophia.inria.fr>
Date: Mon, 20 May 1996 21:37:50 +0200
Message-Id: <199605201937.VAA21559@mygale.inria.fr>
To: jbazuzi@mail.vt.edu
Cc: www-style@w3.org
Jay Bazuzi writes:

 > Apologies if this is a FAQ; I'm new to www-style.  

I don't think it is FAQ, but it has been discussed in some detail. See
my message in the archives at:

    http://lists.w3.org/Archives/Public/www-style/msg00656.html

One additional reason not mentioned there is the fact that a syntax
that doesn't look like SGML is much easier to embed in an SGML
document. That's why CSS doesn't use any `<' or `&' characters.

 > I understand that CSS was originally meant as a proof-of-concept for
 > style negotiation and not as someone's idea of the perfect syntax.  It
 > seems to me, however, that an SGML application would be much more
 > appropriate.  Style sheets have a very clear structure.  There are
 > many reasons for using SGML here, including validation, use of
 > existing SGML tools, and a rigorous and clear syntax specification.

We don't claim that CSS is `the perfect syntax', but is was
consciously designed this way and it was also an early decision *not*
to use SGML syntax.

SGML tools don't help much. They might be able to check the syntax for
you, but I could give you a tiny C program that can do that
better. SGML tools won't check the semantics.

I hoped for a while that browsers would incorporate SGML parsers but
at the moment they don't and it seems unlikely that they will in the
foreseeable future. Therefore, adding a format in the time-proven way,
by defining what Brian Kernighan calls a `little language', is much
easier for users as well as implementers.

SGML may be nice for text, and it is true that it can be used for
anything you like, from databases to graphics formats, but what would
you think if your programming language looked like SGML instead of C
or Pascal?

 > I'm betting that it's way too late now -- MS, Netscape, W3C, and
 > others have decided to support CSS.  



Bert
-- 
  Bert Bos                                ( W 3 C ) http://www.w3.org/
  http://www.w3.org/pub/WWW/People/Bos/                      INRIA/W3C
  bert@w3.org                             2004 Rt des Lucioles / BP 93
  +33 93 65 77 71                 06902 Sophia Antipolis Cedex, France
Received on Monday, 20 May 1996 15:37:55 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:53:44 GMT