runemadsen / rune.js

A JavaScript library for programming graphic design systems with SVG
http://runemadsen.github.io/rune.js
MIT License
654 stars 35 forks source link

Add rounding code to prevent inconsistencies between browsers #13

Closed danielmcq closed 8 years ago

danielmcq commented 8 years ago

This should probably be fixed in more places, but it fixes the test which fails in Safari for now. It's the Vector.rotate test. Another option would be to set the amount of precision that the x and y properties are limited to for vectors upon initialization.

danielmcq commented 8 years ago

I thought more about my solution and don't think it's a great one, since it forces x and y to be integers when the vector it rotated. Closing this pull request.