Resize rectangle in Paper.js
问题 I have a very ordinary rectangle created in Paper.js and I'd like to resize it, but I can't find any obvious ways to do it. var rect = new Rectangle([0, 0],[width,height]); rect.center = mousePoint; var path = new Path.Rectangle(rect, 4); path.fillColor = fillColor; path.meta = fillColor; There's a scale transformation method, but it's not really for mouse interaction and my goal is to create a handle that can resize a component. 回答1: You can calculate the scaling by dividing the intended