paperjs / paper.js

The Swiss Army Knife of Vector Graphics Scripting – Scriptographer ported to JavaScript and the browser, using HTML5 Canvas. Created by @lehni & @puckey
http://paperjs.org
Other
14.53k stars 1.23k forks source link

exportJSON ignores position - v0.9.18 #451

Closed walkandre closed 10 years ago

walkandre commented 10 years ago

I'm serializing the project to json but it's ignoring any changes to the item / svg position. Ex:

var item = paper.project.importSVG(svg);
item.position = new paper.Point(1000, 500);
var json = paper.project.exportJSON() 

When I load the json back the item / svg is in the wrong position 0,0.

paper.project.importJSON(json);
lehni commented 10 years ago

Thanks for the report. That's indeed a bug. Tiny fix coming up!