-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Allow :meth:.VGroup.add
to use iterables of VMobjects
#3556
Closed
JasonGrace2282
wants to merge
8
commits into
ManimCommunity:main
from
JasonGrace2282:vgroup_iterables
Closed
Allow :meth:.VGroup.add
to use iterables of VMobjects
#3556
JasonGrace2282
wants to merge
8
commits into
ManimCommunity:main
from
JasonGrace2282:vgroup_iterables
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JasonGrace2282
added
the
new feature
Enhancement specifically adding a new feature (feature request should be used for issues instead)
label
Dec 29, 2023
for more information, see https://pre-commit.ci
JasonGrace2282
changed the title
:meth:
Allow :meth:Dec 29, 2023
.Mobject.add
allows iterables of Mobjects.VGroup.add
to use iterables of VMobjects
Turns out VGroups (and all things it inherits from) are iterables... oops!
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
@@ -31,6 +31,7 @@ | |||
from typing_extensions import Self | |||
|
|||
from manim.mobject.opengl.opengl_compatibility import ConvertToOpenGL | |||
from manim.mobject.opengl.opengl_mobject import OpenGLMobject |
Check notice
Code scanning / CodeQL
Cyclic import Note
Import of module begins an import cycle.
manim.mobject.opengl.opengl_mobject
Error loading related location
Loading
Closing this as the performance hit for checking if an object is not a VMobject is a bit excessive. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
new feature
Enhancement specifically adding a new feature (feature request should be used for issues instead)
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #3540
Allows for statements like:
Also added a test for this.
As MrDiver said, it's annoying to have to unpack iterables with the
*
operator.