Re: CSS and XSL

Subject: Re: CSS and XSL
From: "Simon St.Laurent" <simonstl@xxxxxxxxxxxx>
Date: Sun, 14 Feb 1999 18:50:25 -0500
At 11:51 AM 2/14/99 -0600, Paul Prescod wrote:
>I've pointed out technical problems with the current mechanism with
>respect to XSL, the DOM, XML Schemas, XML Query Languages etc. Your only
>*technical* argument against, thus far, has been that there will be "too
>many attributes." Perhaps you can clarify how this causes problems. I'm
>really more interested in the technical issues than the sociological ones.

Sociological (and even political) issues do matter, very much.  Technical
utopians who ignore them do so at their peril.

>I'm totally in favour of external styles (where feasible) already.

Good.  We're at least in the same universe.

>> If your constraints are really that critical, then yes, you should specify
>> the style - all of the style - 
>If I have data that must be bold then I don't necessarily want to fix its
>size or slant. Or, as another example it isn't hard to think of a
>situation where the background-color must be fixed but the border-width
>could vary or vice versa. That's why external CSS allows you to specify
>their importance separately.

That's fine - just fix what you need fixed with the style attribute, and
rely on other mechanisms (external sheets) if you really need to make changes.

>Anyhow, it doesn't make sense to get bogged down in the fixed attributes
>example. I've described situations such as the DOM, XSL, Schemas, queries
>and others where the single-attribute way makes life harder. There is a
>huge amount of infrastructure being erected to work with XML attributes
>that will not work cleanly with CSS properties. 

I think you're missing the point - it's not difficult to make XML work
cleanly with CSS properties.  If you want to convert a style attribute to a
bunch of XML attributes, the processing is trivial.  On the other hand,
keeping the style information in a single element makes it much easier to
avoid the crunched-up disaster area that HTML documents were becoming when
formatting was all over the markup.

Don't forget the history - there are good reasons why CSS uses a style
attribute, and not 150 other attributes.  Not relevant?  Too bad.  It's
relevant to lots of folks working with it every day.

As Jelks Cabaniss put it:
>There were good reasons
>for the "schizoid" nature of *ML+CSS.  I question whether reversion to an
>"improved", well-formed Tag Soup is progress.

[Paul Prescod - initial quote (>>) is mine]
>> You can do it (I just typed it in), and it might be easier for some
>> applications, but processing the style attribute to break it up isn't that
>> hard, if you really need your information in that format.
>That argument can be used to justify any poor encoding for information.

Yes, and it's an argument that convinces people every day.  Check out
"Lisp: Good News, Bad News, how to Win Big" at  Rather than griping about 'poor
encoding', you might ask yourself why that encoding was chosen and what its
advantages might be.

Maybe a few weeks work building style sheets with CSS for use on a large
Web site would help with this discussion.  You might stop worrying about
'rich data' and 'elegant styling' and spend more time focusing on how to
make things work without creating more headaches for large numbers of

>I'm not griping about CSS. I'm trying to figure out how to make it useful
>for more of what I do. I'm trying to figure out how to mend the rift
>between formatting objects and CSS.
>Less than three days ago you said: "It's not too late to change CSS.  One
>proposal for doing so and making it more XML-friendly was put forward in
>[XSL and CSS], and [that] certainly signaled a willingness to accommodate
>But when I actually suggest a change to CSS (or, more precisely, when I
>suggest that the conventions from the document you pointed me to and from
>the XSL formatting objects should also be applied to SVG) you crucify me.
>All of a sudden I'm "griping." The really odd thing is that the sentence
>above was *in response to* this same proposal! One minute CSS is ready for
>change. The next, I'm griping for asking for the change.

Give 'em an inch, and they'll take a mile.  I make a kindly comment, and
you lurch in with enormous proposals for large-scale structural change that
don't reflect CSS usage.  Why do I 'crucify' you?  Because I don't think
your 'griping' is a good way to bring about change.  You've told me the
same thing repeatedly, regarding XSL, so I don't mind mirroring it back to

If change is going to come, it should come in response to the needs of
people actually using CSS, not someone who's upset because the CSS models
don't fit 'conventions' of proper behavior.

Simon St.Laurent
XML: A Primer / Building XML Applications (April)
Sharing Bandwidth / Cookies

 XSL-List info and archive:

Current Thread