开发者

Is there a command to move the whole SVG path to a new position?

Is there a command to move the whole SVG path to a new position, instead of adding the offsets to each point of the 开发者_如何学Pythonpath?


Thanks to sehe's comment. The solution is: wrap the path into

<g transform="translate(offset_x,offset_y)"></g>


<path transform="translate(x, y)" d="....">

If your path already has transforms and you'd rather not interfere with them:

<g transform="translate(x, y)">
    <path transform="..." d="....">
</g>

Stealing from Phrogz's comment and Powerboy's answer.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜