Rotate about the local origin by the given angle. Positive angles
correspond to counterclockwise rotation, negative to clockwise. The
angle can be expressed using any of the
Isos on
Angle.
For example,
rotate (1/4 @@ turn),
rotate (tau/4
@@ rad), and
rotate (90 @@ deg) all represent the same
transformation, namely, a counterclockwise rotation by a right angle.
To rotate about some point other than the local origin, see
rotateAbout.
Note that writing
rotate (1/4), with no
Angle
constructor, will yield an error since GHC cannot figure out which
sort of angle you want to use. In this common situation you can use
rotateBy, which interprets its argument as a number of turns.