A community-maintained Python framework for creating mathematical animations.
Improved documentation for `Rotate` (#2458)
Eshaan Naga Venkatab758da4c6529
diff --git a/manim/animation/rotation.py b/manim/animation/rotation.pyindex da2bd391b..198159404 100644--- a/manim/animation/rotation.py+++ b/manim/animation/rotation.py@@ -47,10 +47,45 @@ class Rotating(Animation):class Rotate(Transform):+ """Animation that rotates a Mobject.++ Parameters+ ----------+ mobject+ The mobject to be rotated.+ angle+ The rotation angle.+ axis+ The rotation axis as a numpy vector.+ about_point+ The rotation center.+ about_edge+ If ``about_point``is ``None``, this argument specifies+ the direction of the bounding box point to be taken as+ the rotation center.++ Examples+ --------+ .. manim:: UsingRotate++ class UsingRotate(Scene):+ def construct(self):+ self.play(+ Rotate(+ Square(side_length=0.5).shift(UP * 2),+ angle=2*PI,+ about_point=ORIGIN,+ rate_func=linear,+ ),+ Rotate(Square(side_length=0.5), angle=2*PI, rate_func=linear),+ )++ """+def __init__(self,mobject: Mobject,- angle: np.ndarray = PI,+ angle: float = PI,axis: np.ndarray = OUT,about_point: Sequence[float] | None = None,about_edge: Sequence[float] | None = None,