W3C home > Mailing lists > Public > public-svg-wg@w3.org > October to December 2008

Re: name of 'filter' property and corresponding CSSStyleDeclaration property

From: Maciej Stachowiak <mjs@apple.com>
Date: Sun, 16 Nov 2008 17:59:39 -0800
To: Doug Schepers <schepers@w3.org>
Cc: public-svg-wg@w3.org
Message-id: <D513DF56-E185-4B63-8FBC-039E3577F4E2@apple.com>


On Nov 16, 2008, at 5:17 PM, Doug Schepers wrote:

>
> Hi, Cameron-
>
> It's something to consider... I'm not going to jump to the conclusion
> that renaming the 'filter' property is the right solution, since that
> might be a bit drastic for legacy content, viewers, and authoring  
> tools.
>
> Moreover, it's not clear that renaming 'filter' will, at this point,
> solve anything... there will still be legacy SVG content out there,  
> just
> as there is (legacy?) IE-filter content out there.  A UA which  
> wishes to
> account for both will have to implement accordingly.

It's true that it is a little late to fix this problem completely.

I think there is sufficiently little SVG content on the Web that it's  
not too late for a new property name to help.

> I don't know how common the IE-filter content is, nor whether it's  
> still
> being used in modern content.  Maybe Hixie (or another Googler)  
> could do
> a survey using Google's database.
>
> I think Maciej is exaggerating a bit when he says that this has been
> raised many times... as far as I can see, Hixie raised it once [1] in
> the context of a larger discussion, and pretty much everyone on the
> thread (not just the SVG WG) disagreed that it would be an issue (for
> example, Jim Ley [2] pointed out that the syntax differences makes
> parsing it easy, though that seems not to address the cascade).

Sorry for getting the history wrong.

> It's possible that Maciej's use case is an aspect of the case that  
> wasn't
> discussed enough (use in HTML was discounted in that earlier
> discussion), so I agree that we should figure out what the best  
> strategy
> forward is at this point.

The problem scenario is like this:

1) WebKit implements the SVG 'filter' property, but not the Internet  
Explorer 'filter' property.
2) We will almost certainly never implement the IE proprietary  
'filter' syntax, since it is so thoroughly tied to DirectX and we  
consider Mac OS X a tier 1 platform.
3) Some Web content tests the CSS OM for presence of a 'filter'  
property; if present, it assumes the browser is Internet Explorer, and  
uses the 'filter' property with IE-specific syntax to control opacity,  
instead of the standard 'opacity' property.

We ran into multiple sites where 3 was true.

Our solution was to have the 'filter' property present but  
undetectable to typical if statement checks, using similar techniques  
to what we use for document.all.

>  We should look at exactly how IE-filter is
> being used, and see if we can come up with an effective hack that  
> allows
> both to exist in harmony.

We already have a hack that more or less does that. WebKit's hack is  
exactly what the ECMAScript working group complained about. I think it  
would be better to have a name that could be hack-free in the CSS OM.  
But the hack is not something that is all that hard to live with. It  
does interfere somewhat with the possibility of SVG content feature  
testing for filter support.

Regards,
Maciej
Received on Monday, 17 November 2008 02:00:20 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 17 November 2008 02:00:25 GMT