X Tutup
Skip to content

DOC: Improve writer parameter docs of Animation.save()#30910

Merged
story645 merged 1 commit intomatplotlib:mainfrom
timhoffm:doc-animation.save-writer
Jan 2, 2026
Merged

DOC: Improve writer parameter docs of Animation.save()#30910
story645 merged 1 commit intomatplotlib:mainfrom
timhoffm:doc-animation.save-writer

Conversation

@timhoffm
Copy link
Member

Closes #24159.

Note: type stubs already define the type as AbstractMovieWriter:

writer: AbstractMovieWriter | str | None = ...,

@timhoffm timhoffm added the Documentation: API files in lib/ and doc/api label Dec 30, 2025
Copy link
Member

@story645 story645 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for taking this on!

Comment on lines +959 to +960
The writer to use. This can be an instance of an `AbstractMovieWriter`
subclass or a string. The builtin writers are
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The writer to use. This can be an instance of an `AbstractMovieWriter`
subclass or a string. The builtin writers are
An instance of an `AbstractMovieWriter` subclass or an identifying string. The builtin writers are

I don't think writer to use is adding anything here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We (should) always start with an expression or sentence what the effect of the parameter is. I believe this is valuable to state explicitly, even if one can mostly guess what this is for; e.g. we also have
grafik

More informative wording welcome; e.g. how about

The writer used to grab the frames and create the movie file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the explanation of writer much better.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changed

@timhoffm timhoffm force-pushed the doc-animation.save-writer branch from 56b9276 to b52aac2 Compare January 2, 2026 17:55
@github-actions github-actions bot removed the Documentation: API files in lib/ and doc/api label Jan 2, 2026
@story645 story645 added this to the v3.10-doc milestone Jan 2, 2026
@story645 story645 merged commit 6688d5d into matplotlib:main Jan 2, 2026
34 of 37 checks passed
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Jan 2, 2026
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Jan 2, 2026
@timhoffm timhoffm deleted the doc-animation.save-writer branch January 2, 2026 21:25
timhoffm added a commit that referenced this pull request Jan 2, 2026
…ave() (#30924)

Co-authored-by: Tim Hoffmann <2836374+timhoffm@users.noreply.github.com>
timhoffm added a commit that referenced this pull request Jan 2, 2026
…910-on-v3.10.8-doc

Backport PR #30910 on branch v3.10.8-doc (DOC: Improve writer parameter docs of Animation.save())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Doc]: clarify which writers animation.save supports

2 participants

X Tutup