Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve docs and typings for mobject_update_utils, and add examples for always(), f_always() and cycle_animation() #3976

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

chopan050
Copy link
Contributor

@chopan050 chopan050 commented Oct 24, 2024

Overview: What does this pull request change?

  • Added missing docstrings for always(), cycle_animation() and assert_is_mobject_method().
  • Improved existing docstrings by including missing Parameters, Returns and Raises sections.
  • Added examples for always(), f_always() and cycle_animation().
  • Defined a MobjectT TypeVar in order to get better typings for the Mobjects returned by functions such as always_redraw(). For example, if the lambda function inside always_redraw() returns a Brace, the Mobject returned by always_redraw() is now recognized as a Brace and, as such, autocompletion includes Brace methods and attributes.
  • Completed typings where Callables were missing parameter and return types.
  • Removed unused **kwargs from turn_animation_into_updater() and cycle_animation().

Links to added or changed documentation pages

https://manimce--3976.org.readthedocs.build/en/3976/reference/manim.animation.updaters.mobject_update_utils.html

Reviewer Checklist

  • The PR title is descriptive enough for the changelog, and the PR is labeled correctly
  • If applicable: newly added non-private functions and classes have a docstring including a short summary and a PARAMETERS section
  • If applicable: newly added functions and classes are tested

@chopan050 chopan050 changed the title Improve docstrings and typings in mobject_update_utils, and add examples for always and f_always Improve docstrings and typings in mobject_update_utils, and add examples for always(), f_always() and cycle_animation() Oct 24, 2024
@chopan050 chopan050 changed the title Improve docstrings and typings in mobject_update_utils, and add examples for always(), f_always() and cycle_animation() Improve docs and typings for mobject_update_utils, and add examples for always(), f_always() and cycle_animation() Oct 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🆕 New
Development

Successfully merging this pull request may close these issues.

1 participant