开发者

Resize shapes with RaphaelJS

开发者 https://www.devze.com 2023-03-13 08:01 出处:网络
Is it possible using RaphaelJS ? I mean just 2D part. The only way I thought is to rewrite all paths proportionally and then resize them to fi开发者_开发知识库t inside my canvas container.Yes.

Is it possible using RaphaelJS ? I mean just 2D part.

The only way I thought is to rewrite all paths proportionally and then resize them to fi开发者_开发知识库t inside my canvas container.


Yes. From the raphael site

var c = paper.circle(10, 10, 10);
// makes the circle 1.5 times larger
c.scale(1.5, 1.5);
// makes the circle half as wide, and 75% as high
c.scale(.5, .75);
0

精彩评论

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