JuliaGraphics / Luxor.jl

Simple drawings using vector graphics; Cairo "for tourists!"
http://juliagraphics.github.io/Luxor.jl/
Other
588 stars 71 forks source link

rename rotate_point_around_point and add new method #245

Closed gantz-giraffe closed 1 year ago

gantz-giraffe commented 1 year ago

The underscores in the function name rotate_point_around_point don't conform with the naming conventions of most functions in the library, and the name is somewhat verbose. The more general name rotatepoint also makes it so that there can be an intuitive secondary method which takes a single point and an angle as its arguments, and returns the point rotated around the canvas' origin.

codecov[bot] commented 1 year ago

Codecov Report

Base: 73.08% // Head: 73.02% // Decreases project coverage by -0.06% :warning:

Coverage data is based on head (3936f06) compared to base (bf63b19). Patch coverage: 87.50% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #245 +/- ## ========================================== - Coverage 73.08% 73.02% -0.07% ========================================== Files 32 32 Lines 6365 6446 +81 ========================================== + Hits 4652 4707 +55 - Misses 1713 1739 +26 ``` | [Impacted Files](https://codecov.io/gh/JuliaGraphics/Luxor.jl/pull/245?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics) | Coverage Δ | | |---|---|---| | [src/Luxor.jl](https://codecov.io/gh/JuliaGraphics/Luxor.jl/pull/245/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics#diff-c3JjL0x1eG9yLmps) | `100.00% <ø> (ø)` | | | [src/point.jl](https://codecov.io/gh/JuliaGraphics/Luxor.jl/pull/245/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics#diff-c3JjL3BvaW50Lmps) | `91.91% <80.00%> (-0.40%)` | :arrow_down: | | [src/arrows.jl](https://codecov.io/gh/JuliaGraphics/Luxor.jl/pull/245/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics#diff-c3JjL2Fycm93cy5qbA==) | `90.90% <100.00%> (ø)` | | | [src/text.jl](https://codecov.io/gh/JuliaGraphics/Luxor.jl/pull/245/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics#diff-c3JjL3RleHQuamw=) | `83.24% <100.00%> (ø)` | | | [src/drawings.jl](https://codecov.io/gh/JuliaGraphics/Luxor.jl/pull/245/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics#diff-c3JjL2RyYXdpbmdzLmps) | `66.75% <0.00%> (+0.56%)` | :arrow_up: | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaGraphics)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

cormullion commented 1 year ago

Thanks! We'll either have to leave the old function name in as well, and deprecate it (since we cant just change function names whenever), or wait till the next major version (if my understanding of semver is correct). I'd suggest the former.

cormullion commented 1 year ago

@gantz-giraffe Hi! Do you want this PR to make it into the next release - I'll probably release 3.6 soon, and this could go in with a few additions.

gantz-giraffe commented 1 year ago

@cormullion yeah absolutely!