<div dir="ltr">I mean open the SVG, then iterate through all the vector objects in it and alter them somehow; like change the color attribute or make all their lines into dashed lines.<div><br></div><div>To be more sepcific, I would like to be able to open an SVG, iterate through each vector object in it applying some change along the way, then write out a new SVG.</div>
<div><br></div><div>At the moment I'm using RSVG[2] and Cairo, but I'm assuming it's Cairo that does all the actual image manipulation. I guess my question could also be re-phrased as:</div><div>Does Cairo or any other library re-instantiate objects from items in the DOM of an SVG file when it opens them? If so where are they and how can I iterate over them?</div>
<div><br></div><div>Thanks,</div><div>-Rei</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2014/1/4 Bryce W. Harrington <span dir="ltr"><<a href="mailto:b.harrington@samsung.com" target="_blank">b.harrington@samsung.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Sat, Jan 04, 2014 at 04:02:26AM +0900, 影月 零 wrote:<br>
> Is it possible to edit the content of an SVG image and then save the result<br>
> back? I don't mean just drawing on top of the image, I mean manipulating<br>
> objects/vectors within the image. I've been searching but haven't found a<br>
> good sample or explanation of how this would be done, if it is possible.<br>
<br>
</div></div>Clarify what you mean by 'edit'.  You can certainly edit the XML in an<br>
editor, or graphically via inkscape, but you probably already know that,<br>
so I assume you want to do something different?<br>
<br>
Bryce<br>
<br>
> Thanks,<br>
> -Rei<br>
<span class="HOEnZb"><font color="#888888"><br>
> --<br>
> cairo mailing list<br>
> <a href="mailto:cairo@cairographics.org">cairo@cairographics.org</a><br>
> <a href="http://lists.cairographics.org/mailman/listinfo/cairo" target="_blank">http://lists.cairographics.org/mailman/listinfo/cairo</a><br>
</font></span></blockquote></div><br></div>