Skip to content

Path is now transformable.#9

Open
qhwa wants to merge 12 commits into
awebneck:masterfrom
qhwa:transform
Open

Path is now transformable.#9
qhwa wants to merge 12 commits into
awebneck:masterfrom
qhwa:transform

Conversation

@qhwa

@qhwa qhwa commented Mar 19, 2014

Copy link
Copy Markdown

Hi @awebneck ,
I've made paths, sub paths and directions able to be transformed now.

For example

# for path
path = Parser.parse %Q{C211.003,239.997,253.003,197.997,304.003,197.997}
path.scale( 0.5, -0.5 )
path.translate( 0, 100 )
path.to_command
#=> "C105.5015-19.9985 126.5015 1.0015 152.0015 1.0015"

More examples can be found in spec/transformable_spec.rb .

Some directions are considered "not fully transformable". e.g. HorizontalTo directions are not directly rotatable. An error will be raised if they are being rotated or skewed.

So two methods , to_transformable_commands! and fully_transformable? are added to paths and sub_paths, to help them get transformed.

However, this is transparent to users. Users only need to call transform , scale or other methods. Savage turns paths fully transformable before applying transforms.

Could you take a review at this?

@qhwa

qhwa commented Mar 19, 2014

Copy link
Copy Markdown
Author

Sorry for the calculating mistakes.

@qhwa

qhwa commented May 21, 2014

Copy link
Copy Markdown
Author

I've created another gem savage-transform

@mrmeszaros

Copy link
Copy Markdown

@qhwa @awebneck is this project dead?

@awebneck

Copy link
Copy Markdown
Owner

@mrmeszaros pretty much, yeah - haven't updated the lib in ages, don't have any plans to do in the future.

@mrmeszaros

mrmeszaros commented Dec 27, 2017

Copy link
Copy Markdown

@awebneck I have no experience in doing releases to rubygems.org - so if you could add some starting momentum (eg. a README.md section on the build/release process), I would gladly take the responsibility of maintaining the project.

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

Successfully merging this pull request may close these issues.

3 participants