Re: [CSS] Rules for parsing and compatibility

On Wed, 31 Dec 2003, Ernest Cline wrote:
>>> @property <property-name> (<value>)? <declaration-block>
>>> If only the property name is given, then the rules in the declaration
>>> block are applied only if the UA uses the property.
>> In practice this is not that useful because UAs are notorious for
>> claiming to support a property while doing a bad job of it.
> So, because we have bad UA's we should just give up?
> In good UA's this will be useful.

What good UAs?

> It certainly is a lot better than the current practice of using the
> quirks of existing UA's to try to select what CSS gets used where.

I agree. IMHO the best solution is to simply write to the specs and if it
breaks in a browser somewhere, tough. That browser should be fixed, not
the site.

Of course, with the browser with most market share not getting any further
standards compliance fixes (not even in the next release of its OS, as I
understand it), I understand that content authors do not find that a
workable solution.

> At least with @property a style author can have some hope that he won't
> need to rewrite his style rules when a new UA version that supports what
> he want to use comes out, or supports the kludge he used in place of an
> @property rule, but doesn't support the property he wants.

No, instead he'll just have to deal with the new UA supporting the
feature, but not perfectly. Which is almost always the case for initial

This is exactly the problem that DOM authors that use hasFeature() have
run into. UAs claim to implement, say, DOM2 Core, but don't support
getAttributeByNS() correctly.

> Perhaps you enjoy having to worry about what kludges work with what
> UA's, but I don't.

Personally I ignore failures in UAs. If the UA can't render my site due to
bugs in the UA, that's the UA's problem, not mine. Of course I'm in the
lucky position that many UA implementors read my site, so they tend to fix
their bugs! ;-)

> Perhaps that is what _you_ really need, but a simple to implement "Does
> the UA claim to support this property?" rule is all I need. I don't want
> to wait for a Xanadu-like perfection that may never arrive when the case
> of "Is a property supported?" is all that I need handled, and can be
> easily done.

So should WinIE6, if it supported this @property thing, claim to support
'text-decoration'? Should it claim to support 'height'?

Should Mozilla claim to support 'display: inline' and 'border' and

Ian Hickson                                      )\._.,--....,'``.    fL
U+1047E                                         /,   _.. \   _\  ;`._ ,.                         `._.-(,_..'--(,_..'`-.;.'

Received on Thursday, 1 January 2004 09:19:38 UTC