Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does origin/originX/originY affect Scale? #61

Closed
felixakiragreen opened this issue Jun 18, 2016 · 3 comments
Closed

Does origin/originX/originY affect Scale? #61

felixakiragreen opened this issue Jun 18, 2016 · 3 comments

Comments

@felixakiragreen
Copy link

It works perfectly when I use it for rotate, but the origin doesn't seem to be affecting the scale. I'm just doing this:

<G origin={'20, 28'} scale={.5}>

Am I missing something?

When I do:

<G origin={'20, 28'} rotate={90}>

it works.

@magicismight
Copy link
Collaborator

I have no idea what`s going on here.
Maybe you can provide more information?
Everything works fine to me.

@felixakiragreen
Copy link
Author

felixakiragreen commented Jul 24, 2016

It's pretty complicated and nuanced, so did test of every possible combination of scale and rotate transforms with origins. Then I put them together in this chart, and attempted to show the correct behavior with the transparent versions.
illustration of svg transforms

Side note: any thoughts on if the origin should default to the center of the shape, instead of {0,0}?

@magicismight
Copy link
Collaborator

Thanks for this detailed information.
The 2d matrix libray has several bugs inside,will be replaced with anthor libray instead.
This fix will be landed in next version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants