W3C home > Mailing lists > Public > www-svg@w3.org > May 2000

Re(2): SVGPathElement::getPathSegAtLength()

From: Steve Dickson <sdickson@savagesoftware.com>
Date: Tue, 09 May 2000 17:45:43 -0700
Message-id: <fc.0085846d0000555e0085846d000054da.5561@savagesoftware.com>
To: www-svg@w3.org
>
>The spec does in fact say that it returns an index into pathSegList.

Yes, I overlooked that part.  Thanks.
>
>
>Sorry I didn't respond to your earlier note.

No problem, I know that you're busy.

>
>The user can use either pathSegList or normalizedPathSegList, depending on
>their needs. 
[snip]

That's fine as long as the user is handling the element as an
SVGPathElement explicitly.  I'm thinking of situations where the user is
treating the object as a DOM Element or DOM Node.  Say, for example, that
the user is stepping through the DOM tree (in this case, an SVGDOM tree)
using a treewalker or nodeiterator,  and they want to perform some
processing of attribute "d" on this particular node.  For the purposes of
a concrete example, assume that they want to serialize the DOM tree to
file.  To do so, they walk the tree serializing each node and that node's
attributes.  Now, what happens when they attempt to serialize an
SVGPathElement node?  Which list should be used as the "d" attribute? 
There are ways to code around this, but I think it might be useful to
consider adding some switch which allows the user to specify which list is
used by default in these sorts of situations.

S.
Received on Tuesday, 9 May 2000 20:45:34 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 5 November 2012 23:52:47 GMT