Skip to content

Commit

Permalink
Merge pull request #16 from aravindavk/doc_example_fix
Browse files Browse the repository at this point in the history
doc: Fixed the translate x value and constant `PI` usage in arc
  • Loading branch information
TamasSzekeres authored Jan 22, 2022
2 parents 6c77a41 + 53bb016 commit 2c9258e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/cairo/context.cr
Original file line number Diff line number Diff line change
Expand Up @@ -644,9 +644,9 @@ module Cairo
# by different amounts in the X and Y directions. For example, to draw an ellipse in the box given by *x*, *y*, *width*, *height*:
# ```
# context.save
# context.translate(x + width / 20., y + height / 2.0)
# context.translate(x + width / 2.0, y + height / 2.0)
# context.scale(width / 2.0, height / 2.0)
# context.arc(0.0, 0.0, 1.0, 0.0, 2.0 * Math.PI)
# context.arc(0.0, 0.0, 1.0, 0.0, 2.0 * Math::PI)
# context.restore
# ```
#
Expand Down

0 comments on commit 2c9258e

Please sign in to comment.