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

Already on GitHub? Sign in to your account

Add feature straighten by x degrees (45 for e.g) #490

Closed
wants to merge 3 commits into
from

Conversation

Projects
None yet
2 participants

changes straighten(), fxStraighten(), straightenObject() and  fxStraightenObject() function to allow passing an Int param that is used to define angle steps

for e.g straighten(45) would allow following angle steps 0, 45, 90, 135, 180, 225, 270, etc.

passing no param default to 90.

Let me know if this can be usefull to you and / or if i should improve the way i did it.

Thanks.

fadomire added some commits Mar 21, 2013

Add feature straighten by x degrees (45 for e.g)
changes straighten(), fxStraighten(), straightenObject() and  fxStraightenObject() function to allow passing an Int param that is used to define angle steps

for e.g straighten(45) would allow following angle steps 0, 45, 90, 135, 180, 225, 270, etc.

passing no param default to 90.

@kangax i added some tests but did not commited dist/all.js so travis is throwing errors. I guess i should not commit dist/all.js

let me know

Owner

kangax commented Mar 21, 2013

Hey @flintmakal, this looks good but I don't think it's worth pulling this into core. I actually wanted to deprecate straightening functionality at some point. I added it back in the days when I needed it in printio.ru. In a hindsight, it really should be done on an application level. It's just too specific functionality. I moved it to a separate module now, but it will probably go completely at some point.

@kangax kangax closed this Mar 21, 2013

ok no problem i understand and think your right to try not to make fabric.js do everything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment