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

Re: [geometry] DOMMatrix constructor with CSS transform list string

From: Dirk Schulze <dschulze@adobe.com>
Date: Tue, 27 May 2014 20:52:29 +0000
To: Tab Atkins Jr. <jackalmage@gmail.com>
CC: Rik Cabanier <cabanier@gmail.com>, www-style <www-style@w3.org>, FX <public-fx@w3.org>
Message-ID: <00C6C999-2E36-4E1D-B90C-2AFA5CC21603@adobe.com>

On May 27, 2014, at 10:44 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:

> On Tue, May 27, 2014 at 1:38 PM, Rik Cabanier <cabanier@gmail.com> wrote:
>> On Tue, May 27, 2014 at 12:19 PM, Tab Atkins Jr. <jackalmage@gmail.com>
>> wrote:
>>> On Tue, May 27, 2014 at 12:47 AM, Dirk Schulze <dschulze@adobe.com> wrote:
>>>> 4) Transform function idents and first opening brace can be whitespace
>>>> separated:
>>>>        translate   (20px, 20px) or matrix
>>>>            (1,0,0,1,0,0) are valid.
>>> I consider #4 a bizarre legacy quirk of the SVG syntax that shouldn't
>>> infect anything else in the platform, and would oppose including it.
>> Why would you oppose this? It's not like we're proposing that this is valid
>> CSS transform syntax or that the serialization of a DOMMatrix would return
>> this.
>> If this is valid syntax for the SVG parser, it seems that DOMMatrix needs to
>> support it.
> Why does DOMMatrix need to support it?  That's not true unless there's
> legacy content relying on DOMMatrix (nee SVGMatrix) parsing it.

It is not that DOMMatrix is legacy but DOMMatrix needs to support legacy content. The potential risk not to support the general SVG transform attribute syntax is unclear.

> I oppose it because it's a blight of a syntax. :/  Unless someone has
> a really good explanation, I'm assuming that it was originally allowed
> by mistake in the first place, just an oversight in the grammar nobody
> caught until it was too late.

Well, that is your interpretation. SVG chose the least restrictive syntax for transform. This behavior that you criticize is supported by every SVG viewer including all browsers: http://jsfiddle.net/8AUXk/


> ~TJ
Received on Tuesday, 27 May 2014 20:53:03 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:43 UTC