W3C home > Mailing lists > Public > www-svg@w3.org > February 2015

Re: making comma-wsp optional between points list coordinates

From: Amelia Bellamy-Royds <amelia.bellamy.royds@gmail.com>
Date: Thu, 5 Feb 2015 09:05:17 -0700
Message-ID: <CAFDDJ7z9A3dyLq9aF+W41hhQvxkOFSJeGT0k3N-iOtJdJ+s42w@mail.gmail.com>
To: "Tab Atkins Jr." <jackalmage@gmail.com>
Cc: www-svg <www-svg@w3.org>
Sounds good, so long as the change is to make it exactly the same as <path>
(except for the command letters).  Which is considerably more flexible than
anything I've seen in CSS!   e.g. "1.5.3-1,.2-.7e1.2.3" is valid list of
three points.

Would it be possible to re-arrange the description in the path section to
separate out the parts that would also apply to polygon/polyline from the
path-specific sections?  And then reference that from the other shape
definitions, so that there is a single clear definition of how to parse a
stream of numbers.

It's already true that you can take  a valid points list and insert an "M"
at the front (and a "Z" at the end as applicable) and make it a valid path
string.   This would ensure that the reverse mapping would still work after
optimizing the path string as short as possible.

ABR


On 5 February 2015 at 05:35, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
>
>
> Works for me.  An equivalent CSS grammar, like `<integer>+`, would
> enable you to write "1-2-3" to mean something identical to "1 -2 -3",
> so it's fine for SVG to do the same.
>
> ~TJ
>
>
Received on Thursday, 5 February 2015 16:05:44 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 March 2017 09:47:39 UTC