22 May
2008
22 May
'08
2:32 p.m.
Just thought I'd reply to my own msg here :-)
Of course I'm not suggesting that your data should implement this. However, you might consider making your data structure similar in shape, so that reading from/writing to an SVGPathElement would be easier and more natural.
bob
Bob Jamison wrote:
If you look at the SVG-DOM spec, instead of defining the nodes, they defines the path segments: http://www.w3.org/TR/SVG11/paths.html#DOMInterfaces
SVGElement implements SVGAnimatedPathData, which has getPathSegList() and its variants. And the list holds the segments, each of the subtypes of which has the node data.