Compare commits

..

521 commits

Author SHA1 Message Date
dependabot[bot]
0e83f4b09a
chore(deps): bump jupyterlab from 4.5.7 to 4.5.9 (#4822)
---
updated-dependencies:
- dependency-name: jupyterlab
  dependency-version: 4.5.9
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-20 13:14:07 -04:00
dependabot[bot]
f7fd708276
chore(deps): bump jupyter-server from 2.18.0 to 2.20.0 (#4821)
Bumps [jupyter-server](https://github.com/jupyter-server/jupyter_server) from 2.18.0 to 2.20.0.
- [Release notes](https://github.com/jupyter-server/jupyter_server/releases)
- [Changelog](https://github.com/jupyter-server/jupyter_server/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jupyter-server/jupyter_server/compare/v2.18.0...v2.20.0)

---
updated-dependencies:
- dependency-name: jupyter-server
  dependency-version: 2.20.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-20 11:22:50 -04:00
Caffein3
4c4622df54
feat: support multiple TeX compilers in TexTemplate (#4810)
* feat: support multiple compilations

Allow `tex_compiler` to be a `str | list[str]` instead of just
`str`. When a list is given, document will be compiled sequentially.

* fix: suppress compilation progress log when only one compiler is used

* fix: updated docstrings and variable naming
2026-06-16 22:35:14 -04:00
dependabot[bot]
66d5a4937a
chore(deps): bump bleach from 6.3.0 to 6.4.0 (#4814)
Bumps [bleach](https://github.com/mozilla/bleach) from 6.3.0 to 6.4.0.
- [Changelog](https://github.com/mozilla/bleach/blob/main/CHANGES)
- [Commits](https://github.com/mozilla/bleach/compare/v6.3.0...v6.4.0)

---
updated-dependencies:
- dependency-name: bleach
  dependency-version: 6.4.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-17 01:49:15 +00:00
dependabot[bot]
c07137dbed
chore(deps): bump tornado from 6.5.5 to 6.5.7 (#4813)
Bumps [tornado](https://github.com/tornadoweb/tornado) from 6.5.5 to 6.5.7.
- [Changelog](https://github.com/tornadoweb/tornado/blob/master/docs/releases.rst)
- [Commits](https://github.com/tornadoweb/tornado/compare/v6.5.5...v6.5.7)

---
updated-dependencies:
- dependency-name: tornado
  dependency-version: 6.5.7
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-17 01:33:08 +00:00
dependabot[bot]
71ab85f960
chore(deps): bump idna from 3.11 to 3.15 (#4736)
Bumps [idna](https://github.com/kjd/idna) from 3.11 to 3.15.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.md)
- [Commits](https://github.com/kjd/idna/compare/v3.11...v3.15)

---
updated-dependencies:
- dependency-name: idna
  dependency-version: '3.15'
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-17 01:09:58 +00:00
dependabot[bot]
16f0a3de3e
chore(deps): bump urllib3 from 2.6.3 to 2.7.0 (#4729)
Bumps [urllib3](https://github.com/urllib3/urllib3) from 2.6.3 to 2.7.0.
- [Release notes](https://github.com/urllib3/urllib3/releases)
- [Changelog](https://github.com/urllib3/urllib3/blob/main/CHANGES.rst)
- [Commits](https://github.com/urllib3/urllib3/compare/2.6.3...2.7.0)

---
updated-dependencies:
- dependency-name: urllib3
  dependency-version: 2.7.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-17 00:58:29 +00:00
dependabot[bot]
537a134360
chore(deps): bump mistune from 3.2.0 to 3.2.1 (#4725)
Bumps [mistune](https://github.com/lepture/mistune) from 3.2.0 to 3.2.1.
- [Release notes](https://github.com/lepture/mistune/releases)
- [Changelog](https://github.com/lepture/mistune/blob/main/docs/changes.rst)
- [Commits](https://github.com/lepture/mistune/compare/v3.2.0...v3.2.1)

---
updated-dependencies:
- dependency-name: mistune
  dependency-version: 3.2.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-16 23:49:46 +00:00
dependabot[bot]
b7bf2ea90f
chore(deps): bump docker/setup-buildx-action from 3 to 4 (#4716)
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 3 to 4.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](https://github.com/docker/setup-buildx-action/compare/v3...v4)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-version: '4'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 22:42:37 +00:00
dependabot[bot]
bdaf4497b7
chore(deps): bump jupyterlab from 4.5.2 to 4.5.7 (#4713)
Bumps [jupyterlab](https://github.com/jupyterlab/jupyterlab) from 4.5.2 to 4.5.7.
- [Release notes](https://github.com/jupyterlab/jupyterlab/releases)
- [Changelog](https://github.com/jupyterlab/jupyterlab/blob/main/RELEASE.md)
- [Commits](https://github.com/jupyterlab/jupyterlab/compare/@jupyterlab/lsp@4.5.2...@jupyterlab/lsp@4.5.7)

---
updated-dependencies:
- dependency-name: jupyterlab
  dependency-version: 4.5.7
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-06-16 22:05:50 +00:00
dependabot[bot]
037b376ec2
chore(deps): bump notebook from 7.5.2 to 7.5.6 (#4712)
Bumps [notebook](https://github.com/jupyter/notebook) from 7.5.2 to 7.5.6.
- [Release notes](https://github.com/jupyter/notebook/releases)
- [Changelog](https://github.com/jupyter/notebook/blob/@jupyter-notebook/tree@7.5.6/CHANGELOG.md)
- [Commits](https://github.com/jupyter/notebook/compare/@jupyter-notebook/tree@7.5.2...@jupyter-notebook/tree@7.5.6)

---
updated-dependencies:
- dependency-name: notebook
  dependency-version: 7.5.6
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 17:46:31 -04:00
dependabot[bot]
e9639c2697
chore(deps): bump nbconvert from 7.17.0 to 7.17.1 (#4702)
Bumps [nbconvert](https://github.com/jupyter/nbconvert) from 7.17.0 to 7.17.1.
- [Release notes](https://github.com/jupyter/nbconvert/releases)
- [Changelog](https://github.com/jupyter/nbconvert/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jupyter/nbconvert/compare/v7.17.0...v7.17.1)

---
updated-dependencies:
- dependency-name: nbconvert
  dependency-version: 7.17.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 21:13:42 +00:00
dependabot[bot]
1b2d5ce72b
chore(deps-dev): bump pytest from 9.0.2 to 9.0.3 (#4688)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 9.0.2 to 9.0.3.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/9.0.2...9.0.3)

---
updated-dependencies:
- dependency-name: pytest
  dependency-version: 9.0.3
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 20:38:28 +00:00
dependabot[bot]
c94a7ea9fc
chore(deps): bump pillow from 12.1.1 to 12.2.0 (#4687)
Bumps [pillow](https://github.com/python-pillow/Pillow) from 12.1.1 to 12.2.0.
- [Release notes](https://github.com/python-pillow/Pillow/releases)
- [Changelog](https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst)
- [Commits](https://github.com/python-pillow/Pillow/compare/12.1.1...12.2.0)

---
updated-dependencies:
- dependency-name: pillow
  dependency-version: 12.2.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 20:10:01 +00:00
dependabot[bot]
bb1be6ef8a
chore(deps): bump actions/upload-artifact from 6 to 7 (#4620)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 6 to 7.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 19:48:22 +00:00
rsn
516c8c8ba7
Fix ThreeDScene.set_to_default_angled_camera_orientation() (#4704)
Co-authored-by: neeh <rapetisiddhu@gmail.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 15:20:18 -04:00
Mayank Basena
ccee37a614
Add docstring to GenericGraph.__getitem__() (#4761)
Allows accessing edges via tuple keys like g[(1, 2)] in addition to
vertex lookups like g[1]. Previously only vertex lookups were supported.

Fixes ManimCommunity/manim#3798

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 18:52:42 +00:00
dependabot[bot]
31db147222
chore(deps): bump jupyter-server from 2.17.0 to 2.18.0 (#4720)
Bumps [jupyter-server](https://github.com/jupyter-server/jupyter_server) from 2.17.0 to 2.18.0.
- [Release notes](https://github.com/jupyter-server/jupyter_server/releases)
- [Changelog](https://github.com/jupyter-server/jupyter_server/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jupyter-server/jupyter_server/compare/v2.17.0...v2.18.0)

---
updated-dependencies:
- dependency-name: jupyter-server
  dependency-version: 2.18.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-16 17:57:48 +00:00
GniLudio
34124c3f60
Fix wrong type annotation of Animation._on_finish (#4812) 2026-06-16 13:11:45 -04:00
Benjamin Hackl
d999d422c9
Introduce first-class support for rendering text and markup via Typst (optional dependency) (#4681)
* feat: add TypstMobject and TypstMathMobject for first-class Typst support

Implement the initial TypstMobject proposal (see agents/typst.md):

- TypstMobject: renders arbitrary Typst markup to SVG via the 'typst'
  Python package (self-contained Rust binary, no system install needed),
  then imports through SVGMobject.
- TypstMathMobject: convenience subclass that wraps input in Typst math
  delimiters ($ ... $).

Pipeline: user string → wrap in minimal Typst document (auto-sized page,
transparent background) → write .typ file → compile to SVG via
typst.compile() → import via SVGMobject → scale/center/recolor.

Key details:
- Compilation helper in manim/utils/typst_file_writing.py with SHA-256
  content-hash caching (same scheme as the LaTeX pipeline).
- font_size property mirrors SingleStringMathTex: compile at fixed 11pt,
  scale after import using initial_height / SCALE_FACTOR_PER_FONT_POINT.
- init_colors() recolors black submobjects to self.color (Typst default
  fill is black), preserving any explicit Typst colors.
- path_string_config enables curve subdivision for smooth animation.
- 'typst' added as optional dependency group in pyproject.toml.
- 10 tests covering creation, font_size, caching, preamble, and repr.

* feat(typst): add sub-expression selection via {{ }} groups and .select()

- Override modify_xml_tree in Typst to convert data-typst-label
  attributes to id attributes before svgelements parsing (avoids
  attribute inheritance issue with data-* attributes)
- Add Typst.select(key) method accepting str labels or int indices
  to retrieve VGroup sub-expressions from id_to_vgroup_dict
- Implement {{ }} double-brace preprocessor on TypstMath:
  - {{ content }} → manimgrp("_grp-N", content) (auto-numbered)
  - {{ content : label }} → manimgrp("label", content) (named)
  - Skips {{ }} inside string literals and [...] content blocks
  - Uses math-mode call convention (no # prefix) to keep args in
    math mode
- Auto-inject manimgrp preamble when groups are detected
- Add 12 new tests covering label mapping, nesting, select(),
  error handling, and preprocessor edge cases

* Remove unneeded assert line

* Generalize some more critical hard-coded LaTeX assumptions

* Fix syntax error

* Support Typst labels in existing APIs

* Add ManimTextLabel typing alias

* Preserve Typst SVG stroke widths by default

* Calibrate Typst font sizing against TeX

* Add Typst mobject documentation

* Track Typst baseline frames

* Document Typst baseline frame tracking

* Add Typst section to text guide

* Polish Typst docs and label handling

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Improve Typst stroke scaling and docs examples

* Tune Typst SVG stroke scaling

* Restore Typst math example wording

* Fix pre-commit issues for Typst branch

* Fix number line runtime typing import

* Exclude Typst autogenerated .rst files

* Use Manim directive in docstrings and fix wrong key in Typst.select() docstring

* Fix GroupedMath comments

---------

Co-authored-by: Toon Verstraelen <Toon.Verstraelen@UGent.be>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <francisco.manriquezn@usm.cl>
2026-06-11 03:54:21 +00:00
GniLudio
561de9d72a
Use language parameter to format Code even when passing code_file (#4706)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-10 21:49:59 +00:00
Sai Sridhar Tarra
05b3042ab0
Add tests for edge lookup in GenericGraph.__getitem__() (#4753)
GenericGraph.__getitem__ only handled vertex lookup. Passing a 2-tuple
(u, v) to retrieve an edge mobject raised a KeyError against the
vertices dict instead of looking up self.edges.

Route tuple keys of length 2 to self.edges so that g[(u, v)] returns
the edge mobject, consistent with how edges are stored internally.

Adds a test covering vertex lookup, edge lookup (Graph), and edge
lookup (DiGraph).

Fixes #3798

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-10 17:34:39 -04:00
HairlessVillager
2ece488b2c
Support edge lookup via tuple in GenericGraph.__getitem__() (#3799)
* feat: add tuple key support in GenericGraph.__getitem__()

* feat: add an error message for missing vertice or edge

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* docs: add an example

* fix: tuple vertex return edge

---------

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-10 17:19:24 -04:00
Guillaume Vauvert
852ebd1c60
Fix empty submobjects distorting width/height of parent Mobject (#4088)
* Issue-4087 Add bug test

* Issue-4087 Fix bug

* Issue-4087 Fix comment and add type hint

* Issue-4087 Fix comment

* Issue-4087 Improve previous test instead of adding a new one

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update tests/module/mobject/mobject/test_mobject.py

* Enhance docstring for reduce_across_dimension method

Updated docstring for reduce_across_dimension method to clarify its purpose and parameters.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Remove float typehints for coords in length_over_dim

* Modify test for empty VMobject dimensions

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-06-10 16:21:52 -04:00
Irvanal Haq
82522795f1
Allow CyclicReplace and Swap to accept single Group or VGroup and add example (#4211)
* Allow Swap to accept Group and VGroup and add example

* Modify create_target return type to Group | VGroup

Updated create_target method to allow returning either Group or VGroup.

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-09 17:33:12 -04:00
Henrik Skov Midtiby
12c5640a32
Add type annotations to transform_matching_parts.py (#4400)
* Add type annotations to `transform_matching_parts.py`

* Make two type errors quiet

* Make the pytests pass

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-09 17:11:01 -04:00
Laszlo
33424fe43d
More specific Callable type annotations in mobject_update_utils (#4728)
* More specific Callable type annotations in mobject_update_utils

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-06-03 17:02:00 +00:00
Leonardo Cariaggi
1b3390073c
Allow excluding inner lines of Table (#4731)
* Add option to hide/show inner lines in Table class

* Add tests for Table class inner lines visibility

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Correct indentation

* Fix os.startfile usage to check for availability on Windows

* Add ConversationFlowScene to animate user-chatbot interactions and metadata display

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Revert "Merge remote-tracking branch 'origin/conversation' into hide_table_inner_lines"

This reverts commit c0ba5b8511, reversing
changes made to 1f71f4b0e8.

* Revert change

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Leonardo Cariaggi <leonardo.cariaggi@kbc.be>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-03 09:06:03 -04:00
Rafael Brusiquesi Martins
56f7eb2a1f
Add regression tests for four recent fixes in vectorized_mobject.py (#4750)
* Add regression tests for four recent fixes in vectorized_mobject.py

Adds four regression tests for fixes that landed without tests in the same PR:

  * 21cf9998 (PR #4630, fixes #3569 + #4629) -- IndexError in
    `get_nth_subpath` when `path_list` is empty; ensure it always returns
    a NumPy array.

  * f6cdb547 (PR #4219) -- `add_points_as_corners` silently dropped a
    single new point when called on a VMobject whose last subpath was
    complete.

  * 3d029c12 (PR #4320, fixes #4255) -- `pointwise_become_partial` cleared
    the target's points when the source had no cubic curves, surfacing as
    `Arrow3D.get_start()` / `get_end()` returning the origin after a
    `Create` animation.

  * 429f25328 (PR #4694) -- `scale(scale_stroke=True)` on a compound
    VMobject propagated the parent's scaled stroke width to every
    submobject, overwriting submobjects with their own (e.g. zero) stroke.

Each test reproduces the original failing condition at the unit level
and asserts the post-fix behavior. Validation: every test was confirmed
to fail when the corresponding fix is reverted on the source file, and
pass when the fix is restored.

4 tests, ~0.2s runtime. Tests go in the existing files
`tests/module/mobject/types/vectorized_mobject/test_vectorized_mobject.py`
(three tests, adjacent to their topically-related siblings) and
`tests/module/mobject/types/vectorized_mobject/test_stroke.py` (one test,
next to the existing `test_stroke_scale`).

Co-authored-by: LetMarq <LetMarq@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: THE-RAF <THE-RAF@users.noreply.github.com>
Co-authored-by: LetMarq <LetMarq@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-06-02 21:53:49 +00:00
Rafael Brusiquesi Martins
cfb5c684b7
Add unit tests for module-level color helpers in manim/utils/color/core.py (#4749)
* Add unit tests for module-level color helpers in manim/utils/color/core.py

Adds tests/module/utils/test_color_helpers.py covering the standalone
helper functions exported from manim.utils.color.core (color_to_rgb,
color_to_rgba, color_to_int_rgb, color_to_int_rgba, rgb_to_color,
rgba_to_color, rgb_to_hex, hex_to_rgb, invert_color, color_gradient,
interpolate_color, average_color, random_bright_color, random_color)
and the RandomColorGenerator class.

Before this PR, only the ManimColor class itself was tested
(via tests/module/utils/test_manim_color.py); the standalone helpers
had zero direct test coverage. Coverage on manim/utils/color/core.py
goes from 71% to 80% (line+branch), and 17 of the 18 testable symbols
in the file's __all__ are now exercised. The only deferred symbol is
get_shaded_rgb, which concerns lighting math rather than color
conversion and is better suited to a follow-up.

42 tests, ~0.3s runtime, no new dependencies.

Co-authored-by: LetMarq <LetMarq@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update tests/module/utils/test_color_helpers.py

Increased assertion scheme to cover all colors.

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

---------

Co-authored-by: THE-RAF <THE-RAF@users.noreply.github.com>
Co-authored-by: LetMarq <LetMarq@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-05-29 17:23:28 -04:00
Vihaan Dutta
429f25328d
Fixed inconsistent stroke width scaling for text in compound objects (#4694)
* fixed zero-stroke mobject scaling

* updated vectorized_mobject scale docstring text
2026-04-19 16:10:14 -04:00
GoThrones
c45724989d
Refactor`Mobject.put_start_and_end_on() to shift Mobject to start when it's a closed curve (#4658)
* fix: preserve geometry in put_start_and_end_on for zero-vector mobjects

* fix: preserve geometry in put_start_and_end_on for zero-vector mobjects

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed asser_array_equal line

* removed commets in mobject.py and opengl_mobject.py as suggested

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* added stacklevel=2 suggestion

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-04-14 19:57:06 +00:00
dependabot[bot]
af70b6fef2
chore(deps-dev): bump requests from 2.32.5 to 2.33.0 (#4659)
Bumps [requests](https://github.com/psf/requests) from 2.32.5 to 2.33.0.
- [Release notes](https://github.com/psf/requests/releases)
- [Changelog](https://github.com/psf/requests/blob/main/HISTORY.md)
- [Commits](https://github.com/psf/requests/compare/v2.32.5...v2.33.0)

---
updated-dependencies:
- dependency-name: requests
  dependency-version: 2.33.0
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-07 01:57:29 +00:00
dependabot[bot]
4b32312dd1
chore(deps): bump tornado from 6.5.4 to 6.5.5 (#4635)
Bumps [tornado](https://github.com/tornadoweb/tornado) from 6.5.4 to 6.5.5.
- [Changelog](https://github.com/tornadoweb/tornado/blob/master/docs/releases.rst)
- [Commits](https://github.com/tornadoweb/tornado/compare/v6.5.4...v6.5.5)

---
updated-dependencies:
- dependency-name: tornado
  dependency-version: 6.5.5
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-04-07 01:43:47 +00:00
GoThrones
90141df105
Change VMobject._bezier_t_values typehint to ndarray of np.float64 (#4675)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-04-06 17:02:25 +00:00
Benjamin Hackl
82f93b6c3c
chore: combine dependabot updates for CI retest (#4677)
Includes the changes from PRs #4666, #4668, #4669, #4670, and #4671.

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-04-06 12:19:30 -04:00
Francisco Manríquez Novoa
752b46a003
Update TinyTeX Windows/macOS installation in ci.yml to fix failing pipelines (#4679)
* Update TinyTeX installation method in CI workflow

* Fix path execution for TinyTex Windows installer
2026-04-06 11:59:03 -04:00
Mingqi Geng
21cf9998cc
Fix IndexError in get_nth_subpath() and ensure it always returns a NumPy array (#4630)
* fix #3569 and #4629

* Add changes to opengl_vectorized_mobject.py

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-03-18 11:15:45 -03:00
Henrik Skov Midtiby
ebb230f6f1
Update link in pyproject.toml to X / Twitter (#4642) 2026-03-18 13:40:16 +00:00
Xiuyuan (Jack) Yuan
46177d247e
Fix wrong angle ranges in Sphere documentation and add more examples (#3973)
* Made the document changes

* added additional example

* Apply some suggestions from code review

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Shorten sphere examples

* Fix line breaks and remove trailing whitespace

* Add example for showing portions of spheres

* Undo accidental overwrite of ExampleSphereOverlap

* Change name of manim code block

---------

Co-authored-by: Xiuyuan <u7678992@anu.edu.au>
Co-authored-by: TahitiX <136950383+TahitiX@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <francisco.manriquezn@usm.cl>
2026-03-18 00:28:52 -03:00
Henrik Skov Midtiby
468929889b
Add type annotations to mobject.py (#4388)
* Add type annotations to `mobject.py`

* More work on type annotations for mobject.py

* ...

* Almost handled all mypy errors

* Add the mypy error messages to the lines that trigger them

* Use typing.cast to avoid some mypy errors, as suggested by JasonGrace2282

* Used the ruff linter

* Fixed one typing issue and added the error descriptions to the source code for the remaning 10 errors

* Set the type of the elements in a VGroup to VMobject

* Use typing.cast to handle some specific cases.

* Code cleaning

* Updates

* When started to use typing.cast it is needed to import / define certain elements during runtime and not only during type checking

* Fix bug introduced with the type annotations.

* Made it work again

* ..

* Fixed more issues.

* Code cleanup

* Code cleanup.

Replace self.lines with self.lines_chars and self.lines_alignment.

* Handle slicing when accessing elements inside a VGroup

* Fix missing issues.

* Silence the last mypy error

* Make _Updater, _NonTimeBasedUpdater and _TimeBasedUpdater private.

* Replace | with Union[...] in one location

* Move import of Union

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Remove comment that is no longer relevant

* Overload the auto_zoom method in MovingCamera to provide better type hinting

* Codecleanup

* Code cleanup

* Renamed lines_alignment to lines_alignments and added a TODO about a future cleanup task

* More code cleanup

* Update manim/mobject/matrix.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Addressing multiple comments from Chopan50

* Implementing more suggestions from Chopan50

* More suggestions by Chopan50

* ...

* More renaming and code cleanup, as suggested by Chopan50

* Restructure code

* anim_args

* Update typing in vector_space_scene

* Implemented a number of suggestions from chopan50

* Make a list of faces with the type list[ThreeDVMobject]

* Ensure to return a VGroup if slicing is used.

* Revert back to the original code in text_mobject.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add the propagate_colors option to Mobject as it is used by VMobject.

Replace Self with _UpdateBuilder

* Simplify code

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-03-11 20:33:21 -03:00
xuruidong
98c458b6b2
docs(quickstart): fix incorrect terminology for SquareToCircle (#4631) 2026-03-08 09:47:57 +01:00
Colin Belhomme
d4af5b2baa
fix: fix cast crash in OpenGLMobject.arrange_in_grid() and OpenGLPoint.get_location() (#4622)
Added quotes to Vector3D and to Point3D to match other calls to `cast`, such has Chopan suggested

Issue #4550: https://github.com/ManimCommunity/manim/issues/4550

Co-authored-by: Colin Belhomme <colin.belhomme@telecom-paris.fr>
2026-03-03 23:48:31 -03:00
Benjamin Hackl
1157b746c3
Prepare new release: v0.20.1 (#4615)
* bump version, regenerate lockfile, changelog 1st pass

* fix two docbuild warnings

* update changelog, include newly merged PR + review suggestion
2026-02-27 08:09:59 +01:00
Irvanal Haq
6f825e8513
Fix unintended kwargs propagation in LaggedStartMap (#4613)
* Fix unintended kwargs propagation in LaggedStartMap

Ensure  intended for  are not forwarded to the superclass, and make  explicit.

* add test for keyword propagation in LaggedStartMap

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update test_composition.py

update the test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update test_composition.py

add there_and_back

---------

Co-authored-by: Benjamin Hackl <mail@behackl.dev>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-02-27 07:14:28 +01:00
Henrik Skov Midtiby
a0414dccec
Add type annotations to manim/_config/utils.py (#4230)
* Stop ignoring  manim._config erros in mypy.ini

* Aspect ratio should be a float.

* Handled more mypy issues in _config/utils.py

* Handled more mypy issues in _config/utils.py

* Removed two assert statements that triggered errors in the unittests.

* Fix last mypy issue in utils.py and activate mypy checking

* Fix type of window_size in opengl_renderer_window.py

* ...

---------

Co-authored-by: F. Muenkel <25496279+fmuenkel@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-22 22:15:16 +00:00
Benjamin Hackl
33a0e56d73
enhancement: optimize Docker image build and runtime footprint (#4604)
* docker: add libgl1 runtime dependency for OpenGL

* docker: tighten .dockerignore for smaller build context

* docs(docker): add runtime notes for latest image

* docs(docker): note ctex is not included by default

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-02-22 17:29:18 -03:00
Benjamin Hackl
80fd11efbc
Suppress pydub ffmpeg warning on import (#4603)
Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
2026-02-22 19:30:13 +00:00
Piyush Acharya
498f0b9c89
docs: add alt text to all images for accessibility (#4064)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-22 12:51:39 +01:00
Matvey Merzlikin
87cd63549c
Add support for negative z-index in AnimationGroup (#4389)
* Add support for negative z-index in AnimationGroup

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Refactor animation unpacking logic for clarity

* Fix unpacking logic to handle Mobject instances correctly

* Fix mypy check

* Fix tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix: simplify AnimationGroup unpacking for moving mobjects

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-22 11:24:32 +00:00
u7920349
cd370610c5
Documentation: manual installation of manim as a local package (#4456)
* Documentation: additonal instalation method

* Typo fix

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* docs: simplify dev-install section and restore PR template checklist

---------

Co-authored-by: CA3000 <93896083+CA3000@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-22 11:59:40 +01:00
Josie Thompson
a6af7f3d76
Cleanup TipableVMobject: avoid mutable default and fix assign_tip_attr typo (#4503)
* Small touch-ups before fixing tip bugs
- fixed mutable default argument in Tipable VMobject constructor
- fixed typo in method name assign_tip_attr
- added two todo's which outline unexpected behavior in tip placement and how to solve

* refactor: align tip attr naming and remove TODO comments

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-22 11:36:29 +01:00
Abdelsalam
e34e707858
Fix creation or animation of a zero-length DashedLine (#4606)
* fixing #4591

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-02-22 11:10:21 +01:00
Benjamin Hackl
7c1c9258d0
Fix publish release workflow (#4600)
* ci: fix publish release workflow

- Add sudo to apt-get calls (runner is non-root)
- Add contents: write permission for uploading release assets
- Drop uv sync before uv build (unnecessary)
- Replace archived upload-release-asset action and redundant
  Python/requests API script with gh release upload; tag name
  is available directly from the release event context
- Strip leading v from tag name to match built artifact filename

* ci: set bash shell for release asset upload step
2026-02-22 11:05:09 +01:00
Benjamin Hackl
000e7792bd
fix: MathTex double-brace splitting no longer fires on natural LaTeX }} (#4602)
* fix: replace double-brace splitting regex with state-machine parser

The previous re.split(r'{{|}}', ...) call split on any occurrence of
{{ or }} in the input string, which broke strings whose only }} came
from closing two nested LaTeX brace groups (e.g. ^{\frac{Mq}{M+m}}).

The new _split_double_braces() static method uses a character-level
state machine with three guards:

* Escape priority: \\ is consumed before \{ / \}, so \\}} is
  correctly read as an escaped backslash followed by a real }}, not
  misinterpreted as \ + \} + lone }.

* Whitespace-gated opener: {{ is only treated as a Manim group opener
  at the start of the string or after whitespace. Naturally-occurring
  {{ in LaTeX is usually preceded by non-whitespace (e.g. \frac{{{n}}}
  or a^{{2}}), so this eliminates the most common false positives.

* Depth-tracking closer: inside a Manim group, }} only closes the
  group when the inner brace depth is zero, so {{ a^{b^{c}} }} is
  handled correctly and nested LaTeX }} cannot trigger an early close.

Fixes #4601.

* docs: document double-brace whitespace requirement

Add a Notes section to the MathTex docstring explaining:
- how {{ }} splits a string into submobjects
- that {{ must be at start-of-string or preceded by whitespace
- that this leaves natural LaTeX like \frac{{{n}}}{k} untouched
- the { { ... } } escape hatch when a split is not wanted

Apply the same explanation to the double-brace paragraph in
docs/source/guides/using_text.rst.

* fix: use r-string for _split_double_braces docstring, halve backslash escaping
2026-02-22 10:48:51 +01:00
Benjamin Hackl
704830ff5f fix: fix permission problem in python-publish workflow 2026-02-21 00:16:28 +01:00
Benjamin Hackl
d1eea48aa6
Prepare new release, v0.20.0 (#4599)
* fix: resolve parameter shadowing bug in release script changelog command

* chore: bump version to v0.20.0, regenerate lockfile, update citation

* generate v0.20.0 changelog, first round

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* a bit of copyediting, second pass

* include newly merged PR, apply suggestions from review

* Update docs/source/changelog/0.20.0-changelog.md

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-02-20 23:50:31 +01:00
F. Muenkel
9504757918
Replace scipy.special.comb with math.comb (#4598)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-02-20 15:15:43 -03:00
Daniel Bates
7eab4c5450
Fix coords_to_point treating single list/array as batch of x-values (#4596)
When a single flat list or 1D numpy array was passed to
`Axes.coords_to_point()` (e.g. `ax.c2p([1, 2])` or
`ax.c2p(np.array([1, 2, 1]))`), the values were incorrectly
interpreted as multiple x-coordinates instead of a single (x, y) or
(x, y, z) point.

This happened because `np.asarray(([1, 2],))` produces a 2D array
with shape (1, N), which fell through to the code path that treats
`coords[0]` as a list of x-values. The fix detects this case
(ndim == 2, shape[0] == 1) and extracts the inner array so it is
handled identically to `c2p(1, 2)`.

Closes ManimCommunity#4073

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 17:31:19 +01:00
GoThrones
fda336978b
docs: improve TransformFromCopy docstring (#4597) 2026-02-20 17:20:08 +01:00
F. Muenkel
ab7cfc54d8
Add type annotations to point_cloud_mobject.py (#4586)
* Add type annotations to point_cloud_mobject.py

* Make reset_points return Self instead of None

* Fix return type of get_array_attrs()

* Change return type of reset_points() to Self in image_mobject.py
2026-02-18 12:59:15 +00:00
Aarush Deshpande
601a007192
Implement Mobject.always (#4594) 2026-02-17 19:47:58 -05:00
F. Muenkel
ab17eb58a3
Add type annotations to ``opengl_image_mobject.py`` (#4536)
* Add type annotations to opengl_image_mobject.py

* Remove mypy entry

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-02-16 23:27:05 +00:00
Francisco Manríquez Novoa
a5d4ab134c
Fix YELLOW_C and add PURE_CYAN, PURE_MAGENTA and PURE_YELLOW (#4562)
* Fix YELLOW_C and add PURE_CYAN, PURE_MAGENTA and PURE_YELLOW

* update default colors YELLOW -> PURE_YELLOW throughout the library

* chore: format + check

* Modify RandomColorGenerator.next() doctest whose output changed by adding colors

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-16 20:07:09 -03:00
Francisco Manríquez Novoa
f9b12e5d12
Fix ImageMobject 3D rotation/flipping and remove resampling algorithms lanczos (antialias), box and hamming (#4266)
* Fix 3D ImageMobject rotation

* Remove lanczos, box and hamming resampling algorithms

* Consider case where matrix A is singular (points are aligned)

* homographic_matrix -> homography_matrix

* Fix ImageInterpolationEx scene and increase height in ImageInterpolation test

* Regenerate unit test again

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* ManimFloat should probably not be used as dtype

* Import ImageMobject inside TYPE_CHECKING

* Add Camera.points_to_subpixel_coords() and do not render perpendicular images

* Modify algorithm to use height from longest side

* Prevent possible zero division

* Regenerate ImageMobject.npz

* Edit Image.transform() commentary

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-16 19:46:01 -03:00
Francisco Manríquez Novoa
ae501baf19
Fix assertion in ImageMobjectFromCamera.interpolate_color() (#4593) 2026-02-16 23:18:47 +01:00
Henrik Skov Midtiby
761bc46cc8
Add type annotations to image_mobject.py (#4458)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-02-16 15:28:24 +00:00
Henrik Skov Midtiby
357bb3fbba
Rewrite MathTex to make it more robust regarding splitting (#4515)
* Extracted the method get_mob_from_shape_element

* Moved more functionality to get_mob_from_shape_element

* More cleanup

* Parse the svg file while maintaining the group structure.

* Make the svg groups available

* Handle PERF401 issue

* [pre-commit.ci] pre-commit autoupdate (#4506)

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.14.7 → v0.14.8](https://github.com/astral-sh/ruff-pre-commit/compare/v0.14.7...v0.14.8)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>

* Added an example of the issue

* Experimenting with coloring elements from the latex equation

* ...

* Regular expression can now match more than one object

* Process the string by applying the substrings in the order they match

* Code refactoring and added type annotations

* ...

* Added a lot of test cases

* More examples

* More examples

* Use matched_strings_and_ids to simplify existing methods

* Remove unused code

* Update get_part_by_tex to use matched_strings_and_ids

* This is required for test_MathTable to pass

* Ensure that self.texstring is set.

* Added more examples from exising issues in the github repo

* Ensure that latex groups are maintained by adding an additional pair of curly braces around the extracted part

* ExampleScene -> Scene

* Added comment

* _break_up_by_substrings

* Refactor code

* Added comment to example

* Handle integer inputs well.

* Expose the original tex_string

* Do not treat the content of substrings_to_isolate as regular expressions.

* Updated examples

* Update examples

* Fix SVMobject caching issue.

* Remove traces from brace_notation_split_occurred

* Simplify MathTex::_break_up_by_substrings

* Fix small issue in tex that in some cases moved elements a tiny bit around

* No use of regular expressions for locate substrings.

* Updated notes to the set of test cases

* Handle issues with the center environment.

* Add example

* Fix issue with rectangles (e.g. from sqrt)

* ConvertToOpenGL

* Reduce the number of nesting levels.

* Use the specified arg_seperator

* Deal with the double curly brace markup

* Code cleanup

* Code cleanup

* Rollback a few changes

* Code cleanup

* Adjust paths the generated artefacts in tests that rely on MathTex

* Added a remark to the using text guide on enclosing snippets in curly braces for substrings_to_isolate to work

* Added space around the numerator argument to frac to avoid having double curly braces in the example.

This would otherwise trigger MathTex to split the string at that location.

* Log errors properly and display some information about the errors and their context.

* Code refactoring as suggested by Benjamin

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-16 14:22:56 +01:00
F. Muenkel
6e9ec60b6f
Add type annotations to opengl_compatibility.py (#4585)
* Add type annotations to opengl_compatibility.py

* Tighten type hinting on namespace variables
2026-02-12 22:54:29 +00:00
Sacha
c8db165825
Resolve more race conditions potentially happening during directory creation (#4589)
* fixed division by 0

* fixed division by 0

* fixed division by 0

* updated lock file

* Revert "fixed division by 0"

This reverts commit b916a0c9c9.

* Add tests for turn_animation_into_updater with zero/negative run_time

* updated lock file

* tests

* tests

---------

Co-authored-by: Benjamin Hackl <mail@behackl.dev>
2026-02-12 08:18:26 +01:00
dependabot[bot]
b4049bd6c7
Bump pillow from 12.1.0 to 12.1.1 (#4588)
Bumps [pillow](https://github.com/python-pillow/Pillow) from 12.1.0 to 12.1.1.
- [Release notes](https://github.com/python-pillow/Pillow/releases)
- [Changelog](https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst)
- [Commits](https://github.com/python-pillow/Pillow/compare/12.1.0...12.1.1)

---
updated-dependencies:
- dependency-name: pillow
  dependency-version: 12.1.1
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-11 16:09:06 -03:00
Oll-iver
8a5267a9ee
Enable strict=True for zip() where safe (#4547)
* sub_alphas is derived directly from to_update so they're guaranteed to be of the same length.

* self.shapes is initialised as a direct copy of the mobject, guaranteed to be of same length.

* linspace in this case guarantees both arrays are of equal size (self.n_segments).

* Any transformation already requires that each datapoint in the first tuple has a corresponding datapoint in the second (ie same length)

* Replaced arange with linspace, eliminates risk of floating point errors and forces rgbas and offset to be the same size for strict=True

* all_arc_configs is either defined specifically by length of point_pairs or strictly forced to be the same length (n). In any case they'll always be the same length so strict=True works.

* There should always be an equal amount of start and end anchors; radius_list is defined directly from the length of vertex_group; both outer_vertices and inner_vertices posess n vertices.

* boundary_times always contains has an even length so both 'slices' in the zup function are the same length.

* colors_in_gradient is defined to be the same length as p_list_complete; labels and parts are seemingly user inputs with no guarantee of equal length; val_range is defined to be same lenght as self.bar_names; however there's no authentication that self.values has a fixed length after it's been defined ie user can append to the list creating a mismatch between len(self.values) and len(self.bars)

* In most cases here, the tuples are either defined to be of same length or manipulated to be by the align_data function. In the match_points function there is currently no validation to ensure both mobjects are the same length.

* Reverting _add_x_axis_labels() zip() function back
to strict=False due to failing test cases

* Reverted strict zip usage

* color_gradient is defined to be same length as p_list_complete & within _add_x_axis_labels we define val_range to be the same length as self.bar_names

* align_data and lock_matching_data have no validation to ensure tuples in the zip() function are of the same length. Every other time zip() is used here it is generally immediately manipulating or explicitly defining the tuples to be of same length

* All tuples in zip() functions here are either clearly the same size or manipulated to be the same size using the make_even function.

* The tuples in the zip() function will clearly be of equal length, the second tuple is simply a cyclic shift of the first.

* In the ingest_submobjects function arrays is a one to one mapping of attrs so they are guaranteed to have equal lengths.

* Every usage of zip() consists of tuples that are either manipulated to be equal size or defined to be equal size.

* the zip() function in bezier_remap will always consist of equal length tuples as current_number_of_curves is read directly from the shape of bezier_tuples and is used to dictate the size of split_factors.

* The zip() function color_gradient() will always consist of equal length tuples as floors is defined directly from alphas (which also defines alphas_mod1)

* The tuples in the zip() function in adjacent_n_tuples will always be the same length so strict=True.

* The find_intersection() contains a zip() function that has been set to strict=True. While it is technically possible to pass tuples to this function that are *not* the same length, this would result in generally unexpected behaviour anyway.

* Changed zip() function to have strict=True in __init__() as custom_labels is dependent on tick_range so guaranteed to have the same length.

* Several instances of zip() set to strict=True. In add_coordinates we have axis manipulated to be the same length as tick_range. In get_riemann_rectangles() we have colors dependent on of x_range_Array forcing them to be the same length. Finally in plot_line_graph()  it is clearly intended that all inputs used in the zip() function are of the same length (except possibly z which may not exist and will be made equal length to x); while it is not guaranteed they will be the same length this would cause unintended behaviour.

* zip() function bool changed to strict=True in all these test cases. Most test cases either a) hardcode two things to be the same length, b) verify things are the same length before the function or c) explicitly exist to check whether two things are the same length.
2026-02-11 10:39:25 +01:00
Tim Hutt
6adc6e4cf6
Add py.typed to declare manim as having type hints (#4553)
* Add py.typed to declare manim as having type hints

This tells tools like Pyright that this package has its own type hints and it should try to look for them in typeshed.

Fixes #4552

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-02-11 10:35:12 +01:00
Henrik Skov Midtiby
21e7e0d9c1
Cleaned up mypy.ini (#4584)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-02-11 10:04:31 +01:00
Sacha
7efa45492f
Fix TOCTOU Race Conditions when creating directories (#4587)
* fixed division by 0

* fixed division by 0

* fixed division by 0

* updated lock file

* Revert "fixed division by 0"

This reverts commit b916a0c9c9.

* Add tests for turn_animation_into_updater with zero/negative run_time

* updated lock file

* tests

---------

Co-authored-by: Benjamin Hackl <mail@behackl.dev>
2026-02-11 10:00:40 +01:00
dependabot[bot]
c261c61dfd
Bump nbconvert from 7.16.6 to 7.17.0 (#4582)
Bumps [nbconvert](https://github.com/jupyter/nbconvert) from 7.16.6 to 7.17.0.
- [Release notes](https://github.com/jupyter/nbconvert/releases)
- [Changelog](https://github.com/jupyter/nbconvert/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jupyter/nbconvert/compare/v7.16.6...v7.17.0)

---
updated-dependencies:
- dependency-name: nbconvert
  dependency-version: 7.17.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-10 22:42:58 -03:00
Aarush Deshpande
9d98f00ee9
Remove __future__.annotations from required imports (#4571)
* Remove __future__.annotations from required imports
2026-02-05 21:57:20 -03:00
Benjamin Hackl
587e8d6546
Rework and consolidate release changelog script, add previously skipped changelog entries (#4568)
* rewrite dev_changelog script from scratch, turn into release util cli

* cleanup dependencies

* regenerate skipped changelog entries

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* remove changelog section from PR template

* fix pre-commit checks

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2026-02-04 10:10:39 +01:00
Sacha
d49115316e
Fixed division by 0 in "turn_animation_into_updater" (#4567)
* fixed division by 0

* fixed division by 0

* fixed division by 0

* updated lock file

* Revert "fixed division by 0"

This reverts commit b916a0c9c9.

* Add tests for turn_animation_into_updater with zero/negative run_time

* updated lock file

---------

Co-authored-by: Benjamin Hackl <mail@behackl.dev>
2026-02-03 22:40:09 +00:00
Rin
2f38426ceb
fix: initialize a_tex to prevent UnboundLocalError in PolarPlane (#4557) 2026-02-02 01:09:50 -03:00
Arnaud
bbdcda1ff5
add type annotations and docstrings for opengl_renderer.py (#4537)
* type annotations and docs for opengl_renderer.py

* add missing self

* Fix RTD build: move Window import to TYPE_CHECKING block

The Window import was moved to module-level in a recent type annotation
commit, but this causes opengl_renderer_window.py to be imported at
load time, triggering pyglet which fails on headless systems (RTD) when
it tries to create a shadow window. Moving the import into TYPE_CHECKING
preserves type hints for mypy while avoiding runtime display dependency.

* Fix mypy errors in opengl_renderer.py

- Cast np.linalg.inv() result to correct type
- Convert quaternion list to ndarray before passing to rotation_matrix_transpose_from_quaternion
- Cast get_center return value
- Fix return type for pixel_coords_to_space_coords (ensure float dtype)
- Add type: ignore for moderngl.create_context backend arg (incorrect stubs)
- Add type: ignore for blend_func assignment (incorrect stubs)

* Fix mypy errors and runtime import issues in opengl_renderer.py

- Import MatrixMN and Point3D at runtime (needed for typing.cast)
- Cast np.linalg.inv() result to correct MatrixMN type
- Convert quaternion list to ndarray before passing to rotation_matrix_transpose_from_quaternion
- Cast get_center and pixel_coords_to_space_coords return values to Point3D
- Ensure float dtype in np.array literals for type consistency

* Add runtime import of Window in init_scene

The Window class is imported inside TYPE_CHECKING for type hints, but
needs to be imported at runtime when actually creating a window. This
import is deferred to avoid triggering pyglet display initialization
on headless systems (RTD build).

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-01-25 21:24:16 +01:00
BHearron38
2c0b49be9f
fix: infinite recursion caused by accessing color of a highlighted Ta… (#4435)
* fix: infinite recursion caused by accessing color of a highlighted Table cell.

fix: removed type: ignore[attr-defined] mypy was not a fan of

* fix: added back needed mypy type ignore

* Add regression tests for Table/BackgroundRectangle color access

Tests for infinite recursion issue fixed in PR #4435 (issue #4419).

Refs: #4419

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Refactor BackgroundRectangle color test to geometry tests

Move test_background_rectangle_color from test_table.py to
test_unit_geometry.py since BackgroundRectangle lives in
geometry/shape_matchers.py, not in tables.

Regression test for ManimCommunity/manim#4419 (infinite recursion
when accessing BackgroundRectangle.color)

* Fix: Added missing manim GREEN import needed for test_BackgroundRectangle_color_access()

---------

Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
Co-authored-by: Benjamin Hackl <mail@behackl.dev>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: bhearr <None>
2026-01-25 16:47:58 +01:00
Benjamin Hackl
eb8194a640
Fix broken aquabeam OpenGL link using Wayback Machine (#4545)
Refs: #4468, #4509

Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
2026-01-25 12:33:39 +00:00
Aditi Juneja
eca7f17853
using color instead of fill_color with MathTeX for node labels (#4501)
* fill_color --> color for MathTeX

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-01-25 11:53:05 +01:00
Arnaud
2317b0ee8b
feat: add a 'seed' option for reproducible outputs (#4532)
* feat: 'seed' option for reproducible outputs

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* enh: let Scene automatically pick global random seed, use arg as override

* chore: move import slightly

* chore: add test for color generator being reproducible with global config seed

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-01-20 22:24:32 +01:00
F. Muenkel
d938533742
Add type annotations to ``rotation.py`` (#4535)
* Add type annotations to rotation.py

* Remove mypy entry

* Make typing of axis, about_point and about_edge consistent

* More typing in transform.py
2026-01-19 17:32:29 -03:00
Francisco Manríquez Novoa
0b3f28a5af
Revert "Set the default Python version to 3.13 in the uv installation guide (…" (#4534)
This reverts commit 83bcafb0e7.
2026-01-18 08:49:10 +01:00
Arnaud
6a56cc5ce6
fix: show doc of RandomColorGenerator (#4533) 2026-01-17 15:53:31 -03:00
Benjamin Hackl
cd7cd1b219
fix release pipeline: install dependencies (#4531) 2026-01-17 11:55:01 +01:00
Benjamin Hackl
9a6550d356
Prepare new release v0.19.2 (#4528)
* chore: bump version numbers etc

* chore: update lockfile

* chore: update date before release
2026-01-17 09:26:40 +01:00
Henrik Skov Midtiby
06f2fe231a
Checking version requirements for dependencies (#4529)
* Update pydub minimum version to 0.22

* numpy>=2.1

* av>=15.0

* isosurfaces>=0.1.1

* Updated lower bounds on dependencies.
2026-01-16 01:31:56 +01:00
Benjamin Hackl
d64af99f89
Add .github/release.yml for improved classifications in automatically generated changelogs (#4526)
* add release.yml file for automated changelog classification

* chore: cleanup leftover comments, add link to doc reference
2026-01-13 22:37:39 +01:00
dependabot[bot]
2e0aa8f529
Bump virtualenv from 20.35.4 to 20.36.1 (#4525)
Bumps [virtualenv](https://github.com/pypa/virtualenv) from 20.35.4 to 20.36.1.
- [Release notes](https://github.com/pypa/virtualenv/releases)
- [Changelog](https://github.com/pypa/virtualenv/blob/main/docs/changelog.rst)
- [Commits](https://github.com/pypa/virtualenv/compare/20.35.4...20.36.1)

---
updated-dependencies:
- dependency-name: virtualenv
  dependency-version: 20.36.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-13 22:05:07 +01:00
dependabot[bot]
88718ce43f
Bump filelock from 3.20.0 to 3.20.3 (#4527)
Bumps [filelock](https://github.com/tox-dev/py-filelock) from 3.20.0 to 3.20.3.
- [Release notes](https://github.com/tox-dev/py-filelock/releases)
- [Changelog](https://github.com/tox-dev/filelock/blob/main/docs/changelog.rst)
- [Commits](https://github.com/tox-dev/py-filelock/compare/3.20.0...3.20.3)

---
updated-dependencies:
- dependency-name: filelock
  dependency-version: 3.20.3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-13 22:04:42 +01:00
Swarnlata
73eeacb880
fix: correct Circle.point_at_angle calculation (#4236) (#4438)
* fix: correct Circle.point_at_angle calculation for accurate arc mapping

* chore: remove unused variable 'start_angle' to fix pre-commit CI

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* test: add test for Circle.point_at_angle()

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Benjamin Hackl <mail@behackl.dev>
2026-01-13 18:45:02 +01:00
Jude Nimo
739c2c3f14
Fix type error: pass scene instead of self to get_hash_from_play_call (#4524)
Co-authored-by: Jude Nimo <judenimo@users.noreply.github.com>
2026-01-13 18:19:20 +01:00
dependabot[bot]
d75f84a985
Bump actions/upload-artifact from 5 to 6 (#4522)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 5 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-13 17:54:32 +01:00
dependabot[bot]
b59f311331
Bump actions/cache from 4 to 5 (#4523)
Bumps [actions/cache](https://github.com/actions/cache) from 4 to 5.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-13 17:54:08 +01:00
Christian Clauss
dc4a8bb741
Replace legacy numpy usage ruff rule NPY002 (#4516) 2026-01-13 17:23:34 +01:00
Benjamin Hackl
4bc77b3a00
Bump Python target versions of both mypy and ruff
Merging #4520 - all CI checks passing and approved by JasonGrace2282
2026-01-13 01:13:21 +01:00
Benjamin Hackl
c424f83cb4
Bump minimum Python to 3.11 and av to 14.0.1 (#4385)
* chore: bump minimum supported python to 3.11

* fix: breaking changes from av upgrade

* chore: slightly bump minimum required version of av to 14.0.1

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* chore: update lockfile

* chore: update lockfile again with --upgrade

* Update pyproject.toml

* chore: CI pipeline os/version changes

* fix: indentation in ci.yml

* fix: use result.output instead of result.stdout for test_manim_cfg_subcommand

In Click 8.3.1 (pulled in by av>=14.0.1), help text output
behavior changed for no_args_is_help=True. Using result.output
instead of result.stdout makes the test robust across Click versions,
matching the pattern used in other tests like
test_manim_plugins_subcommand.

* fix: add UP to imports in get_winding_number doctest

* fix: add match_interpolate to imports in doctest

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-01-12 14:27:48 +01:00
Christian Clauss
0d2533231b
Test on Apple Silicon ARM64 (#4496)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-01-12 01:22:16 +01:00
Henrik Skov Midtiby
b24b61776b
Add type annotations to three_dimensions.py (#4497)
* Initial type work

* More kwargs Any

* More typing

* _get_u_values_and_v_values cleaned

* self.checkerboard_colors

* Simplify code

* colorscale

* new_colors

* Ugly hacks to make the opengl objects behave

* checkerboard_colors

* Ignored a single type error

* Ignored the last type error

* Remove entry from mypy.ini

* set_fill_by_checkerboard

* resolution

* u_range and v_range

* ThreeDAxes

* Is tuple a color?

* resolution

* Point3D and Vector3D

* More with Point3D

* resolution

* colorscale

* checkerboard_colors Iterable

* Breaking change: checkerboard_colors can now be set to None

* Revert "Breaking change: checkerboard_colors can now be set to None"

This reverts commit d5c54cf5fa.

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2026-01-11 23:47:38 +01:00
pre-commit-ci[bot]
d308ae3372
[pre-commit.ci] pre-commit autoupdate (#4518)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.14.9 → v0.14.10](https://github.com/astral-sh/ruff-pre-commit/compare/v0.14.9...v0.14.10)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2026-01-11 23:41:24 +01:00
Benjamin Hackl
ff86ee6333 Merge remote-tracking branch 'codeberg/main' 2026-01-11 00:01:43 +01:00
TahaShams
ef0cf2a34d Docs: Fix TangentialArc example and add quadrant visualization (codeberg-mirror/#1)
## Overview: What does this pull request change?
This PR fixes the documentation for `TangentialArc`.
1. It replaces the static code block in the `TangentialArc` example with the `.. manim::` directive, allowing the example image/video to actually render in the documentation.
2. It adds a new second example scene, `TangentialArcCorners`, which visually demonstrates how the `corner` parameter (e.g., `(1,1)`, `(-1,1)`) affects the arc's orientation.

## Motivation and Explanation: Why and how do your changes improve the library?
Previously, the `TangentialArc` example was hidden inside a standard code block, so users could not see what the output looked like.
Additionally, the `corner` parameter is complex to visualize mentally. The new `TangentialArcCorners` scene provides a clear visual reference for all four possible quadrant configurations, making the class much easier to learn.

## Links to added or changed documentation pages
N/A

## Further Information and Comments
I have tested these changes locally and verified that the images generate correctly.
I am submitting this to the Codeberg mirror as per the current guidance regarding the GitHub incident.

**Visual Proof of the new example:**
I have attached the image

## 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

Reviewed-on: https://codeberg.org/ManimCommunity/manim/pulls/1
Reviewed-by: Benjamin Hackl <behackl@noreply.codeberg.org>
Co-authored-by: TahaShams <01-134222-153@student.bahria.edu.pk>
Co-committed-by: TahaShams <01-134222-153@student.bahria.edu.pk>
2026-01-10 23:58:06 +01:00
Benjamin Hackl
75285d1f01 chore: update README 2026-01-09 23:30:49 +01:00
pre-commit-ci[bot]
d60154d024
[pre-commit.ci] pre-commit autoupdate (#4514)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.14.8 → v0.14.9](https://github.com/astral-sh/ruff-pre-commit/compare/v0.14.8...v0.14.9)
- [github.com/pre-commit/mirrors-mypy: v1.19.0 → v1.19.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.19.0...v1.19.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-12-16 14:08:38 +01:00
Henrik Skov Midtiby
976d634656
Remove deprecation warning from pytest np.trapz -> np.trapezoid (#4513) 2025-12-15 17:42:23 +01:00
pre-commit-ci[bot]
765f02f3ed
[pre-commit.ci] pre-commit autoupdate (#4506)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.14.7 → v0.14.8](https://github.com/astral-sh/ruff-pre-commit/compare/v0.14.7...v0.14.8)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-12-15 12:10:32 +01:00
dependabot[bot]
a50d8363e7
Bump actions/checkout from 5 to 6 (#4498)
Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-02 01:18:38 +01:00
Christian Clauss
de090c1bd0
Add ruff rules PERF for performance (#4492)
* Add ruff rules PERF for performance

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-12-01 10:42:46 +00:00
Benjamin Hackl
e85bfca015
Prepare new release v0.19.1 and remove support for Python 3.9 (#4490)
Co-authored-by: Francisco Manríquez <francisco.manriquezn@usm.cl>
2025-11-30 23:20:20 -03:00
Benjamin Hackl
0541f9e6f1 Merge branch 'dependabot/github_actions/actions/upload-artifact-5' 2025-11-30 15:36:11 +01:00
Benjamin Hackl
c78de89e64 Merge branch 'dependabot/github_actions/github/codeql-action-4' into dependabot/github_actions/actions/upload-artifact-5 2025-11-30 15:35:10 +01:00
Benjamin Hackl
ab045f0ae1 Merge branch 'dependabot/github_actions/astral-sh/setup-uv-7' into dependabot/github_actions/actions/upload-artifact-5 2025-11-30 15:34:55 +01:00
pre-commit-ci[bot]
52820c6b65
[pre-commit.ci] pre-commit autoupdate (#4467)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.14.2 → v0.14.6](https://github.com/astral-sh/ruff-pre-commit/compare/v0.14.2...v0.14.6)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-11-30 15:18:39 +01:00
Jake Kinchen
51aa01acea
Fix duplicated arrow tips in DashedVMobject (issue #3220) (#4484)
* Fix duplicated arrow tips in DashedVMobject and add tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-11-27 09:55:53 +00:00
dependabot[bot]
fcb9f6fee3
Bump astral-sh/setup-uv from 6 to 7
Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 6 to 7.
- [Release notes](https://github.com/astral-sh/setup-uv/releases)
- [Commits](https://github.com/astral-sh/setup-uv/compare/v6...v7)

---
updated-dependencies:
- dependency-name: astral-sh/setup-uv
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-26 22:20:43 +00:00
dependabot[bot]
adb0915605
Bump actions/upload-artifact from 4 to 5
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-26 22:20:22 +00:00
dependabot[bot]
b6a464ed64
Bump github/codeql-action from 3 to 4
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3 to 4.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v3...v4)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: '4'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-26 22:20:21 +00:00
Francisco Manríquez Novoa
3bf384ab1e
Bump macOS image from deprecated macos-13 to macos-15-intel (#4481) 2025-11-26 22:19:19 +00:00
godalming123
a1bca6c3b9
Fix type errors and add typings for Mobject.apply_function(), its derivatives, and other utility functions (#4228)
* Fixes

Fix type errors, add types for the transformation functions, and fix one case where the about_point and about_edge options were not correctly passed in apply_complex_function in mobject.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* More fixes

- Import a couple types that should have been imported
- Remove the redefinition of self.background_stroke_width in manim/mobject/types/vectorized_mobject.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-11-26 15:11:09 -03:00
Guilherme Tomiasi
51377b530c
Pass ndarrays to mapbox_earcut.triangulate_float32() to fix TypeError in mapbox_earcut==2.0.0 (#4479)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-11-20 02:03:23 +00:00
nubDotDev
3c6ea0e2d6
Allow passing a buff to LabeledDot (#4403)
* Give LabeledDot a buffer and improve radius calculation

* fix norm calculation

* documentation

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-11-19 20:11:11 +00:00
Benjamin Hackl
00d0b297b4
make sure that if updating is suspended for a parent mobject, children are still updated (#4402)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-11-19 19:47:21 +00:00
Henrik Skov Midtiby
83bcafb0e7
Set the default Python version to 3.13 in the uv installation guide (#4480)
* Set the default python version to 3.13 in the uv installation guide.

* Capitalize Python

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-11-19 19:12:11 +00:00
Morkunas
7e950b38fa
Prevent mutation of about_point in apply_points_function_about_point - Fixes #4445 (#4478)
* Add regression tests for about_point view mutation issue

This adds regression tests for issue #4445 where using get_vertices()[0]
as about_point in transformation methods would cause incorrect results
due to numpy array view mutation.

Tests added:
- test_rotate_about_vertex_view
- test_scale_about_vertex_view
- test_stretch_about_vertex_view
- test_apply_matrix_about_vertex_view
- test_opengl_rotate_about_vertex_view (OpenGL was not affected by the bug)

Related to #4445

* Fix about_point view mutation in apply_points_function_about_point

When about_point parameter receives a numpy array view (e.g., from
get_vertices()[0]), the in-place operation `mob.points -= about_point`
would mutate the view, corrupting the transformation calculation.

This fix copies about_point before using it to prevent view mutation.

The OpenGL renderer was not affected by this bug because it uses
`arr - about_point` (creates temporary) instead of `arr -= about_point`
(mutates in-place).

Fixes #4445

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-11-16 21:17:08 +01:00
NightyStudios
9528337ad4
Allow selection of all scenes to render using '*' (#4470)
* added option to render all scenes by typing '*' when prompted

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-11-08 20:22:57 +01:00
Brainsucker92
afa4692f7b
Add implementation for tangential arc (#4469)
* Add implementation for tangential arc

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add example

* Improve doc slightly

* Remove corner type

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add test for TangentialArc

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Import Line only if type checking

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add missing type hint

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add test for tangential arc

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-11-06 23:05:24 +01:00
pre-commit-ci[bot]
038d16b531
[pre-commit.ci] pre-commit autoupdate (#4460)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.14.1 → v0.14.2](https://github.com/astral-sh/ruff-pre-commit/compare/v0.14.1...v0.14.2)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-31 21:35:10 +01:00
Sir James Clark Maxwell
3e8f41c9be
Better parsing of color styles in CodeMobject (#4454)
* fixed problem: default value of color in styles in CodeMobject

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* added accidently removed test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update code_mobject.py

Code suggested by maejam

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
Co-authored-by: Henrik Skov Midtiby <henrikmidtiby@gmail.com>
2025-10-26 08:47:47 +01:00
F. Muenkel
4dd2937f1e
Add type annotations to cairo_renderer.py (#4393)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
2025-10-24 20:59:11 +00:00
SASHAKT1290
a810f5535c
Update default resolution in CLI to match Manim’s 1920x1080 default settings (#4452)
* swapped height and width values

* updated default resolution settings
2025-10-24 21:56:35 +02:00
Henrik Skov Midtiby
dd04fce52a
Solution to issue 3562. (#4373)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-10-24 21:56:08 +02:00
Sir James Clark Maxwell
e7d69834b3
Ensure that start and end points are stored as float values in Line3D (#4080)
* fixed problem with type conversions in Line3D

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed broken test and Arrow3D

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update manim/mobject/three_d/three_dimensions.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Update manim/mobject/three_d/three_dimensions.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Delete unnecessary file

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed typo in variable nam

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2025-10-24 21:14:55 +02:00
Nikhil Arora
7ffdf04dcb
Fix: correct tuple order to (height, width) and map height→pixel_height, width→pixel_width (#4440)
Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
2025-10-24 13:18:04 +00:00
pre-commit-ci[bot]
e489ebf220
[pre-commit.ci] pre-commit autoupdate (#4409)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.12.9 → v0.14.1](https://github.com/astral-sh/ruff-pre-commit/compare/v0.12.9...v0.14.1)
- [github.com/pre-commit/mirrors-mypy: v1.17.1 → v1.18.2](https://github.com/pre-commit/mirrors-mypy/compare/v1.17.1...v1.18.2)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
2025-10-24 14:41:40 +02:00
dependabot[bot]
ce2c3c43e4
Bump actions/checkout from 4 to 5 (#4418)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-23 10:22:40 +02:00
dependabot[bot]
5ccc5bac19
Bump actions/setup-python from 5 to 6 (#4433)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5 to 6.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Henrik Skov Midtiby <hemi@mmmi.sdu.dk>
2025-10-23 10:21:56 +02:00
Christian Clauss
e6777d6334
Fix failing pre-commit tests (#4434) 2025-10-23 08:39:17 +02:00
Riccardo Bergamaschi
855ea863b6
Add type annotations to opengl_mobject.py (#4398)
* feat(manim.mobject.opengl): added type annotations for `opengl_compatibility.py`

* feat(manim.mobject.opengl): typed almost all attribute definitions in `OpenGLMobject.__init__`

* feat(manim.mobject.opengl): typed more methods for `OpenGLMobject`

* fix(manim.mobject.opengl): import `override` from `typing_extensions`

* fix(manim.mobject.opengl): import `Never` from `typing_extensions`

* feat(manim.utils.config_ops): made `_Data` descriptor generic, to allow correctly typing `OpenGLMobject`

* fix(mypy.ini): don't ignore `manim.mobject.opengl.opengl_mobject`

* fix(manim.utils.config_ops): import `TypeVar` from `typing_extensions`, because the `typing` one does not have the `default` argument.

* feat(manim.mobject.opengl.opengl_mobject): Type checked more methods in `OpenGLMobject`.

* fix(manim.mobject.opengl.opengl_mobject): Fix a typo in `OpenGLMobject.restore`.

* feat(manim.mobject.opengl.opengl_mobject): Typed more methods in `OpenGLMobject`.

* feat(manim.mobject.opengl.opengl_mobject): Moved `overload`s inside an `if TYPE_CHECKING` statement.

* feat(manim.mobject.opengl.opengl_mobject): Added type annotations for `**kwargs` in a set of related methods.

* Revert "feat(manim.mobject.opengl): added type annotations for `opengl_compatibility.py`"

This reverts commit 1cd1550dd2.

* fix(OpenGLMobject): defined `get_array_attrs` method (and typed `_original__init__` at class scope).

I followed the advice of an existing `# TODO` comment and the implementation in `Mobject`. This also resolves a mypy error in this class (missing attribute).
It's interesting because the `get_array_attrs` method is (was) only defined in three classes:
- `Mobject`
- `PMobject`
- `OpenGLPMobject`

* feat(manim.mobject.opengl.opengl_mobject): Added type annotations for the `override_animate()`.

* feat(manim.mobject.opengl.opengl_mobject): Added type annotations to `_AnimationBuilder` and some methods in `OpenGLPoint`.

* fix(manim.mobject.opengl.opengl_mobject): fix failing tests

* fix(OpenGLMobject): default implementation of `pointwise_become_partial(…)` had to return `self`!

* feat(OpenGLMobject): added `type: ignore[no-untyped-call]` for calls to `ShaderWrapper` methods (not yet annotated).

* feat(OpenGLMobject): annotated shader-related `ClassVar`s

* feat(OpenGLMobject): typed several `**kwargs` and added `type: ignore[no-any-return]`s for cases where mypy cannot understand operations on numpy arrays.

* feat(OpenGLMobject): typed more `**kwargs` and fixed `set_color` arguments

* feat(OpenGLMobject): Added more type annotations.

* feat(OpenGLMobject): Typed `OpenGLMobject.uniforms` and `OpenGLMobject.fixed_orientation_center`

* fix(OpenGLMobject): fix tests

* fix(OpenGLGroup): annotate `**kwargs`

* fix(OpenGLPoint): annotate `**kwargs`

* fix(OpenGLPoint): corrected `**kwargs` and removed two `type: ignore`s

* fix(OpenGLPoint): removed `# type: ignore[no-untyped-call]`s

* fix(ci): import `Self` from `typing_extensions` rather than `typing`.

* fix(ci): import `TypeAlias` from `typing_extensions` rather than `typing`.

* feat(OpenGLMobject): make use of PEP 728.

* fix(ci): update `typing-extensions` requirement to the first version that supports PEP 728.

* fix(OpenGLMobject): avoid variable redefinitions in the `arrange_in_grid` method.

* fix(mypy.ini): remove unused changes to `mypy` configuration.

* fix(OpenGLMobject): use different symbols for the two `updater` variables.

* Revert "fix(ci): update `typing-extensions` requirement to the first version that supports PEP 728."

This reverts commit 69b96c6420.

* fix(OpenGLMobject): remove `TypedDict`s and switch to the less precise `**kwargs: Any`.

* Handle three no-any-return issues.

* Removed the slash divider in function parameters

* Removed the slash divider in function parameters

* Keep a single slash divider - to make return types match

---------

Co-authored-by: Henrik Skov Midtiby <henrikmidtiby@gmail.com>
2025-08-21 20:59:47 +00:00
NIKIL PAUL
8535d0675b
Added license information to documentation landing page (#3986)
* edit: added the descriptions to /docs/source/index.rst

* apply suggestions from review

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-08-18 23:16:45 +02:00
pre-commit-ci[bot]
3ea23e9cd0
[pre-commit.ci] pre-commit autoupdate (#4405)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.12.8 → v0.12.9](https://github.com/astral-sh/ruff-pre-commit/compare/v0.12.8...v0.12.9)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-18 21:09:36 +02:00
Benjamin Hackl
7e2ea86e98
Fix some config options specified via --config_file not being respected properly (#4401) 2025-08-17 09:40:38 -04:00
Henrik Skov Midtiby
6b668784f2
Add type annotations to moving_camera.py (#4397) 2025-08-13 18:33:51 -04:00
Henrik Skov Midtiby
dd91a8a2ee
Simplify the function remove_invisible_chars in text_mobject.py (#4394)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-13 15:01:20 +00:00
Henrik Skov Midtiby
ec306075a9
Add type annotations to opengl_geometry.py (#4396) 2025-08-13 10:29:45 -04:00
Benjamin Hackl
2d3aa0d2f4
Ensure leading whitespace does not change line height for lines in CodeMobject (#4392)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-12 21:38:42 -04:00
Francisco Manríquez Novoa
a56c06cd51
Rename types like RGBA_Array_Float to FloatRGBA and add types like FloatRGBA_Array (#4386)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-08-12 10:37:59 -04:00
Henrik Skov Midtiby
03a94141d2
Add type annotations to text_mobject.py (#4381)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-08-11 21:16:39 +00:00
Henrik Skov Midtiby
5a2b3384f1
Rewrite color_gradient to always return a list of ManimColors (#4380)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-11 15:15:38 -04:00
nubDotDev
c4dc0ea86d
Allow passing a tuple to buff in SurroundingRectangle to specify buffer in x and y direction independently (#4390)
* Give SurroundingRectangle 2D buffer

* add test for SurroundingRectangle buff parameter

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-08-11 20:20:57 +02:00
pre-commit-ci[bot]
e822de0315
[pre-commit.ci] pre-commit autoupdate (#4391)
updates:
- [github.com/pre-commit/pre-commit-hooks: v5.0.0 → v6.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v5.0.0...v6.0.0)
- [github.com/astral-sh/ruff-pre-commit: v0.12.7 → v0.12.8](https://github.com/astral-sh/ruff-pre-commit/compare/v0.12.7...v0.12.8)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-11 20:18:58 +02:00
F. Muenkel
f69f2545d9
Rename SceneFileWriter.save_final_image() to save_image() (#4378)
* Rename save_final_image() to save_image()

* Rename SceneFileWriter.save_final_image() to save_image() and fix
  docstring

* fix some type annotations

* make docstrings consistent

* Update manim/scene/scene_file_writer.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-11 18:59:48 +02:00
F. Muenkel
48d5a36aad
Typing opengl_renderer_window.py (#4363)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Francisco Manríquez <francisco.manriquezn@usm.cl>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-08-09 17:11:41 -04:00
Francisco Manríquez Novoa
05cc414014
Refactor imports from collections.abc, typing and typing_extensions for Python 3.9 (#4353)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-09 17:51:30 +00:00
Francisco Manríquez Novoa
b3df1cf79e
Properly define init_points methods (#4360) 2025-08-09 19:28:20 +02:00
nubDotDev
cb8af6f2d0
Bevel cube corners (#4361)
* Fixed surface animations in OpenGL

* bevel cube joints
2025-08-09 19:24:37 +02:00
Benjamin Hackl
d8a7e55ee1
Exclude check for cyclic imports by CodeQL (#4384)
* exclude check for cyclic imports by CodeQL

* also exclude py/unsafe-cyclic-import
2025-08-09 19:22:07 +02:00
pre-commit-ci[bot]
2d8d81c209
[pre-commit.ci] pre-commit autoupdate (#4204)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.11.0 → v0.12.7](https://github.com/astral-sh/ruff-pre-commit/compare/v0.11.0...v0.12.7)
- [github.com/pre-commit/mirrors-mypy: v1.15.0 → v1.17.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.15.0...v1.17.1)

* Fix errors

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
2025-08-09 17:23:28 +02:00
Kabilan
fc68c10433
Add info-level logging for config files read and enhance output (#4375)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-08-07 20:24:59 +00:00
Henrik Skov Midtiby
d0521fa06d
Add type annotations to movement.py (#4371)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-06 17:52:16 -04:00
Henrik Skov Midtiby
e339a68e54
Add type annotations to growing.py (#4368)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-06 21:21:57 +00:00
Henrik Skov Midtiby
c887b51d63
Add type annotations to composition.py (#4366)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-06 20:38:59 +00:00
Henrik Skov Midtiby
ded54e41ae
Add type annotations to indication.py (#4367)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-08-06 13:54:36 +00:00
Benjamin Hackl
04503adb70
Fix Sphinx exceptions when trying to build documentation via latex / as pdf (#4370)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-06 08:43:50 -04:00
Henrik Skov Midtiby
9c9ebf428e
Add type annotations to dot_cloud.py, vectorized_mobject_rendering.py and opengl_three_dimensions.py (#4359)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-01 11:07:09 -04:00
Francisco Manríquez Novoa
d18dc8f89b
Add VectorNDLike type aliases (#4068)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-01 04:31:30 +00:00
Henrik Skov Midtiby
7eb88562c2
Add type annotations for most of camera and mobject.graphing (#4125)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-01 00:59:29 +00:00
F. Muenkel
aa0cd4fe82
Add type hints to scene_file_writer.py, section.py, and zoomed_scene.py (#4133)
* Add type hints to scene/scene_file_write.py

* Add type hints to scene/scene_file_write.py

* Add type hints to scene/section.py

* Add type hints to scene/zoomed_scene.py

* Add type hints to scene/moving_camera_scene.py

* Fix typing of variable scene_name

* Fix typing

* Fix one more type hint
2025-07-30 08:52:22 -04:00
Henrik Skov Midtiby
a9b65eed5f
Revert change of default value (#4358) 2025-07-29 10:09:21 -04:00
Henrik Skov Midtiby
dba6fa8f99
Add type annotations to three_d_camera.py (#4356)
* Adding type annotations to three_d_camera.py

* Suggestions from Chopan50

* Removed a comment.

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-29 13:09:55 +00:00
Henrik Skov Midtiby
df36f4f196
Add type annotations to tex_mobject.py (#4355)
* Starting to work on type annotations for tex_mobject.py

* More work

* Finished.

* Code cleanup.

* ...

* Removed the ignore errors line in mypy for tex_mobject

* Fix typing of colors

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-29 12:32:23 +00:00
Francisco Manríquez Novoa
7ea765a759
Optimize Mobject.become() (#4357) 2025-07-29 07:57:02 -04:00
Henrik Skov Midtiby
21fe73b5c2
Add type annotations to manim/renderer/shader.py (#4350)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-27 23:14:41 +00:00
F. Muenkel
088affd876
Fix typo in import of OpenGLCamera (#4352) 2025-07-26 18:08:15 +00:00
F. Muenkel
c7ff795c0a
Add support for arithmetic operators //, %, *, ** and / on `ValueTracker` (#4351)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-26 17:45:05 +00:00
Irvanal Haq
dea245ad9a
Fix duplicate references in Scene.mobjects after ReplacementTransform with existing target mobject (#4242)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-07-26 01:30:54 +00:00
F. Muenkel
a8c16fbfb1
Add type hints to mobject/value_tracker.py (#4129)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-07-25 21:25:01 +00:00
gui martins
83d4301184
Add docstrings for ChangingDecimal and ChangeDecimalToValue (#4346)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-07-25 16:43:19 +00:00
nubDotDev
b65b0f2470
Fixed surface animations in OpenGL (#4286) 2025-07-25 15:40:52 +00:00
Abhilasha Tandon
4ddf77739d
Include Text.gradient in hash to properly regenerate Text when its gradient changes (#4099)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-25 15:13:09 +00:00
Francisco Manríquez Novoa
e73b6590dd
Add classes MethodWithArgs, SceneInteractContinue and SceneInteractRerun inside new module manim.data_structures (#4315)
* Add classes MethodWithArgs, SceneInteractRerun and SceneInteractExit

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add missing manim.data_structures file

* Rename SceneInteractExit to SceneInteractContinue and use dataclasses

* Revert using @dataclass(slots=True), because Python 3.9 does not support it

* Change order of dataclasses

* Add references to Scene.queue in docstrings

* Include data_structures in utilities_misc.rst

* Use qualified names and mark strings as code in data_structures.py

* Add module docstring to data_structures.py

* Move Scene.interact() objects from data_structures.py into scene.py

* Use qualified name in SceneInteractAction docstring

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-07-25 00:37:14 +02:00
Henrik Skov Midtiby
fd8ab62613
Fix BraceLabel.change_label() and document BraceText (#4347)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-24 22:09:02 +00:00
Henrik Skov Midtiby
047db453ff
Add type annotations to mobject/svg/brace.py (#4309)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-24 21:37:43 +00:00
Luka Rahne
2f02eb9328
Fix Prism rendering with wrong dimensions in OpenGL (#4003)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-07-24 20:44:25 +00:00
dependabot[bot]
c1663f1a1e
Bump astral-sh/setup-uv from 5 to 6 (#4234)
Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 5 to 6.
- [Release notes](https://github.com/astral-sh/setup-uv/releases)
- [Commits](https://github.com/astral-sh/setup-uv/compare/v5...v6)

---
updated-dependencies:
- dependency-name: astral-sh/setup-uv
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-21 17:55:33 +02:00
NASAnerd05
2790a70bc5
Improved readability, grammar, as well as added docstrings for consistency (#4267)
* Improve MappingCamera, MovingCamera, Rotation, CliColors, and _init_.py readability and docstrings

* Readibility and docsstrings

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Apply suggestion from @behackl

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-07-20 14:33:45 +02:00
Henrik Skov Midtiby
fdb5cb9f04
Add typing annotations to svg_mobject.py (#4318)
* Add typing annotations to svg_mobject.py

* Added ignore statements in four locations.

* cleanly resolve non-None stroke_width in svg_mobject

* revert clean solution (???)

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-07-20 14:17:40 +02:00
Francisco Manríquez Novoa
ec501b960c
Remove manim.gui and move configure_pygui into Scene as a method (#4314) 2025-07-20 13:22:24 +02:00
Henrik Skov Midtiby
e54113e263
Handling typing errors in text/numbers.py (#4317) 2025-07-20 12:51:59 +02:00
Henrik Skov Midtiby
b83410aee0
Ensure that the stroke_width property of SVGMobject is not set to None. (#4319)
This change fixes issue 4311.
2025-07-20 12:36:09 +02:00
Henrik Skov Midtiby
f124235a9b
Adding type annotations to polyhedra.py and matrix.py (#4322)
* Fixed all mypy errors in polyhedra.py

* Added type annotations to matrix.py
2025-07-20 12:31:25 +02:00
Mohamed El Shorbagy
9e74ee7edf
Add zero to remove negative zeros (#4332) 2025-07-20 12:28:56 +02:00
OliverStrait
3721fb1612
Use utf-8 encoding to read generated .tex files. (#4334)
Co-authored-by: Oliver Strait <strait.devoliver@gmail.com>
2025-07-20 12:27:25 +02:00
Henrik Skov Midtiby
3d029c1280
Fix for issue 4255 - Arrow3D: get_start() and get_end() methods both return np.array([0,0,0]). (#4320) 2025-07-10 10:24:23 +02:00
S. M. Mohiuddin Khan Shiam
f63ba71f04
Gracefully fall back when version metadata is missing (#4324)
* Update __init__.py

* Update manim/__init__.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-07-10 10:23:12 +02:00
Benjamin Hackl
a234ff31e8
Replace setup-texlive-action in CI workflow (#4326)
* replace setup texlive action

* cleanup in packages to install

* one more
2025-07-03 08:29:01 -04:00
Henrik Skov Midtiby
9c43ad0d21
Store the original alpha channel from the image when creating the ImageMObject and then use it in the set_opacity method (#4313)
Change from PR 2923 by NicoWeio
2025-06-26 10:56:49 +02:00
Henrik Skov Midtiby
ea16d22735
Add type annotations to scene.py and vector_space_scene.py (#4260)
* Stop ignoring errors from manim/scene.py

Count: 307 errors

Type annotations on scene/vector_space_scene.py

Add type annotations to scene/vector_space_scene.py

Mypy count: 210

Reverting two changes that triggers an error in the automatic testing.

Further work on type hinting.

Avoid forwarding positional arguments from Arrow to Line in the constructor.

Revert "Avoid forwarding positional arguments from Arrow to Line in the constructor."

This reverts commit 80ae8576c1.

Removed several type ignore statements and addressed comments from JasonGrace2282

Revert "Activate mypy check of mobject.geometry.*"

This reverts commit d477c9a994.

Revert "Removed several type ignore statements and addressed comments from JasonGrace2282"

This reverts commit 07bbe3f220.

Added type annotations to zoomed_scene.py

Error count: 308 -> 303

Adding type annotations to all methods in vector_space_scene.py

Error count: 303 -> 272

Get rid of no-untyped-call errors from my in the vector_space_scene.py file

Error count: 272 -> 343

Handle type issues related to ManimColor in vector_space_scene.py

Handle var-annotated issues in vector_space_scene.py

Error count: 332 -> 330

Handling has-type type errors in vector_space_scene.py

Error count: 330 -> 285

Handled name-defined type issues in vector_space_scene.py

Error count: 285 -> 282

Address type issue with calling an untyped method.

Error count: 282 -> 281

Fix some typing issues in transform_mathcing_parts.py

Change stroke_width to float in vector_space_scene.py

Handled a few type errors.

Error count: 267

Handled several typing issues in three_d_scene.py

Error count: 267 -> 248

Dealing with type errors in scene_file_writer.py

Error count: 248 -> 216

Ensured that all methods in scene.py have type declarations.

Error count: 216 -> 225

Handle type issues related to interactivity by asserting that the camera is the OpenGLCamera

Error count: 225 -> 182

Handle type issues in scene.py

Error count: 182 -> 167

Asserting that the renderer or camera is of the proper type to use certain methods.

This is mainly related to interactive elements and the 3D camera used in the ThreeDScene

Error count: 167 -> 143

Avoid cyclic import of dependencies

Error count: 143 -> 143

Handling no-untyped-call type errors in manim/scene/scene.py

Error count: 143 -> 131

Handling assignment type errors in manim/scene/*.py

Error count: 131 -> 121

Handling arg-type type errors in manim/scene/*.py

Error count: 121 -> 116

Handling arg-type type errors in manim/scene/*.py

Error count: 116 -> 112

Fixing various type errors

Error count: 112 -> 102

Fixing various type errors

Error count: 102 -> 97

Fixing various type errors

Error count: 97 -> 90

Some aggressive changes to silence a significant number of type errors.

Error count: 90 -> 66

Commented out an import (IPython) that makes the CI tests fail.

Fix various type errors.

More type annotations.

Code cleanup.

Remove the property mobject_updater_lists of the Scene class as it is not used anywhere.

Handle import-untyped typing issues.

More work on type annotations in manin/scene/.*

More work on scenes/*.py looking at the dependency opengl_renderer.py

More work on types in scenes/*.py

Ignored an old bunch of type ignore statements.

More work on dependencies for scene.py

More work on dependencies for scene.py

* Stop ignoring errors from manim/scene/scene.py

mypy error count: 307

* Adding type annotations to scene.py (C1)

* Adding type annotations to scene.py (C2.1)

* Adding type annotations to scene.py (C2.2)

* Adding type annotations to scene.py (C2.3)

* Adding type annotations to scene.py (C3)

* Adding type annotations to scene.py (C4)

* Adding type annotations to scene.py (C5)

* Adding type annotations to scene.py (C6)

* Adding type annotations to scene.py (C7)

* ...

* Focus on scene.py

* Adding type annotations to vector_space_scene.py

* Added types to opengl_renderer.py

* Added types to cairo_renderer.py

* Fixed the last mypy errors in scene.py - many was ignored

* Fixed the last mypy errors in vector_space_scene.py - many was ignored

* Got rid of the last mypy errors.

* Activate mypy check of vector_space_scene.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Code cleanup.

* Update manim/gui/gui.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/renderer/opengl_renderer.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update manim/scene/scene.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/scene/scene.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/scene/scene.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/scene/scene.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/scene/scene.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Implementing suggestions from chopan50

* Explicitly mention all files where type errors are ignored in mypy.ini

# Conflicts:
#	mypy.ini

* Fix issue

* Updates based on comments from chopan50

* Updates suggested by Chopan50

* Addressed more comments from chopan50

* Addressing more comments from chopan50

* Added docstring to SceneInteractAction

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Differentiate between _AnimationBuilder from an mobject and an opengl_mobject

* Avoid a nameclash with the mobject module and variable name

* Last touches.

* Rolled back some changes related to _AnimationBuilder

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-06-24 13:50:40 -04:00
Henrik Skov Midtiby
c4b7a80258
Remove dead code from scene.py and vector_space_scene.py (#4310) 2025-06-24 12:23:42 -04:00
Henrik Skov Midtiby
0cec80216b
Explicit mention all files that mypy should ignore in the mypy.ini configuration file (#4306)
* Explicitly mention all files where type errors are ignored in mypy.ini

* Minor adjustments to mypy.ini suggested by chopan50
2025-06-24 07:43:57 -04:00
Louis GERARD
a1bb04947a
Fix Microsoft typo in TexFontTemplateLibrary scene in example_scenes/advanced_tex_fonts.py (#4305)
Co-authored-by: Louis Pierre Jean Gerard <louis_global@fasoo.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-06-23 21:15:39 -04:00
Henrik Skov Midtiby
325fa08a72
Fixing files with few typing (mypy) errors (#4263)
* Fixed mypy errors in several files with a few errors in each file.

* Fixed a few easy mypy errors.

* Fix mypy issues in animation/changing.py

* Handled mypy issues in _config/cli_colors.py

* Handled mypy issues in mobject/logo.py

* Handling mypy errors in fading.py

* Removed a default parameter (scene = None) in the method clean_up_from_scene in the class FadeOut

* Handled mypy errors in graphing/scale.py

* Handled a few mypy errors in updaters/update.py

* Handled mypy errors in three_d_utils.py

* Updated mypy.ini to check more files

* Avoid a circular import loop.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update manim/animation/changing.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/animation/changing.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/animation/changing.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/mobject/logo.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/animation/changing.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/animation/changing.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/animation/changing.py

Cleaner way to indicate the float type

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/animation/changing.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Updated the type annotations of MoveAlongPath and ChangingDecimal

* Suggestions from review by chopan50

* Fix missing import.

* Update mypy.ini

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update mypy.ini

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update mypy.ini

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update mypy.ini

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Updated mypy.ini

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-06-23 08:08:00 -04:00
Steven Hedges
a8458cb329
Fix default config of manim init project to use correct pixel_height and pixel_width (#4213) 2025-06-23 03:27:47 +00:00
Irvanal Haq
64862994ac
Refactor Rotating and add docstrings to Mobject.rotate() and Rotating (#4147)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-06-22 04:15:12 +00:00
Ishu Bansal
c9707f281d
Introduce seed in random_color method to produce colors deterministically (#4265)
* add a random generator to hold the seed for random generation

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* add DOCSTRING for new class RandomColorGenerator

* fix RandomColorGenerator doctest

* introduce the sample colors param in RandomColorGenerator

* Update docstrings to include sample_colors param for RandomColorGenerator

* fix cyclic import issues

* fix indentations for code blocks

* docstring formatting changes

* removed performance warning
added class method

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-06-21 22:39:19 +02:00
Ishu Bansal
23a2df1e5a
use the same opacity to init the super class obj of DecimalNumber (#4291) 2025-06-21 22:34:11 +02:00
Irvanal Haq
3377f6c1f6
Replace exceptions, remove unused parameters, and fix type hints in Animation, ShowPartial, Create, ShowPassingFlash, and DrawBorderThenFill (#4214)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Francisco Manríquez <francisco.manriquezn@usm.cl>
2025-06-20 00:38:56 +00:00
Irvanal Haq
e4b1d105a3
Rename misleading function dot_position to update_label in .add_updater() example (#4196)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-06-19 13:12:55 +00:00
Theo Barollet
204e44a106
Fixed artifact in Animation docstring (#4283) 2025-06-12 06:51:40 -04:00
Kaique Barbosa Dultra
d517b50567
Add support for pycodestyle W rule in Ruff (#4276)
* Add suport for `pycodestyle W` rule in Ruff and remove invalid noqa comments for deprecated rules

* Exclude `py/method-first-arg-is-not-self` false positive for metaclass `__init__`

---------

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2025-06-11 14:35:39 +00:00
Giovanne
5301ab874f
Add tests for polylabel utility (#4269)
* Fix polygon inside/outside logic for edge cases

* Stop using hardcoded values and improve variable naming

* Decompose inside/outside logic into smaller functions

Improves readability and maintanance.

* Improve test readability

* Fix polylabel test logic

* Fix polylabel test by adding multiple options of pole

* Improve docstring description of argument

* Stop checking type checking blocks on coverage

* Fix OpenGLMobject methods doctests
2025-06-11 09:54:51 +02:00
Pedro Peixoto
be6a9dfaa7
docs: add explanation about the rate_func in the custom animation (#4278) 2025-06-11 09:50:11 +02:00
Pedro Zanelato
e569fd47ad
test: add matrix tests (#4279) 2025-06-11 09:48:39 +02:00
Irvanal Haq
bf72127152
Enhance and Paraphrase Description of Manim Community Edition in README.md (#4141)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-06-10 06:52:47 -04:00
Benjamin Hackl
ffa6ffa548
Fix formatting of color space documentation (#4274) 2025-06-08 12:53:56 -04:00
Akshat
bcab73a3d2
Fix(graph): Allow any Line subclass as edge_type in Graph/DiGraph (#4251)
* Fix(graph) : fix Line subclass usage for Graph and DiGraph

Fix(graph): LabeledLine can now be used in _add_edge

* Test(test_graph.py): add tests for LabeledLine as edge_type in Graph and DiGraph

Fix(test_graph): Fixed test_graph_accepts_labeledline_as_edge_type() always failing.
2025-05-27 17:30:19 +02:00
F. Muenkel
fdc496c211
Complete typing for logger_utils.py (#4134)
* Complete typing for logger_utils.py

* Stop ignoring  manim._config erros in mypy.ini

* Ignore manim._config errors in mypy.ini

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-05-23 01:17:08 +00:00
Irvanal Haq
f6cdb547d2
Fix add_points_as_corners not connecting single point to existing path (#4219) 2025-05-22 15:40:11 +00:00
SAYAN02-DEV
5a3dcf77fa
fix: update incorrect docstring for ManimConfig.gui_location property (#4254)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-05-22 12:53:46 +00:00
Irvanal Haq
c53ac5544a
Add docstring to :meth:Mobject.family_members_with_points (#4128)
* Add example to family_members_with_points method in Mobject

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add the word 'recursively' to clarify the method description

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Improve the sentence of method description

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Improve the method description

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Adding brackets

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add 'See also' section

* Update manim/mobject/mobject.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* chenge list to list[Mobject]

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-05-22 12:23:40 +00:00
Irvanal Haq
7f6743e97c
Fix :meth:VMobject.pointwise_become_partial failing when vmobject is self (#4193)
* Fix Line failing with buff and path_arc
- make copy of vmobject.points if necessary

* change self to self.copy() in Line, and remove the previous change in pointwise_become_partial()

* Revert to first approach: copy points if self is vmobject

* Add unit test for pointwise_become_partial and Line

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-05-22 07:59:46 -04:00
Irvanal Haq
a2876dc77c
Add docstrings to Line and remove None handling for path_arc parameter (#4223)
* In Line: simplify _account_for_buff and set default path_arc to 0.0

* In Line: add docstring

* change 0.0 to 0

* Use explicit check for path_arc == 0 in _account_for_buff

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-05-22 10:26:08 +00:00
Irvanal Haq
de210bad8b
Improve docstring for interpolate method in Mobject class (#4149)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-05-21 22:40:29 +00:00
Irvanal Haq
ab4855728f
Improve Mobject.align_data docstring (#4152)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2025-05-21 22:09:33 +00:00
Francisco Manríquez Novoa
f304bd93ea
Fix return type of Polygram.get_vertex_groups() and rename variables in .round_corners() (#4063) 2025-04-26 02:16:14 +00:00
xinoehp512
384350cf3b
Replace poetry with uv in the README (#4226) 2025-04-21 19:02:31 -04:00
thehugwizard
593010b87b
Bugfix: HSL color ordering in ManimColor (#4202)
* Bugfix: colorsys uses HLS (hue, luminance, saturation) ordering when converting to/from rgb. Manim says it uses HSL ordering. Fixed order of parameters in call to colorsys for ManimColor.from_hsl and ManimColor.to_hsl.
Added tests ensure correct HSL ordering.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update to fix the correct color tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: SonnyRoomex <sonny.campbell@roomex.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2025-04-21 01:46:59 +00:00
Ryan Gibson
3c6a1ee80b
docs: Fix links to Pango website (#4217) 2025-04-14 14:59:52 -04:00
pre-commit-ci[bot]
44da20d71d
[pre-commit.ci] pre-commit autoupdate (#4181)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.9.7 → v0.11.0](https://github.com/astral-sh/ruff-pre-commit/compare/v0.9.7...v0.11.0)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-03-17 14:34:57 -04:00
Hasan Mesbaul Ali Taher
e1925e46dc
Add missing line break in Code of Conduct conflict of interest policy (#4185) 2025-03-11 13:59:35 -03:00
pre-commit-ci[bot]
2ab99b53d3
[pre-commit.ci] pre-commit autoupdate (#4148)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.9.3 → v0.9.7](https://github.com/astral-sh/ruff-pre-commit/compare/v0.9.3...v0.9.7)
- [github.com/pre-commit/mirrors-mypy: v1.14.1 → v1.15.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.14.1...v1.15.0)
- [github.com/codespell-project/codespell: v2.4.0 → v2.4.1](https://github.com/codespell-project/codespell/compare/v2.4.0...v2.4.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-02-24 16:56:54 -05:00
Benjamin Hackl
2bdd5ac230
Make new Code mobject compatible with OpenGL renderer (#4164)
* fix: enable opengl compatibility for Code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-02-11 06:29:23 +01:00
Benjamin Hackl
9479febef2
docs: add explicit instructions for installing pkg-config and cairo as required by pycairo for macos (#4146) 2025-02-10 20:52:36 +01:00
BenKirkels
d85ddb0ca5
refactor: improved consistency of rate_functions (#4144)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2025-02-09 17:19:36 +00:00
F. Muenkel
cd2a3b92f6
Fixed Tex environment doubling braces (#4159)
* Fix environment formating for Tex() mobject

* Add test for handling of Tex() environments
2025-02-09 11:56:59 -05:00
Benjamin Hackl
01fc1ef71f
fix: re-add ffmpeg to docker container (#4150) 2025-02-04 09:10:33 -05:00
pre-commit-ci[bot]
d521bc9104
[pre-commit.ci] pre-commit autoupdate (#4140)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.9.2 → v0.9.3](https://github.com/astral-sh/ruff-pre-commit/compare/v0.9.2...v0.9.3)
- [github.com/codespell-project/codespell: v2.3.0 → v2.4.0](https://github.com/codespell-project/codespell/compare/v2.3.0...v2.4.0)

* fix: typos in two files

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-02-02 17:28:20 +01:00
Benjamin Hackl
95fba7da10
Change project management tool from poetry to uv (#4138)
* rewrite pyproject.toml to support uv; version upgrades of several dev dependencies

* codespellrc: poetry.lock -> uv.lock

* rewrite workflows, first attempt

* change name of pre-commit-hook

* dev-dependencies -> dependency-groups.dev

* lint + format

* Update .github/workflows/ci.yml

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* convert development.rst to myst markdown

* fix (most) docbuild warnings from theme upgrade

* development instructions: switch to uv, plus minor updates

* update entrypoint config in plugin docs + tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-02-02 17:16:46 +01:00
Irvanal Haq
a6990bd83c
Fix link formatting and clarify the distinction between Manim versions in index.rst (#4131)
* Fix link formatting and clarify the distinction between Manim versions

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-01-22 10:28:18 +01:00
Irvanal Haq
8f919b1726
Add docstring to :meth:.Mobject.get_family (#4127)
* Add example to get_family method in Mobject

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-01-21 13:29:47 -05:00
pre-commit-ci[bot]
6ca08fd187
[pre-commit.ci] pre-commit autoupdate (#4122)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.9.1 → v0.9.2](https://github.com/astral-sh/ruff-pre-commit/compare/v0.9.1...v0.9.2)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-01-21 00:52:52 +01:00
Aarush Deshpande
106b849a6d
Bump typing extensions minimum version (#4121) 2025-01-20 16:37:26 +00:00
Aarush Deshpande
c2dfb597ff
Create changelog for 0.19.0 (#4032)
* First draft of Changelog for 0.19.0

* fix typos

* added 3967

* Add #4037

* Update count 97 -> 98

* Add #4039

* Add #3930 and #4044

* Add this PR to changelog

* Add small description to changelog

* Add #3924, #3951, and #4038

* Bump Manim version to 0.19.0

* Update CITATION.cff to be more consistent

* remove github-security[bot]

* Feedback + missing PRs

* add newly merged PRs

* added more details to highlights + breaking changes

* bump date

* sort PRs in breaking changes section and include 3964

* sort highlights section

* fix: add required configuration key in .readthedocs.yml

* Update docs/source/changelog/0.19.0-changelog.rst

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-01-20 14:36:53 +01:00
Francisco Manríquez Novoa
765c090027
Complete typing of manim.utils.color and polish its documentation (#4065)
* Type color and polish docstrings

* Stop ignoring manim.utils.color MyPy errors

* Remove manim.mobject.mobject from mypy.ini (put there on accident)

* Fix MyPy errors in GitHub pre-commit

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Modify _construct_from_space parameter type

* Modify _construct_from_space parameter type

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix: remove duplicate property definitions

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-01-19 19:46:26 +01:00
Francisco Manríquez Novoa
8bb28aae8e
Draw more accurate circular Arcs for larger angles (#4034)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-01-19 18:32:58 +00:00
czuzu
bad88a11f9
Update README and documentation landing page, improve way how 3b1b is credited (#4077)
* Update readme to properly credit Grant Sanderson and revise dismissive language

* Adjust readme and add landing-page mention about Grant's Manim

* Apply suggestions from code review

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-01-19 18:57:53 +01:00
Benjamin Hackl
1efe869293
Completely rewrite Code mobject + add support for short notation RGB(A) hex code specifications to ManimColor (#4115)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-01-19 14:39:13 -03:00
Sophia Wisdom
86a971940f
Add __hash__ to ManimColor (#4051)
* add __hash__ to ManimColor

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update core.py

* add test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix: correct typehint

* fix test

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-01-19 18:09:26 +01:00
pre-commit-ci[bot]
97f818eb7f
[pre-commit.ci] pre-commit autoupdate (#4035)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.8.0 → v0.9.1](https://github.com/astral-sh/ruff-pre-commit/compare/v0.8.0...v0.9.1)
- [github.com/pre-commit/mirrors-mypy: v1.13.0 → v1.14.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.13.0...v1.14.1)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* enh: ignore ruff lint rule A005 (module shadowing standard library module)

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-01-19 18:08:36 +01:00
Romit Mohane
c933c74a40
Add Noto fonts install command to Dockerfile (#4069)
* added notosans fonts install command to dockerfile

* enh: move fonts-noto package to other packages

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2025-01-19 17:23:13 +01:00
F. Muenkel
530dd4d782
Fix broken link to Poetry installation guidelines (#4116) 2025-01-19 17:11:08 +01:00
Henrik Skov Midtiby
95b4625ef2
Fix of ImageMobject opacity bug (#4089)
* Fix issue 4072.

* Added a unittest for the interpolate function in utils/bezier.py
2025-01-19 16:56:47 +01:00
Irvanal Haq
def7241db3
Add Homotopy example for waving square (#4100)
* Add missing changes for homotopy example

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-01-19 16:38:30 +01:00
Aarush Deshpande
f18a2b46e5
Remove PT004 from Ruff (#4102) 2025-01-19 16:34:16 +01:00
modjfy
9d51c0d44d
Corrected spelling mistake in documentation (#4107) 2025-01-19 16:26:28 +01:00
Irvanal Haq
9e45cf6ff8
Remove duplicate __all__ declarations in vectorized_mobject.py (#4108) 2025-01-19 16:18:48 +01:00
Francisco Manríquez Novoa
7879fe4377
Fix VMobject.add_points_as_corners() to return self and safely handle empty points parameter (#4091)
* Fix VMobject.add_points_as_corners() to return self and safely handle case where no points are passed

* Add test_vmobject_add_points_as_corners()

* assert np.allclose() -> np.testing.assert_allclose()
2025-01-05 10:46:43 -03:00
Henrik Skov Midtiby
17d4a7f635
Add type annotations to manim.utils.* (#3999)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Francisco Manríquez <francisco.manriquezn@usm.cl>
2025-01-02 07:12:59 +00:00
Francisco Manríquez Novoa
dbad8a86bc
Rename InternalPoint3D to Point3D, Point3D to Point3DLike and other point-related type aliases (#4027) 2024-12-17 19:17:34 +00:00
Aarush Deshpande
112c99ba4a
Fix SyntaxWarnings when building the docs and bump readthedocs to Python 3.13 (#3924)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-12-16 16:04:07 +00:00
Laifsyn
46dbf3d3ed
Call .finish() for every animation in AnimationGroup on finish (#3951)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-12-16 11:50:35 -03:00
Aarush Deshpande
6abcc611b9
Fix typehint of :meth:.Scene.play to allow .animate (#4038) 2024-12-07 16:56:55 +00:00
Aarush Deshpande
953888e68e
Rewrite installation instructions (#3930)
Follow-up to #3501

This commit combines all the installation documentation onto one page, and switches to recommending the usage
of `uv` for installing Manim.
2024-12-06 18:50:18 -05:00
Francisco Manríquez Novoa
d485986122
Add support in documentation for type aliases using Python 3.12 type definition (#4044) 2024-12-06 20:07:31 -03:00
ChungLeeCN
263623e10c
Added a `delay parameter to :func:.turn_animation_into_updater` (#4039) 2024-12-03 14:02:53 +00:00
Benjamin Hackl
73d22454f1
pin av to <14 (#4037) 2024-12-02 16:06:53 -05:00
Aarush Deshpande
e74933049e
Add support for Python 3.13 (#3967)
* Allow python 3.13

* Specify scipy more strictly

* try using 3rd-party audioop package

* debug: wrap context generation in try-block

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* remove audioop-lts, update dependencies

* add wrapt pre-release (wheels!)

* update lockfile

* CI, windows: try installing all tinytex packages at once

* tmp: verbosity of pytest

* tmp: pass -n 0 for testing

* tmp: disable pytest-xdist

* remove deprecated poetry installer option

* try running tests via uv-provided env

* tmp: run -> run --no-project

* try --full-trace

* try running tests via python -v ...

* tmp: test import of suspicious modules

* test click/cloup

* ci: back to poetry

* ci: disable pytest plugins altogether

* update lockfile

* ci: upgrade pytest

* remove all flags from pytest call

* ci: move conftest, temporarily disable test header

* fix test fixture

* try with more recent version of pytest-xdist

* loadfile -> loadscope

* explicitly test pytest for non-manim module

* some proper tests

* only keep fixtures in new conftest.py

* remove all non-necessary fixtures

* try a literal try/except in fixture file

* simplify tests further

* try and explicitly trigger non-silent errors

* Revert "try and explicitly trigger non-silent errors"

This reverts commit 35b862d483.

* more pytest debug output

* test whether manim can be imported correctly

* test with upgraded numpy

* revert all sorts of debug changes, attempt clean pytest run

* fix whitespace

* pre-commit hooks

* apply config fixture to render tests

* let config fixture ensure renderer is set to cairo

* update doctests for numpy>=2.0

* missed some

* upgrade required numpy version, revert separate treatment of numpy in ci

* upgraded moderngl-window to latest

* more delicate versioning of numpy dependency

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-12-02 08:50:14 +01:00
Francisco Manríquez Novoa
f81d5713b3
Allow animations with run_time=0 and implement convenience Add animation (#4017)
* Allow animations with run_time=0 and implement convenience Add animation

* Modify examples so that there are less characters per line

* Docstring fixes

* Update manim/animation/animation.py

* Address comments

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-11-27 01:00:54 +00:00
Jay Gupta
862504fa45
Added ConvexHull, ConvexHull3D, Label and LabeledPolygram (#3933)
* initial commit

* Update labeled.py

* general fixes

fixed added utils (i.e., Incomplete ordering and Explicit returns mixed with implicit), added :quality: high to docstrings, made ConvexHullExample determined

* typing

added typing to `qhull.py` and `polylabel.py` for debugging. simplified test cases for `ConvexHull` and `ConvexHull3D` and rewrote control data. added tip to LabeledPolygon documentation.

* response to feedback

added `label_config` and `box_config` and `frame_config` for additional configuration options and cleaner interface. added `InternalPointND` and `PointND ` and `InternalPointND_Array` and `PointND_Array` for typing. updated docstring.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* typing

* Update manim/mobject/geometry/labeled.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* Update manim/mobject/geometry/labeled.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

* typing, docstring, class name

* typing

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-11-26 21:32:14 -03:00
Hugo Chargois
fac0aa5218
Add darker, lighter and contrasting methods to ManimColor (#3992)
* Add darker, lighter and contrasting methods to ManimColor

* Fixes

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-11-25 11:05:08 +01:00
pre-commit-ci[bot]
faecdd3365
[pre-commit.ci] pre-commit autoupdate (#3987)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.7.0 → v0.8.0](https://github.com/astral-sh/ruff-pre-commit/compare/v0.7.0...v0.8.0)
- [github.com/pre-commit/mirrors-mypy: v1.12.1 → v1.13.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.12.1...v1.13.0)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-11-24 12:59:04 +01:00
dependabot[bot]
8f6eaf372e
Bump tornado from 6.4.1 to 6.4.2 (#4023)
Bumps [tornado](https://github.com/tornadoweb/tornado) from 6.4.1 to 6.4.2.
- [Changelog](https://github.com/tornadoweb/tornado/blob/v6.4.2/docs/releases.rst)
- [Commits](https://github.com/tornadoweb/tornado/compare/v6.4.1...v6.4.2)

---
updated-dependencies:
- dependency-name: tornado
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-22 17:33:43 -05:00
Benjamin Hackl
c516932f9f
Fix scene skipping for config.upto_animation_number (-n flag in CLI) set to 0 to end after first animation (#4013)
* make checks involving from/upto_animation_number more explicit

* add test for flag -n 0,0 for only rendering first animation

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-11-13 21:23:50 -03:00
Francisco Manríquez Novoa
ab577dc2ea
Add typings to manim/__main__.py (#4007)
* Add typings to __main__.py

* Remove `Unused parameter.` from docstrings
2024-11-13 22:16:17 +00:00
Francisco Manríquez Novoa
a21a5e5719
Stop ignoring manim.plugins errors in mypy.ini (#4006) 2024-11-11 00:44:52 +01:00
Aarush Deshpande
97efef4542
Add a time property to Scene (#3997)
* Add a time property to scene

* fix mistaken search/replace

* Add typehint
2024-11-07 21:45:46 +00:00
Francisco Manríquez Novoa
ee0501c2b6
Add type hints to manim.cli module (#3988)
* Add type hints to cli

* Import click.Parameter instead of non existing cloup.Parameter

* Stop ignoring manim.cli errors in mypy.ini

* Fix mypy errors

* Remove unused TypeVar C

* click.Command.command -> cloup.Group.command

* Address Jason's requested changes

* exit() -> sys.exit()
2024-11-04 16:05:07 +00:00
Christopher Hampson
c6edb330a9
Feat: dvipsnames and svgnames color palettes (#3913)
* feat: added dvipsnames color palette

* added svgnames color palette

* fixed docstrings

* Commit changes requested by JasonGrace2282

* Double backticks in xcolor

---------

Co-authored-by: Francisco Manríquez <francisco.manriquezn@usm.cl>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-11-04 14:13:28 +00:00
Nemo2510
9f1f239f10
Allow :class:.SurroundingRectangle to accept multiple Mobjects (#3964)
* Implement SurroundingRectangle.multiple and BackgroundRectangle.multiple

* Integrate SurroundingRectangle constructor for multiple objects into __init__

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* SurroundingRectangle now takes multiple Mobjects as positional args

* Add tests for multiple Mobjects in SurroundingRectangle

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix example that was not using keyword args for SurroundingRectangle

* Remove duplicate code from BackgroundRectangle

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add typing to manim argument of SurroundingRecrabgle constructor

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Remove redundant argument from test_SurroundingRectangle

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Remove type check from SurroundingRectangle

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix missing line issue

* resolve merge conflict

* Fix Group import

* Move Group import into the body of SurroundingRectangle

* Return type checking to SurroundingRectangle

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* small change to error message

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix missing imports

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
2024-10-29 23:30:32 +00:00
Nemo2510
2570a251c9
Add scale_stroke boolean parameter to VMobject.scale() to allow scaling stroke_width along with the VMobject (#3965)
* Add option to scale object outlines with objects

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Move outline scaling into VMobject.scale()

* Add unit tests for stroke width

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix docstring for VMobject.scale

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Remove tautology from VMobject.scale

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-10-28 14:48:46 +00:00
Francisco Manríquez Novoa
f65b7f8085
Refactored run_time validation for Animation and Scene.wait() (#3982)
* Refactored Animation run_time validation

* Rewrite error and warning messages, and add validations to wait(), pause() and wait_until()

* Undo rewriting of imports
2024-10-28 14:24:29 +00:00
Francisco Manríquez Novoa
20f44b456b
Added PointND and PointND_Array typing aliases (#3980)
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-10-28 01:28:31 +00:00
Henrik Skov Midtiby
87732527d3
Type annotation work in manim/mobject/geometry/ (#3961)
Fixes typehints in manim.mobject.geometry, and enables type checking of those modules. Part of #3375
2024-10-27 21:13:58 +00:00
Larry Skuse
a395ffd698
Allow videos to be embedded in Google Colab without explicitly setting config.media_embed = True (#3974)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-10-24 17:34:49 +00:00
Xiuyuan (Jack) Yuan
327db11c54
Added example to documentation for moving_camera_scene module (#3972)
Co-authored-by: Xiuyuan <u7678992@anu.edu.au>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tianxiong Dai <u7581325@anu.edu.au>
2024-10-24 07:35:53 -04:00
Nikhila Gurusinghe
d5b8b41283
Implemented VGroup parsing iterables (#3966) 2024-10-23 08:08:52 -04:00
pre-commit-ci[bot]
39382e6ba8
[pre-commit.ci] pre-commit autoupdate (#3929)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/pre-commit/pre-commit-hooks: v4.6.0 → v5.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.6.0...v5.0.0)
- [github.com/astral-sh/ruff-pre-commit: v0.6.2 → v0.7.0](https://github.com/astral-sh/ruff-pre-commit/compare/v0.6.2...v0.7.0)
- [github.com/pre-commit/mirrors-mypy: v1.11.2 → v1.12.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.11.2...v1.12.1)

* Fixes for ruff 0.7.0

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-10-22 14:32:12 +00:00
Aarush Deshpande
96e58aeb05
Fix typehints of ParametricFunction (#3926)
* Fix typehints of ParametricFunction

* add typehint
2024-10-22 14:07:01 +00:00
nitzanbueno
ce1fff645d
Improve line rendering performance by decreasing redundant subdivision count (#3893)
* Reduce line cylinder height resolution to 2

Subdividing a line cylinder by its height adds no extra resolution -
since it's not checkerboarded, all new rectangles would look the same as
one long rectangle. Decreasing the default subdivision resolution to 2
reduces submobject count by 12x while sacrificing no quality.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Allow for 2 resolution values in Line3D

This prevents a breaking change where a tuple of resolution values
passed to Line3D.resolution would no longer work.
Also applies to Arrow3D.

* Assign field before init

* Add checkered line info to docstring

* Regenerate test control frame

* Regenerate missing control frames

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-10-20 01:01:04 +00:00
Aarush Deshpande
fc58a46615
Fixed typehint in types.rst and replaced outdated reference to manim.typing.Image with manim.typing.PixelArray (#3878)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-10-20 00:36:32 +00:00
Aarush Deshpande
225efcad22
Use Github Markdown on README (#3925)
* test out new Github markdown README stuff

* Change warning -> caution
2024-10-20 00:24:14 +02:00
Rehmatpal Singh
0cdfd4b304
Fix: .to_edge()'s example demonstration in docs (#3958)
* ToEdgeExample's circle is added to the scene

* Made it consistent to the surrounding code

---------

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-10-19 21:54:34 +00:00
Francisco Manríquez Novoa
75a7525ed5
Optimized interpolate and bezier in manim.utils.bezier (#3960)
* Optimized bezier and interpolate in bezier.py

* Minor doc changes

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-10-19 21:32:12 +00:00
Achille Fouilleul
5788f8131f
Set AAC codec for audio in mp4 files, add transcoding utility (#3956)
* scene_file_writer: convert frame_rate to fraction

* Set audio codec to AAC when format=mp4

* refactor: change import uv.utils.Fraction -> fractions.Fraction

* use config as single source of truth for container format

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-10-19 23:12:07 +02:00
Achille Fouilleul
0a96aacb24
os.system -> subprocess (#3955)
Quoting the python library documentation:

> The subprocess module provides more powerful facilities for spawning
> new processes and retrieving their results; using that module is
> preferable to using this function.
2024-10-15 20:43:02 -03:00
Geoo Chi
d6f066c131
Fix np.float_ to np.float64 while using numpy >= 2.0 (#3940)
Co-authored-by: Geoo Chi <szchixy@gmail.com>
2024-10-04 16:28:15 +02:00
dependabot[bot]
1dcb81268a
Bump cryptography from 43.0.0 to 43.0.1 (#3931)
Bumps [cryptography](https://github.com/pyca/cryptography) from 43.0.0 to 43.0.1.
- [Changelog](https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/43.0.0...43.0.1)

---
updated-dependencies:
- dependency-name: cryptography
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-03 21:56:21 -04:00
Aarush Deshpande
74f79a42b6
Use Ruff pygrep rules (#3923)
* Add config for ruff pygrep

* Fix pygrep linting errors
2024-09-01 17:55:22 +02:00
Christopher Hampson
2536b7fafb
feat: preserve original TeX colors (#3903)
* feat: preserve original Tex colors

* added test for preserving tex color

* fix: fixed breaking change to tex color inheritance

* updated docstring and comment

* Update manim/mobject/text/tex_mobject.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-09-01 15:45:30 +00:00
Aarush Deshpande
1097ed9692
Standardize docstrings with ruff pydocstyle rules (#3881)
Used Ruff rules for `pydocstyle` to standardize docstring formatting.

* Add config for ruff pydocstyle

* Safe fixes from ruff

* Unsafe fixes from ruff
2024-09-01 08:03:38 -04:00
Irvanal Haq
8deac51abc
Changing the 'side_length' attribute to a property (#3901)
* Changing the 'side_length' attribute to a property

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add tests for Square side_length property

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update tests/module/mobject/geometry/test_unit_geometry.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-08-31 11:40:09 +00:00
Irvanal Haq
76e6a57164
Remove inner radius for :class:.Sector (#3922)
A Sector is a special case of `AnnualarSector` where the inner radius is zero. As such, it does not make sense to also have a parameter for the inner radius.

* Simplify Sector Class by Removing Redundant Parameters

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-08-30 16:29:41 -04:00
pre-commit-ci[bot]
95966a7f61
[pre-commit.ci] pre-commit autoupdate (#3918)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.6.1 → v0.6.2](https://github.com/astral-sh/ruff-pre-commit/compare/v0.6.1...v0.6.2)
- [github.com/pre-commit/mirrors-mypy: v1.11.1 → v1.11.2](https://github.com/pre-commit/mirrors-mypy/compare/v1.11.1...v1.11.2)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-08-26 14:19:46 -04:00
Irvanal Haq
32cc7abee1
fix type hint, change int to float (#3916) 2024-08-26 16:03:19 +00:00
pre-commit-ci[bot]
2462d0d011
[pre-commit.ci] pre-commit autoupdate (#3911)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.7 → v0.6.1](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.7...v0.6.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-08-19 16:55:47 -04:00
Benjamin Hackl
d029beb2b7
bugfix: convert non-.wav/.raw files to .wav before passing to pydub (#3832)
pydub will try to use `ffmpeg` for non-`.wav`/`.raw` files, which is no longer a dependency of Manim. To avoid this, we convert non `.wav`/`.raw` files into `.wav` files before passing it to pydub.

---------

Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
2024-08-14 16:42:15 +00:00
pre-commit-ci[bot]
99ce78fd60
[pre-commit.ci] pre-commit autoupdate - Ruff (#3904)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.6 → v0.5.7](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.6...v0.5.7)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-08-12 13:59:07 -04:00
fogsong233
aa660c77ec
Fix typehint of :meth:.Scene.restructure_mobjects. (#3902) 2024-08-12 07:05:18 -04:00
Aarush Deshpande
c0b04876db
Run poetry lock (#3895) 2024-08-06 15:31:53 +02:00
pre-commit-ci[bot]
0ac03869f5
[pre-commit.ci] pre-commit autoupdate (#3896)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.5 → v0.5.6](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.5...v0.5.6)
- [github.com/PyCQA/flake8: 7.1.0 → 7.1.1](https://github.com/PyCQA/flake8/compare/7.1.0...7.1.1)
- [github.com/pre-commit/mirrors-mypy: v1.11.0 → v1.11.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.11.0...v1.11.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-08-05 14:36:37 -04:00
Saveliy Yusufov
11ea41633c
Significantly reduce rendering time with a separate thread for writing frames to stream (#3888)
* Add separate thread for writing frames to stream

* [pre-commit.ci] pre-commit autoupdate (#3889)

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.4 → v0.5.5](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.4...v0.5.5)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>

* Replace the TypeError message code in the _typecheck_input method in … (#3890)

* Replace the TypeError message code in the _typecheck_input method in the DrawBorderThenFill class.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>

* Remove print statements used for debugging

* Remove writing process termination

- This is probably leftover from back when manim used subprocess to
  write frames to FFmpeg via stdin

* Add type hints to modified methods & instance vars

* Fix inline code in docstring & type hint for queue

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Irvanal Haq <125118413+irvanalhaq9@users.noreply.github.com>
2024-08-04 17:15:58 -04:00
Irvanal Haq
17e5a77b09
Replace the TypeError message code in the _typecheck_input method in … (#3890)
* Replace the TypeError message code in the _typecheck_input method in the DrawBorderThenFill class.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-30 06:31:12 -04:00
pre-commit-ci[bot]
85d9ac8f47
[pre-commit.ci] pre-commit autoupdate (#3889)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.4 → v0.5.5](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.4...v0.5.5)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-29 14:19:17 -04:00
Aarush Deshpande
5bda1075e6
Fix typo from HSV PR (#3887) 2024-07-28 08:31:38 +02:00
Tristan Schulz
c47b2d5f44
Experimenting with an HSV class (#3518)
* Experimenting with an HSL class

* Add some more functionality

* Adding a lot of tests and implementing fully functional conversion between color spaces over proxy rgba

* Fixing tests

* Fixing typing

* return str to normal

* Additional documentation

* Update manim/utils/color/core.py

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Update manim/utils/color/core.py

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Update manim/utils/color/core.py

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Update manim/utils/color/core.py

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Fix documentation and typing and revamp operators to respect color spaces

* Fix color operator typing and add operator tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix typeguard

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Import ManimFloat

* Update manim/utils/color/core.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Update manim/utils/color/core.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Add docstring to _internal_space

* naming of functions according to pep8

* Fix naming

* Update manim/utils/color/core.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Update manim/utils/color/core.py

Co-authored-by: Aarush Deshpande <110117391+JasonGrace2282@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-25 22:44:22 +02:00
Aarush Deshpande
2075f82bed
Fix :meth:.OpenGLMobject.invert not reassembling family (#3885)
* fix OpenGLMobject.invert

* return self to match typehint
2024-07-25 18:58:58 +00:00
alembcke
20d0194074
Added colorscale to axes.plot() (#3148)
* add colorscale to plot

* Update manim/mobject/graphing/coordinate_systems.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* updated typing and moved one line

* added test

* fix input_to_graph_point error

* Performance improvement by using cairo color drawing

* Add OpenGL support

* Add OpenGL tests and split test for x and y axis for more behavior coverage

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated gradient_line tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: MrDiver <mrdiverlp@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
Co-authored-by: chopan <francisco.manriquezn@usm.cl>
2024-07-25 18:46:15 +00:00
Aarush Deshpande
3a4ab4cd25
Rename parameters and variables conflicting with builtin functions (#3884)
* Config for flake8-builtins

* Manual changes for flake8-builtins
2024-07-25 20:06:18 +02:00
Aarush Deshpande
d6dac76fa3
Change flake8-comprehensions and flake8-bugbear to ruff (#3882)
* Add config for bugbear/comprehensions

note: flake8-comprehensions has 0 changes to the files

* Safe fixes from pre-commit

* Manual changes to make pre-commit pass

* Remove deps from pyproject
2024-07-25 10:40:13 -04:00
pre-commit-ci[bot]
3aad3553d8
[pre-commit.ci] pre-commit autoupdate (#3880)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.2 → v0.5.4](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.2...v0.5.4)
- [github.com/pre-commit/mirrors-mypy: v1.10.1 → v1.11.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.10.1...v1.11.0)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-22 17:35:46 +00:00
adeshpande
f463423abe
Use ruff instead of flake8-simplify (#3873)
* pyproject

* Autofixes from pre-commit

* use get over get(x, None)

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

---------

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
2024-07-22 16:22:11 +00:00
Christopher Hampson
0843632932
feat: set_default for Animation class (#3876)
* feat: Animation.set_default

Adds set_default class method to Animation class based on existing implementation for Mobject class.

Addresses issue #3142

* test: added missing test

* fix: docstring formatting

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-07-22 13:37:16 +02:00
adeshpande
c8fe4d9e4f
Use ruff for pytest style (#3872)
* Add ruff config for pytest

* Fixes for pre-commit

* Changes to make pre-commit happy (Unrelated to PR)

---------

Co-authored-by: Tristan Schulz <tristanschulz1200@gmail.com>
2024-07-21 14:37:57 +00:00
adeshpande
fa65b488b0
Fix pre-commit linting (#3877) 2024-07-21 15:03:31 +02:00
pre-commit-ci[bot]
a03e73c822
[pre-commit.ci] pre-commit autoupdate (#3865)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.1 → v0.5.2](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.1...v0.5.2)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-15 22:54:45 -04:00
Abulafia
f1ce512225
Fixed behavior of config.background_opacity < 1 and duplicated log messages (#3680)
* Fixes #3614

Setting background_transparency=0.0 should have the same effect than
setting transparent=True. The output format must be compatible
with transparency (.mov, .webm). Otherwise ffpmeg fails.

This patch ensures that background_transparency=0.0 triggers the
change of the output format. Also a WARNING is raised about
the change in the output format.

I want to thank @SirJamesClarkMaxwell for inspiring me to tackle
this issue.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* test config.background_opacity < 1

* fix config behavior for config.background_opacity < 1

* fix logger messages being emitted twice

* actually cleanup usage of loggers, remove logger-imports; black

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* dry_run fixture

* remove debug print

* applied suggestion from review

* remove custom fixture from test_deprecation, use manim_caplog

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-15 00:50:44 +02:00
adeshpande
205f746bbd
Update docker to use ENV x=y instead of ENV x y (#3858) 2024-07-14 21:13:26 +02:00
CJ Lee
b064af9abb
Update macos.rst (#3857)
* Update macos.rst

As of July/2024, brew installs Manim and its dependencies.
Guideline for installing dependencies with brew, and attempt to install using pip3 will no longer work either venv or not.
Now homebrew team manages python resources as "System-wide" only with Brew installed resources. 
Hence, to give first time installer just leave a single line install command would be the simplest option we have.

* Update docs/source/installation/macos.rst

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-07-14 12:00:08 +00:00
Francisco Manríquez Novoa
374eeeba0d
Optimize VMobject.pointwise_become_partial() (#3760)
* Optimize VMobject.pointwise_become_partial()

* selftransformation -> self

* Small factorization of nppc
2024-07-13 19:57:08 +02:00
Francisco Manríquez Novoa
3a71411527
Log execution time of scene rendering in the Manim Checkhealth command (#3855)
* Log execution time of scene rendering in the Manim Checkhealth command

* Use timeit.timeit instead of time.time for more reliable profiling
2024-07-13 17:13:14 +00:00
Francisco Manríquez Novoa
1df1709e49
Rewrite manim.utils.bezier.get_quadratic_approximation_of_cubic() to produce curves which can be animated smoothly (#3829)
* Rewrite get_quadratic_approximation_of_cubic() and add test

* Move test_get... to end of file

* Complete docstring for get_quadratic...()
2024-07-13 18:27:45 +02:00
adeshpande
628a54535b
Fix :attr:.ManimConfig.format not updating movie file extension (#3839)
* Fix config.format not updating config.movie_file_extension

* Add test
2024-07-13 11:37:17 +02:00
adeshpande
75625964b6
Change from tempconfig to a config fixture in tests (#3853)
* Implement changes to fixtures

* Change tests to use the config fixture
2024-07-12 22:41:51 +02:00
Francisco Manríquez Novoa
67f95db213
Rename typing.Image type aliases to PixelArray to avoid conflict with PIL.Image (#3851) 2024-07-12 14:07:44 +00:00
dependabot[bot]
bf2feee19e
Bump zipp from 3.18.2 to 3.19.1 (#3847)
Bumps [zipp](https://github.com/jaraco/zipp) from 3.18.2 to 3.19.1.
- [Release notes](https://github.com/jaraco/zipp/releases)
- [Changelog](https://github.com/jaraco/zipp/blob/main/NEWS.rst)
- [Commits](https://github.com/jaraco/zipp/compare/v3.18.2...v3.19.1)

---
updated-dependencies:
- dependency-name: zipp
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-11 13:18:45 -04:00
adeshpande
246e44b3d0
Fix incorrect version number in plugin section in docs (#3849) 2024-07-11 11:24:19 -04:00
dependabot[bot]
bb98eca37a
Bump certifi from 2024.2.2 to 2024.7.4 (#3841)
Bumps [certifi](https://github.com/certifi/python-certifi) from 2024.2.2 to 2024.7.4.
- [Commits](https://github.com/certifi/python-certifi/compare/2024.02.02...2024.07.04)

---
updated-dependencies:
- dependency-name: certifi
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-07-08 18:53:08 +00:00
pre-commit-ci[bot]
8614b9832e
[pre-commit.ci] pre-commit autoupdate (#3844)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.5.0 → v0.5.1](https://github.com/astral-sh/ruff-pre-commit/compare/v0.5.0...v0.5.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-08 14:34:16 -04:00
dependabot[bot]
73200d6644
Bump docker/build-push-action from 5 to 6 (#3835)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 5 to 6.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](https://github.com/docker/build-push-action/compare/v5...v6)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-01 21:17:46 +00:00
pre-commit-ci[bot]
1260346f4e
[pre-commit.ci] pre-commit autoupdate (#3834)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.4.10 → v0.5.0](https://github.com/astral-sh/ruff-pre-commit/compare/v0.4.10...v0.5.0)
- [github.com/pre-commit/mirrors-mypy: v1.10.0 → v1.10.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.10.0...v1.10.1)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-01 15:14:32 -04:00
Chin Zhe Ning
d117c9f4b5
Doc: add docstrings to Brace (#3715)
* Add docstrings to `Brace` methods

* Add full NumPy format docstring for the `Brace` methods

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* feedback

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-06-30 10:35:26 +00:00
adeshpande
8d70b0e886
Fix docker profile (#3827) 2024-06-27 23:53:24 +02:00
Francisco Manríquez Novoa
64ab9ade2b
Optimized manim.utils.bezier.get_smooth_cubic_bezier_handle_points() (#3767)
* Optimized manim.utils.get_smooth_cubic_bezier_handle_points()

* Fixed typo in docstring regarding vector u

* Add tests for get_smooth_cubic_bezier_handle_points

* Fix backreference in test docstrings

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

---------

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-06-26 16:33:39 +00:00
Sir James Clark Maxwell
0d21a7e6ed
Fixed Arrow3D.put_start_and_end_on() to use the actual end of the arrow (#3706)
* my test is not passing, i need to add a little bit of docs. except that everything is fine. Issue is solved!

* fixed the issue #3655

* removed comments

* fix: 3706 original issue, without adding unnecessary dot
added: i added self.height parameter in Cone class
my tests passes

* Changes that way how end point of Arrow3D is calculated.

* I've improved the methods get_start and get_end for the Cone class, and get_end for the Arrow3D class to ensure they return accurate geometrical points after transformations. Additionally, I've included unit tests to verify the correctness of these methods for the Cone class.

* Finished! Replaced VMobject by VectorizedPoint as Ben suggested while ago

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-06-26 15:33:33 +00:00
adeshpande
93a20cd9e7
feat(autoaliasattr): Implement documentation of TypeVar's (#3818)
* feat(autoaliasattr): Implement Documentation of TypeVar's

* Feedback

---------

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-06-26 14:55:03 +00:00
pre-commit-ci[bot]
a70aeee723
[pre-commit.ci] pre-commit autoupdate (#3823)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.4.9 → v0.4.10](https://github.com/astral-sh/ruff-pre-commit/compare/v0.4.9...v0.4.10)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-06-24 13:35:32 -04:00
Nikhil Iyer
d5cdd79709
Fix DiGraph edges not fading correctly on FadeIn and FadeOut (#3786)
* Make `Line::set_points_by_ends` behavior consistent with constructor

* Use `Line::set_points_by_ends` in edge updaters

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Undo unnecessary change to Graph

* Update manim/mobject/geometry/line.py

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-06-22 20:35:21 +00:00
adeshpande
fdb4e37f75
docs(contributing): add manim.typing guide (#3669)
* docs: add manim.typing guide

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add colors

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add another example for when to typehint as Vector

* Add docs for images+functions

* write Beziers

* Improve based on feedback

* type -> Type

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-06-22 20:14:36 +00:00
Cameron Burdgick
89d5ed4398
Fixed infinite loop in OpenGL BackgroundRectangle.get_color() (#3732)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-06-21 16:56:34 +00:00
adeshpande
82ff488f9c
Update macos packages (#3812) 2024-06-19 13:47:12 -04:00
dependabot[bot]
56354af1e5
Bump urllib3 from 2.2.1 to 2.2.2 (#3810)
Bumps [urllib3](https://github.com/urllib3/urllib3) from 2.2.1 to 2.2.2.
- [Release notes](https://github.com/urllib3/urllib3/releases)
- [Changelog](https://github.com/urllib3/urllib3/blob/main/CHANGES.rst)
- [Commits](https://github.com/urllib3/urllib3/compare/2.2.1...2.2.2)

---
updated-dependencies:
- dependency-name: urllib3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-18 11:47:10 -04:00
pre-commit-ci[bot]
7802e73b88
[pre-commit.ci] pre-commit autoupdate (#3809)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.4.8 → v0.4.9](https://github.com/astral-sh/ruff-pre-commit/compare/v0.4.8...v0.4.9)
- [github.com/PyCQA/flake8: 7.0.0 → 7.1.0](https://github.com/PyCQA/flake8/compare/7.0.0...7.1.0)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-06-17 13:34:33 -04:00
Eddie Ruiz
3ed86a820b
fix: importing manim should not trigger pygments.styles.get_all_styles (#3797)
* fix: importing manim should not trigger pygments.styles.get_all_styles

Removed the Code.styles_list attribute.

Rewrote the documentation to say that a list of all styles can be generated by calling list(pygments.styles.get_all_styles()).

The example in the docstring of Code was rewritten to use an explicit code style name.

* fix: small change to documentation

* Added potential class method to get available code styles.

* Adding typehints to newly-added attributes.

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Removing unnecessary lines.

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

---------

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-06-17 08:31:44 -04:00
Francisco Manríquez Novoa
4641c0a808
Add typings to OpenGLMobject (#3803)
* Add typings to OpenGLMobject

* Import typing_extensions

* Add explicit returns to inner functions in .arrange_in_grid()

* Add quotes to parameters in ValueError

* Add some more typings

* Address requested changes

* Type apply_over_attr_arrays with TypeVar

* Fix use of TypeVar

* Add Vector3D typing in set_x, set_y and set_z
2024-06-13 18:07:43 -04:00
pre-commit-ci[bot]
ece1235d49
[pre-commit.ci] pre-commit autoupdate (#3801)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.4.7 → v0.4.8](https://github.com/astral-sh/ruff-pre-commit/compare/v0.4.7...v0.4.8)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-06-10 14:18:56 -04:00
yang-tsao
c2fa4f926b
Update opengl_vectorized_mobject.py (#3790)
The "insert_n_curves_to_point_list" function requires the "points" argument to be a numpy array, since it calls the "get_bezier_tuples_from_points" function, which requires "points" to be a numpy array because it has the "return points.reshape((-1, nppc, 3))" statement. Ordinary lists do not have a "reshape" method.

So we need to convert "sp1" and "sp2" to numpy arrays before calling the "insert_n_curves_to_point_list" function.

Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-06-10 08:07:20 -04:00
dependabot[bot]
e30ed6ed82
Bump tornado from 6.4 to 6.4.1 (#3796)
Bumps [tornado](https://github.com/tornadoweb/tornado) from 6.4 to 6.4.1.
- [Changelog](https://github.com/tornadoweb/tornado/blob/master/docs/releases.rst)
- [Commits](https://github.com/tornadoweb/tornado/compare/v6.4.0...v6.4.1)

---
updated-dependencies:
- dependency-name: tornado
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-09 23:18:12 -04:00
adeshpande
e74f37ed68
Replace Pyupgrade with Ruff rule (#3795)
* Add config for pyupgrade

* Fix pyupgrade errors

* Unsafe-fixes

* Nicer way of formatting

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Revert "Nicer way of formatting"

This reverts commit 48013f4a30.

---------

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-06-05 08:08:21 -04:00
adeshpande
252aac30da
Add Ruff Lint (#3780)
Adds Ruff Linting to CI, and replaces isort in the pre-commit config with Ruff's isort rules.

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
2024-06-03 23:39:08 -04:00
pre-commit-ci[bot]
aec3d86122
[pre-commit.ci] pre-commit autoupdate (#3794)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.4.5 → v0.4.7](https://github.com/astral-sh/ruff-pre-commit/compare/v0.4.5...v0.4.7)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-06-03 23:16:13 -04:00
pre-commit-ci[bot]
31df6d0a23
[pre-commit.ci] pre-commit autoupdate (#3784)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.4.4 → v0.4.5](https://github.com/astral-sh/ruff-pre-commit/compare/v0.4.4...v0.4.5)
- [github.com/codespell-project/codespell: v2.2.6 → v2.3.0](https://github.com/codespell-project/codespell/compare/v2.2.6...v2.3.0)

* Fix typo

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
2024-05-27 20:19:22 +00:00
adeshpande
90ae6ad804
Add @ shorthand for CoordinateSystem methods coords_to_point (c2p) and point_to_coords (p2c) (#3754)
* Add shorthand for axes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add spacing

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

* Convert CoordinateSystem example, and add to NumberLine

* Add doctest for NumberLine

* Add test

* Fix typehint for c2p

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-05-27 17:34:08 +00:00
Francisco Manríquez Novoa
938b8fc344
Optimize VMobject methods which append to points (#3765) 2024-05-23 10:30:25 -04:00
jkjkil4
0a2fbbeffb
Fixed there_and_back_with_pause() rate function behaviour with different pause_ratio values (#3778)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-05-22 18:22:35 +00:00
Victorien
c9776be7da
Ignore Ruff format in git blame (#3781) 2024-05-22 13:32:50 -04:00
adeshpande
24025b60d5
pre-commit change to ruff (#3779)
* pre-commit change to ruff

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixes

* astral-sh ruff bump

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-05-22 12:03:23 -04:00
adeshpande
21eb0b7769
Add pyproject for ruff formatting (#3777)
* Add pyproject for ruff

* add black config back

* Make only formatting

* rearrange isort to undo diff

* poetry lock

* Feedback

* style

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

---------

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
2024-05-22 10:56:40 +00:00
Francisco Manríquez Novoa
0d67dcdc6e
Fix assertions and improve error messages when adding submobjects (#3756)
* Optimized AnimationGroup computation of start-end times with lag ratio

* Added extra comment for init_run_time

* Added full path to imports in composition.py

* Optimized AnimationGroup.interpolate

* Fixed final bugs

* Removed accidental print

* Final fix to AnimationGroup.interpolate

* Fixed animations being skipped unintentionally

* Fix and improve Mobject assertions when adding submobjects

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update examples in Mobject.add() and OpenGLMobject.add() docstrings

* overriden -> overridden

* Joined string in OpenGLMobject error message

* Address requested changes

* OpenGLVMObjects -> OpenGLVMobjects

* Use tuplify in VGroup.__setitem__()

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-05-21 15:30:46 -04:00
dependabot[bot]
739958514f
Bump requests to 2.32.0 (#3776)
updated-dependencies:
- dependency-name: requests
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-21 09:00:12 -04:00
Francisco Manríquez Novoa
7b841c27cc
Created and optimized Bézier splitting functions such as partial_bezier_points() in manim.utils.bezier (#3766)
* Optimized manim.utils.partial_bezier_points()

* Added split_bezier, subdivide_bezier and bezier_remap, and tests

* Use bezier_remap() in VMobject and OpenGLVMobject()

* Note that partial_bezier_points is similar to calling split_bezier twice
2024-05-21 05:26:59 +00:00
Francisco Manríquez Novoa
b4156045a3
Optimized manim.utils.bezier.is_closed() (#3768)
* Optimized manim.utils.bezier.is_closed()

* oops, that shouldn't have been there

* Slightly optimized is_closed() even more

* Added doctest for is_closed()
2024-05-20 03:49:52 +00:00
adeshpande
203a5366c2
Use --py39-plus in pre-commit (#3761)
* Use --py39-plus in pre-commit

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix indication.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-05-15 17:24:16 -04:00
Benjamin Hackl
1f249e45b9
Let SceneFileWriter access ffmpeg via av instead of via external process (#3501)
* added av as a dependency

* make partial movie files use av instead of piping to external ffmpeg

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* opengl rendering: use av for movie files

* no need to check for ffmpeg executable

* refactor: *_movie_pipe -> *_partial_movie_stream

* improve (oneline) documentation

* pass more options to partial movie file rendering

* move ffmpeg verbosity settings to config; renamed option dict

* replaced call to ffmpeg in combine_files by using av

Co-authored-by: Jérome Eertmans <jeertmans@icloud.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* there was one examples saved as a gif?

* chore(deps): re-order av

* chore(lib): simplify `write_frame` method

Reduces the overall code complexity

* chore(lib): add audio

* fix(lib): same issue for conversion

* fix(lib): webm export

* fix(lib): transparent export

Though the output video is weird

* try(lib): fix gif + TODOs

* chore(deps): lower dep crit

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* feat(lib): add support for GIF

* fix(ci): rewrite tests

* fix

* chore(ci): prevent calling concat on empty list

* add missing dot

* fix(ci): update frame comparison ?

* fix(log): add handler to libav logger

* chore: add TODO

* fix(lib): concat issue

* Revert "fix(ci): update frame comparison ?"

This reverts commit 904cfb46ae.

* fix(ci): make it pass tests

* chore(lib/docs/ci): remove FFMPEG entirely

This removes any reference to FFMPEG, except in translation files

* added av as a dependency

* make partial movie files use av instead of piping to external ffmpeg

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* opengl rendering: use av for movie files

* no need to check for ffmpeg executable

* refactor: *_movie_pipe -> *_partial_movie_stream

* improve (oneline) documentation

* pass more options to partial movie file rendering

* move ffmpeg verbosity settings to config; renamed option dict

* replaced call to ffmpeg in combine_files by using av

Co-authored-by: Jérome Eertmans <jeertmans@icloud.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* there was one examples saved as a gif?

* chore(deps): re-order av

* chore(lib): simplify `write_frame` method

Reduces the overall code complexity

* chore(lib): add audio

* fix(lib): same issue for conversion

* fix(lib): webm export

* fix(lib): transparent export

Though the output video is weird

* try(lib): fix gif + TODOs

* chore(deps): lower dep crit

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* feat(lib): add support for GIF

* fix(ci): rewrite tests

* fix

* chore(ci): prevent calling concat on empty list

* add missing dot

* fix(ci): update frame comparison ?

* fix(log): add handler to libav logger

* chore: add TODO

* fix(lib): concat issue

* Revert "fix(ci): update frame comparison ?"

This reverts commit 904cfb46ae.

* fix(ci): make it pass tests

* chore(lib/docs/ci): remove FFMPEG entirely

This removes any reference to FFMPEG, except in translation files

* chore(deps): update lockfile

* chore(lib): rewrite ffprobe

* fix typo

* slightly more aggressive removal of ffmpeg in docs; minor language changes

* fix gif output stream dimensions

* minor style change

* fix encoding of (transparent) mov files

* fixed metadata / comment

* set frame rate for --format=gif in output_stream

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* more video tests for different render settings, also test pix_fmt

* improve default bitrate setting via crf

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* parametrized format/transparency rendering test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* context managers for (some) av.open

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update manim/utils/commands.py

Co-authored-by: Jérome Eertmans <jeertmans@icloud.com>

* fixed segfault

* update test data involving implicit functions (output improved!)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* explicity set pix_fmt for transparent webms

* special-special case extracting frame from vp9-encoded file with transparency

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix transparent gifs, more special casing in parametrized video format test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* run tests on macos-latest again

* removed old control data

* Revert "run tests on macos-latest again"

This reverts commit f50efa4b88.

* added sound to codec test; fixed issue with sound track in gif (disabled) and webm (now via opus)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* manual wav -> ogg transcoding

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed f-string

* refactored codec test, split out gif

* check for non-zero audio samples

* more cleanup

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* remove ffmpeg from readthedocs apt_packages

* round up run_time if positive and shorter than current frame rate

* added more run_time tests

* black

* improve implementation of test

* removed some unused imports

* improve wording of logged warning

Co-authored-by: Jérome Eertmans <jeertmans@icloud.com>

* move run_time checks from Animation.begin to Scene.get_run_time

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* remove unused import

* flake: PT012

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Jérome Eertmans <jeertmans@icloud.com>
2024-05-15 13:23:09 +00:00
adeshpande
4bd2f860b4
Add typehints to manim.utils.iterables (#3751)
* typehint iterables

* organize typing hints

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* remove any

* Add overloads for tuplify

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Remove example

* feedback

* Make TypeVars accessible at runtime

* Add hints for zip

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

* typing -> collections.abc

Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>

* try to make mypy happy

* zip[tuple[T, ...]] instead of zip[T]

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com>
2024-05-11 21:33:03 -04:00
dependabot[bot]
94cd27c234
Bump jinja2 from 3.1.3 to 3.1.4 (#3750)
Bumps [jinja2](https://github.com/pallets/jinja) from 3.1.3 to 3.1.4.
- [Release notes](https://github.com/pallets/jinja/releases)
- [Changelog](https://github.com/pallets/jinja/blob/main/CHANGES.rst)
- [Commits](https://github.com/pallets/jinja/compare/3.1.3...3.1.4)

---
updated-dependencies:
- dependency-name: jinja2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-06 19:41:58 -04:00
dependabot[bot]
e4ee9a06a1
Bump tqdm from 4.66.1 to 4.66.3 (#3746)
Bumps [tqdm](https://github.com/tqdm/tqdm) from 4.66.1 to 4.66.3.
- [Release notes](https://github.com/tqdm/tqdm/releases)
- [Commits](https://github.com/tqdm/tqdm/compare/v4.66.1...v4.66.3)

---
updated-dependencies:
- dependency-name: tqdm
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-04 15:08:19 -04:00
anagorko
93c601f013
Fixes #3744 (#3745)
Co-authored-by: Andrzej Nagórko <>
2024-05-03 20:46:20 +02:00
pre-commit-ci[bot]
31f189519b
[pre-commit.ci] pre-commit autoupdate (#3739)
updates:
- [github.com/psf/black: 24.4.0 → 24.4.2](https://github.com/psf/black/compare/24.4.0...24.4.2)
- [github.com/pre-commit/mirrors-mypy: v1.9.0 → v1.10.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.9.0...v1.10.0)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-04-29 14:17:54 -04:00
adeshpande
a56c0c9fee
Fix release documentation building (#3737) 2024-04-29 00:37:27 +02:00
VPC
4a0c7057db
feat: Add three animations that together simulate a typing animation (#3612)
* feat: Add animations that together simulate typing

AddTextLetterByLetterWithCursor

RemoveTextLetterByLetterWithCursor

Blink

* Revert "feat: Add animations that together simulate typing"

This reverts commit 5fe256880d.

* Revert "Revert "feat: Add animations that together simulate typing""

This reverts commit 6a8244a157.

* Add new animations to __all__

* Temporarily remove docs example

* Modify "Blink" and add docstring examples back in

To avoid 0-second animations, which fail docstring test

* Address requested changes

Fix imports
Remove redundant constructor arguments
Improve names

* Shorten names
2024-04-28 16:19:24 +00:00
Benjamin Hackl
33e560473d
Prepare new release: v0.18.1 (#3719)
* add note about changelog in changelog.rst

* bump version

* Update CITATION.cff
2024-04-28 09:02:22 +00:00
Benjamin Hackl
6cb89a06ba
fixed [""] being set as loaded plugins (#3734) 2024-04-28 00:35:29 +02:00
Jinchu Li
c4e7502968
Fixed ``get_anchors()`` Return Type Inconsistency (#3214)
* changed return type of get_anchors()

* Ensured consistency with OpenGLVMobject

* Fixed CodeQl, updated docstring

* Update manim/mobject/types/vectorized_mobject.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update manim/mobject/opengl/opengl_vectorized_mobject.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* fixed typo, t -> e

* fixed doctest

---------

Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2024-04-27 23:54:24 +02:00
Francisco Manríquez Novoa
1ce3edd97a
AnimationGroup: optimized interpolate() and fixed alpha bug on finish() (#3542)
* Optimized AnimationGroup computation of start-end times with lag ratio

* Added extra comment for init_run_time

* Added full path to imports in composition.py

* Optimized AnimationGroup.interpolate

* Fixed final bugs

* Removed accidental print

* Final fix to AnimationGroup.interpolate

* Fixed animations being skipped unintentionally

* Addressed requested changes

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-04-27 23:34:17 +02:00
adeshpande
98641a2f82
Add `--preview_command` cli flag (#3615)
* Add preview_command cli flag

* Edit help for --preview_command

* Change back from subprocess.run

* Remove old comment

* Bug with timg stopped happening with sp.run

* Fix docstring

* Revert "Fix docstring"

This reverts commit d2c00fc24dc46586f994237f1d2758528b78d6a3.

* Actually fix docstring

* Change help for option

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-04-27 23:18:48 +02:00
adeshpande
a3d584b7f4
build(ci): change from macos-latest to macos-13 (#3729) 2024-04-27 00:57:17 +02:00
Amirreza A
791a892be3
Update coordinate_systems.py (#3730)
small change
2024-04-27 00:55:03 +02:00
Benjamin Hackl
0f268e6f9c
Follow-up to graph layout cleanup: improvements for tests and typing (#3728)
* suggestions from review on #3434

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-04-25 00:38:16 +02:00
Nikhil Iyer
a3adcaaab3
Clean Graph layouts and increase flexibility (#3434)
* allow user-defined layout functions for Graph
+ fixup type annotations

* only pass relevant args

* write tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* change_layout forward root_vertex and partitions
- deduplicated layout code in __init__ and change_layout
- fixed change_layout backwards compatibility

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* add test for change_layout

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix copy/paste error

* fix

* fixup types for CodeQL

* static type the Layout Names

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix dynamic union type for Python 3.9

* add example scenes to LayoutFunction protocol documentation

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Replace references to np.ndarray with standard Manim types

* Label NxGraph as a TypeAlias

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-04-24 23:33:44 +02:00
Greg Rupp
aa3e2cf54e
Fix issue where SpiralIn doesn't show elements. (#3589)
* Set SpiralIn to use fill_opacity 1 if not set

* Create SpiralIn control data

* Create test for SpiralIn

* Fix spiralin to separate fill and stroke opacity

* resolve opacity issue

* fix test data

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-04-24 22:02:13 +02:00
adeshpande
c32f0fd83a
build(deps): read-the-docs sphinx (#3720) 2024-04-24 16:52:15 +02:00
adeshpande
a4e5233273
fix(autoaliasattr): search for type aliases under if TYPE_CHECKING (#3671) 2024-04-24 08:02:43 -04:00
pre-commit-ci[bot]
1aee37bfb5
[pre-commit.ci] pre-commit autoupdate (#3332)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/pre-commit/pre-commit-hooks: v4.4.0 → v4.6.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.4.0...v4.6.0)
- [github.com/pycqa/isort: 5.12.0 → 5.13.2](https://github.com/pycqa/isort/compare/5.12.0...5.13.2)
- [github.com/asottile/pyupgrade: v3.10.1 → v3.15.2](https://github.com/asottile/pyupgrade/compare/v3.10.1...v3.15.2)
- [github.com/psf/black: 23.7.0 → 24.4.0](https://github.com/psf/black/compare/23.7.0...24.4.0)
- [github.com/asottile/blacken-docs: 1.15.0 → 1.16.0](https://github.com/asottile/blacken-docs/compare/1.15.0...1.16.0)
- [github.com/PyCQA/flake8: 6.1.0 → 7.0.0](https://github.com/PyCQA/flake8/compare/6.1.0...7.0.0)
- [github.com/pre-commit/mirrors-mypy: v1.5.1 → v1.9.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.5.1...v1.9.0)
- [github.com/codespell-project/codespell: v2.2.5 → v2.2.6](https://github.com/codespell-project/codespell/compare/v2.2.5...v2.2.6)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* make smoothererstep readable again, avoid overlong line

* zoom_value more readable

* fix blacken-docs touching .github

* fix codespell setup, remove unnecessary file, fix some typos

* flake8: ignore E704, triggered by overload

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update docs/source/tutorials/quickstart.rst

* more flake fixes

* try to make blacken-docs happy

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-04-24 13:11:03 +02:00
MontroyJosh
0fd16b8918
Fixed Mobject.put_start_and_end_on with same start and end point (#3718)
* fix put_start_and_end_on() at the same point

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-04-24 12:37:44 +02:00
Stefano Ottolenghi
563810a772
Fix typo (#3721) 2024-04-24 12:21:37 +02:00
dependabot[bot]
dff83be61f
Bump pillow from 10.2.0 to 10.3.0 (#3672)
Bumps [pillow](https://github.com/python-pillow/Pillow) from 10.2.0 to 10.3.0.
- [Release notes](https://github.com/python-pillow/Pillow/releases)
- [Changelog](https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst)
- [Commits](https://github.com/python-pillow/Pillow/compare/10.2.0...10.3.0)

---
updated-dependencies:
- dependency-name: pillow
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-21 11:23:20 +02:00
dependabot[bot]
83957b9c2f
Bump idna from 3.6 to 3.7 (#3693)
Bumps [idna](https://github.com/kjd/idna) from 3.6 to 3.7.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](https://github.com/kjd/idna/compare/v3.6...v3.7)

---
updated-dependencies:
- dependency-name: idna
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-21 11:22:37 +02:00
adeshpande
f8e3408f9e
Fix some typehints in mobject.py (#3668)
* refactor(mobject): fix some typehints

* Move typing_extensions import under `if TYPE_CHECKING`
* Change from using `def animate(self: T ,...) -> T` to `def
  animate(self, ...) -> Self` as stated in PEP 673
* Fix incorrect usage of `T` in a method

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* move updaters type alias into TYPE_CHECKING

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-04-20 16:16:29 +02:00
adeshpande
679b89a43f
fix(copyright): automate copyright updating for docs (#3708) 2024-04-19 23:42:17 +02:00
Daniel Zhu
f9dc9c7a5b
Update documentation and typings for ParametricFunction (#3703)
* Update documentation and typings for ParametricFunction

* Use manim tyings

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* fix typings

* a few doc fixes

* Update manim/mobject/graphing/functions.py

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* update typings

* remove extraneous line

* update example code

* add line back for comptibility

* import TYPE_CHECKING

---------

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-04-19 07:11:13 -04:00
adeshpande
5139765ff4
docs: update typing guidelines (#3704)
* Update typing guidelines

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix formatting

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci
2024-04-16 21:40:15 -04:00
dependabot[bot]
04bfa22107
Bump ssciwr/setup-mesa-dist-win from 1 to 2 (#3609)
Bumps [ssciwr/setup-mesa-dist-win](https://github.com/ssciwr/setup-mesa-dist-win) from 1 to 2.
- [Release notes](https://github.com/ssciwr/setup-mesa-dist-win/releases)
- [Commits](https://github.com/ssciwr/setup-mesa-dist-win/compare/v1...v2)

---
updated-dependencies:
- dependency-name: ssciwr/setup-mesa-dist-win
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-14 22:18:04 +00:00
dependabot[bot]
dc0db41245
Bump FedericoCarboni/setup-ffmpeg from 2 to 3 (#3608)
Bumps [FedericoCarboni/setup-ffmpeg](https://github.com/federicocarboni/setup-ffmpeg) from 2 to 3.
- [Release notes](https://github.com/federicocarboni/setup-ffmpeg/releases)
- [Commits](https://github.com/federicocarboni/setup-ffmpeg/compare/v2...v3)

---
updated-dependencies:
- dependency-name: FedericoCarboni/setup-ffmpeg
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-14 21:50:46 +00:00
dependabot[bot]
a45c0d4b67
Bump actions/cache from 3 to 4 (#3607)
Bumps [actions/cache](https://github.com/actions/cache) from 3 to 4.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-04-14 21:20:24 +00:00
Sir James Clark Maxwell
27766127e2
Fix successive calls of :meth:.LinearTransformationScene.apply_matrix (#3675)
* docs: improve installation FAQ's

* I have potentially resolved the issue when in LinearTransformationScene between two animations of transforming space we invoke the self.wait()

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* added another solutions in comments, added tests and removed wrong files from git

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* yeah , i forgot to save the file xd

* fixed the test, removed the comments my in changed file

* fix test and speed up test time for test_apply_matrix

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed the test, removed the comments my in changed file

* fixed the test

* Revert "docs: improve installation FAQ's"

This reverts commit e53a1c8d6f.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-04-14 13:22:36 +00:00
Pavel Zwerschke
2a4c2da1d7
Mention pixi in installation guide (#3678)
* Mention pixi in installation guide

* Update docs/source/installation/conda.rst

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Add note

---------

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-04-14 11:56:25 +00:00
adeshpande
902c3f4215
only do actions if try succeeded (#3694) 2024-04-14 10:31:40 +02:00
HairlessVillager
aef8184379
Docs: fix out-dated CLI option in Manim's Output Settings (#3674)
* Docs: fix out-dated CLI option in Manim's Output Settings

* Docs: more fluent English

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Docs: break lines

* Docs: more fluent English

* Docs: remove a space

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

---------

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-04-13 09:02:34 -04:00
Chin Zhe Ning
b750152700
Fix typo (#3696) 2024-04-12 06:42:28 -04:00
adeshpande
93cf85cd42
Attempted fix for windows cp1252 encoding failure (#3687)
* Attempt to fix windows test

* Revert "Attempt to fix windows test"

This reverts commit e31c2077cd.

* try a different fix

* maybe both fixes together?

* try adding in CI

* Update ci.yml

* Update logger_utils.py

* maybe needs a dash?

* try utf8 again

* Remove legacy_windows

* try changing test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Try decoding after capturing bytes output

* Nicer fix

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci
2024-04-11 23:56:59 +02:00
adeshpande
294313d683
Remove deprecated parameters and animations (#3688)
* Remove deprecated parameters/animations

* Remove test

* Remove test data
2024-04-11 19:49:02 +02:00
adeshpande
a6da37b88c
fix(LICENSE): update year (#3689) 2024-04-11 17:57:55 +02:00
Chin Zhe Ning
d62a04f059
Fix minor grammatical errors found in the index page of the documentation (#3690)
* Fix some minor grammatical errors in the index page of the docs

* Fix grammar

* Undo uneccessary change in phrasing
2024-04-11 17:57:40 +02:00
Chin Zhe Ning
7936c7d08a
Fix broken link to Poetry's installation guide in the first time contributors page (#3692) 2024-04-11 17:55:40 +02:00
Christian Clauss
1aad0c7b1a
Flake8 rule C901 is about McCabe code complexity (#3673)
* Flake8 rule C901 is about McCabe code complexity

It is not about flake8-comprehensions.

* max-complexity = 29
2024-04-09 08:22:30 +02:00
Abulafia
c025be6516
Fix bug in :class:.VMobjectFromSVGPath (#3677)
* Fixes #3676

* Update manim/mobject/svg/svg_mobject.py

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>

* Fixed problem and added test

---------

Co-authored-by: adeshpande <110117391+JasonGrace2282@users.noreply.github.com>
2024-04-08 18:46:43 +02:00
adeshpande
ef675b64f0
Fix typehint of Vector direction parameter (#3640)
* Fix typehint of Vector

* Change from Vector to Point in typehint

In `TipableVMobject._pointify` it converts a 3D
list of the form [x, y, z] to a Vector3D. Therefore
the direction parameter can take lists, not just numpy arrays.
2024-04-02 18:44:41 +00:00
adeshpande
afe1d18de5
Added some examples for Mobject/VMobject methods (#3641)
* Add examples to mobject+vmobject methods

* Add missing import

* Separate whitespace to point_from_proportion

* Fixes!

* Changed example of Mobject.get_color

* Remove unneccessary import

* Add in import
2024-04-01 13:50:10 +00:00
Tristan Schulz
909ffded28
Fixing the behavior of .become to not modify target mobject via side effects fix color linking (#3508)
* Copied ndarray for rgbas when interpolating

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* changing .become to copy the target mobject

* change tests and test data to reflect .become new behavior

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update tests/test_graphical_units/test_mobjects.py

* removed unused copy_submobject kwarg

* added doctests and improved documentation

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-04-01 03:41:57 +00:00
adeshpande
7a794e341f
Code Cleanup: removing unused imports and global variables (#3620)
* Remove unused import

* More security fixes

* Remove unused global variable

* More fixes

* Revert change (actual fix would require some rewrite)

* Add exception for edge case to satisfy warning

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Stuff

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-04-01 03:21:14 +00:00
dependabot[bot]
d1cf1c5750
Bump cryptography from 42.0.0 to 42.0.4 (#3629)
Bumps [cryptography](https://github.com/pyca/cryptography) from 42.0.0 to 42.0.4.
- [Changelog](https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/42.0.0...42.0.4)

---
updated-dependencies:
- dependency-name: cryptography
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-01 02:55:22 +00:00
dependabot[bot]
f65ebf2194
Bump black from 23.12.1 to 24.3.0 (#3649)
Bumps [black](https://github.com/psf/black) from 23.12.1 to 24.3.0.
- [Release notes](https://github.com/psf/black/releases)
- [Changelog](https://github.com/psf/black/blob/main/CHANGES.md)
- [Commits](https://github.com/psf/black/compare/23.12.1...24.3.0)

---
updated-dependencies:
- dependency-name: black
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-01 04:26:37 +02:00
adeshpande
9f3d486095
Fix Vector3 -> Vector3D in contributing docs (#3639) 2024-03-17 15:13:08 -04:00
Abulafia
77d42d2a46
Update jupyter.rst (#3630)
Pinpoint IPython==8.21.0 for Google Colab, because more recent versions are incompatible with their runtime.
2024-02-24 00:08:47 +01:00
Jason Grace
c7e7ca2e46
Run poetry lock --no-update (#3621) 2024-02-15 17:17:29 -05:00
Victorien
206f8740b9
Remove support for dynamic plugin imports (#3524)
* Remove call to deprecated `pkg_resources`

* Remove support for dynamic plugin imports, update plugin utilities

* fix affected tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* more fixes

* Last fix

* Fix import

* Update docs

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>
2024-02-15 08:17:13 -08:00
Said Taghadouini
fcd81b21a4
Improve handling of specified font name (#3429)
Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>

The proposed fix does two things :

* If the specified font is 'sans-serif' : change it to 'sans' as this is the name used in the list of fonts
* if the font name is not in the list of fonts, automatically check if the capitalized version of the font exists in the list of fonts. If not, print a warning to the user.
2024-02-13 15:26:54 -05:00
Francisco Manríquez Novoa
011c36a634
Revert vector type aliases to NumPy ndarrays (#3595) 2024-02-13 00:27:39 +01:00
yuan
ed1b203993
fix type hint of indication.py (#3613) 2024-02-03 19:14:16 -05:00
Benjamin Hackl
1520481812
Update ci.yml (#3611) 2024-02-01 19:22:24 -05:00
Jason Grace
65d352d0ab
Fix typehint (#3592) 2024-02-02 00:31:53 +01:00
Jason Grace
f70980aa40
Add ref_class (#3598) 2024-02-01 23:27:49 +01:00
Sparsh Goenka
e2cec98f9a
fix get_arc_center() returning reference of point (#3599) 2024-02-01 23:27:17 +01:00
yuan
d0fe0c3894
fix typo in value_tracker.py (#3594) 2024-01-25 08:27:18 +01:00
NotWearingPants
f8b5066899
Update docker.rst to use bash from the PATH (#3582) 2024-01-25 00:41:38 +01:00
yuan
175cb89400
fix write_subcaption_file error when using opengl renderer (#3546)
* fix write_subcaption_file error when using opengl renderer

* Update manim/scene/scene_file_writer.py

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2024-01-25 00:40:30 +01:00
Greg Rupp
7006d6b79e
Removed -s / --save_last_frame flag from CLI arguments (#3528)
* Remove -s flag

* Make help text more verbose
2024-01-24 21:12:24 +01:00
Benjamin Hackl
8264595e3b
updated several packages (pillow, jupyterlab, notebook, jupyterlab-lsp, jinja2, gitpython) (#3593) 2024-01-24 21:07:17 +01:00
dependabot[bot]
9289a5c68d
Bump actions/setup-python from 4 to 5 (#3565)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 4 to 5.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-01-24 20:22:51 +01:00
dependabot[bot]
9d880c2f80
Bump actions/upload-artifact from 3 to 4 (#3566)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 3 to 4.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-01-24 20:21:47 +01:00
dependabot[bot]
775482bc20
Bump github/codeql-action from 2 to 3 (#3567)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 2 to 3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v2...v3)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-01-24 20:21:21 +01:00
Viicos
68bd79093e
Refactor TexTemplate (#3520)
* Refactor `TexTemplate`

* Add tests, refactor some things

* Fixed Some tests

* Move typing imports

* Fix remaining tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-01-15 18:39:03 +00:00
Francisco Manríquez Novoa
a57fb69f68
Add 'to be used in the future' TODOs to ManimFrame (#3553) 2024-01-15 18:07:50 +00:00
Dan Davison
9a84ec6a45
Fix typing of Animation (#3568) 2024-01-13 18:39:40 +01:00
Hydromel Victor Doledji
4e3cfd207a
exception add if new_rings is none (#3574)
* exception add if new_rings is none

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-01-11 08:23:49 -05:00
Václav Volhejn
3b496ea2e6
Add helpful hints to VGroup.add() error message (#3561)
* Improve VGroup creation error message

* Use .__name__ for the type

Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>

---------

Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>
2024-01-03 00:30:53 +01:00
Francisco Manríquez Novoa
286f366a35
Improve documentation section about contributing to docs (#3555)
* Improve section in docs about contributing to docs

* Add note about doc build command depending on the OS

* Improve section in docs about contributing to docs

* Add note about doc build command depending on the OS

* Fix wrong toctree path in docs/source/contributing/docs.rst
2023-12-30 00:22:24 +01:00
Francisco Manríquez Novoa
02391d71ac
Added support for Manim type aliases in Sphinx docs + Added new TypeAliases (#3484)
* Updated manim.typing and included TypeAliases in docs.source.conf

* Added Vector2 and reorganized manim_type_aliases

* Fixed __all__ exports for __all__ of manim

* Update manim/cli/render/global_options.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Draft of new typing docs and new autotyping directive

* Changed vertical bars to Unions

* Updated poetry.lock

* Created custom file parser for manim.typing

* Got reST parser going

* Updated autotyping and parsing

* Update parsing

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added code_block toggle

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added typings to directives

* Renamed Tuple to tuple in manim.typings

* Added missing docs for type aliases

* Fixed exponent typo in ManimInt

* Hyperlinks to types work - removed Module Attributes section

* Removed Unused Import

Remove ``import re``

* Added freeglut-devel to workflows for Linux

Hopefully (?) fix the GLU import error

* Fix package name

* Add support for Type Aliases section in every module - Renaming of Vector types

* Add/fix docs for directive, parser and others

* Fixed alias typo in module_parsing

* Fix decode/import bugs, fix minor details in docs

* Added missing docs for utils.docbuild and utils.testing

* Sort alphabetically entries in utilities_misc.rst

* Address review comments, add notes about Vector and hyperlinks inside definition blocks

---------

Co-authored-by: MrDiver <mrdiverlp@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
2023-12-29 19:04:31 +01:00
Jason Grace
4a963c45ab
add note in docstring of ManimColor about class constructors (#3554) 2023-12-28 18:57:21 +01:00
Jason Grace
472eaae6fe
Fix use of Mobject's deprecated get_*() and set_*() methods in Cairo tests (#3549)
* Fix Deprecation warnings in cairo tests

* Fix animation/specialized.py
2023-12-26 22:36:26 +01:00
Jason Grace
9b18a861f3
Finish TODO's in `contributing/typings.rst` (#3545)
* Updated typing docs

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added link for protocols

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added object vs Any

* Fix Typo

* Rephrase TypeVar

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* Compare between tuple vs list

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* typing -> collections.abc

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* typing -> collections.abc

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* change method to attr

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* clarify object typehint

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* Fix code typo

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* Added if TYPE_CHECKING section

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix reST for inline code

* Elaborate on if TYPE_CHECKING

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

* functions -> collections

Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>
2023-12-24 12:33:45 -05:00
yuan
34e7d68644
Fix typo of get_y_axis_label docstring (#3547) 2023-12-23 15:58:07 +01:00
Jason Grace
3037f0e713
Remove wag method from Mobject (#3539)
Co-authored-by: Francisco Manríquez Novoa <49853152+chopan050@users.noreply.github.com>
2023-12-22 16:01:59 -05:00
Jason Grace
dd327a37ca
Fixed Animate Type-hint (#3543) 2023-12-21 01:37:24 +00:00
Jason Grace
8ea8f25576
Fix formatting of `MoveAlongPath` docs (#3541)
* Remove wag method from Mobject

* Fixed MoveAlongPath

* Revert remove wag

Created a new branch with the wrong base, sorry ;)
2023-12-21 00:33:56 +00:00
Jérome Eertmans
196fa1fa2f
chore(docs): add some words about Cairo 1.18 (#3530)
* chore(docs): add some words about Cairo 1.18

Closes #3521

* fix(docs): typo

* Update testing.rst

* Update testing.rst
2023-12-17 17:37:01 +01:00
Benjamin Hackl
cac608bf2a follow-up to #3491, made errors more consistent. fixes #3527 2023-12-17 17:32:38 +01:00
Tristan Schulz
b69e1d72cf
Adding the ability to pass lists and generators to .play() (#3365)
* adding the ability to pass lists and generators to .play()

* fix for _AnimationBuilder

* Changed handling of generators to accept lists of generators and normal arguments at the same time

* Animation group handles generators

* Refactored into own function for reusability

* Fix typing

* Fix typing

---------

Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>
2023-12-13 11:24:05 +00:00
TheMathematicFanatic
fc4271061c
Add Documentation to .to_edge and to_corner (#3408)
* Added docstrings and example renders to Mobject.to_corner() and Mobject.to_edge

* Added docstrings and example renders to Mobject.to_corner() and Mobject.to_edge

* Update manim/mobject/mobject.py

* Update manim/mobject/mobject.py

* Update manim/mobject/mobject.py

* Update manim/mobject/mobject.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update manim/mobject/mobject.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-12-13 12:06:22 +01:00
Yash Mundada
98a7f42ed2
fixed the stroke width issue with single color in streamlines (#3436)
* fixed the stroke width issue with single color in streamlines

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added test for streamlines

* Added test for streamlines

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: MrDiver <mrdiverlp@gmail.com>
2023-12-12 19:44:49 +00:00
Tristan Schulz
17043747ef
Fix animations with zero runtime length to give a useful error instead of a broken pipe (#3491)
* Fix animation group not erroring when instantiated with an empty list

* Move error messages into Animation.begin()

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update manim/animation/animation.py

* Update manim/animation/composition.py

* Update manim/animation/animation.py

Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>
2023-12-12 20:19:16 +01:00
Paul Uhlenbruck
d39097825a
Fix rectangle grid properties (#3082) (#3513)
* Import  for both vertical and horizontal gridlines in

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-12-12 19:44:07 +01:00
Robin Dimasin
9938bf59a3
Added grid_lines attribute to Rectangle to add individual styling to the grid lines (#3428)
* Added 'grid_line_stroke_width' parameter in Rectangle

* Added 'grid_lines' (VGroup) attribute to 'Rectangle' class

---------

Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
2023-12-12 18:09:51 +00:00
Jérome Eertmans
0a24cad22a
Account for dtype in the pixel array so the maximum value stays correct in the invert function (#3493)
* fix(lib): fix

This fixes an issue where the `invert` argument would only work for `uint8` dtypes. Now the `max` value is updated according to the pixel array dtype.

Maybe we should add unit tests for that, but haven't found an obvious place to put unit tests.

* chore(ci): add basic test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix(ci): wrong attr name

* Update tests/module/mobject/test_image.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-12-12 13:31:28 +01:00
dependabot[bot]
912ae76f8f
Bump jupyter-server from 2.9.1 to 2.11.2 (#3497)
Bumps [jupyter-server](https://github.com/jupyter-server/jupyter_server) from 2.9.1 to 2.11.2.
- [Release notes](https://github.com/jupyter-server/jupyter_server/releases)
- [Changelog](https://github.com/jupyter-server/jupyter_server/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jupyter-server/jupyter_server/compare/v2.9.1...v2.11.2)

---
updated-dependencies:
- dependency-name: jupyter-server
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-12-12 12:53:52 +01:00
Tristan Schulz
18a7294164
Fix formatting building blocks (#3515)
* Fix formatting building blocks

* Fix formatting building blocks

---------

Co-authored-by: Jason Grace <110117391+JasonGrace2282@users.noreply.github.com>
2023-12-12 10:45:39 +01:00
Jason Grace
9a35756048
Explain `.Transform vs .ReplacementTransform` in quickstart examples (#3500)
* Explained ReplacementTransform vs Transform

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added section explaining Transform vs ReplacementTransform

* Added a->b->c example

* Clarified explanation

* Fixed Typo

* Fixed missing colon

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
2023-12-10 23:56:55 +00:00
Doaa Muhammad
64a0e9db43
Reformatting the --save_sections output to have the format <Scene>_<SecNum>_<SecName><extension> (#3499)
* Worked on issue 3471, fixing rendered file names to inherit section name

* Modified file name to include section number and name

* Modified tests for file names to include number and name, in order to pass

---------

Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
2023-12-10 23:17:38 +00:00
Jérome Eertmans
018e4a3c1a
feat(cli): optionally hide version splash (#3329)
* feat(cli): optionally hide version splash

As discussed in #3326, this PR proposes a new optional flag to hide the version splash when manim command in launched. Additionally, the splash print is now inly executed when the CLI is executed, not on module import.

After looking at the current documentation, it does not seem to change anything. I only saw that you documented a version splash for when the CLI is used, but not when the module is imported. So removing it should not break the api docs.

In the future, users can still have version information with `import manim; print(manim.__version__)`.

Closes #3326

* chore(tests): make tests pass

---------

Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
2023-12-10 22:47:11 +00:00
Benjamín Ubilla
03f9d4b90b
Added cap_style feature to VMobject (#3516)
* Added cap_style feature to VMobject

* Added an example to `set_cap_style` method

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Unsplitted line 2501

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added graphical test for cap_style

* Added vmobject_cap_styles.npz for testing cap_styles

* Removed # noqa comments from vectorized_mobject.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-12-10 23:10:34 +01:00
Francisco Manríquez Novoa
3f118e4921
Removed deprecated new command (#3512)
Co-authored-by: Naveen M K <naveen521kk@gmail.com>
2023-12-10 19:05:32 +00:00
Tristan Schulz
370d883374
Implement caching of fonts list to improve runtime performance (#3316)
* Implement caching of fonts list to improve runtime performance

* Fix small use_svg_cache kwargs error

* replaced font list with LRU cache
2023-12-11 00:21:41 +05:30
yuan
0cba710a38
fix typo in docstring for DtUpdater example: line -> square (#3509) 2023-12-09 20:26:18 +00:00
szchixy
27d53606d4
fix line_join to joint_type in example_scenes/basic.py (#3510) 2023-12-09 20:57:32 +01:00
Melody Griesen
40766cb648
Update Docker base image to python3.12-slim (#3458) (#3459)
* Update Docker base image to python3.12-slim (#3458)

* Update docker/Dockerfile

---------

Co-authored-by: Melody Griesen <jvgriese@ncsu.edu>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-12-07 00:30:17 +01:00
szchixy
7590086753
fix 360° to 180° in quickstart tutorial (#3498) 2023-12-06 18:06:35 +01:00
Viicos
61a2d05b69
Update dependency constraints, fix deprecation warnings (#3376)
* WIP: Update metadata

* Finish removing upper bounds

Drop requests dependency, use urllib instead
order depencencies

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix issues on 3.12

* Order dev dependencies

* Update most dev deps, update lint config

* Add missing import

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* trigger CI

* More deprecation fixes

* Missing argument

* Deprecation fixes, again

* Use older xdist to fix test flakyness

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-12-06 14:44:13 +01:00
Francisco Manríquez Novoa
6949c66922
Optimized get_unit_normal() and replaced np.cross() with custom cross() in manim.utils.space_ops (#3494)
* Added cross and optimized get_unit_normal in manim.utils.space_ops

* Added missing border case to new get_unit_normal where one vector is nonzero

* Updated test_threed.py::test_Sphere test data
2023-12-06 14:40:10 +01:00
JosephD
7cead84d21
Update indication.py (#3477)
reading docs, im sure oppising isnt a word
2023-11-30 13:10:39 +01:00
Lawrence Qupty
28bf4dd2a6
Fix Idicate docs typo (#3461) 2023-11-20 19:32:11 +01:00
Viicos
212bca09ca
Add type hints to _config (#3440)
* Add type hints to `_config`

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix call issues

* Fix wrong value being used

* Fix test

* Fix wrong value being set

* lint

* Few type fixes

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-11-20 19:31:18 +01:00
Jason Grace
94711f742d
Allow accessing ghost vectors in :class:.LinearTransformationScene (#3435)
* Fix CSV reader adding empty files

Fixes issue #3311

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added LinearTransformationScene.ghost_vectors

* Added test and prevented empty VGroups as ghost vectors

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fixed typo in example

* Added ability to join together multiple renders

* Revert "Added ability to join together multiple renders" (wrong branch)

This reverts commit dee29c390f.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-11-19 09:20:59 +01:00
Benjamin Hackl
4315549c31
Fixed wrong path in action building downloadable docs (#3450)
* fixed wrong path in action building downloadable docs

* fix second occurrence of wrong path
2023-11-12 10:42:37 +01:00
Benjamin Hackl
e66c5807fb
Prepare v0.18.0 (#3439)
* generated changelog and bumped version

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* changed some PR descriptions in the changelog

* fix some docbuild warnings

* fixed a reference that became ambiguous

* copyedit pass of changelog

* some more changelog polishing

* bump release date

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* updated release date

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-11-11 18:21:45 +01:00
Naveen M K
adfef5e7a5
Add option to run examples directly with binder (#3427)
* Add option to run examples directly with binder

The minified JS is from
https://github.com/naveen521kk/manim-binder

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* slight style changes

* update the js file to fix on chrome

Signed-off-by: Naveen M K <naveen521kk@gmail.com>

* show the run button as an cursor

* make the video to be 100% of the width

* Update manim/utils/docbuild/manim_directive.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Add a "Make interactive" button instead of "Run" button

Clicking on the "Make interactive" button show the code-editor and "run" button

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* update margin for run interactive button

---------

Signed-off-by: Naveen M K <naveen521kk@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-11-10 21:52:43 +01:00
Uwe Zimmermann
20028cef46
feat: DecimalNumber() - added spacing between values and unit (#3366)
* feat: DecimalNumber() - added spacing between values and unit

* Update manim/mobject/text/numbers.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update manim/mobject/text/numbers.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update manim/mobject/text/numbers.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update manim/mobject/text/numbers.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update manim/mobject/text/numbers.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update manim/mobject/text/numbers.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update manim/mobject/text/numbers.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

---------

Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-11-04 15:07:24 +01:00
Jason Grace
3962a12cd8
Added ability to remove non-svg LaTeX files (#3322)
* Added ability to remove latex junk (default True)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fixed tests (hopefully), and whitelisted .tex

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* reverted weird changes from merge

* See previous commit message

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fixed logs-too-long test

* Fixed log output

* Fixed typo ;)

* deleted unused variable

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* moved latex deletion to tex_file_writing.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* removed changes in scene files

* Added caching based on LaTeX expression .svg

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Deleted unused function in delete_old_tex

* make if condition more readable

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* cleaned up svg file check

* changed blacklist -> whitelist for file endings

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Reverted docstring change

* Updated delete_non_svg files docstring

* Changed list to a set

* Update manim/_config/utils.py

* Update manim/cli/render/global_options.py

* added one test for the no_latex_cleanup config option

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
2023-11-04 15:05:17 +01:00
Jérome Eertmans
8fe1665915
chore(deps): add Python 3.12 support (#3395)
* chore(deps): add Python 3.11 and 3.12 support


chore(deps): update lock file


chore(deps): remove colour


fix(deps): force NumPy version


fix(deps): relax constraints


chore(deps): update lock file

* fix(deps): make poetry happy

* fix(ci): skia pathops on 3.12

* fix(test): doctest skip

* disable python 3.8 pipeline

* removed get_parameters, replaced by direct call to inspect

* black

---------

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-11-04 14:36:51 +01:00
Václav Blažej
652f1b3d6a
fix: issue with ImageMobject bounding box (#3340)
* fix: fix an issue with ImageMobject bounding box

A missing point resulted in smaller bounding box causing issues it to be
smaller when the object is rotated. Added the missing fourth point to
ImageMobject points and altered call from camera. Filled in docstring
that used to propagate from superclass, saying that ImageMobject has no
points.

* add a test to check that rotating an image to and from doesn't change it

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Václav Blažej <vaclav.blazej@warwick.ac.uk>
Co-authored-by: Naveen M K <naveen521kk@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-11-04 14:36:22 +01:00
Tristan Schulz
d77a47a233
Fix Typing (#3086)
* first draft of color class + starting library conversion

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* changed everything to Manim color todo: figure out circular dependency in utils

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* first working draft of new color version

* resolving conflicts

* resolving conflicts

* resolving conflicts

* resolving conflicts

* resolving conflicts

* changed default internal value of ManimColor to np.ndarray[float]

* starting to fix tests

* fixed more tests and changed precision of manim color

* removed premature color conversion

* fixed some more tests

* final test changes

* fix doctests

* fix for 3.8

* fixing ManimColor string representation

* removing some unneccesary conversions

* moved community constants to manim_colors.py and added more color standards

* Added typing.py and typed bezier.py, core.py, constants.py  fully

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed codeql complaints

* add type ignore for np.allclose

* fixed import in three_dimensions

* added ignore for F401 back again in flake

* added typings to coordinate_systems.py

* Few improvements to `graphing/coordinate_systems.py`

* added some typings to mobject/geometry/line.py

* updated typings for mobject/geometry/line.py

* Add missing imports to `line.py`

* added typings to three_dimensions.py

* Use `FunctionOverride` for animation overrides

Fix type signature of `set_color_by_gradient`

* Remove `TYPE_CHECKING` check

Doc is failing

* Revert "Remove `TYPE_CHECKING` check"

Fails due to circular import

* Use `Self` in `coordinate_systems.py`

* Typehinted mobject.py and updated manim.typing.py

* Typed VMobject

* Type-hinted manim.mobject.geometry

* math.cos->np.cos, etc & fixed incorrect typehints

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix missing annotations import

* TypeAlias fix in typing.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add ignore errors again to mypy because commits are not possible like this

* Fix last typing issues

* Update docs

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Only type check manim

* Try fixing pre-commit

* fix merge

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix compat

* Fix compat again

* Fix imports compat

* Use union syntax

* Use union syntax

* Fix reduce_across_dimension

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Various test and merge fixes

* Doc fixes

* Last doc fix

* Revert usage of np over math

* Bump numpy version

* Remove obsolete duplicate example

* Fixed Incorrect Typehint in manim.constants

* Fix docstring typo

* More fixes

Use mypy.ini instead of .mypy.ini
Fix more docstrings
Improve types in utils and constants

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* docs fixes

* Add internal aliases

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix compat

* line lengths in .rst file, formatting, typos

* add docstring for space_ops:cross2d

* add some more arrow tip typings (in a non-circular import causing way)

* yes, this can be deleted

* fix formatting of example

* added docstring to bezier::inverse_interpolation

* added docstring + test for bezier::match_interpolate

* some improvements in coordinate_systems

* Vector -> Vector3

* replaced np.ndarray with more appropriate type hints

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Apply feedback

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* revert to previous (new) version

* fix doctest

* fix ReST errors

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Alex Lembcke <alex.lembcke@gmail.com>
Co-authored-by: Viicos <65306057+Viicos@users.noreply.github.com>
Co-authored-by: JasonGrace2282 <aarush.deshpande@gmail.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-11-04 00:49:11 +01:00
Harald Schilly
25bb381528
bump dependencies -- see #3241 (#3433) 2023-11-03 19:39:18 +01:00
dependabot[bot]
1b880996a9
Bump teatimeguest/setup-texlive-action from 2 to 3 (#3431)
Bumps [teatimeguest/setup-texlive-action](https://github.com/teatimeguest/setup-texlive-action) from 2 to 3.
- [Release notes](https://github.com/teatimeguest/setup-texlive-action/releases)
- [Commits](https://github.com/teatimeguest/setup-texlive-action/compare/v2...v3)

---
updated-dependencies:
- dependency-name: teatimeguest/setup-texlive-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-02 19:10:26 +01:00
Nikhil Iyer
190ae5db53
Fix None check order in _tree_layout (#3421)
* Fix None check order in _tree_layout

* add tests to test_graph.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-11-02 19:00:10 +01:00
Jason Grace
5d73525836
Fix CSV reader adding empty lists in rendering summary (#3430)
* Fix CSV reader adding empty files

Fixes issue #3311

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-11-02 16:23:30 +01:00
Naveen M K
b7a8a2d4d8
CI: fix caching of cairo (#3419)
I forgot to change the path after moving around the file.
2023-10-27 09:29:12 +02:00
Benjamin Hackl
b7eefca98f
Fix incorrect submobject count of multi-part Tex/MathTex mobjects by stopping them from adding empty submobjects (#3423)
* do not add a VectorizedPoint as a submobject if SingleStringMathTex renders to empty SVG

* test new behavior

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update tests/module/mobject/text/test_texmobject.py

* Update tests/module/mobject/text/test_texmobject.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-10-27 09:28:23 +02:00
Benjamin Hackl
5193e1cfd1
Introduce new workflow creating a downloadable version of the documentation (#3417)
* Revert "rtd: enable htmlzip build (#3355)"

This reverts commit 571f79be2c.

* use python3.11 to build docs

* upgrade python version used in release publish workflow

* new workflow for building downloadable docs

* change event trigger for testing

* sudo apt

* rename release job; build html in poetry env

* set GITHUB_PATH instead of PATH

* introduce additional step

* use correct binary path

* forgot microtype

* fonts-roboto + actually compress files correctly

* fix asset path

* Update .github/workflows/release-publish-documentation.yml

Co-authored-by: Naveen M K <naveen521kk@gmail.com>

* pull_request -> workflow_dispatch

* Update .github/workflows/release-publish-documentation.yml

---------

Co-authored-by: Naveen M K <naveen521kk@gmail.com>
2023-10-26 12:29:21 +00:00
Immanuel-Alvaro-Bhirawa
76b4061aa6
Fix: Fixed a bug in regards to empty inputs in AddTextLetterByLetter class. (#3404)
* Misc: Just a class to test out some functions

* Fix: Fixed a bug in AddTextLetterByLetter class

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix: Adjusted changes according to Ben's comments

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix: Removed imports

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Feat: Adjusted changes to AddTextLetterByLetter

* Feat: Added test_creation

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-10-26 12:38:57 +02:00
Naveen M K
b04869579b
Fix tests to run on Cairo 1.18.0 (#3416)
* Add a script to build and install cairo

* Update gui tests for cairo 1.18.0

* update script to set env vars

* Make the script run with plain python

* Prefer the recently built one in pkg-config

* Skip the built if it's windows

* CI: build and install latest cairo

* CI: only run when cache is missed

* Disable compiling tests while building cairo

* update poetry lock file

* Display the cairo version when running pytest

* fixup

* tests: skip graphical test when cairo is old

* fix the path to find the pkgconfig files on linux

* set the LD_LIBRARY_PATH too

only then it'll work on linux

* fixup

* small fixup

* Move the script inside `.github/scripts` folder

* Make the minimum cairo version a constant

* Seperate setting env vars to a sperate step

this seem to have broken when cache is hit
2023-10-25 21:54:45 +02:00
Jason Grace
8320cdde80
Added docs for functions in mobject_update_utils (#3325)
* Added docs for functions in mobject_update_utils

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated docstring of always_shift

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Added period to sentence.

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Updated parameter description in always_redraw

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Update always_rotate description

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Finished parameters in always_redraw

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Changed comment in always_shift

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* update always_shift description

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* used normalize from manim.utils.space_ops

* fixed indentation in always_redraw

* added type-hints

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-10-23 10:49:30 +02:00
Naveen M K
7ad7e99c96
pyproject.toml: update manimpango version (#3405)
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-10-22 20:29:20 +02:00
Benjamin Hackl
94df2c44d8
Updated several dependencies (#3399)
* updated lockfile

* ran poetry update again
2023-10-22 20:05:38 +02:00
Narahari Rao
7fab9cdbf9
Bug fix: Use np.isclose for float equality in number line elongated ticks (#3392)
* use np.isclose for float equality in number line elongated ticks

* use offsets relative to x_min to tell if we need to elongate a tick

* forgot to subtract to create list of offsets

* add test for elongated ticks float equality

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Remove unused import

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-10-12 08:28:43 +02:00
Anousheh Moonen
684014a861
fix(docs): Remove extra curly bracket in LaTeX math expression to fix issue #3330 (#3389) 2023-10-10 12:29:03 +02:00
Naveen M K
571f79be2c
rtd: enable htmlzip build (#3355)
also, bump python to 3.11
fixes https://github.com/ManimCommunity/manim/issues/3342
2023-10-09 20:41:37 +02:00
Benjamin Hackl
73e30cea89
Several GitHub actions updates (#3397)
* Bump docker/login-action from 2 to 3

Bumps [docker/login-action](https://github.com/docker/login-action) from 2 to 3.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](https://github.com/docker/login-action/compare/v2...v3)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump docker/setup-buildx-action from 2 to 3

Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2 to 3.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](https://github.com/docker/setup-buildx-action/compare/v2...v3)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump docker/build-push-action from 4 to 5

Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4 to 5.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](https://github.com/docker/build-push-action/compare/v4...v5)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump docker/setup-qemu-action from 2 to 3

Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 2 to 3.
- [Release notes](https://github.com/docker/setup-qemu-action/releases)
- [Commits](https://github.com/docker/setup-qemu-action/compare/v2...v3)

---
updated-dependencies:
- dependency-name: docker/setup-qemu-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump actions/checkout from 3 to 4

Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-09 20:38:20 +02:00
Holly and Prosper
c6450b21c7
fix a typo in deep_dive.rst (#3377) 2023-09-23 23:49:27 +02:00
Uwe Zimmermann
bff2ea4442
feat: adding three new rate_functions based on the SmoothStep function. These have the added benefits of zero derivatives at the endpoints. (#3361) 2023-09-09 14:27:33 +02:00
Benjamin Hackl
50d663eb8b
Added docstring to Mobject.center (#3353) 2023-09-02 21:53:58 +05:30
Uwe Zimmermann
3b4fca2c75
fix: return value of TexTemplate.add_to... (#3343)
Unlike similar methods on other objects .add_to_preamble and
.add_to_document do not return the TexTemplate object itself.
This does not allow for stacking these methods.

Just added the `return self` for both methods

Co-authored-by: Uwe Zimmermann <C:\Users\uwezi\AppData\Roaming\The Bat! Pwd>
2023-09-01 16:55:11 +02:00
Benjamin Hackl
eac99e89a8
added missing dependency typing-extensions (#3350) 2023-09-01 15:06:16 +02:00
pre-commit-ci[bot]
88836df8ab
[pre-commit.ci] pre-commit autoupdate (#3308)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/asottile/pyupgrade: v3.9.0 → v3.10.1](https://github.com/asottile/pyupgrade/compare/v3.9.0...v3.10.1)
- [github.com/PyCQA/flake8: 6.0.0 → 6.1.0](https://github.com/PyCQA/flake8/compare/6.0.0...6.1.0)

* fixed flake8 E721

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-08-09 19:44:17 +02:00
Tristan Schulz
82e55b5da2
Adding :class: ManimColor to manim and converting all types (#3020)
* first draft of color class + starting library conversion

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* changed everything to Manim color todo: figure out circular dependency in utils

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* first working draft of new color version

* resolving conflicts

* resolving conflicts

* resolving conflicts

* resolving conflicts

* resolving conflicts

* changed default internal value of ManimColor to np.ndarray[float]

* starting to fix tests

* fixed more tests and changed precision of manim color

* removed premature color conversion

* fixed some more tests

* final test changes

* fix doctests

* fix for 3.8

* fixing ManimColor string representation

* removing some unneccesary conversions

* moved community constants to manim_colors.py and added more color standards

* broke some too long lines

* added fallback: check whether passed object has get_hex method

* actually fix _internal_from_string

* added hsv support

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* remove dependency on colour

* fixed DARK_EARTH being assigned twice

* fixed double assignment

* remove more duplicated colour names

* raise NotImplementedError for ManimColor.gradient

* removed unused import

* remove superfluous ManimColor import

* fix circular import, remove dependency of space_ops on config

* one more Color -> ParseableManimColor

* removed one *-import

* somewhat unrelated fixed type hint

* -1 *-import

* fixed change of logic in CoordinateSystem.get_graph_label

* removed debug print; fixed type hint in mobject.py

* some fixes and improvements to text_mobject.py

* update three_dimensions

* fixes for rendered documentation of utils.color.*

* substantial improvements to documentation, including new Sphinx directive

Co-authored-by: MrDiver <mrdiverlp@gmail.com>

* Rewrite of the sphinx directive to use docutils nodes and 2 column design

* I just had to do it

* Improve the color table

* minor cleanup

* fixed ColorOverview example

* documentation improvements

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update manim/mobject/mobject.py

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix flake8 errors

* Removed test in test_text_mobject

* Improved Documentation of core.py and added private members in sphinx so that internal methods can be documented

* Change color types of labeled.py

* removed some unused imports

* turned docstring into comment

* _colors  -> _all_manim_colors; move to manim_color module

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed typing

* rewrite import

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
Co-authored-by: Naveen M K <naveen521kk@gmail.com>
2023-08-08 14:47:00 +02:00
Jason Grace
59ff3271a5
Added Docstring/Example for :meth:always_redraw (#3312)
* Added docstring & example for always_redraw

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* made more descriptive names for vars in example

* Change runtime 10s->3s

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* change Create -> add

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Added typehint for always_redraw

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Changed description of :meth:`always_redraw`

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

* Added return type to :meth:`always_redraw`

Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>
Co-authored-by: Benjamin Hackl <devel@benjamin-hackl.at>
2023-08-07 00:11:39 +02:00
Tristan Schulz
9561896d9e
Fix random complaint about list (#3315) 2023-08-06 11:36:18 +02:00
Benjamin Hackl
efd6474b76
Added new `manim checkhealth` CLI subcommand (#3299)
* added new checkhealth subcommand

* basic checkhealth tests

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* check -> healthcheck

* more helpful test output on checkhealth fail

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* callable -> Callable

* fix executable check for windows

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fixed type

* shutil already returns .exe in case it is there

* debug commit ...

* do proper debug commit for windows ...

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* fix failing test if executable is batch file

* added more helpful (?) recommendations on failed tests

* allow rendering ManimBanner from prerendered SVG path

* improved test scene, actually test text / latex

* added debug info on python executable

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* remove debug test again

* move SCALE_FACTOR_PER_FONT_POINT to constants

* access constants via module in logo.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* replaced other occurrence of 48 / 960

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-08-05 11:03:09 +02:00
Jason Villanueva
2c74f62fea
Fixed IPython terminal history and embedded shell instatiation for interactive_embed scenes (#3306)
* Fixed IPython sqlite errors/history for interactive_embed scenes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add config to instance method

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tristan Schulz <mrdiverlp@gmail.com>
2023-08-05 01:42:55 +02:00
Andres Berejnoi
8ba210ff61
Two New Classes in geometry module: :class:.LabeledLine and :class:.LabeledArrow (#3264)
* feat: added two new classes LabeledLine and LabeledArrow

* test: added tests for new LabeledLine and LabeledArrow for the geometry module testing suite

* feat: added new class names to '__all__' module attribute

* fix: added missing import line for new classes

* fix: removed import lines causing cyclic import error

* new file containing two new classes

* modified files to correctly load new classes when manim is imported

* commented out new classes in line.py

* created control frames for LabeledLine and LabeledArrow

* removed commented out classes

* removed unused import of 'Colors'

* Update manim/mobject/geometry/labeled_shapes.py

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* Update manim/mobject/geometry/labeled_shapes.py

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* Update manim/mobject/geometry/labeled_shapes.py

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* Update manim/mobject/geometry/labeled_shapes.py

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update __init__.py

will change name of labeled_shapes.py to labeled.py

* Rename labeled_shapes.py to labeled.py

* Update __init__.py

Changed name of file from labeled_shapes.py to labeled.py and updated __init__.py to import from the correct location.

* Update manim/mobject/geometry/labeled.py

Removed color import line because of redundancy.

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* Update labeled.py

default label_color parameter is now set to `None` instead of `WHITE`.

* Update manim/mobject/geometry/labeled.py

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* Update tests/test_graphical_units/test_geometry.py

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>

* Revert changes related to WHITE and it's import

SurroundingRectangle uses label_color as well and using a default of None removes the rectangle.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Jason Villanueva <a@jsonvillanueva.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-07-31 14:16:28 -07:00
816 changed files with 52625 additions and 21890 deletions

View file

@ -1 +0,0 @@
<path id="nd" d="m 464.7,68.6 -1.1,2.8 .8,1.4 -.3,5.1 -.5,1.1 2.7,9.1 1.3,2.5 .7,14 1,2.7 -.4,5.8 2.9,7.4 .3,5.8 -.1,2.1 -29.5,-.4 -46,-2.1 -39.2,-2.9 5.2,-66.7 44.5,3.4 55.3,1.6 z">

5
.codespell_ignorewords Normal file
View file

@ -0,0 +1,5 @@
nam
sherif
falsy
medias
strager

View file

@ -1,4 +1,4 @@
[codespell]
exclude-file=.codespell_ignorelines
check-hidden=True
ignore-words-list = sherif
check-hidden = True
skip = .git,*.js,*.js.map,*.css,*.css.map,*.html,*.po,*.pot,uv.lock,*.log,*.svg
ignore-words = .codespell_ignorewords

View file

@ -1 +1,20 @@
.git
# Development / test artifacts
__pycache__
**/__pycache__
*.pyc
*.pyo
*.pyd
*.egg-info
dist/
build/
coverage.xml
# Not needed to install the package
docs/
tests/
example_scenes/
media/
logo/
scripts/

17
.flake8
View file

@ -1,7 +1,8 @@
[flake8]
# Exclude the grpc generated code
exclude = ./manim/grpc/gen/*
max-complexity = 15
exclude = ./manim/grpc/gen/*, __pycache__,.git,
per-file-ignores = __init__.py:F401
max-complexity = 29
max-line-length = 88
statistics = True
# Prevents some flake8-rst-docstrings errors
@ -9,7 +10,7 @@ rst-roles = attr,class,func,meth,mod,obj,ref,doc,exc
rst-directives = manim, SEEALSO, seealso
docstring-convention=numpy
select = A,A00,B,B9,C4,C90,D,E,F,F,PT,RST,SIM,W
select = A,A00,B,B9,C4,C90,D,E,F,F,PT,RST,SIM,W,F401
# General Compatibility
extend-ignore = E203, W503, D202, D212, D213, D404
@ -17,18 +18,18 @@ extend-ignore = E203, W503, D202, D212, D213, D404
# Misc
F401, F403, F405, F841, E501, E731, E402, F811, F821,
# multiple statements on one line (overload)
E704,
# Plug-in: flake8-builtins
A001, A002, A003,
# Plug-in: flake8-bugbear
B006, B007, B008, B009, B010,
B006, B007, B008, B009, B010, B903, B950,
# Plug-in: flake8-simplify
SIM105, SIM106, SIM119,
# Plug-in: flake8-comprehensions
C901
# Plug-in: flake8-pytest-style
PT001, PT004, PT006, PT011, PT018, PT022, PT023,
@ -40,4 +41,4 @@ extend-ignore = E203, W503, D202, D212, D213, D404
# Plug-in: flake8-rst-docstrings
RST201, RST203, RST210, RST212, RST213, RST215,
RST301, RST303,
RST301, RST303, RST499

2
.git-blame-ignore-revs Normal file
View file

@ -0,0 +1,2 @@
# Switched to ruff format:
24025b60d57301b0a59754c38d77bccd8ed69feb

View file

@ -70,14 +70,5 @@ PASTE HERE
<!-- output of `tlmgr list --only-installed` for TeX Live or a screenshot of the Packages page for MikTeX -->
</details>
<details><summary>FFMPEG</summary>
Output of `ffmpeg -version`:
```
PASTE HERE
```
</details>
## Additional comments
<!-- Add further context that you think might be relevant for this issue here. -->

View file

@ -11,7 +11,7 @@ assignees: ''
- [ ] I have followed the latest version of the
[installation instructions](https://docs.manim.community/en/stable/installation.html).
- [ ] I have checked the [troubleshooting page](https://docs.manim.community/en/stable/installation/troubleshooting.html) and my problem is either not mentioned there,
- [ ] I have checked the [installation FAQ](https://docs.manim.community/en/stable/faq/installation.html) and my problem is either not mentioned there,
or the solution given there does not help.
## Description of error
@ -53,14 +53,5 @@ PASTE HERE
<!-- output of `tlmgr list --only-installed` for TeX Live or a screenshot of the Packages page for MikTeX -->
</details>
<details><summary>FFMPEG</summary>
Output of `ffmpeg -version`:
```
PASTE HERE
```
</details>
## Additional comments
<!-- Add further context that you think might be relevant for this issue here. -->

View file

@ -1,17 +0,0 @@
---
name: Suggestion
about: Make a suggestion for the enhancement of existing features
title: ""
labels: enhancement
assignees: ''
---
## Enhancement proposal
<!-- Add a clear and concise description of your enhancement proposal. In particular,
if your enhancement introduces changes to the API, illustrate them with
(fictional) code examples. -->
## Additional comments
<!-- Add further context that you think might be relevant. -->

View file

@ -1,10 +1,6 @@
<!-- Thank you for contributing to Manim! Learn more about the process in our contributing guidelines: https://docs.manim.community/en/latest/contributing.html -->
## Overview: What does this pull request change?
<!-- If there is more information than the PR title that should be added to our release changelog, add it in the following changelog section. This is optional, but recommended for larger pull requests. -->
<!--changelog-start-->
<!--changelog-end-->
## Motivation and Explanation: Why and how do your changes improve the library?
<!-- Optional for bugfixes, small enhancements, and documentation-related PRs. Otherwise, please give a short reasoning for your changes. -->

22
.github/codeql.yml vendored Normal file
View file

@ -0,0 +1,22 @@
query-filters:
- exclude:
id: py/init-calls-subclass
- exclude:
id: py/unexpected-raise-in-special-method
- exclude:
id: py/modification-of-locals
- exclude:
id: py/multiple-calls-to-init
- exclude:
id: py/missing-call-to-init
- exclude:
id: py/method-first-arg-is-not-self
- exclude:
id: py/cyclic-import
- exclude:
id: py/unsafe-cyclic-import
paths:
- manim
paths-ignore:
- tests/
- example_scenes/

11
.github/dependabot.yml vendored Normal file
View file

@ -0,0 +1,11 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "monthly"
ignore:
- dependency-name: "*"
update-types:
- "version-update:semver-minor"
- "version-update:semver-patch"

View file

@ -4,7 +4,10 @@
"standalone",
"preview",
"doublestroke",
"ms",
"count1to",
"multitoc",
"prelim2e",
"ragged2e",
"everysel",
"setspace",
"rsfs",
@ -29,7 +32,10 @@
"standalone",
"preview",
"doublestroke",
"ms",
"count1to",
"multitoc",
"prelim2e",
"ragged2e",
"everysel",
"setspace",
"rsfs",

67
.github/release.yml vendored Normal file
View file

@ -0,0 +1,67 @@
# https://docs.github.com/en/repositories/releasing-projects-on-github/automatically-generated-release-notes
changelog:
exclude:
labels:
- duplicate/wontfix
- invalid
- question
- release
authors:
- dependabot[bot]
- pre-commit-ci[bot]
categories:
# High Impact
- title: "Breaking Changes 🚨"
labels:
- breaking changes
# Highlights
- title: "Highlights 🌟"
labels:
- highlight
# User-facing
- title: "New Features ✨"
labels:
- new feature
- title: "Enhancements 🚀"
labels:
- enhancement
- title: "Bug Fixes 🐛"
labels:
- pr:bugfix
- title: "Deprecations & Removals ⚠️"
labels:
- pr:deprecation
# Developer-facing
- title: "Documentation 📚"
labels:
- documentation
- title: "Testing 🧪"
labels:
- testing
- title: "Infrastructure & Build 🔨"
labels:
- infrastructure
- title: "Code Quality & Refactoring 🧹"
labels:
- maintenance
- refactor
- title: "Type Hints 📝"
labels:
- typehints
# Catch-all (must be last)
- title: "Other Changes"
labels:
- "*"

237
.github/scripts/ci_build_cairo.py vendored Normal file
View file

@ -0,0 +1,237 @@
# Logic is as follows:
# 1. Download cairo source code: https://cairographics.org/releases/cairo-<version>.tar.xz
# 2. Verify the downloaded file using the sha256sums file: https://cairographics.org/releases/cairo-<version>.tar.xz.sha256sum
# 3. Extract the downloaded file.
# 4. Create a virtual environment and install meson and ninja.
# 5. Run meson build in the extracted directory. Also, set required prefix.
# 6. Run meson compile -C build.
# 7. Run meson install -C build.
import hashlib
import logging
import os
import subprocess
import sys
import tarfile
import tempfile
import urllib.request
from collections.abc import Generator
from contextlib import contextmanager
from pathlib import Path
from sys import stdout
CAIRO_VERSION = "1.18.0"
CAIRO_URL = f"https://cairographics.org/releases/cairo-{CAIRO_VERSION}.tar.xz"
CAIRO_SHA256_URL = f"{CAIRO_URL}.sha256sum"
VENV_NAME = "meson-venv"
BUILD_DIR = "build"
INSTALL_PREFIX = Path(__file__).parent.parent.parent / "third_party" / "cairo"
logging.basicConfig(level=logging.INFO, format="%(asctime)s %(levelname)s %(message)s")
logger = logging.getLogger(__name__)
def is_ci():
return os.getenv("CI", None) is not None
def download_file(url, path):
logger.info(f"Downloading {url} to {path}")
block_size = 1024 * 1024
with urllib.request.urlopen(url) as response, open(path, "wb") as file:
while True:
data = response.read(block_size)
if not data:
break
file.write(data)
def verify_sha256sum(path, sha256sum):
with open(path, "rb") as file:
file_hash = hashlib.sha256(file.read()).hexdigest()
if file_hash != sha256sum:
raise Exception("SHA256SUM does not match")
def extract_tar_xz(path, directory):
with tarfile.open(path) as file:
file.extractall(directory)
def run_command(command, cwd=None, env=None):
process = subprocess.Popen(command, cwd=cwd, env=env)
process.communicate()
if process.returncode != 0:
raise Exception("Command failed")
@contextmanager
def gha_group(title: str) -> Generator:
if not is_ci():
yield
return
print(f"\n::group::{title}")
stdout.flush()
try:
yield
finally:
print("::endgroup::")
stdout.flush()
def set_env_var_gha(name: str, value: str) -> None:
if not is_ci():
return
env_file = os.getenv("GITHUB_ENV", None)
if env_file is None:
return
with open(env_file, "a") as file:
file.write(f"{name}={value}\n")
stdout.flush()
def get_ld_library_path(prefix: Path) -> str:
# given a prefix, the ld library path can be found at
# <prefix>/lib/* or sometimes just <prefix>/lib
# this function returns the path to the ld library path
# first, check if the ld library path exists at <prefix>/lib/*
ld_library_paths = list(prefix.glob("lib/*"))
if len(ld_library_paths) == 1:
return ld_library_paths[0].absolute().as_posix()
# if the ld library path does not exist at <prefix>/lib/*,
# return <prefix>/lib
ld_library_path = prefix / "lib"
if ld_library_path.exists():
return ld_library_path.absolute().as_posix()
return ""
def main():
if sys.platform == "win32":
logger.info("Skipping build on windows")
return
with tempfile.TemporaryDirectory() as tmpdir:
with gha_group("Downloading and Extracting Cairo"):
logger.info(f"Downloading cairo version {CAIRO_VERSION}")
download_file(CAIRO_URL, os.path.join(tmpdir, "cairo.tar.xz"))
logger.info("Downloading cairo sha256sum")
download_file(CAIRO_SHA256_URL, os.path.join(tmpdir, "cairo.sha256sum"))
logger.info("Verifying cairo sha256sum")
with open(os.path.join(tmpdir, "cairo.sha256sum")) as file:
sha256sum = file.read().split()[0]
verify_sha256sum(os.path.join(tmpdir, "cairo.tar.xz"), sha256sum)
logger.info("Extracting cairo")
extract_tar_xz(os.path.join(tmpdir, "cairo.tar.xz"), tmpdir)
with gha_group("Installing meson and ninja"):
logger.info("Creating virtual environment")
run_command([sys.executable, "-m", "venv", os.path.join(tmpdir, VENV_NAME)])
logger.info("Installing meson and ninja")
run_command(
[
os.path.join(tmpdir, VENV_NAME, "bin", "pip"),
"install",
"meson",
"ninja",
]
)
# Inherit the current environment so PKG_CONFIG_PATH, CFLAGS, LDFLAGS, etc. are preserved.
env_vars = os.environ.copy()
# Prepend the venv bin directory so meson/ninja from the venv are used.
env_vars["PATH"] = f"{os.path.join(tmpdir, VENV_NAME, 'bin')}{os.pathsep}{env_vars.get('PATH','')}"
# Ensure Homebrew-provided pkgconfig and include/lib paths are present on macOS ARM.
if sys.platform == "darwin":
try:
# Try to get specific prefix for lzo (safer for opt path), fall back to generic brew prefix.
brew_prefix = subprocess.check_output(["brew", "--prefix", "lzo"], text=True).strip()
except subprocess.CalledProcessError:
try:
brew_prefix = subprocess.check_output(["brew", "--prefix"], text=True).strip()
except Exception:
brew_prefix = None
if brew_prefix:
# pkg-config files can live in lib/pkgconfig or opt/<pkg>/lib/pkgconfig
pkgconfig_paths = [f"{brew_prefix}/lib/pkgconfig", f"{brew_prefix}/opt/lzo/lib/pkgconfig"]
# merge with any existing PKG_CONFIG_PATH
existing_pc = env_vars.get("PKG_CONFIG_PATH", "")
merged_pc = ":".join([p for p in pkgconfig_paths if p]) + (f":{existing_pc}" if existing_pc else "")
env_vars["PKG_CONFIG_PATH"] = merged_pc
# Ensure compiler & linker flags include brew include/lib
existing_cflags = env_vars.get("CFLAGS", "")
existing_ldflags = env_vars.get("LDFLAGS", "")
env_vars["CFLAGS"] = f"-I{brew_prefix}/include {existing_cflags}".strip()
env_vars["LDFLAGS"] = f"-L{brew_prefix}/lib {existing_ldflags}".strip()
# Debugging: log environment keys relevant to detection
# logger.info(f"env vars for meson: {env_vars}")
with gha_group("Building and Installing Cairo"):
logger.info("Running meson setup")
run_command(
[
os.path.join(tmpdir, VENV_NAME, "bin", "meson"),
"setup",
BUILD_DIR,
f"--prefix={INSTALL_PREFIX.absolute().as_posix()}",
"--buildtype=release",
"-Dtests=disabled",
],
cwd=os.path.join(tmpdir, f"cairo-{CAIRO_VERSION}"),
env=env_vars,
)
logger.info("Running meson compile")
run_command(
[
os.path.join(tmpdir, VENV_NAME, "bin", "meson"),
"compile",
"-C",
BUILD_DIR,
],
cwd=os.path.join(tmpdir, f"cairo-{CAIRO_VERSION}"),
env=env_vars,
)
logger.info("Running meson install")
run_command(
[
os.path.join(tmpdir, VENV_NAME, "bin", "meson"),
"install",
"-C",
BUILD_DIR,
],
cwd=os.path.join(tmpdir, f"cairo-{CAIRO_VERSION}"),
env=env_vars,
)
logger.info(f"Successfully built cairo and installed it to {INSTALL_PREFIX}")
if __name__ == "__main__":
if "--set-env-vars" in sys.argv:
with gha_group("Setting environment variables"):
# append the pkgconfig directory to PKG_CONFIG_PATH
set_env_var_gha(
"PKG_CONFIG_PATH",
f"{Path(get_ld_library_path(INSTALL_PREFIX), 'pkgconfig').as_posix()}{os.pathsep}"
f'{os.getenv("PKG_CONFIG_PATH", "")}',
)
set_env_var_gha(
"LD_LIBRARY_PATH",
f"{get_ld_library_path(INSTALL_PREFIX)}{os.pathsep}"
f'{os.getenv("LD_LIBRARY_PATH", "")}',
)
sys.exit(0)
main()

View file

@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out a copy of the repository
uses: actions/checkout@v2
uses: actions/checkout@v6
- name: Check whether the citation metadata from CITATION.cff is valid
uses: citation-file-format/cffconvert-github-action@2.0.0

View file

@ -13,114 +13,84 @@ on:
- main
jobs:
test-arm:
runs-on: self-hosted
env:
DISPLAY: :0
PYTEST_ADDOPTS: "--color=yes" # colors in pytest
strategy:
fail-fast: false
matrix:
python: ['3.7.12', '3.10.2']
steps:
- name: Checkout the repository
uses: actions/checkout@v2
- name: Check Runner
run: |
which latex
which ffmpeg
latex --version
ffmpeg -version
which python
python --version
- name: Activate Python ${{ matrix.python }}
run: |
echo "/root/.pyenv/versions/${{ matrix.python }}/bin:/root/.poetry/bin:$PATH" > $GITHUB_PATH
- name: Show Python Version
run: |
python --version --version
- name: Install Manim
run: |
poetry install
- name: Run tests
run: |
poetry run pytest
- name: Run module doctests
run: |
poetry run pytest --cov-append --doctest-modules --ignore-glob="*opengl*" manim
- name: Run doctests in rst files
run: |
cd docs && pip install -r requirements.txt && poetry run make doctest O=-tskip-manim
test:
runs-on: ${{ matrix.os }}
env:
DISPLAY: :0
PYTEST_ADDOPTS: "--color=yes" # colors in pytest
GLCONTEXT_WIN_LIBGL: C:\msys64\mingw64\bin\opengl32.dll
PYTHONIOENCODING: "utf8"
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python: ['3.7', '3.8', '3.9', '3.10']
os: [ubuntu-22.04, macos-latest, windows-latest]
python: ["3.11", "3.12", "3.13", "3.14"]
include:
- os: macos-15-intel
python: "3.13"
steps:
- name: Checkout the repository
uses: actions/checkout@v2
uses: actions/checkout@v6
- name: Setup Python ${{ matrix.python }}
uses: actions/setup-python@v2
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python }}
- name: Install Poetry
run: |
pip install --user poetry
- name: Setup macOS PATH
if: runner.os == 'macOS'
run: |
echo "$HOME/.local/bin" >> $GITHUB_PATH
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
- name: Setup cache variables
shell: bash
id: cache-vars
run: |
echo "::set-output name=poetry-venv-dir::$(poetry config virtualenvs.path)"
echo "::set-output name=date::$(/bin/date -u "+%m%w%Y")"
- name: Setup Poetry cache
uses: actions/cache@v2
with:
path: ${{ steps.cache-vars.outputs.poetry-venv-dir }}
key: ${{ runner.os }}-poetry-${{ env.pythonLocation }}-${{ hashFiles('pyproject.toml') }}-${{ hashFiles('poetry.lock') }}
- name: Install and cache ffmpeg (all OS)
uses: FedericoCarboni/setup-ffmpeg@v1.1.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
id: setup-ffmpeg
echo "date=$(/bin/date -u "+%m%w%Y")" >> $GITHUB_OUTPUT
- name: Install system dependencies (Linux)
if: runner.os == 'Linux'
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: python3-opengl libpango1.0-dev xvfb freeglut3-dev
version: 1.0
- name: Install Texlive (Linux)
if: runner.os == 'Linux'
uses: zauguin/install-texlive@v4
with:
packages: >
scheme-basic latex fontspec tipa calligra xcolor
standalone preview doublestroke setspace rsfs relsize
ragged2e fundus-calligra microtype wasysym physics dvisvgm jknapltx
wasy cm-super babel-english gnu-freefont mathastext cbfonts-fd xetex
- name: Start virtual display (Linux)
if: runner.os == 'Linux'
run: |
sudo apt update
sudo apt-get -y install texlive texlive-latex-extra texlive-fonts-extra texlive-latex-recommended texlive-science texlive-fonts-extra tipa python-opengl libpango1.0-dev xvfb
# start xvfb in background
sudo /usr/bin/Xvfb $DISPLAY -screen 0 1280x1024x24 &
- name: Setup Cairo Cache
uses: actions/cache@v5
id: cache-cairo
if: runner.os == 'Linux' || runner.os == 'macOS'
with:
path: ${{ github.workspace }}/third_party
key: ${{ runner.os }}-${{ runner.arch }}-dependencies-cairo-${{ hashFiles('.github/scripts/ci_build_cairo.py') }}
- name: Build and install Cairo (Linux and macOS)
if: (runner.os == 'Linux' || runner.os == 'macOS') && steps.cache-cairo.outputs.cache-hit != 'true'
run: python .github/scripts/ci_build_cairo.py
- name: Set env vars for Cairo (Linux and macOS)
if: runner.os == 'Linux' || runner.os == 'macOS'
run: python .github/scripts/ci_build_cairo.py --set-env-vars
- name: Setup macOS cache
uses: actions/cache@v5
id: cache-macos
if: runner.os == 'macOS'
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/macos-cache
key: ${{ runner.os }}-dependencies-tinytex-${{ hashFiles('.github/manimdependency.json') }}-${{ steps.cache-vars.outputs.date }}-1
@ -134,8 +104,8 @@ jobs:
oriPath=$PATH
sudo mkdir -p $PWD/macos-cache
echo "Install TinyTeX"
sudo curl -L -o "/tmp/TinyTeX.tgz" "https://github.com/yihui/tinytex-releases/releases/download/daily/TinyTeX-1.tgz"
sudo tar zxf "/tmp/TinyTeX.tgz" -C "$PWD/macos-cache"
sudo curl -L -o "/tmp/TinyTeX.tar.xz" "https://github.com/rstudio/tinytex-releases/releases/download/daily/TinyTeX-1-darwin.tar.xz"
sudo tar xJf "/tmp/TinyTeX.tar.xz" -C "$PWD/macos-cache"
export PATH="$PWD/macos-cache/TinyTeX/bin/universal-darwin:$PATH"
sudo tlmgr update --self
for i in "${ttp[@]}"; do
@ -144,35 +114,22 @@ jobs:
export PATH="$oriPath"
echo "Completed TinyTeX"
- name: Install cairo (MacOS)
if: runner.os == 'macOS'
run: brew install cairo
- name: Add macOS dependencies to PATH
if: runner.os == 'macOS'
shell: bash
run: |
echo "/Library/TeX/texbin" >> $GITHUB_PATH
echo "$HOME/.poetry/bin" >> $GITHUB_PATH
echo "$PWD/macos-cache/TinyTeX/bin/universal-darwin" >> $GITHUB_PATH
- name: Setup Windows cache
id: cache-windows
if: runner.os == 'Windows'
uses: actions/cache@v2
uses: actions/cache@v5
with:
path: ${{ github.workspace }}\ManimCache
key: ${{ runner.os }}-dependencies-tinytex-${{ hashFiles('.github/manimdependency.json') }}-${{ steps.cache-vars.outputs.date }}-1
- name: Setup MSYS2 (Windows)
if: runner.os == 'Windows'
uses: msys2/setup-msys2@v2
with:
release: false
msystem: MINGW64
path-type: inherit
install: >-
mingw-w64-x86_64-mesa
- uses: ssciwr/setup-mesa-dist-win@v3
- name: Install system dependencies (Windows)
if: runner.os == 'Windows' && steps.cache-windows.outputs.cache-hit != 'true'
@ -180,41 +137,32 @@ jobs:
$tinyTexPackages = $(python -c "import json;print(' '.join(json.load(open('.github/manimdependency.json'))['windows']['tinytex']))") -Split ' '
$OriPath = $env:PATH
echo "Install Tinytex"
Invoke-WebRequest "https://github.com/yihui/tinytex-releases/releases/download/daily/TinyTeX-1.zip" -O "$($env:TMP)\TinyTex.zip"
Expand-Archive -LiteralPath "$($env:TMP)\TinyTex.zip" -DestinationPath "$($PWD)\ManimCache\LatexWindows"
$env:Path = "$($PWD)\ManimCache\LatexWindows\TinyTeX\bin\win32;$($env:PATH)"
Invoke-WebRequest "https://github.com/rstudio/tinytex-releases/releases/download/daily/TinyTeX-1-windows.exe" -OutFile "$($env:TMP)\TinyTex.exe"
.$env:TMP\TinyTex.exe -o"$($PWD)\ManimCache\LatexWindows"
$env:Path = "$($PWD)\ManimCache\LatexWindows\TinyTeX\bin\windows;$($env:PATH)"
tlmgr update --self
foreach ($c in $tinyTexPackages){
$c=$c.Trim()
tlmgr install $c
}
tlmgr install $tinyTexPackages
$env:PATH=$OriPath
echo "Completed Latex"
- name: Add Windows dependencies to PATH
if: runner.os == 'Windows'
run: |
$env:Path += ";" + "$($PWD)\ManimCache\LatexWindows\TinyTeX\bin\win32"
$env:Path = "$env:USERPROFILE\.poetry\bin;$($env:PATH)"
$env:PATH = "C:\msys64\mingw64\bin;$($env:PATH)"
$env:Path += ";" + "$($PWD)\ManimCache\LatexWindows\TinyTeX\bin\windows"
echo "$env:Path" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
- name: Install manim
- name: Install dependencies and manim
run: |
poetry config experimental.new-installer false
poetry install
uv sync --all-extras --locked
- name: Run tests
run: |
poetry run pytest
uv run python -m pytest
- name: Run module doctests
run: |
poetry run pytest --cov-append --doctest-modules --ignore-glob="*opengl*" manim
uv run python -m pytest -v --cov-append --ignore-glob="*opengl*" --doctest-modules manim
- name: Run doctests in rst files
run: |
cd docs && pip install -r requirements.txt && poetry run make doctest O=-tskip-manim
- name: Upload coverage
uses: codecov/codecov-action@v1
cd docs && uv run make doctest O=-tskip-manim

42
.github/workflows/codeql.yml vendored Normal file
View file

@ -0,0 +1,42 @@
name: "CodeQL"
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
schedule:
- cron: "21 16 * * 3"
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: [ python ]
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
languages: ${{ matrix.language }}
config-file: ./.github/codeql.yml
queries: +security-and-quality
- name: Autobuild
uses: github/codeql-action/autobuild@v4
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4
with:
category: "/language:${{ matrix.language }}"

72
.github/workflows/publish-docker.yml vendored Normal file
View file

@ -0,0 +1,72 @@
name: Publish Docker Image
on:
push:
branches:
- main
release:
types: [released]
jobs:
docker-latest:
runs-on: ubuntu-latest
if: github.event_name != 'release'
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v4
- name: Login to DockerHub
uses: docker/login-action@v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v7
with:
platforms: linux/arm64,linux/amd64
push: true
file: docker/Dockerfile
tags: |
manimcommunity/manim:latest
docker-release:
runs-on: ubuntu-latest
if: github.event_name == 'release'
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v4
- name: Login to DockerHub
uses: docker/login-action@v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Get Version
id: create_release
shell: python
env:
tag_act: ${{ github.ref }}
run: |
import os
ref_tag = os.getenv('tag_act').split('/')[-1]
with open(os.getenv('GITHUB_OUTPUT'), 'w') as f:
print(f"tag_name={ref_tag}", file=f)
- name: Build and push
uses: docker/build-push-action@v7
with:
platforms: linux/arm64,linux/amd64
push: true
file: docker/Dockerfile
tags: |
manimcommunity/manim:stable
manimcommunity/manim:latest
manimcommunity/manim:${{ steps.create_release.outputs.tag_name }}

View file

@ -6,64 +6,42 @@ on:
jobs:
release:
name: "Publish release"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
environment: release
permissions:
id-token: write
contents: write
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
steps:
- uses: actions/checkout@v6
- name: Install dependencies
run: python -m pip install --upgrade poetry
run: sudo apt-get update && sudo apt-get install -y build-essential python3-dev libcairo2-dev libpango1.0-dev
# TODO: Set PYPI_API_TOKEN to api token from pip in secrets
- name: Configure pypi credentials
env:
PYPI_API_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
run: poetry config http-basic.pypi __token__ "$PYPI_API_TOKEN"
- name: Set up Python 3.13
uses: actions/setup-python@v6
with:
python-version: 3.13
- name: Publish release to pypi
- name: Install uv
uses: astral-sh/setup-uv@v7
- name: Build and push release to PyPI
run: |
poetry publish --build
poetry build
uv build
uv publish
- name: Store artifacts
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v7
with:
path: dist/*.tar.gz
name: manim.tar.gz
- name: Install Dependency
run: pip install requests
- name: Get Upload URL
id: create_release
shell: python
env:
access_token: ${{ secrets.GITHUB_TOKEN }}
tag_act: ${{ github.ref }}
run: |
import requests
import os
ref_tag = os.getenv('tag_act').split('/')[-1]
access_token = os.getenv('access_token')
headers = {
"Accept":"application/vnd.github.v3+json",
"Authorization": f"token {access_token}"
}
url = f"https://api.github.com/repos/ManimCommunity/manim/releases/tags/{ref_tag}"
c = requests.get(url,headers=headers)
upload_url=c.json()['upload_url']
print(f"::set-output name=upload_url::{upload_url}")
print(f"::set-output name=tag_name::{ref_tag[1:]}")
- name: Upload Release Asset
id: upload-release
uses: actions/upload-release-asset@v1
shell: bash
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: dist/manim-${{ steps.create_release.outputs.tag_name }}.tar.gz
asset_name: manim-${{ steps.create_release.outputs.tag_name }}.tar.gz
asset_content_type: application/gzip
run: |
TAG=${{ github.event.release.tag_name }}
gh release upload "$TAG" "dist/manim-${TAG#v}.tar.gz"

View file

@ -0,0 +1,87 @@
name: Publish downloadable documentation
on:
release:
types: [released]
workflow_dispatch:
jobs:
build-and-publish-htmldocs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: 3.13
- name: Install uv
uses: astral-sh/setup-uv@v7
- name: Install system dependencies
run: |
sudo apt update && sudo apt install -y \
pkg-config libcairo-dev libpango1.0-dev wget fonts-roboto
wget -qO- "https://yihui.org/tinytex/install-bin-unix.sh" | sh
echo ${HOME}/.TinyTeX/bin/x86_64-linux >> $GITHUB_PATH
- name: Install LaTeX and Python dependencies
run: |
tlmgr update --self
tlmgr install \
babel-english ctex doublestroke dvisvgm frcursive fundus-calligra jknapltx \
mathastext microtype physics preview ragged2e relsize rsfs setspace standalone \
wasy wasysym
uv sync --extra typst
- name: Build and package documentation
run: |
cd docs/
uv run make html
cd build/html/
tar -czvf ../html-docs.tar.gz *
- name: Store artifacts
uses: actions/upload-artifact@v7
with:
path: ${{ github.workspace }}/docs/build/html-docs.tar.gz
name: html-docs.tar.gz
- name: Install Dependency
run: pip install requests
- name: Get Upload URL
if: github.event == 'release'
id: create_release
shell: python
env:
access_token: ${{ secrets.GITHUB_TOKEN }}
tag_act: ${{ github.ref }}
run: |
import requests
import os
ref_tag = os.getenv('tag_act').split('/')[-1]
access_token = os.getenv('access_token')
headers = {
"Accept":"application/vnd.github.v3+json",
"Authorization": f"token {access_token}"
}
url = f"https://api.github.com/repos/ManimCommunity/manim/releases/tags/{ref_tag}"
c = requests.get(url,headers=headers)
upload_url=c.json()['upload_url']
with open(os.getenv('GITHUB_OUTPUT'), 'w') as f:
print(f"upload_url={upload_url}", file=f)
print(f"tag_name={ref_tag[1:]}", file=f)
- name: Upload Release Asset
if: github.event == 'release'
id: upload-release
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ${{ github.workspace }}/docs/build/html-docs.tar.gz
asset_name: manim-htmldocs-${{ steps.create_release.outputs.tag_name }}.tar.gz
asset_content_type: application/gzip

3
.gitignore vendored
View file

@ -131,3 +131,6 @@ dist/
/media_dir.txt
# ^TODO: Remove the need for this with a proper config file
# Ignore the built dependencies
third_party/*

View file

@ -1,88 +0,0 @@
[mypy]
show_error_codes = True
# ignore most files; should be checked once proper types have been implemented
[mypy-manim.__main__]
ignore_errors = True
[mypy-manim.camera.*]
ignore_errors = True
[mypy-manim.scene.*]
ignore_errors = True
[mypy-manim.cli.cfg.*]
ignore_errors = True
[mypy-manim.mobject.*]
ignore_errors = True
[mypy-manim._config.*]
ignore_errors = True
[mypy-manim.utils.*]
ignore_errors = True
[mypy-manim.animation.*]
ignore_errors = True
# ---------------- We can't properly type this ------------------------
[mypy-manim.grpc.*]
ignore_errors = True
# ---------------- Stubless imported Modules --------------------------
# We should be able to create stubs for this or type hint it
[mypy-manimpango]
ignore_missing_imports = True
# Has stubs in 3.8
[mypy-numpy]
ignore_missing_imports = True
# Has stubs in 3.8
[mypy-pydub]
ignore_missing_imports = True
[mypy-matplotlib]
ignore_missing_imports = True
[mypy-scipy.*]
ignore_missing_imports = True
[mypy-networkx]
ignore_missing_imports = True
[mypy-git]
ignore_missing_imports = True
[mypy-moderngl.*]
ignore_missing_imports = True
[mypy-moderngl_window.*]
ignore_missing_imports = True
[mypy-colour]
ignore_missing_imports = True
[mypy-dearpygui.*]
ignore_missing_imports = True
[mypy-screeninfo]
ignore_missing_imports = True
[mypy-IPython.*]
ignore_missing_imports = True
[mypy-watchdog.*]
ignore_missing_imports = True
[mypy-tqdm]
ignore_missing_imports = True
[mypy-mapbox_earcut]
ignore_missing_imports = True
[mypy-click_default_group]
ignore_missing_imports = True

View file

@ -1,9 +1,9 @@
default_stages: [commit, push]
default_stages: [pre-commit, pre-push]
fail_fast: false
exclude: ^(manim/grpc/gen/|docs/i18n/)
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.2.0
rev: v6.0.0
hooks:
- id: check-ast
name: Validate Python
@ -11,57 +11,35 @@ repos:
- id: mixed-line-ending
- id: end-of-file-fixer
- id: check-toml
name: Validate Poetry
- repo: https://github.com/pycqa/isort
rev: 5.10.1
hooks:
- id: isort
name: isort (python)
- id: isort
name: isort (cython)
types: [cython]
- id: isort
name: isort (pyi)
types: [pyi]
- repo: https://github.com/asottile/pyupgrade
rev: v2.32.0
hooks:
- id: pyupgrade
name: Update code to new python versions
args: [--py37-plus]
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.9.0
hooks:
- id: python-check-blanket-noqa
name: Precision flake ignores
- repo: https://github.com/psf/black
rev: 22.3.0
hooks:
- id: black
- repo: https://github.com/asottile/blacken-docs
rev: v1.12.1
hooks:
- id: blacken-docs
additional_dependencies: [black==22.3.0]
- repo: https://github.com/asottile/yesqa
rev: v1.3.0
hooks:
- id: yesqa
name: Remove unneeded flake ignores
- repo: https://github.com/PyCQA/flake8
rev: 4.0.1
hooks:
- id: flake8
additional_dependencies: [flake8-builtins==1.5.3, flake8-bugbear==21.4.3,
flake8-docstrings==1.6.0, flake8-rst-docstrings==0.2.3,
flake8-pytest-style==1.5.0, flake8-simplify==0.14.1, flake8-comprehensions>=3.6.1]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v0.942'
hooks:
- id: mypy
additional_dependencies: [types-decorator, types-docutils, types-requests, types-setuptools]
name: Validate pyproject.toml
- repo: https://github.com/codespell-project/codespell
rev: v2.1.0
rev: v2.4.1
hooks:
- id: codespell
files: ^.*\.(py|md|rst)$
args: ["-L", "medias,nam"]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.14.10
hooks:
- id: ruff
name: ruff lint
types: [python]
args: [--exit-non-zero-on-fix]
- id: ruff-format
types: [python]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.19.1
hooks:
- id: mypy
additional_dependencies:
[
types-backports,
types-decorator,
types-docutils,
types-requests,
types-setuptools,
]
files: ^manim/

View file

@ -1,11 +1,19 @@
version: 2
sphinx:
configuration: docs/source/conf.py
build:
image: latest
os: ubuntu-22.04
tools:
python: "3.13"
apt_packages:
- libpango1.0-dev
- ffmpeg
- graphviz
python:
version: 3.8
install:
- requirements: docs/rtd-requirements.txt
- requirements: docs/requirements.txt

View file

@ -4,10 +4,10 @@ authors:
-
name: "The Manim Community Developers"
cff-version: "1.2.0"
date-released: 2022-03-08
date-released: 2026-02-27
license: MIT
message: "We acknowledge the importance of good software to support research, and we note that research becomes more valuable when it is communicated effectively. To demonstrate the value of Manim, we ask that you cite Manim in your work."
title: Manim Mathematical Animation Framework
url: "https://www.manim.community/"
version: "v0.15.1"
version: "v0.20.1"
...

View file

@ -152,6 +152,7 @@ Examples of conflicts of interest include:
* The reporter or reported person is a maintainer who regularly reviews your contributions
* The reporter or reported person is your metamour.
* The reporter or reported person is your family member
Committee members do not need to state why they have a conflict of interest, only that one exists. Other team members should not ask why the person has a conflict of interest.
Anyone who has a conflict of interest will remove themselves from the discussion of the incident, and recluse themselves from voting on a response to the report.

View file

@ -1,6 +1,6 @@
MIT License
Copyright (c) 2021, the Manim Community Developers
Copyright (c) 2024, the Manim Community Developers
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

View file

@ -1,17 +1,15 @@
<p align="center">
<a href="https://www.manim.community/"><img src="https://raw.githubusercontent.com/ManimCommunity/manim/main/logo/cropped.png"></a>
<a href="https://www.manim.community/"><img src="https://raw.githubusercontent.com/ManimCommunity/manim/main/logo/cropped.png" alt="Manim Community logo"></a>
<br />
<br />
<a href="https://pypi.org/project/manim/"><img src="https://img.shields.io/pypi/v/manim.svg?style=flat&logo=pypi" alt="PyPI Latest Release"></a>
<a href="https://hub.docker.com/r/manimcommunity/manim"><img src="https://img.shields.io/docker/v/manimcommunity/manim?color=%23099cec&label=docker%20image&logo=docker" alt="Docker image"> </a>
<a href="https://mybinder.org/v2/gh/ManimCommunity/jupyter_examples/HEAD?filepath=basic_example_scenes.ipynb"><img src="https://mybinder.org/badge_logo.svg"></a>
<a href="https://mybinder.org/v2/gh/ManimCommunity/jupyter_examples/HEAD?filepath=basic_example_scenes.ipynb"><img src="https://mybinder.org/badge_logo.svg" alt="Launch Binder"></a>
<a href="http://choosealicense.com/licenses/mit/"><img src="https://img.shields.io/badge/license-MIT-red.svg?style=flat" alt="MIT License"></a>
<a href="https://www.reddit.com/r/manim/"><img src="https://img.shields.io/reddit/subreddit-subscribers/manim.svg?color=orange&label=reddit&logo=reddit" alt="Reddit" href=></a>
<a href="https://twitter.com/manim_community/"><img src="https://img.shields.io/twitter/url/https/twitter.com/cloudposse.svg?style=social&label=Follow%20%40manim_community" alt="Twitter">
<a href="https://www.manim.community/discord/"><img src="https://img.shields.io/discord/581738731934056449.svg?label=discord&color=yellow&logo=discord" alt="Discord"></a>
<a href="https://github.com/psf/black"><img src="https://img.shields.io/badge/code%20style-black-000000.svg" alt="Code style: black">
<a href="https://twitter.com/manimcommunity/"><img src="https://img.shields.io/twitter/url/https/twitter.com/cloudposse.svg?style=social&label=Follow%20%40manimcommunity" alt="Twitter">
<a href="https://manim.community/discord/"><img src="https://img.shields.io/discord/581738731934056449.svg?label=discord&color=yellow&logo=discord" alt="Discord"></a>
<a href="https://docs.manim.community/"><img src="https://readthedocs.org/projects/manimce/badge/?version=latest" alt="Documentation Status"></a>
<a href="https://pepy.tech/project/manim"><img src="https://pepy.tech/badge/manim/month?" alt="Downloads"> </a>
<img src="https://github.com/ManimCommunity/manim/workflows/CI/badge.svg" alt="CI">
<br />
<br />
@ -21,21 +19,23 @@
Manim is an animation engine for explanatory math videos. It's used to create precise animations programmatically, as demonstrated in the videos of [3Blue1Brown](https://www.3blue1brown.com/).
> NOTE: This repository is maintained by the Manim Community and is not associated with Grant Sanderson or 3Blue1Brown in any way (although we are definitely indebted to him for providing his work to the world). If you would like to study how Grant makes his videos, head over to his repository ([3b1b/manim](https://github.com/3b1b/manim)). This fork is updated more frequently than his, and it's recommended to use this fork if you'd like to use Manim for your own projects.
> [!NOTE]
> The community edition of Manim (ManimCE) is a version maintained and developed by the community. It was forked from 3b1b/manim, a tool originally created and open-sourced by Grant Sanderson, also creator of the 3Blue1Brown educational math videos. While Grant Sanderson continues to maintain his own repository, we recommend this version for its continued development, improved features, enhanced documentation, and more active community-driven maintenance. If you would like to study how Grant makes his videos, head over to his repository ([3b1b/manim](https://github.com/3b1b/manim)).
## Table of Contents:
- [Installation](#installation)
- [Usage](#usage)
- [Documentation](#documentation)
- [Docker](#docker)
- [Help with Manim](#help-with-manim)
- [Contributing](#contributing)
- [License](#license)
- [Installation](#installation)
- [Usage](#usage)
- [Documentation](#documentation)
- [Docker](#docker)
- [Help with Manim](#help-with-manim)
- [Contributing](#contributing)
- [License](#license)
## Installation
> **WARNING:** These instructions are for the community version _only_. Trying to use these instructions to install [3b1b/manim](https://github.com/3b1b/manim) or instructions there to install this version will cause problems. Read [this](https://docs.manim.community/en/stable/installation/versions.html) and decide which version you wish to install, then only follow the instructions for your desired version.
> [!CAUTION]
> These instructions are for the community version _only_. Trying to use these instructions to install [3b1b/manim](https://github.com/3b1b/manim) or instructions there to install this version will cause problems. Read [this](https://docs.manim.community/en/stable/faq/installation.html#why-are-there-different-versions-of-manim) and decide which version you wish to install, then only follow the instructions for your desired version.
Manim requires a few dependencies that must be installed prior to using it. If you
want to try it out first before installing it locally, you can do so
@ -88,11 +88,11 @@ The `-p` flag in the command above is for previewing, meaning the video file wil
Some other useful flags include:
- `-s` to skip to the end and just show the final frame.
- `-n <number>` to skip ahead to the `n`'th animation of a scene.
- `-f` show the file in the file browser.
- `-s` to skip to the end and just show the final frame.
- `-n <number>` to skip ahead to the `n`'th animation of a scene.
- `-f` show the file in the file browser.
For a thorough list of command line arguments, visit the [documentation](https://docs.manim.community/en/stable/tutorials/configuration.html).
For a thorough list of command line arguments, visit the [documentation](https://docs.manim.community/en/stable/guides/configuration.html).
## Documentation
@ -118,8 +118,8 @@ The contribution guide may become outdated quickly; we highly recommend joining
[Discord server](https://www.manim.community/discord/) to discuss any potential
contributions and keep up to date with the latest developments.
Most developers on the project use `poetry` for management. You'll want to have poetry installed and available in your environment.
Learn more about `poetry` at its [documentation](https://python-poetry.org/docs/) and find out how to install manim with poetry at the [manim dev-installation guide](https://docs.manim.community/en/stable/contributing/development.html) in the manim documentation.
Most developers on the project use `uv` for management. You'll want to have uv installed and available in your environment.
Learn more about `uv` at its [documentation](https://docs.astral.sh/uv/) and find out how to install manim with uv at the [manim dev-installation guide](https://docs.manim.community/en/latest/contributing/development.html) in the manim documentation.
## How to Cite Manim

382
agents/typst_selector.md Normal file
View file

@ -0,0 +1,382 @@
# Design: Sub-Expression Selection for `Typst` / `TypstMath`
## Problem Statement
Users need to interact with individual parts of a Typst-rendered expression:
color a variable, animate the numerator of a fraction, morph one sub-expression
into another, etc. The `MathTex` class solves this with:
1. **`{{ ... }}` double-brace notation** — splits the TeX string into named
submobject groups at compile time.
2. **`substrings_to_isolate` / `get_part_by_tex`** — identifies submobjects
whose TeX source matches a given string.
Both mechanisms ultimately rely on injecting `\special{dvisvgm:raw <g id='...'>}`
markers into the LaTeX source so that the resulting SVG contains `<g>` elements
with known `id` attributes, which SVGMobject's parser maps to `VGroup`
sub-trees via `id_to_vgroup_dict`.
We need an analogous mechanism for Typst.
## Key Discovery: `data-typst-label` in SVG Output
Typst's SVG renderer (`typst-svg` crate) already emits a `data-typst-label`
attribute on `<g>` elements whenever a `GroupItem` (hard frame) carries a
label. The relevant code path:
```rust
// typst-svg/src/lib.rs — render_group()
if let Some(label) = group.label {
svg.init().attr("data-typst-label", label.resolve());
}
```
A **hard frame** is created by the `box` element (and `block`, etc.). Crucially,
`box` can be used inline inside math mode, and labels can be attached to it.
### Proof of Concept
The following Typst helper wraps content in a labeled `box`:
```typst
#let grp(lbl, body) = [#box(body) #label(lbl)]
```
When used in math:
```typst
$ #grp("numerator", $a + b$) / #grp("denom", $c - d$) = #grp("result", $x$) $
```
The compiled SVG contains:
```xml
<g class="typst-group" ... data-typst-label="numerator">
<!-- glyphs for a + b -->
</g>
<g class="typst-group" ... data-typst-label="denom">
<!-- glyphs for c - d -->
</g>
<g class="typst-group" ... data-typst-label="result">
<!-- glyph for x -->
</g>
```
**Nesting works.** A `grp` wrapping a fraction that itself contains `grp`-ed
sub-parts produces nested `data-typst-label` groups:
```typst
$ #grp("whole-frac", $frac(#grp("numerator", $a + b$), #grp("denom", $c - d$))$) $
```
SVG output:
```xml
<g ... data-typst-label="whole-frac">
<g ... data-typst-label="numerator"> ... </g>
<g ... data-typst-label="denom"> ... </g>
<path class="typst-shape" ... /> <!-- fraction bar -->
</g>
```
### SVG Parser Compatibility
Manim uses `svgelements` to parse SVGs. The library preserves
`data-typst-label` in the `values` dictionary of `Group` objects, and it
propagates to child elements. Manim's `SVGMobject.get_mobjects_from()` already
iterates over groups and builds `id_to_vgroup_dict` keyed by the `id` attribute.
Extending this to also key by `data-typst-label` is straightforward.
## Proposed Interface
### 1. Explicit Groups via `{{ ... }}` Notation (Compile-Time)
Mirror the `MathTex` double-brace convention. Users write:
```python
eq = TypstMath("{{ a + b }} / {{ c - d }} = {{ x }}")
```
The pre-processor splits on `{{ ... }}` (reusing the same whitespace-guard
rules as `MathTex._split_double_braces`) and wraps each group in a labeled
`box` call:
```typst
$ #box[$a + b$] <_grp-0> / #box[$c - d$] <_grp-1> = #box[$x$] <_grp-2> $
```
Each group gets an auto-generated label (`_grp-0`, `_grp-1`, ...).
The `data-typst-label` attributes then appear in the SVG, and
`SVGMobject.get_mobjects_from()` can map them to `VGroup` entries in
`label_to_vgroup_dict` (or reuse `id_to_vgroup_dict`).
These groups become sub-mobjects of the `TypstMath` instance, accessible by
index:
```python
eq[0] # VGroup for "a + b"
eq[1] # VGroup for "c - d"
eq[2] # VGroup for "x"
```
(Non-group content between groups — like `/` and `=` — also becomes
its own submobject, mirroring `MathTex` behavior.)
**For `Typst` (text mode):** the same `{{ ... }}` notation applies, but the
wrapper is `#box[...]` without math delimiters.
### 2. Named Groups via Labels
Users can also assign explicit label names for retrieval by name:
```python
eq = Typst(
r"$ #box[$a + b$] <numerator> / #box[$c - d$] <denom> $"
)
eq.select("numerator").set_color(RED)
eq.select("denom").set_color(BLUE)
```
Alternatively, an even more ergonomic approach that hides the `box` boilerplate
and uses the `{{ ... : label }}` notation:
```python
eq = TypstMath("{{ a + b : numerator }} / {{ c - d : denom }}")
eq.select("numerator").set_color(RED)
```
Here the pre-processor recognizes `{{ content : label }}` and emits
`#box[$content$] <label>` in the Typst source.
### 3. The `.select()` Method
```python
def select(self, key: str | int) -> VGroup:
"""Select a labeled sub-expression.
Parameters
----------
key
Either a label name (string) matching a ``data-typst-label``
in the SVG, or an integer index into the auto-numbered
``{{ ... }}`` groups.
Returns
-------
VGroup
The sub-mobjects corresponding to the selected group.
Raises
------
KeyError
If no group with the given label/index exists.
"""
```
This returns a `VGroup` containing exactly the submobjects (paths) that
were rendered inside the corresponding `<g data-typst-label="...">` in the SVG.
## Implementation Plan
### Step 1: Extend `SVGMobject.get_mobjects_from()` to Track Labels
In `manim/mobject/svg/svg_mobject.py`, the group-walking loop already checks
for `id` attributes. Add a parallel check for `data-typst-label`:
```python
try:
group_name = str(element.values["id"])
except Exception:
# Fall back to data-typst-label if available
label = element.values.get("data-typst-label")
if label:
group_name = f"typst-label:{label}"
else:
group_name = f"numbered_group_{group_id_number}"
group_id_number += 1
```
This automatically populates `id_to_vgroup_dict` with label-keyed entries.
### Step 2: Pre-Processing `{{ ... }}` in Typst Source
Add a `_split_and_label_groups()` method that:
1. Scans the input for `{{ ... }}` or `{{ ... : label }}` patterns
(using the same whitespace-guard rules as `MathTex._split_double_braces`).
2. Replaces each group with `#box[$content$] <label>` (math mode) or
`#box[content] <label>` (text mode).
3. Records the mapping from label → original source string for later lookup.
### Step 3: `Typst.select()` / Index Access
- Store the ordered list of group labels and their source strings.
- `select(label_or_index)` looks up the corresponding `VGroup` from
`id_to_vgroup_dict` (using the `typst-label:...` key).
- `__getitem__(int)` returns the *n*-th group's `VGroup`.
### Step 4: Compatibility with `TransformMatchingTex` (future)
`TransformMatchingTex` (and its successor `TransformMatchingShapes`) works by
matching submobjects between two `MathTex` instances by their TeX string keys.
The same approach extends to `Typst` if each `{{ ... }}` group carries its
original source string as metadata. A `TransformMatchingTypst` animation could
match groups by label name or by source string equality.
## Open Design Questions
### Q1: Context-Aware Wrapping — Math vs. Text Mode
The `box` + `label` mechanism works identically in math and text mode, but the
**wrapping** of group content must match the surrounding context:
- **In text mode:** `{{ Hello : greeting }}``#box[Hello] <greeting>`
- **In math mode:** `{{ y^2 : second }}``#box[$y^2$] <second>`
Getting this wrong is not a silent error — it produces visually broken output.
Wrapping math content with `#box[y^2]` (no `$...$`) renders `y^2` as literal
text in the body font instead of as a math superscript.
This is a real problem for `Typst()`, where a single source string can mix text
and math freely:
```python
Typst("hello world, here is a formula: $x^2 + {{ y^2 : second }} = z^2$")
```
Here `{{ y^2 : second }}` is inside a `$ ... $` block, so it needs the
math-mode wrapper, but the pre-processor has no way to know this unless it
tracks `$` delimiters.
### The `#` prefix problem and math calls
A natural idea is to translate `{{ content }}` into a Typst function call like
`grp("lbl", content)`. However, this has a subtle but critical context
sensitivity: Typst has two different call conventions depending on context:
- **Math call** (no `#` prefix): `$ grp("lbl", a^2 + b) $` — arguments are
parsed **in math mode**. The content `a^2 + b` is math. ✓
- **Code call** (`#` prefix): `$ #grp("lbl", a^2 + b) $` — arguments are
parsed **in code mode**. `a^2` is a syntax error in code! ✗
So in math mode, the function MUST be called without `#` for args to stay in
math mode. In text/markup mode, the function MUST be called WITH `#` (that's
how you invoke code from markup), and content arguments need `[...]` wrapping:
```typst
// Text context: #grp("lbl", [Hello world])
// Math context: grp("lbl", a^2 + b)
```
The function definition is the same either way:
```typst
#let grp(lbl, body) = [#box(body) #label(lbl)]
```
This means the function call approach has **exactly the same context problem**
as the raw `#box` approach: the pre-processor must know whether it's in math or
text to emit the right calling convention.
### Further complication: string literals and content blocks
Even inside `TypstMath` (where everything is math), the scanner must avoid
`{{ }}` matches inside string literals or content blocks:
```python
TypstMath('x^2 + y^2 =_("Hello {{ world }}") z^2')
```
Here `{{ world }}` is inside a `"..."` string literal — it should NOT be
processed. Similarly, content blocks `[...]` inside math switch back to text
mode.
### Options
**A. `TypstMath`: math calls with simple string-aware scanning.**
For `TypstMath`, the entire body is math, so `{{ content }}` always becomes
`grp("_grp-N", content)` (no `#`, no `$...$`). The scanner just needs to
skip `"..."` string literals and `[...]` content blocks — no `$` tracking
needed. This is clean and robust.
**B. `Typst`: context-aware scanning (full parser).**
For the general `Typst` class, the scanner must additionally track `$...$`
math blocks (toggling a mode flag on unescaped `$`) to choose between
`grp(...)` (in math) and `#grp("lbl", [...])` (in text). It must also handle
string literals and content blocks inside math that switch context back. This
is doable but non-trivial — essentially a mini Typst lexer.
**C. `Typst`: no `{{ }}`, manual groups only.**
For the general `Typst` class, don't support `{{ }}` at all. Users write
`grp(...)` / `#grp(...)` themselves (with the helper injected into the
preamble). `{{ }}` is only available on `TypstMath`. This is simpler and
avoids the parsing complexity, at the cost of ergonomics for mixed-mode
documents.
**Recommendation:** Start with A (TypstMath only) and C (manual for Typst).
Upgrade to B later if demand warrants it — the function call infrastructure
is already in place, it's only the scanner that needs upgrading.
### Q2: What about "unlabeled" content between groups?
Like `MathTex`, the pieces of content *between* `{{ ... }}` groups should also
become their own submobjects (auto-labeled with sequential indices). For
example:
```python
TypstMath("{{ a }} + {{ b }} = {{ c }}")
# group-0: "a"
# group-1: "+" (auto-group for inter-group content)
# group-2: "b"
# group-3: "=" (auto-group for inter-group content)
# group-4: "c"
```
Each segment (group or inter-group) gets wrapped in its own labeled `box`.
### Q3: What happens with `box` and baseline alignment?
`box` is an inline element in Typst, and when used inside math mode it
participates in math layout. Testing confirms that fractions, superscripts, and
other constructs render correctly when their children are `box`-wrapped.
However, `box` creates a "hard frame" boundary which may subtly affect spacing
in edge cases (e.g., math operator spacing around a boxed expression). This
needs further testing; if issues arise, we could explore `block(breakable: false)`
or invisible `rect` wrappers as alternatives.
### Q4: Can we avoid the `#grp(...)` / `#box[...] <label>` verbosity?
Yes — the `{{ ... }}` double-brace notation is purely syntactic sugar that gets
pre-processed by Manim before the source reaches the Typst compiler. Users never
need to write raw `#box` or `#label()` calls unless they want finer control.
### Q5: String-based selection without explicit groups?
A future enhancement could support:
```python
eq = TypstMath(r"a + b = c")
eq.select("a") # finds submobjects corresponding to the glyph "a"
```
This is hard to do reliably because:
- Typst SVGs embed glyphs as `<use xlink:href="#gXXX">` references; there's no
text content in the SVG itself.
- A single variable in Typst may span multiple glyphs (e.g., `"alpha"` → one
glyph) or identical glyphs may appear multiple times.
A possible approach: at pre-processing time, wrap every "token" in the Typst
math source in its own labeled `box`. This would require a Typst math tokenizer
and is better suited for a v2 implementation.
## Summary: What Typst Gives Us
| Mechanism | How it works | SVG output |
|---|---|---|
| `#box(body) <label>` | Creates a hard-frame `GroupItem` with a `Label` | `<g data-typst-label="label">...</g>` |
| `#metadata(val) <label>` | Invisible; queryable via `typst query` CLI | No visual output (useful for CLI queries, not SVG) |
| Show rules on labels | `#show <label>: ...` | Transforms visual output but no automatic SVG grouping |
| `context query(<label>)` | Document introspection (positions, counters) | In-document only; not available from Python |
The `box` + `label` mechanism is the **only** one that produces identifiable
groups in the SVG output, making it the correct tool for sub-expression
selection in Manim.

View file

@ -1,26 +0,0 @@
# This file is automatically picked by pytest
# while running tests. So, that each test is
# run on difference temporary directories and avoiding
# errors.
from __future__ import annotations
# If it is running Doctest the current directory
# is changed because it also tests the config module
# itself. If it's a normal test then it uses the
# tempconfig to change directories.
import pytest
from _pytest.doctest import DoctestItem
from manim import config, tempconfig
@pytest.fixture(autouse=True)
def temp_media_dir(tmpdir, monkeypatch, request):
if isinstance(request.node, DoctestItem):
monkeypatch.chdir(tmpdir)
yield tmpdir
else:
with tempconfig({"media_dir": str(tmpdir)}):
assert config.media_dir == str(tmpdir)
yield tmpdir

View file

@ -1,55 +1,88 @@
FROM python:3.8-slim
# ── Stage 1: builder ─────────────────────────────────────────────────────────
FROM python:3.14-slim AS builder
RUN apt-get update -qq \
&& apt-get install --no-install-recommends -y \
ffmpeg \
build-essential \
gcc \
cmake \
make \
pkg-config \
wget \
libcairo2-dev \
libffi-dev \
libpango1.0-dev \
freeglut3-dev \
pkg-config \
make \
wget
libegl-dev \
&& rm -rf /var/lib/apt/lists/*
# setup a minimal texlive installation
# Setup a minimal TeX Live installation (no ctex: drops ~100 MB of CJK fonts/packages)
COPY docker/texlive-profile.txt /tmp/
ENV PATH=/usr/local/texlive/bin/armhf-linux:/usr/local/texlive/bin/aarch64-linux:/usr/local/texlive/bin/x86_64-linux:$PATH
RUN wget -O /tmp/install-tl-unx.tar.gz http://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz && \
mkdir /tmp/install-tl && \
tar -xzf /tmp/install-tl-unx.tar.gz -C /tmp/install-tl --strip-components=1 && \
/tmp/install-tl/install-tl --profile=/tmp/texlive-profile.txt \
RUN wget -O /tmp/install-tl-unx.tar.gz http://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz \
&& mkdir /tmp/install-tl \
&& tar -xzf /tmp/install-tl-unx.tar.gz -C /tmp/install-tl --strip-components=1 \
&& /tmp/install-tl/install-tl --profile=/tmp/texlive-profile.txt \
&& tlmgr install \
amsmath babel-english cbfonts-fd cm-super ctex doublestroke dvisvgm everysel \
amsmath babel-english cbfonts-fd cm-super count1to doublestroke dvisvgm everysel \
fontspec frcursive fundus-calligra gnu-freefont jknapltx latex-bin \
mathastext microtype ms physics preview ragged2e relsize rsfs \
setspace standalone tipa wasy wasysym xcolor xetex xkeyval
mathastext microtype multitoc physics prelim2e preview ragged2e relsize rsfs \
setspace standalone tipa wasy wasysym xcolor xetex xkeyval \
&& rm -rf /tmp/install-tl /tmp/install-tl-unx.tar.gz
# Install manim into an isolated virtualenv
ENV VIRTUAL_ENV=/opt/venv
RUN python -m venv $VIRTUAL_ENV
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
# clone and build manim
COPY . /opt/manim
WORKDIR /opt/manim
RUN pip install --no-cache .[jupyterlab]
RUN pip install --no-cache-dir .[jupyterlab]
RUN pip install -r docs/requirements.txt
# ── Stage 2: runtime ─────────────────────────────────────────────────────────
FROM python:3.14-slim
# Runtime libs only:
# - no ffmpeg: PyAV (av package) bundles its own ffmpeg libraries in av.libs/
# - OpenGL: keep EGL for headless rendering and libGL as required by moderngl/glcontext
# - fonts-noto-core instead of fonts-noto (drops CJK noto fonts)
RUN apt-get update -qq \
&& apt-get install --no-install-recommends -y \
libcairo2 \
libpango-1.0-0 \
libpangocairo-1.0-0 \
libpangoft2-1.0-0 \
libffi8 \
libegl1 \
libgl1 \
ghostscript \
fonts-noto-core \
fontconfig \
&& rm -rf /var/lib/apt/lists/*
RUN fc-cache -fv
# Copy TeX Live from builder
ENV PATH=/usr/local/texlive/bin/armhf-linux:/usr/local/texlive/bin/aarch64-linux:/usr/local/texlive/bin/x86_64-linux:$PATH
COPY --from=builder /usr/local/texlive /usr/local/texlive
# Copy the pre-built virtualenv from builder
ENV VIRTUAL_ENV=/opt/venv
COPY --from=builder /opt/venv /opt/venv
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
ARG NB_USER=manimuser
ARG NB_UID=1000
ENV USER ${NB_USER}
ENV NB_UID ${NB_UID}
ENV HOME /manim
ENV USER=${NB_USER}
ENV NB_UID=${NB_UID}
ENV HOME=/manim
RUN adduser --disabled-password \
--gecos "Default user" \
--uid ${NB_UID} \
${NB_USER}
# create working directory for user to mount local directory into
WORKDIR ${HOME}
USER root
RUN chown -R ${NB_USER}:${NB_USER} ${HOME}
RUN chmod 777 ${HOME}
RUN chown -R ${NB_USER}:${NB_USER} ${HOME} && chmod 777 ${HOME}
USER ${NB_USER}
CMD [ "/bin/bash" ]
CMD ["/bin/bash"]

View file

@ -13,3 +13,11 @@ Multi-platform builds are possible by running
docker buildx build --push --platform linux/arm64/v8,linux/amd64 --tag manimcommunity/manim:TAG -f docker/Dockerfile .
```
from the root directory of the repository.
# Runtime notes
- The image is built via a multi-stage Dockerfile (build dependencies are not
carried into the runtime stage).
- The image does not include the `ffmpeg` CLI binary.
- The default TeX installation is minimal and does not include `ctex`.
- Headless OpenGL rendering relies on EGL/GL runtime libraries available in the
image.

View file

@ -255,7 +255,7 @@ msgid ":pr:`2415`: Removed instructions on using and installing Docker in README
msgstr ""
#: ../../source/changelog/0.14.0-changelog.rst:114
msgid ":pr:`2414`: Made improvements to the :doc:`configuration` tutorial"
msgid ":pr:`2414`: Made improvements to the :doc:`/guides/configuration` tutorial"
msgstr ""
#: ../../source/changelog/0.14.0-changelog.rst:117

View file

@ -0,0 +1,426 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/changelog/0.15.2-changelog.rst:3
msgid "v0.15.2"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:0
msgid "Date"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:5
msgid "April 25, 2022"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:8
msgid "Contributors"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:10
msgid "A total of 33 people contributed to this release. People with a '+' by their names authored a patch for the first time."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:14
msgid "Bailey Powers +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:15
#: ../../source/changelog/0.15.2-changelog.rst:44
msgid "Benjamin Hackl"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:16
msgid "Dan Walsh +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:17
msgid "Darigov Research"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:18
#: ../../source/changelog/0.15.2-changelog.rst:46
msgid "Darylgolden"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:19
msgid "David Millard +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:20
msgid "Hamidreza Hashemi +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:21
#: ../../source/changelog/0.15.2-changelog.rst:49
msgid "Jan-Hendrik Müller"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:22
#: ../../source/changelog/0.15.2-changelog.rst:50
msgid "Jason Villanueva"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:23
msgid "Jonathan Alpert +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:24
msgid "Joy Bhalla"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:25
msgid "Kian Cross +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:26
msgid "Luca +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:27
msgid "Mohsin Shaikh +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:28
#: ../../source/changelog/0.15.2-changelog.rst:53
msgid "Naveen M K"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:29
msgid "Prismo +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:30
#: ../../source/changelog/0.15.2-changelog.rst:55
msgid "Ryan McCauley"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:31
msgid "WillSoltas +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:32
#: ../../source/changelog/0.15.2-changelog.rst:56
msgid "ad_chaos"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:33
msgid "darkways +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:34
msgid "dawn*squirryl +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:35
#: ../../source/changelog/0.15.2-changelog.rst:59
msgid "icedcoffeeee"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:36
#: ../../source/changelog/0.15.2-changelog.rst:60
msgid "peaceheis"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:37
msgid "sparshg"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:38
msgid "trickypr +"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:41
msgid "The patches included in this release have been reviewed by the following contributors."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:45
msgid "Dan Walsh"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:47
msgid "GameDungeon"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:48
msgid "Hugues Devimeux"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:51
msgid "Jonathan Alpert"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:52
msgid "Luca"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:54
msgid "Prismo"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:57
msgid "darkways"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:58
msgid "hickmott99"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:63
msgid "Pull requests merged"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:65
msgid "A total of 39 pull requests were merged for this release."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:68
msgid "New features"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:74
msgid ":pr:`1975`: Improved CLI help page styling"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:71
msgid "Updates dependencies on Click and Cloup libraries for CLI help page styling."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:72
msgid "Removed the dependency on click-default-group."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:73
msgid "Added ``no_args_is_help`` parameter for ``manim render`` to allow easy access to help page."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:74
msgid "Added note to ``manim`` help page epilog on how to access other command help pages."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:77
msgid ":pr:`2404`: Add :class:`.SpiralIn` Animation"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:77
msgid "Make :class:`.ManimBanner` to use :class:`.SpiralIn`."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:79
msgid ":pr:`2534`: Implement :class:`~.OpenGLImageMobject`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:82
msgid ":pr:`2684`: Created a more accessible way to create Angles with line.py angle function - :meth:`.Angle.from_three_points`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:86
msgid "Enhancements"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:88
msgid ":pr:`2062`: Reuse shader wrappers and shader data"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:92
msgid ":pr:`2642`: Migrated ``file_ops.py`` and ``scene_file_writer.py`` from os.path to Pathlib"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:92
msgid "In ``file_ops.py`` and ``scene_file_writer.py``: Uses of str type file names have been mostly (see further information) converted to pathlib's Path objects. Uses of ``os.path`` methods have been converted to equivalent pathlib methods."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:94
msgid ":pr:`2655`: Fix :func:`.assert_is_mobject_method` when using OpenGL"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:97
msgid ":pr:`2665`: Improved handling of attributes when using the ``.animate`` syntax"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:102
msgid ":pr:`2674`: Document and type ``simple_functions.py``"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:101
msgid "Add documentation for ``simple_functions.py``."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:102
msgid "Small additions with some extra clarity for these functions."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:105
msgid ":pr:`2693`: Allow using :meth:`.MovingCamera.auto_zoom` without animation"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:105
msgid "Allows auto zooming camera without having to play an animation by passing an ``animation=False`` argument"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:108
msgid "Fixed bugs"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:110
msgid ":pr:`2546`: Fixed a file logging bug and some maintenance"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:116
msgid ":pr:`2597`: Fix Bug in :class:`.Uncreate` with ``rate_func`` via introducing new parameter ``reversed`` to :class:`.Animation`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:114
msgid "Refractor the :class:`.Uncreate`. The new implementation uses a flag member ``reversed``. Set it to ``True`` and its superclass handles the reverse."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:115
msgid "Introduce a bool parameter ``reversed`` to :class:`.Animation`. It decides whether the animation needs to be played backwards. Default to be False."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:116
msgid "Add conditional branches in :meth:`.Animation.get_sub_alpha`. If the parameter ``reversed`` is True, it would set ``rate_func(t)`` to ``rate_func(1 - t)``."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:118
msgid ":pr:`2613`: Fixed bug in :meth:`.Circle.point_at_angle` when the angle is not in the interval :math:`[0, 2\\pi]`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:121
msgid ":pr:`2634`: Fix background lines drawn twice in :class:`.NumberPlane`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:124
msgid ":pr:`2648`: Handle user-defined centers for Wiggle animation"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:128
msgid ":pr:`2658`: Fix arguments of overridden ``set_style`` for :class:`.BackgroundRectangle`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:128
msgid "Using :class:`.Write` animation on a :class:`.Text` object with ``.add_background_rectangle()`` applied no longer generates a ``TypeError``."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:130
msgid ":pr:`2668`: (Re)set background color of :class:`.OpenGLRenderer` when initializing scene"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:133
msgid ":pr:`2676`: Fixed propagation of custom attributes in animations for the OpenGL renderer"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:136
msgid ":pr:`2688`: Fixed two minor issues of :class:`.SpiralIn` and :class:`.ManimBanner`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:140
msgid "Documentation-related changes"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:142
msgid ":pr:`2609`: Copyedit troubleshooting.rst"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:145
msgid ":pr:`2610`: Add example PolygonOnAxes"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:148
msgid ":pr:`2617`: Re-added :mod:`.value_tracker` documentation"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:151
msgid ":pr:`2619`: Improve Example for arrange_in_grid"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:154
msgid ":pr:`2620`: Fixed typo in :meth:`.Animation.is_introducer`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:158
msgid ":pr:`2640`: Copyedited Documentation"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:158
msgid "Reviewed ``tutorials/configurations.rst``. Edited simple mistakes such as Manim not being capitalized and commas."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:160
msgid ":pr:`2649`: Document and type utils/iterables.py"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:163
msgid ":pr:`2651`: Update copyright year in documentation to 2020-2022"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:165
msgid ":pr:`2663`: Added documentation for scene updater functions"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:168
msgid ":pr:`2686`: Add instructions to install extra dependencies with poetry"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:172
msgid "Changes to our development infrastructure"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:174
msgid ":pr:`2561`: Run tests on Linux-aarch64"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:177
msgid ":pr:`2656`: Fixed incompatibility with black version"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:181
msgid "Code quality improvements and similar refactors"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:184
msgid ":pr:`2630`: Remove WebGL renderer"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:184
msgid "The WebGL renderer is broken and unmaintained. The support for it in Manim is removed."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:186
msgid ":pr:`2652`: Update ``cloup`` version to 0.13.0 from 0.7.0"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:189
msgid ":pr:`2678`: Require ``backports-cached-property`` only for Python < 3.8"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:193
msgid ":pr:`2685`: Migrate from ``os.path`` to ``pathlib`` in testing scripts"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:193
msgid "This pull request changes a number of instances of ``os.path`` to Pathlib objects and functions. In addition, this PR modifies the SVGMobject constructor to accept both a Pathlib object or a string variable pathname its constructor."
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:195
msgid ":pr:`2691`: Removed :class:`CameraFrame`"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:198
msgid ":pr:`2696`: Made changelog generation run in parallel plus further improvements to ``scripts/dev_changelog.py``"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:201
msgid ":pr:`2697`: Sort PRs by number in changelog sections before writing"
msgstr ""
#: ../../source/changelog/0.15.2-changelog.rst:205
msgid "New releases"
msgstr ""

View file

@ -0,0 +1,501 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/changelog/0.16.0-changelog.rst:3
msgid "v0.16.0"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:0
msgid "Date"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:5
msgid "July 13, 2022"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:8
msgid "Contributors"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:10
msgid "A total of 44 people contributed to this release. People with a '+' by their names authored a patch for the first time."
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:14
#: ../../source/changelog/0.16.0-changelog.rst:51
msgid "Alex Lembcke"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:15
msgid "Baroudi Aymen +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:16
#: ../../source/changelog/0.16.0-changelog.rst:52
msgid "Benjamin Hackl"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:17
msgid "Charalampos Georgiou +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:18
msgid "Cindy Park +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:19
msgid "Ejar +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:20
msgid "Francesco Frassinelli +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:21
msgid "Francisco Manríquez Novoa +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:22
msgid "Jacob Evan Shreve +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:23
msgid "Jaime Santos +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:24
#: ../../source/changelog/0.16.0-changelog.rst:58
msgid "Jonathan Alpert"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:25
msgid "Joshua Mankelow +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:26
msgid "Kevin Lubick +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:27
#: ../../source/changelog/0.16.0-changelog.rst:60
msgid "Laith Bahodi"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:28
msgid "Lingren Kong +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:29
msgid "Logen +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:30
#: ../../source/changelog/0.16.0-changelog.rst:61
msgid "Naveen M K"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:31
msgid "Noam Zaks"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:32
msgid "Pedro Lamkowski +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:33
#: ../../source/changelog/0.16.0-changelog.rst:64
msgid "Raghav Goel"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:34
msgid "Simeon Widdis"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:35
#: ../../source/changelog/0.16.0-changelog.rst:66
msgid "Sparsh Goenka"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:36
msgid "TornaxO7 +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:37
msgid "Tristan Schulz +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:38
msgid "WillSoltas"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:39
#: ../../source/changelog/0.16.0-changelog.rst:69
msgid "ad_chaos"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:40
msgid "conor-oneill-2 +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:41
msgid "fcrozatier +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:42
msgid "mooncaker816 +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:43
msgid "niklebedenko +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:44
msgid "nyabkun +"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:45
msgid "quark67"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:48
msgid "The patches included in this release have been reviewed by the following contributors."
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:53
msgid "Darylgolden"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:54
msgid "Francesco Frassinelli"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:55
msgid "Francisco Manríquez Novoa"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:56
msgid "Gianluca Gippetto"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:57
msgid "Jan-Hendrik Müller"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:59
msgid "Kevin Lubick"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:62
msgid "Pedro Lamkowski"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:63
msgid "Philipp Imhof"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:65
msgid "Ryan McCauley"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:67
msgid "TornaxO7"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:68
msgid "Tristan Schulz"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:70
msgid "hickmott99"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:73
msgid "Pull requests merged"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:75
msgid "A total of 56 pull requests were merged for this release."
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:78
msgid "Highlights"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:82
msgid ":pr:`2550`: New thematic guide: a deep dive into the internals of the library"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:81
msgid "This new :doc:`thematic guide </guides/deep_dive>` aims to be a comprehensive walkthrough describing all the things that Manim does when you run it to produce a video."
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:84
msgid ":pr:`2732`: Improved overall structure of deployed documentation; added a dedicated :doc:`FAQ section </faq/index>`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:90
msgid ":pr:`2749`: Added :class:`.ChangeSpeed`, an animation wrapper that allows to smoothly change the speed at which an animation is played"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:88
msgid "The speed of any animation can be changed by wrapping the animation with :class:`.ChangeSpeed` and passing a dictionary as ``speedinfo`` whose keys are the relative animation run time stamps and whose values are the absolute speed factors; e.g., ``{0.5: 2, 0.75: 0.25}`` smoothly speeds up the animation by a factor of 2 once it has been completed to 50%, and then it is smoothly slowed down to 1/4 of the default run speed after 75% of the animation are completed. The ``run_time`` of the animation will be adjusted to match the changed play speed."
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:90
msgid "It is also possible to add time-based updaters that respect the change in speed, use the auxiliary :meth:`.ChangeSpeed.add_updater` method to do so."
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:93
msgid "New features"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:95
msgid ":pr:`2667`: Made FFmpeg executable path configurable"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:98
msgid ":pr:`2739`: Added vectorized plotting functionality via keyword argument ``use_vectorized`` to improve performance"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:102
msgid "Enhancements"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:104
msgid ":pr:`2186`: Enabled filling color by value for :class:`.OpenGLSurface`, replaced ``colors`` keyword argument of :meth:`.Surface.set_fill_by_value` with ``colorscale``"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:107
msgid ":pr:`2288`: Added warning when attempting to add same mobject as child twice"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:112
msgid ":pr:`2707`: Fixed missing ``get_nth_curve_length_pieces`` method of :class:`.OpenGLVMobject`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:111
msgid "Removed duplicate definition of ``get_curve_functions_with_lengths`` in ``OpenGLVMobject``"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:112
msgid "Added definition of ``get_nth_curve_length_pieces`` to ``OpenGLVMobject``"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:114
msgid ":pr:`2709`: Improved the look of the brackets of :class:`.Matrix`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:117
msgid ":pr:`2714`: Fixed :meth:`.OpenGLVMobject.pointwise_become_partial` to improve stroke rendering"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:120
msgid ":pr:`2727`: Slight performance improvement for :class:`.ArrowVectorField` and Bézier curve computation"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:123
msgid ":pr:`2728`: Added :meth:`.VectorField.fit_to_coordinate_system` to fit a vector field to a given coordinate system"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:126
msgid ":pr:`2730`: Added note to let users find documentation of default CLI subcommand easier"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:129
msgid ":pr:`2746`: Installed ghostscript in the docker image"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:132
msgid ":pr:`2841`: Added :func:`.split_quadratic_bezier` and :func:`.subdivide_quadratic_bezier`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:135
msgid ":pr:`2842`: CLI: Moved functionality from ``manim new`` to ``manim init`` and added deprecation warning for ``manim new``"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:138
msgid ":pr:`2866`: Reorganize test files to match library module structure"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:142
msgid "Fixed bugs"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:144
msgid ":pr:`2567`: Use tempconfig for every scene render"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:147
msgid ":pr:`2638`: Fixed :meth:`BarChart.change_bar_values` not updating when height is 0"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:150
msgid ":pr:`2661`: Fixed tip resize functionality for :class:`.Axes` to match documentation"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:153
msgid ":pr:`2703`: Default to utf-8 when reading files in :class:`.Code`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:156
msgid ":pr:`2721`: Fixed bad text slicing for lines in :class:`.Paragraph`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:159
msgid ":pr:`2725`: Fixed wrong indentation in :class:`.Code`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:162
msgid ":pr:`2734`: Fixed OpenGL segfaults when running :meth:`.Scene.play` or :meth:`.Scene.wait` in interactive mode"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:165
msgid ":pr:`2753`: Fixed multiplatform builds for docker images in pipeline"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:168
msgid ":pr:`2757`: Added missing ``__init__.py`` file in :mod:`.docbuild` module"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:171
msgid ":pr:`2770`: Fixed bug in :meth:`.VMobject.proportion_from_point` that caused proportions greater than 1 to be returned"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:174
msgid ":pr:`2826`: Fixed leaked mobjects coming from :class:`.TransformMatchingAbstractBase`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:177
msgid ":pr:`2870`: Fixed issue with ``manim init scene SCENE_NAME filename.py`` and removed necessity of ``main.py`` to be present in working directory"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:181
msgid "Documentation-related changes"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:183
msgid ":pr:`2704`: Updated URL to Pango Markup formatting page"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:186
msgid ":pr:`2716`: Improved the order of the reference manuals"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:189
msgid ":pr:`2720`: Fixed typo in docstring of :class:`.Angle`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:192
msgid ":pr:`2722`: Fixed typos in docstrings of classes in :mod:`.mobject.table`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:195
msgid ":pr:`2726`: Edited note on :class:`.NumberPlane` length and added another example"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:198
msgid ":pr:`2740`: Fixed documentation of :meth:`.Cylinder.get_direction`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:201
msgid ":pr:`2755`: Fixed docstring of :meth:`.VMobject.get_end_anchors`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:204
msgid ":pr:`2760`: Removed ``cmake`` from the MacOS installation section"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:207
msgid ":pr:`2767`: Added more questions and answers to FAQ section, new :doc:`OpenGL FAQ </faq/opengl>`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:210
msgid ":pr:`2771`: Added documentation and testing for ``path_func`` keyword argument of :class:`.Transform`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:213
msgid ":pr:`2828`: Removed suggestion issue template, added FAQ answer regarding proposing new features"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:216
msgid ":pr:`2849`: Added example for ``path_arc`` keyword argument of :class:`.Transform`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:219
msgid ":pr:`2851`: Added an example on constructing a (neural) network using a partite :class:`.Graph`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:222
msgid ":pr:`2855`: Added implicit ``docker.io/`` URL base in reference to docker images"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:225
msgid ":pr:`2861`: Added docstring for :meth:`.CoordinateSystem.plot_parametric_curve`"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:229
msgid "Changes concerning the testing system"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:231
msgid ":pr:`2743`: Replaced ``assert`` statements with with assertion functions from ``np.testing``"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:235
msgid "Changes to our development infrastructure"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:237
msgid ":pr:`2700`: CI: updated Python versions"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:240
msgid ":pr:`2701`: CI: added a workflow to publish docker image after releases and commits to main branch"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:244
msgid "Code quality improvements and similar refactors"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:246
msgid ":pr:`2680`: Increased minimum required version of ``numpy`` to 1.19"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:249
msgid ":pr:`2687`: Migrated from ``os.path`` to ``pathlib`` in :class:`.SVGMobject` and other locations"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:252
msgid ":pr:`2715`: Updated deprecated ``pillow`` constants"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:255
msgid ":pr:`2735`: Bump pyjwt from 2.3.0 to 2.4.0"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:258
msgid ":pr:`2748`: Bump pillow from 9.1.0 to 9.1.1"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:261
msgid ":pr:`2751`: Fixed flake C417 and improved a comment"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:264
msgid ":pr:`2825`: Bump notebook from 6.4.11 to 6.4.12"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:267
msgid ":pr:`2864`: Updated lockfile"
msgstr ""
#: ../../source/changelog/0.16.0-changelog.rst:271
msgid "New releases"
msgstr ""

View file

@ -11,7 +11,7 @@ msgid "Code of Conduct"
msgstr ""
#: ../../source/conduct.md:7
msgid "TL;DR Be excellent to each other; we're a community after all. If you run into issues with others in our community, please contact a Manim Community Dev, or Moderator."
msgid "TL;DR Be excellent to each other; we're a community after all. If you run into issues with others in our community, please [contact](https://www.manim.community/discord/) a Manim Community Dev, or Moderator."
msgstr ""
#: ../../source/conduct.md:9
@ -31,31 +31,31 @@ msgid "Members of Manim Community are respectful, open, and considerate. Behavio
msgstr ""
#: ../../source/conduct.md:19
msgid "Being respectful. Respectful of others, their positions, experiences, viewpoints, skills, commitments, time, and efforts."
msgid "**Being respectful.** Respectful of others, their positions, experiences, viewpoints, skills, commitments, time, and efforts."
msgstr ""
#: ../../source/conduct.md:21
msgid "Being open. Open to collaboration, whether it's on problems, Pull Requests, issues, or otherwise."
msgid "**Being open.** Open to collaboration, whether it's on problems, Pull Requests, issues, or otherwise."
msgstr ""
#: ../../source/conduct.md:23
msgid "Being considerate. Considerate of their peers -- other Manim users and developers."
msgid "**Being considerate.** Considerate of their peers -- other Manim users and developers."
msgstr ""
#: ../../source/conduct.md:25
msgid "Focusing on what is best for the community. We're respectful of the processes set forth in the community, and we work within them."
msgid "**Focusing on what is best for the community.** We're respectful of the processes set forth in the community, and we work within them."
msgstr ""
#: ../../source/conduct.md:27
msgid "Showing empathy towards other community members. We're attentive in our communications, whether in person or online, and we're tactful when approaching differing views."
msgid "**Showing empathy towards other community members.** We're attentive in our communications, whether in person or online, and we're tactful when approaching differing views."
msgstr ""
#: ../../source/conduct.md:29
msgid "Gracefully accepting constructive criticism. When we disagree, we are courteous in raising our issues."
msgid "**Gracefully accepting constructive criticism.** When we disagree, we are courteous in raising our issues."
msgstr ""
#: ../../source/conduct.md:31
msgid "Using welcoming and inclusive language. We're accepting of all who wish to take part in our activities, fostering an environment where anyone can participate and everyone can make a difference."
msgid "**Using welcoming and inclusive language.** We're accepting of all who wish to take part in our activities, fostering an environment where anyone can participate and everyone can make a difference."
msgstr ""
#: ../../source/conduct.md:35
@ -147,19 +147,19 @@ msgid "This Code of Conduct applies to the following online spaces:"
msgstr ""
#: ../../source/conduct.md:69
msgid "The ManimCommunity GitHub Organization and all of its repositories"
msgid "The [ManimCommunity GitHub Organization](https://github.com/ManimCommunity) and all of its repositories"
msgstr ""
#: ../../source/conduct.md:71
msgid "The Manim Discord"
msgid "The Manim [Discord](https://www.manim.community/discord/)"
msgstr ""
#: ../../source/conduct.md:73
msgid "The Manim Reddit"
msgid "The Manim [Reddit](https://www.reddit.com/r/manim/)"
msgstr ""
#: ../../source/conduct.md:75
msgid "The Manim Twitter"
msgid "The Manim [Twitter](https://twitter.com/manim\\_community/)"
msgstr ""
#: ../../source/conduct.md:77
@ -211,7 +211,7 @@ msgid "Contact Information"
msgstr ""
#: ../../source/conduct.md:107
msgid "If you believe someone is violating the code of conduct, or have any other concerns, please contact a Manim Community Dev, or Moderator immediately. They can be reached on Manim's Community Discord."
msgid "If you believe someone is violating the code of conduct, or have any other concerns, please contact a Manim Community Dev, or Moderator immediately. They can be reached on Manim's Community [Discord](https://www.manim.community/discord/)."
msgstr ""
#: ../../source/conduct.md:117
@ -323,11 +323,11 @@ msgid "Jurisdiction"
msgstr ""
#: ../../source/conduct.md:165
msgid "Is this a Code of Conduct violation? Is this behavior on our list of inappropriate behavior? Is it borderline inappropriate behavior? Does it violate our community norms?"
msgid "*Is this a Code of Conduct violation?* Is this behavior on our list of inappropriate behavior? Is it borderline inappropriate behavior? Does it violate our community norms?"
msgstr ""
#: ../../source/conduct.md:166
msgid "Did this occur in a space that is within our Code of Conduct's scope? If the incident occurred outside the community, but a community member's mental health or physical safety may be negatively impacted if no action is taken, the incident may be in scope. Private conversations in community spaces are also in scope."
msgid "*Did this occur in a space that is within our Code of Conduct's scope?* If the incident occurred outside the community, but a community member's mental health or physical safety may be negatively impacted if no action is taken, the incident may be in scope. Private conversations in community spaces are also in scope."
msgstr ""
#: ../../source/conduct.md:167
@ -335,15 +335,15 @@ msgid "Impact"
msgstr ""
#: ../../source/conduct.md:169
msgid "Did this incident occur in a private conversation or a public space? Incidents that all community members can see will have a more negative impact."
msgid "*Did this incident occur in a private conversation or a public space?* Incidents that all community members can see will have a more negative impact."
msgstr ""
#: ../../source/conduct.md:170
msgid "Does this behavior negatively impact a marginalized group in our community? Is the reporter a person from a marginalized group in our community? How is the reporter being negatively impacted by the reported person's behavior? Are members of the marginalized group likely to disengage with the community if no action was taken on this report?"
msgid "*Does this behavior negatively impact a marginalized group in our community?* Is the reporter a person from a marginalized group in our community? How is the reporter being negatively impacted by the reported person's behavior? Are members of the marginalized group likely to disengage with the community if no action was taken on this report?"
msgstr ""
#: ../../source/conduct.md:171
msgid "Does this incident involve a community leader? Community members often look up to community leaders to set the standard of acceptable behavior"
msgid "*Does this incident involve a community leader?* Community members often look up to community leaders to set the standard of acceptable behavior"
msgstr ""
#: ../../source/conduct.md:172
@ -351,15 +351,15 @@ msgid "Risk"
msgstr ""
#: ../../source/conduct.md:174
msgid "Does this incident include sexual harassment?"
msgid "*Does this incident include sexual harassment?*"
msgstr ""
#: ../../source/conduct.md:175
msgid "Does this pose a safety risk? Does the behavior put a person's physical safety at risk? Will this incident severely negatively impact someone's mental health?"
msgid "*Does this pose a safety risk?* Does the behavior put a person's physical safety at risk? Will this incident severely negatively impact someone's mental health?"
msgstr ""
#: ../../source/conduct.md:176
msgid "Is there a risk of this behavior being repeated? Does the reported person understand why their behavior was inappropriate? Is there an established pattern of behavior from past reports?"
msgid "*Is there a risk of this behavior being repeated?* Does the reported person understand why their behavior was inappropriate? Is there an established pattern of behavior from past reports?"
msgstr ""
#: ../../source/conduct.md:179
@ -479,15 +479,15 @@ msgid "When discussing a change to the Manim Community code of conduct or enforc
msgstr ""
#: ../../source/conduct.md:241
msgid "Brainstorm options. Team members should discuss any relevant context and brainstorm a set of possible options. It is important to provide constructive feedback without getting side-tracked from the main question."
msgid "**Brainstorm options.** Team members should discuss any relevant context and brainstorm a set of possible options. It is important to provide constructive feedback without getting side-tracked from the main question."
msgstr ""
#: ../../source/conduct.md:242
msgid "Vote. Proposed changes to the code of conduct will be decided by a two-thirds majority of all voting members of the Code of Conduct team. Team members are listed in the charter. Currently active voting members are listed in the following section."
msgid "**Vote.** Proposed changes to the code of conduct will be decided by a two-thirds majority of all voting members of the Code of Conduct team. Team members are listed in the charter. Currently active voting members are listed in the following section."
msgstr ""
#: ../../source/conduct.md:243
msgid "Board Vote. Once a working draft is in place for the Code of Conduct and procedures, the Code of Conduct team shall provide the Manim Community Moderators with a draft of the changes. The Manim Community Moderators will vote on the changes at a board meeting."
msgid "**Board Vote.** Once a working draft is in place for the Code of Conduct and procedures, the Code of Conduct team shall provide the Manim Community Moderators with a draft of the changes. The Manim Community Moderators will vote on the changes at a board meeting."
msgstr ""
#: ../../source/conduct.md:246
@ -503,7 +503,7 @@ msgid "License"
msgstr ""
#: ../../source/conduct.md:254
msgid "This Code of Conduct is licensed under the Creative Commons Attribution-ShareAlike 3.0 Unported License."
msgid "This Code of Conduct is licensed under the [Creative Commons Attribution-ShareAlike 3.0 Unported License](https://creativecommons.org/licenses/by-sa/3.0/)."
msgstr ""
#: ../../source/conduct.md:258

View file

@ -11,7 +11,7 @@ msgid "Contributing"
msgstr ""
#: ../../source/contributing.rst:5
msgid "Manim is currently undergoing a major refactor. In general, contributions implementing new features will not be accepted in this period. Other contributions unrelated to cleaning up the codebase may also take a longer period of time to be reviewed. This guide may quickly become outdated quickly; we highly recommend joining our `Discord server <https://www.manim.community/discord/>`_ to discuss any potential contributions and keep up to date with the latest developments."
msgid "Manim is currently undergoing a major refactor. In general, contributions implementing new features will not be accepted in this period. Other contributions unrelated to cleaning up the codebase may also take a longer period of time to be reviewed. This guide may quickly become outdated quickly; we highly recommend joining our `Discord server <https://www.manim.community/discord/>`__ to discuss any potential contributions and keep up to date with the latest developments."
msgstr ""
#: ../../source/contributing.rst:12
@ -50,7 +50,11 @@ msgstr ""
msgid "Translating documentation and docstrings"
msgstr ""
#: ../../source/contributing.rst:31
#: ../../source/contributing.rst:30
msgid "To get an overview of what our community is currently working on, check out `our development project board <https://github.com/orgs/ManimCommunity/projects/7/views/1>`__."
msgstr ""
#: ../../source/contributing.rst:34
msgid "Please ensure that you are reading the latest version of this guide by ensuring that \"latest\" is selected in the version switcher."
msgstr ""

View file

@ -75,202 +75,202 @@ msgid "If you choose to use Poetry as well, follow `Poetry's installation guidel
msgstr ""
#: ../../source/contributing/development.rst:69
msgid "In case you want to install extra dependencies that are defined in the ``[tool.poetry.extras]`` section of ``pyproject.toml``, this can be done by passing the ``-E`` flag, for example ``poetry install -E jupyterlab -E gui``."
msgstr ""
#: ../../source/contributing/development.rst:73
msgid "In case you decided against Poetry, you can install Manim via pip by running ``python3 -m pip install .``. Note that due to our development infrastructure being based on Poetry, we currently do not support editable installs via ``pip``, so you will have to re-run this command every time you make changes to the source code."
msgstr ""
#: ../../source/contributing/development.rst:78
#: ../../source/contributing/development.rst:82
msgid "The following steps assume that you chose to install and work with Poetry."
msgstr ""
#: ../../source/contributing/development.rst:81
#: ../../source/contributing/development.rst:85
msgid "Install Pre-Commit:"
msgstr ""
#: ../../source/contributing/development.rst:87
#: ../../source/contributing/development.rst:91
msgid "This will ensure during development that each of your commits is properly formatted against our linter and formatters, ``black``, ``flake8``, ``isort`` and ``codespell``."
msgstr ""
#: ../../source/contributing/development.rst:91
#: ../../source/contributing/development.rst:95
msgid "You are now ready to work on manim!"
msgstr ""
#: ../../source/contributing/development.rst:94
#: ../../source/contributing/development.rst:98
msgid "Develop your contribution"
msgstr ""
#: ../../source/contributing/development.rst:96
#: ../../source/contributing/development.rst:100
msgid "Checkout your local repository's main branch and pull the latest changes from ManimCommunity, ``upstream``, into your local repository:"
msgstr ""
#: ../../source/contributing/development.rst:104
#: ../../source/contributing/development.rst:108
msgid "Create a branch for the changes you want to work on rather than working off of your local main branch:"
msgstr ""
#: ../../source/contributing/development.rst:111
#: ../../source/contributing/development.rst:115
msgid "This ensures you can easily update your local repository's main with the first step and switch branches to work on multiple features."
msgstr ""
#: ../../source/contributing/development.rst:114
#: ../../source/contributing/development.rst:118
msgid "Write some awesome code!"
msgstr ""
#: ../../source/contributing/development.rst:116
#: ../../source/contributing/development.rst:120
msgid "You're ready to make changes in your local repository's branch. You can add local files you've changed within the current directory with ``git add .``, or add specific files with"
msgstr ""
#: ../../source/contributing/development.rst:124
#: ../../source/contributing/development.rst:128
msgid "and commit these changes to your local history with ``git commit``. If you have installed pre-commit, your commit will succeed only if none of the hooks fail."
msgstr ""
#: ../../source/contributing/development.rst:130
#: ../../source/contributing/development.rst:134
msgid "When crafting commit messages, it is highly recommended that you adhere to `these guidelines <https://www.conventionalcommits.org/en/v1.0.0/>`_."
msgstr ""
#: ../../source/contributing/development.rst:133
#: ../../source/contributing/development.rst:137
msgid "Add new or update existing tests."
msgstr ""
#: ../../source/contributing/development.rst:135
#: ../../source/contributing/development.rst:139
msgid "Depending on your changes, you may need to update or add new tests. For new features, it is required that you include tests with your PR. Details of our testing system are explained in the :doc:`testing guide <testing>`."
msgstr ""
#: ../../source/contributing/development.rst:140
#: ../../source/contributing/development.rst:144
msgid "Update docstrings and documentation:"
msgstr ""
#: ../../source/contributing/development.rst:142
#: ../../source/contributing/development.rst:146
msgid "Update the docstrings (the text in triple quotation marks) of any functions or classes you change and include them with any new functions you add. See the :doc:`documentation guide <docstrings>` for more information about how we prefer our code to be documented. The content of the docstrings will be rendered in the :doc:`reference manual <../reference>`."
msgstr ""
#: ../../source/contributing/development.rst:150
#: ../../source/contributing/development.rst:154
msgid "Use the :mod:`manim directive for Sphinx <manim.utils.docbuild.manim_directive>` to add examples to the documentation!"
msgstr ""
#: ../../source/contributing/development.rst:156:<autosummary>:1
msgid "A directive for including Manim videos in a Sphinx document"
msgstr ""
#: ../../source/contributing/development.rst:158
#: ../../source/contributing/development.rst:157
msgid "As far as development on your local machine goes, these are the main steps you should follow."
msgstr ""
#: ../../source/contributing/development.rst:162
#: ../../source/contributing/development.rst:161
msgid "Polishing Changes and Submitting a Pull Request"
msgstr ""
#: ../../source/contributing/development.rst:164
#: ../../source/contributing/development.rst:163
msgid "As soon as you are ready to share your local changes with the community so that they can be discussed, go through the following steps to open a pull request. A pull request signifies to the ManimCommunity organization, \"Here are some changes I wrote; I think it's worthwhile for you to maintain them.\""
msgstr ""
#: ../../source/contributing/development.rst:172
#: ../../source/contributing/development.rst:171
msgid "You do not need to have everything (code/documentation/tests) complete to open a pull request (PR). If the PR is still under development, please mark it as a draft. Community developers will still be able to review the changes, discuss yet-to-be-implemented changes, and offer advice; however, the more complete your PR, the quicker it will be merged."
msgstr ""
#: ../../source/contributing/development.rst:178
#: ../../source/contributing/development.rst:177
msgid "Update your fork on GitHub to reflect your local changes:"
msgstr ""
#: ../../source/contributing/development.rst:184
#: ../../source/contributing/development.rst:183
msgid "Doing so creates a new branch on your remote fork, ``origin``, with the contents of your local repository on GitHub. In subsequent pushes, this local branch will track the branch ``origin`` and ``git push`` is enough."
msgstr ""
#: ../../source/contributing/development.rst:189
#: ../../source/contributing/development.rst:188
msgid "Make a pull request (PR) on GitHub."
msgstr ""
#: ../../source/contributing/development.rst:191
#: ../../source/contributing/development.rst:190
msgid "In order to make the ManimCommunity development team aware of your changes, you can make a PR to the ManimCommunity repository from your fork."
msgstr ""
#: ../../source/contributing/development.rst:196
#: ../../source/contributing/development.rst:195
msgid "Make sure to select ``ManimCommunity/manim`` instead of ``3b1b/manim`` as the base repository!"
msgstr ""
#: ../../source/contributing/development.rst:199
#: ../../source/contributing/development.rst:198
msgid "Choose the branch from your fork as the head repository - see the screenshot below."
msgstr ""
#: ../../source/contributing/development.rst:205
#: ../../source/contributing/development.rst:204
msgid "Please make sure you follow the template (this is the default text you are shown when first opening the 'New Pull Request' page)."
msgstr ""
#: ../../source/contributing/development.rst:209
#: ../../source/contributing/development.rst:208
msgid "Your changes are eligible to be merged if:"
msgstr ""
#: ../../source/contributing/development.rst:211
#: ../../source/contributing/development.rst:210
msgid "there are no merge conflicts"
msgstr ""
#: ../../source/contributing/development.rst:212
#: ../../source/contributing/development.rst:211
msgid "the tests in our pipeline pass"
msgstr ""
#: ../../source/contributing/development.rst:213
#: ../../source/contributing/development.rst:212
msgid "at least one (two for more complex changes) Community Developer approves the changes"
msgstr ""
#: ../../source/contributing/development.rst:215
#: ../../source/contributing/development.rst:214
msgid "You can check for merge conflicts between the current upstream/main and your branch by executing ``git pull upstream main`` locally. If this generates any merge conflicts, you need to resolve them and push an updated version of the branch to your fork of the repository."
msgstr ""
#: ../../source/contributing/development.rst:220
#: ../../source/contributing/development.rst:219
msgid "Our pipeline consists of a series of different tests that ensure that manim still works as intended and that the code you added sticks to our coding conventions."
msgstr ""
#: ../../source/contributing/development.rst:224
#: ../../source/contributing/development.rst:223
msgid "**Code style**: We use the code style imposed by `Black <https://black.readthedocs.io/en/stable/>`_, `isort <https://pycqa.github.io/isort/>`_ and `flake8 <https://flake8.pycqa.org/en/latest/>`_. The GitHub pipeline makes sure that the (Python) files changed in your pull request also adhere to this code style. If this step of the pipeline fails, fix your code formatting automatically by running ``black <file or directory>`` and ``isort <file or directory>``. To fix code style problems, run ``flake8 <file or directory>`` for a style report, and then fix the problems manually that were detected by ``flake8``."
msgstr ""
#: ../../source/contributing/development.rst:233
#: ../../source/contributing/development.rst:232
msgid "**Tests**: The pipeline runs manim's test suite on different operating systems (the latest versions of Ubuntu, MacOS, and Windows) for different versions of Python. The test suite consists of two different kinds of tests: integration tests and doctests. You can run them locally by executing ``poetry run pytest`` and ``poetry run pytest --doctest-modules manim``, respectively, from the root directory of your cloned fork."
msgstr ""
#: ../../source/contributing/development.rst:240
#: ../../source/contributing/development.rst:239
msgid "**Documentation**: We also build a version of the documentation corresponding to your pull request. Make sure not to introduce any Sphinx errors, and have a look at the built HTML files to see whether the formatting of the documentation you added looks as you intended. You can build the documentation locally by running ``make html`` from the ``docs`` directory. Since the inheritance diagrams require you to have `Graphviz <https://graphviz.org/>`_ installed locally."
msgstr ""
#: ../../source/contributing/development.rst:247
#: ../../source/contributing/development.rst:246
msgid "Finally, if the pipeline passes and you are satisfied with your changes: wait for feedback and iterate over any requested changes. You will likely be asked to edit or modify your PR in one way or another during this process. This is not an indictment of your work, but rather a strong signal that the community wants to merge your changes! Once approved, your changes may be merged!"
msgstr ""
#: ../../source/contributing/development.rst:254
#: ../../source/contributing/development.rst:253
msgid "Further useful guidelines"
msgstr ""
#: ../../source/contributing/development.rst:256
#: ../../source/contributing/development.rst:255
msgid "When submitting a PR, please mention explicitly if it includes breaking changes."
msgstr ""
#: ../../source/contributing/development.rst:258
#: ../../source/contributing/development.rst:257
msgid "When submitting a PR, make sure that your proposed changes are as general as possible, and ready to be taken advantage of by all of manim's users. In particular, leave out any machine-specific configurations, or any personal information it may contain."
msgstr ""
#: ../../source/contributing/development.rst:263
#: ../../source/contributing/development.rst:262
msgid "If you are a maintainer, please label issues and PRs appropriately and frequently."
msgstr ""
#: ../../source/contributing/development.rst:266
#: ../../source/contributing/development.rst:265
msgid "When opening a new issue, if there are old issues that are related, add a link to them in your new issue (even if the old ones are closed)."
msgstr ""
#: ../../source/contributing/development.rst:269
#: ../../source/contributing/development.rst:268
msgid "When submitting a code review, it is highly recommended that you adhere to `these general guidelines <https://conventionalcomments.org/>`_."
msgstr ""
#: ../../source/contributing/development.rst:272
#: ../../source/contributing/development.rst:271
msgid "If you find stale or inactive issues that seem to be irrelevant, please post a comment saying 'This issue should be closed', and a community developer will take a look."
msgstr ""
#: ../../source/contributing/development.rst:276
#: ../../source/contributing/development.rst:275
msgid "Please do as much as possible to keep issues, PRs, and development in general as tidy as possible."
msgstr ""
#: ../../source/contributing/development.rst:280
msgid "You can find examples for the ``docs`` in several places: the :doc:`Example Gallery <../examples>`, :doc:`Tutorials <../tutorials>`, and :doc:`Reference Classes <../reference>`."
#: ../../source/contributing/development.rst:279
msgid "You can find examples for the ``docs`` in several places: the :doc:`Example Gallery <../examples>`, :doc:`Tutorials <../tutorials/index>`, and :doc:`Reference Classes <../reference>`."
msgstr ""
#: ../../source/contributing/development.rst:284
#: ../../source/contributing/development.rst:283
msgid "In case you are contributing, please have a look at this flowchart:"
msgstr ""

View file

@ -42,7 +42,7 @@ msgstr ""
msgid "Plotting with Manim"
msgstr ""
#: ../../source/examples.rst:438
#: ../../source/examples.rst:496
msgid "Special Camera Settings"
msgstr ""

View file

@ -0,0 +1,181 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/faq/general.md:1
msgid "FAQ: General Usage"
msgstr ""
#: ../../source/faq/general.md:3
msgid "Why does Manim say that \"there are no scenes inside that module\"?"
msgstr ""
#: ../../source/faq/general.md:5
msgid "There are two main reasons why this error appears: if you have edited the file containing your `Scene` class and forgot to save it, or if you have accidentally passed the name of a wrong file to `manim`, this is a likely outcome. Check that you have spelled everything correctly."
msgstr ""
#: ../../source/faq/general.md:10
msgid "Otherwise you are likely mixing up Manim versions. See {ref}`this FAQ answer <different-versions>` for an explanation regarding why there are different versions. Under the assumption that you are trying to use the `manim` executable from the terminal to run a scene that has been written for the community version (i.e., there is `from manim import *`, or more specifically `from manim import Scene`)"
msgstr ""
#: ../../source/faq/general.md:18
msgid "No matter what code I put in my file, Manim only renders a black frame! Why?"
msgstr ""
#: ../../source/faq/general.md:20
msgid "If you are using the usual pattern to write a `Scene`, i.e.,"
msgstr ""
#: ../../source/faq/general.md:27
msgid "then double check whether you have spelled `construct` correctly. If the method containing your code is not called `construct` (or if you are not calling a different, custom method from `construct`), Manim will not call your method and simply output a black frame."
msgstr ""
#: ../../source/faq/general.md:34
msgid "What are the default measurements for Manim's scene?"
msgstr ""
#: ../../source/faq/general.md:36
msgid "The scene measures 8 units in height and has a default ratio of 16:9, which means that it measures {math}`8 \\cdot 16 / 9 = 14 + 2/9` units in width. The origin is in the center of the scene, which means that, for example, the upper left corner of the scene has coordinates `[-7-1/9, 4, 0]`."
msgstr ""
#: ../../source/faq/general.md:43
msgid "How do I find out which keyword arguments I can pass when creating a `Mobject`?"
msgstr ""
#: ../../source/faq/general.md:45
msgid "Let us consider some specific example, like the {class}`.Circle` class. When looking at its documentation page, only two specific keyword arguments are listed (`radius`, and `color`). Besides these concrete arguments, there is also a catchall `**kwargs` argument which captures all other arguments that are passed to `Circle`, and passes them on to the base class of {class}`.Circle`, {class}`.Arc`."
msgstr ""
#: ../../source/faq/general.md:51
msgid "The same holds for {class}`.Arc`: some arguments are explicitly documented, and there is again a catchall `**kwargs` argument that passes unprocessed arguments to the next base class -- and so on."
msgstr ""
#: ../../source/faq/general.md:55
msgid "The most important keyword arguments relevant to styling your mobjects are the ones that are documented for the base classes {class}`.VMobject` and {class}`.Mobject`."
msgstr ""
#: ../../source/faq/general.md:61
msgid "Can Manim render a video with transparent background?"
msgstr ""
#: ../../source/faq/general.md:63
msgid "Yes: simply pass the CLI flag `-t` (or its long form `--transparent`). Note that the default video file format does not support transparency, which is why Manim will output a `.mov` instead of a `.mp4` when rendering with a transparent background. Other movie file formats that support transparency can be obtained by passing `--format=webm` or `--format=gif`."
msgstr ""
#: ../../source/faq/general.md:72
msgid "I have watched a video where a creator ran command X, but it does not work for me. Why?"
msgstr ""
#: ../../source/faq/general.md:74
msgid "The video you have been watching is likely outdated. If you want to follow along, you either need to use the same version used in the video, or modify the code (in many cases it is just a method having been renamed etc.) accordingly. Check the video description, in some cases creators point out whether changes need to be applied to the code shown in the video."
msgstr ""
#: ../../source/faq/general.md:82
msgid "When using `Tex` or `MathTex`, some letters are missing. How can I fix this?"
msgstr ""
#: ../../source/faq/general.md:84
msgid "It is possible that you have to (re)build some fonts used by LaTeX. For some distributions, you can do this manually by running"
msgstr ""
#: ../../source/faq/general.md:89
msgid "We recommend consulting the documentation of your LaTeX distribution for more information."
msgstr ""
#: ../../source/faq/general.md:94
msgid "I want to translate some code from `manimgl` to `manim`, what do I do with `CONFIG` dictionaries?"
msgstr ""
#: ../../source/faq/general.md:96
msgid "The community maintained version has dropped the use of `CONFIG` dictionaries very early, with {doc}`version v0.2.0 </changelog/0.2.0-changelog>` released in January 2021."
msgstr ""
#: ../../source/faq/general.md:100
msgid "Before that, Manim's classes basically processed `CONFIG` dictionaries by mimicking inheritance (to properly process `CONFIG` dictionaries set by parent classes) and then assigning all of the key-value-pairs in the dictionary as attributes of the corresponding object."
msgstr ""
#: ../../source/faq/general.md:105
msgid "In situations where there is not much inheritance going on, or for any custom setting, you should set these attributes yourself. For example, for an old-style `Scene` with custom attributes like"
msgstr ""
#: ../../source/faq/general.md:114
msgid "should be written as"
msgstr ""
#: ../../source/faq/general.md:122
msgid "In situations where values should be properly inherited, the arguments should be added to the initialization function of the class. An old-style mobject `Thing` could look like"
msgstr ""
#: ../../source/faq/general.md:135
msgid "where `stroke_color` and `fill_opacity` are arguments that concern the parent class of `Thing`, and `my_awesome_argument` is a custom argument that only concerns `Thing`. A version without `CONFIG` could look like this:"
msgstr ""
#: ../../source/faq/general.md:150
msgid "My installation does not support converting PDF to SVG, help?"
msgstr ""
#: ../../source/faq/general.md:152
msgid "This is an issue with `dvisvgm`, the tool shipped with LaTeX that transforms LaTeX output to a `.svg` file that Manim can parse."
msgstr ""
#: ../../source/faq/general.md:156
msgid "First, make sure your ``dvisvgm`` version is at least 2.4 by checking the output of"
msgstr ""
#: ../../source/faq/general.md:163
msgid "If you do not know how to update `dvisvgm`, please refer to your LaTeX distributions documentation (or the documentation of your operating system, if `dvisvgm` was installed as a system package)."
msgstr ""
#: ../../source/faq/general.md:167
msgid "Second, check whether your ``dvisvgm`` supports PostScript specials. This is needed to convert from PDF to SVG. Run:"
msgstr ""
#: ../../source/faq/general.md:174
msgid "If the output to this command does **not** contain `ps dvips PostScript specials`, this is a bad sign. In this case, run"
msgstr ""
#: ../../source/faq/general.md:181
msgid "If the output does **not** contain `--libgs=filename`, this means your `dvisvgm` does not currently support PostScript. You must get another binary."
msgstr ""
#: ../../source/faq/general.md:184
msgid "If, however, `--libgs=filename` appears in the help, that means that your `dvisvgm` needs the Ghostscript library to support PostScript. Search for `libgs.so` (on Linux, probably in `/usr/local/lib` or `/usr/lib`) or `gsdll32.dll` (on 32-bit Windows, probably in `C:\\windows\\system32`) or `gsdll64.dll` (on 64-bit Windows, also probably in `C:\\windows\\system32`) or `libgsl.dylib` (on MacOS, probably in `/usr/local/lib` or `/opt/local/lib`). Please look carefully, as the file might be located elsewhere, e.g. in the directory where Ghostscript is installed."
msgstr ""
#: ../../source/faq/general.md:193
msgid "When you have found the library, try (on MacOS or Linux)"
msgstr ""
#: ../../source/faq/general.md:200
msgid "or (on Windows)"
msgstr ""
#: ../../source/faq/general.md:207
msgid "You should now see `ps dvips PostScript specials` in the output. Refer to your operating system's documentation to find out how you can set or export the environment variable ``LIBGS`` automatically whenever you open a shell."
msgstr ""
#: ../../source/faq/general.md:211
msgid "As a last check, you can run"
msgstr ""
#: ../../source/faq/general.md:217
msgid "(while still having `LIBGS` set to the correct path, of course.) If `dvisvgm` can find your Ghostscript installation, it will be shown in the output together with the version number."
msgstr ""
#: ../../source/faq/general.md:221
msgid "If you do not have the necessary library on your system, please refer to your operating system's documentation to find out where you can get it and how you have to install it."
msgstr ""
#: ../../source/faq/general.md:225
msgid "If you are unable to solve your problem, check out the [dvisvgm FAQ](https://dvisvgm.de/FAQ/)."
msgstr ""
#: ../../source/faq/general.md:230
msgid "Where can I find more resources for learning Manim?"
msgstr ""

View file

@ -0,0 +1,105 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/faq/help.md:1
msgid "FAQ: Getting Help"
msgstr ""
#: ../../source/faq/help.md:3
msgid "How do I animate X? Why do I get error Y? Can someone help me?"
msgstr ""
#: ../../source/faq/help.md:5
msgid "Before asking the community, please make sure that the issue you are having is not already discussed in our {doc}`FAQ section </faq/index>` sufficiently well so that you can resolve the problem yourself. You can also try to use your favorite search engine, if you are lucky you might find a blog post, a question on [StackOverflow](https://stackoverflow.com/questions/tagged/manim), or a post in the [r/manim subreddit](https://reddit.com/r/manim)."
msgstr ""
#: ../../source/faq/help.md:12
msgid "If this is not the case, please take a moment to properly prepare your question: the better you manage to explain what exactly it is you are struggling with, the more efficient people will be able to help you. Regardless of the platform you choose in the next step, StackOverflow has a good guide on [asking good questions](https://stackoverflow.com/help/how-to-ask)."
msgstr ""
#: ../../source/faq/help.md:18
msgid "As soon as you have a good idea of what exactly you want to ask, pick one of the following communication channels:"
msgstr ""
#: ../../source/faq/help.md:21
msgid "The community is most active [in our Discord server](https://manim.community/discord/). Click the link to join, then pick one of the `#manim-help` channels in the sidebar, and post your question there. If you are comfortable with using Discord, try to search for your problem using the search function of our server; perhaps people have been talking about it before!"
msgstr ""
#: ../../source/faq/help.md:26
msgid "We are also monitoring questions on [StackOverflow](https://stackoverflow.com/questions/tagged/manim) that are tagged with `manim`."
msgstr ""
#: ../../source/faq/help.md:29
msgid "Many people are also active in our [r/manim subreddit](https://reddit.com/r/manim), feel free to post there if you are an avid Redditor -- but be aware that Discord or StackOverflow might be better choices."
msgstr ""
#: ../../source/faq/help.md:32
msgid "And finally, you can also start a new [discussion on GitHub](https://github.com/ManimCommunity/manim/discussions) if you dislike all other options."
msgstr ""
#: ../../source/faq/help.md:35
msgid "In all of these channels, please make sure to abide by Manim's {doc}`Code of Conduct </conduct>` -- in short, be *excellent* to one another: be friendly and patient, considerate, and respectful."
msgstr ""
#: ../../source/faq/help.md:41
msgid "What should I do if nobody answers my question?"
msgstr ""
#: ../../source/faq/help.md:43
msgid "Try and see whether your question can be improved: did you include all relevant information (in case of errors: the full stack trace, the code that you were rendering, and the command you used to run Manim?). In case you used a very long example, is it possible to construct a more minimal version that has the same (faulty) behavior?"
msgstr ""
#: ../../source/faq/help.md:49
msgid "If you posted in one of our help channels on Discord and your question got buried, you are allowed to ping the `@Manim Helper` role to bring it to the attention of the volunteers who are willing to take a look. Please refrain from pinging the role immediately when asking your question for the first time, this is considered impolite."
msgstr ""
#: ../../source/faq/help.md:54
msgid "You can also try to post your question to a different channel if you feel that you are not having any success with your initial choice -- but please do not spam your question in all of our communication channels (and in particular for Discord: please don't use multiple help channels at once)."
msgstr ""
#: ../../source/faq/help.md:59
msgid "In the end, it is as for most open-source projects: our community members are volunteers. If you do not receive a quick answer to your question, it may be because nobody knows the answer, or because your question is not clear enough, or it could be that everyone who can help you with your problem is busy doing other things."
msgstr ""
#: ../../source/faq/help.md:67
msgid "The library does not behave as documented, or something broke in a new release. What should I do?"
msgstr ""
#: ../../source/faq/help.md:69
msgid "Sounds like you have found a bug. One of the best ways of contributing to the development of Manim is by reporting it!"
msgstr ""
#: ../../source/faq/help.md:72
msgid "Check our list of known issues and feature requests [in our GitHub repository](https://github.com/ManimCommunity/manim/issues). If the problem you have found is not listed there yet (use the search function; also check whether there is a corresponding closed issue, it is possible that your problem has already been resolved and will be fixed with the next release), please consider the following steps to submit a new issue."
msgstr ""
#: ../../source/faq/help.md:80
msgid "If you are unsure whether or not you should file a new issue for some odd behavior that you found, feel free to ask the community developers, preferably in one of our `#manim-dev` channels in [our Discord](https://manim.community/discord/)."
msgstr ""
#: ../../source/faq/help.md:85
msgid "Make sure you are running the latest released version of Manim, your problem might otherwise already be fixed in a more recent version. Check the {doc}`/changelog` for a full list of changes between Manim releases."
msgstr ""
#: ../../source/faq/help.md:89
msgid "Choose the correct category for your report when [creating a new issue](https://github.com/ManimCommunity/manim/issues/new/choose). We have dedicated issue templates for *bug reports*, *feature requests*, and *installation issues*. If your report falls into one of these categories, read the issue template carefully! Instructions are given in the `<!-- ... -->` sections of the text field. If you want to suggest a new feature without concrete implementation details, see {ref}`the instructions given in this answer <creating-suggestions>`."
msgstr ""
#: ../../source/faq/help.md:98
msgid "For bug reports: prepare a minimal example that can be used to illustrate the issue. Examples with hundreds of lines are very inefficient and tedious to debug. Your problem needs to be reproducible for others, so please make sure to prepare a suitable example."
msgstr ""
#: ../../source/faq/help.md:103
msgid "This is mentioned in the bug report template as well, but it is very important: if you report that some code raises an error, make sure to include the full terminal output, from the command you used to run the library up to and including the last line with the error message. Read carefully: if the message mentions that there is another relevant log file, include this other file as well!"
msgstr ""
#: ../../source/faq/help.md:112
msgid "I have an idea for a really cool feature that should be implemented, where should I share my idea?"
msgstr ""

View file

@ -0,0 +1,14 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/faq/index.rst:4
#: ../../source/faq/index.rst:4
msgid "Table of Contents"
msgstr ""

View file

@ -0,0 +1,165 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/faq/installation.md:1
msgid "FAQ: Installation"
msgstr ""
#: ../../source/faq/installation.md:4
msgid "Why are there different versions of Manim?"
msgstr ""
#: ../../source/faq/installation.md:6
msgid "Manim was originally created by Grant Sanderson as a personal project and for use in his YouTube channel, [3Blue1Brown](https://www.youtube.com/channel/UCYO_jab_esuFRV4b17AJtAw). As his channel gained popularity, many grew to like the style of his animations and wanted to use manim for their own projects. However, as manim was only intended for personal use, it was very difficult for other users to install and use it."
msgstr ""
#: ../../source/faq/installation.md:13
msgid "In late 2019, Grant started working on faster OpenGL rendering in a new branch, known as the `shaders` branch. In mid-2020, a group of developers forked it into what is now the community edition; this is the version documented on this website. In early 2021, Grant merged the shaders branch back into master, making it the default branch in his repository -- and this is what `manimgl` is. The old version, before merging the `shaders` branch is sometimes referred to as `ManimCairo` and is, at this point, only useful for one singular purpose: rendering Grant's old videos locally on your machine. It is still available in his GitHub repository in form of the `cairo-backend` branch."
msgstr ""
#: ../../source/faq/installation.md:22
msgid "To summarize:"
msgstr ""
#: ../../source/faq/installation.md:23
msgid "[**Manim**, or **ManimCE**](https://manim.community) refers to the community maintained version of the library. This is the version documented on this website; the package name on PyPI is [`manim`](https://pypi.org/project/manim/)."
msgstr ""
#: ../../source/faq/installation.md:26
msgid "[ManimGL](https://github.com/3b1b/manim) is the latest released version of the version of the library developed by Grant \"3b1b\" Sanderson. It has more experimental features and breaking changes between versions are not documented. Check out its documentation [here](https://3b1b.github.io/manim/index.html); on PyPI the package name is [`manimgl`](https://pypi.org/project/manimgl/)."
msgstr ""
#: ../../source/faq/installation.md:31
msgid "[ManimCairo](https://github.com/3b1b/manim/tree/cairo-backend) is the name that is sometimes used for the old, pre-OpenGL version of `manimgl`. The latest version of it is available [on PyPI as `manimlib`](https://pypi.org/project/manimgl/), but note that if you intend to use it to compile some old project of Grant, you will likely have to install the exact version from the time the project was created from source."
msgstr ""
#: ../../source/faq/installation.md:40
msgid "Which version should I use?"
msgstr ""
#: ../../source/faq/installation.md:42
msgid "We recommend the community maintained version especially for beginners. It has been developed to be more stable, better tested and documented (!), and quicker to respond to community contributions. It is also perfectly reasonable to start learning with the community maintained version and then switch to a different version later on."
msgstr ""
#: ../../source/faq/installation.md:47
msgid "If you do not care so much about documentation or stability, and would like to use the exact same version that Grant is using, then use ManimGL."
msgstr ""
#: ../../source/faq/installation.md:50
msgid "And as mentioned above, ManimCairo should only be used for (re)rendering old 3Blue1Brown projects (basically 2019 and before)."
msgstr ""
#: ../../source/faq/installation.md:55
msgid "What are the differences between Manim, ManimGL, ManimCairo? Can I tell for which version a scene was written for?"
msgstr ""
#: ../../source/faq/installation.md:57
msgid "You can! The thing that usually gives it away is the `import` statement at the top of the file; depending on how the code imports Manim you can tell for which version of the code it was written for:"
msgstr ""
#: ../../source/faq/installation.md:61
msgid "If the code imports from `manim` (i.e., `from manim import *`, `import manim as mn`, etc.), then the code you are reading is supposed to be run with the community maintained version."
msgstr ""
#: ../../source/faq/installation.md:63
msgid "If the import reads `import manimlib` (or `from manimlib import *`), you are likely reading a file to be rendered with ManimGL."
msgstr ""
#: ../../source/faq/installation.md:65
msgid "And if the import reads `from manimlib.imports import *`, or perhaps even `from big_ol_pile_of_manim_imports import *` you are reading a snippet that is supposed to be rendered with an early, or very early version of ManimCairo, respectively."
msgstr ""
#: ../../source/faq/installation.md:71
msgid "How do I know which version of Manim I have installed?"
msgstr ""
#: ../../source/faq/installation.md:73
msgid "Assuming you can run `manim` in your terminal and there is some output, check the first line of the text being produced. If you are using the community maintained version, the first line of any output will be `Manim Community <version number>`. If it does not say that, you are likely using ManimGL."
msgstr ""
#: ../../source/faq/installation.md:78
msgid "You can also check the list of packages you have installed: if typing `python` in your terminal spawns the interpreter that corresponds to the Python installation you use (might also be `py`, or `python3`, depending on your operating system), running `python -m pip list` will print a list of all installed packages. Check whether `manim` or `manimgl` appear in that list."
msgstr ""
#: ../../source/faq/installation.md:84
msgid "Similarly, you can use `python -m pip install <package name>` and `python -m pip uninstall <package name>` to install and uninstall packages from that list, respectively."
msgstr ""
#: ../../source/faq/installation.md:90
msgid "I am following the video guide X to install Manim, but some step fails. What do I do?"
msgstr ""
#: ../../source/faq/installation.md:92
msgid "It is only natural that there are many video guides on installing Manim out there, given that Manim is a library used for creating videos. Unfortunately however, (YouTube) videos can't be updated easily (without uploading a new one, that is) when some step in the installation process changes, and so there are many **severely outdated** resources out there."
msgstr ""
#: ../../source/faq/installation.md:98
msgid "This is why we strongly recommend following our {doc}`written installation guide </installation>` to guide you through the process. In case you prefer using a video guide regardless, please check whether the creator whose guide you have been watching has made a more recent version available, and otherwise please contact them directly. Asking for help in the community will likely lead to being suggested to follow our written guide."
msgstr ""
#: ../../source/faq/installation.md:107
msgid "Why does ManimPango fail to install when running `pip install manim`?"
msgstr ""
#: ../../source/faq/installation.md:109
msgid "This most likely means that pip was not able to use our pre-built wheels of the `manimpango` dependency. Let us know (via [Discord](https://www.manim.community/discord/) or by opening a [new issue on GitHub](https://github.com/ManimCommunity/ManimPango/issues/new)) which architecture you would like to see supported, and we'll see what we can do about it."
msgstr ""
#: ../../source/faq/installation.md:116
msgid "To fix errors when installing `manimpango`, you need to make sure you have all the necessary build requirements. Check out the detailed instructions given in [the BUILDING section](https://github.com/ManimCommunity/ManimPango#BUILDING) of [ManimPango's README](https://github.com/ManimCommunity/ManimPango)."
msgstr ""
#: ../../source/faq/installation.md:123
msgid "I am using Windows and get the error `X is not recognized as an internal or external command, operable program or batch file`"
msgstr ""
#: ../../source/faq/installation.md:125
msgid "Regardless of whether `X` says `python` or `manim`, this means that the executable you are trying to run is not located in one of the directories your system is looking for them (specified by the `PATH` variable). Take a look at the instructions {doc}`in the installation guide for Windows </installation/windows>`, or [this StackExchange answer](https://superuser.com/questions/143119/how-do-i-add-python-to-the-windows-path/143121#143121) to get help with editing the `PATH` variable manually."
msgstr ""
#: ../../source/faq/installation.md:132
msgid "If `python` is recognized but not `manim` or `pip`, you can try running commands by prepending `python -m`. That is, `manim` becomes `python -m manim`, and `pip` becomes `python -m pip`."
msgstr ""
#: ../../source/faq/installation.md:138
msgid "I have tried using Chocolatey (`choco install manimce`) to install Manim, but it failed!"
msgstr ""
#: ../../source/faq/installation.md:140
msgid "Make sure that you were running the command with administrator permissions, otherwise there can be problems. If this is not the issue, read Chocolatey's output carefully, it should mention a `.log` file containing information why the process failed."
msgstr ""
#: ../../source/faq/installation.md:145
msgid "You are welcome to take this file (and any other input you feel might be relevant) and submit it to Manim's community to ask for help with your problem. See the {doc}`FAQ on getting help </faq/help>` for instructions."
msgstr ""
#: ../../source/faq/installation.md:151
msgid "On Windows, when typing `python` or `python3` the Windows store is opened, can I fix this?"
msgstr ""
#: ../../source/faq/installation.md:153
msgid "Yes: you can remove these aliases with these steps:"
msgstr ""
#: ../../source/faq/installation.md:155
msgid "Go to the Windows Setting."
msgstr ""
#: ../../source/faq/installation.md:156
msgid "Under *Apps and Features* you will find application execution aliases."
msgstr ""
#: ../../source/faq/installation.md:157
msgid "Within this menu, disable the alias(es) that are causing the issue (`python` and/or `python3`)."
msgstr ""
#: ../../source/faq/installation.md:162
msgid "I am using Anaconda and get an `ImportError` mentioning that some Symbol is not found."
msgstr ""

View file

@ -0,0 +1,17 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/faq/internals.md:1
msgid "Where can I learn more about Manim's internal structure?"
msgstr ""
#: ../../source/faq/internals.md:3
msgid "Efforts to document the internal structure of Manim is ongoing on our [wiki](https://github.com/ManimCommunity/manim/wiki/Developer-documentation-(WIP))."
msgstr ""

View file

@ -0,0 +1,29 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/faq/opengl.md:1
msgid "FAQ: OpenGL rendering"
msgstr ""
#: ../../source/faq/opengl.md:3
msgid "Are there any resources on how the OpenGL renderer in the community maintained version can be used?"
msgstr ""
#: ../../source/faq/opengl.md:5
msgid "Yes. Unfortunately, at this point, the official online documentation does not contain the relevant base classes like `OpenGLMobject` and `OpenGLVMobject` or specific OpenGL classes like `OpenGLSurface`, but documentation for some of them is available in form of docstrings [in the source code](https://github.com/ManimCommunity/manim/tree/main/manim/mobject/opengl)."
msgstr ""
#: ../../source/faq/opengl.md:11
msgid "Furthermore, [this user guide by *aquabeam*](https://www.aquabeam.me/manim/opengl_guide/) can be helpful to get started using the OpenGL renderer."
msgstr ""
#: ../../source/faq/opengl.md:16
msgid "I am trying to run an interactive scene with `--renderer=opengl` and `Scene.interactive_embed`, but an error (`sqlite3.ProgrammingError`) is raised. How can I fix this?"
msgstr ""

View file

@ -0,0 +1,313 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/guides/configuration.rst:2
msgid "Configuration"
msgstr ""
#: ../../source/guides/configuration.rst:4
msgid "Manim provides an extensive configuration system that allows it to adapt to many different use cases. There are many configuration options that can be configured at different times during the scene rendering process. Each option can be configured programmatically via `the ManimConfig class`_, at the time of command invocation via `command-line arguments`_, or at the time the library is first imported via `the config files`_."
msgstr ""
#: ../../source/guides/configuration.rst:11
msgid "The most common, simplest, and recommended way to configure Manim is via the command-line interface (CLI), which is described directly below."
msgstr ""
#: ../../source/guides/configuration.rst:15
msgid "Command-line arguments"
msgstr ""
#: ../../source/guides/configuration.rst:17
msgid "By far the most commonly used command in the CLI is the ``render`` command, which is used to render scene(s) to an output file. It is used with the following arguments:"
msgstr ""
#: ../../source/guides/configuration.rst:24
msgid "However, since Manim defaults to the :code:`render` command whenever no command is specified, the following form is far more common and can be used instead:"
msgstr ""
#: ../../source/guides/configuration.rst:31
msgid "An example of using the above form is:"
msgstr ""
#: ../../source/guides/configuration.rst:37
msgid "This asks Manim to search for a Scene class called :code:`SceneOne` inside the file ``file.py`` and render it with medium quality (specified by the ``-qm`` flag)."
msgstr ""
#: ../../source/guides/configuration.rst:40
msgid "Another frequently used flag is ``-p`` (\"preview\"), which makes manim open the rendered video after it's done rendering."
msgstr ""
#: ../../source/guides/configuration.rst:43
msgid "The ``-p`` flag does not change any properties of the global ``config`` dict. The ``-p`` flag is only a command-line convenience."
msgstr ""
#: ../../source/guides/configuration.rst:47
msgid "Advanced examples"
msgstr ""
#: ../../source/guides/configuration.rst:49
msgid "To render a scene in high quality, but only output the last frame of the scene instead of the whole video, you can execute"
msgstr ""
#: ../../source/guides/configuration.rst:56
msgid "The following example specifies the output file name (with the :code:`-o` flag), renders only the first ten animations (:code:`-n` flag) with a white background (:code:`-c` flag), and saves the animation as a ``.gif`` instead of as a ``.mp4`` file (``--format=gif`` flag). It uses the default quality and does not try to open the file after it is rendered."
msgstr ""
#: ../../source/guides/configuration.rst:67
msgid "A list of all CLI flags"
msgstr ""
#: ../../source/guides/configuration.rst:75
msgid "The ManimConfig class"
msgstr ""
#: ../../source/guides/configuration.rst:77
msgid "The most direct way of configuring Manim is through the global ``config`` object, which is an instance of :class:`.ManimConfig`. Each property of this class is a config option that can be accessed either with standard attribute syntax or with dict-like syntax:"
msgstr ""
#: ../../source/guides/configuration.rst:88
msgid "The former is preferred; the latter is provided for backwards compatibility."
msgstr ""
#: ../../source/guides/configuration.rst:91
msgid "Most classes, including :class:`.Camera`, :class:`.Mobject`, and :class:`.Animation`, read some of their default configuration from the global ``config``."
msgstr ""
#: ../../source/guides/configuration.rst:103
msgid ":class:`.ManimConfig` is designed to keep internal consistency. For example, setting ``frame_y_radius`` will affect ``frame_height``:"
msgstr ""
#: ../../source/guides/configuration.rst:114
msgid "The global ``config`` object is meant to be the single source of truth for all config options. All of the other ways of setting config options ultimately change the values of the global ``config`` object."
msgstr ""
#: ../../source/guides/configuration.rst:118
msgid "The following example illustrates the video resolution chosen for examples rendered in our documentation with a reference frame."
msgstr ""
#: ../../source/guides/configuration.rst:140
msgid "The config files"
msgstr ""
#: ../../source/guides/configuration.rst:142
msgid "As the last example shows, executing Manim from the command line may involve using many flags simultaneously. This may become a nuisance if you must execute the same script many times in a short time period, for example, when making small incremental tweaks to your scene script. For this reason, Manim can also be configured using a configuration file. A configuration file is a file ending with the suffix ``.cfg``."
msgstr ""
#: ../../source/guides/configuration.rst:149
msgid "To use a local configuration file when rendering your scene, you must create a file with the name ``manim.cfg`` in the same directory as your scene code."
msgstr ""
#: ../../source/guides/configuration.rst:152
msgid "The config file **must** be named ``manim.cfg``. Currently, Manim does not support config files with any other name."
msgstr ""
#: ../../source/guides/configuration.rst:155
msgid "The config file must start with the section header ``[CLI]``. The configuration options under this header have the same name as the CLI flags and serve the same purpose. Take, for example, the following config file."
msgstr ""
#: ../../source/guides/configuration.rst:167
msgid "Config files are parsed with the standard python library ``configparser``. In particular, they will ignore any line that starts with a pound symbol ``#``."
msgstr ""
#: ../../source/guides/configuration.rst:170
msgid "Now, executing the following command"
msgstr ""
#: ../../source/guides/configuration.rst:176
msgid "is equivalent to executing the following command, provided that ``manim.cfg`` is in the same directory as <file.py>,"
msgstr ""
#: ../../source/guides/configuration.rst:183
msgid "The names of the configuration options admissible in config files are exactly the same as the **long names** of the corresponding command- line flags. For example, the ``-c`` and ``--background_color`` flags are interchangeable, but the config file only accepts :code:`background_color` as an admissible option."
msgstr ""
#: ../../source/guides/configuration.rst:189
msgid "Since config files are meant to replace CLI flags, all CLI flags can be set via a config file. Moreover, any config option can be set via a config file, whether or not it has an associated CLI flag. See the bottom of this document for a list of all CLI flags and config options."
msgstr ""
#: ../../source/guides/configuration.rst:194
msgid "Manim will look for a ``manim.cfg`` config file in the same directory as the file being rendered, and **not** in the directory of execution. For example,"
msgstr ""
#: ../../source/guides/configuration.rst:201
msgid "will use the config file found in ``path/to/file.py``, if any. It will **not** use the config file found in the current working directory, even if it exists. In this way, the user may keep different config files for different scenes or projects, and execute them with the right configuration from anywhere in the system."
msgstr ""
#: ../../source/guides/configuration.rst:207
msgid "The file described here is called the **folder-wide** config file because it affects all scene scripts found in the same folder."
msgstr ""
#: ../../source/guides/configuration.rst:212
msgid "The user config file"
msgstr ""
#: ../../source/guides/configuration.rst:214
msgid "As explained in the previous section, a :code:`manim.cfg` config file only affects the scene scripts in its same folder. However, the user may also create a special config file that will apply to all scenes rendered by that user. This is referred to as the **user-wide** config file, and it will apply regardless of where Manim is executed from, and regardless of where the scene script is stored."
msgstr ""
#: ../../source/guides/configuration.rst:221
msgid "The user-wide config file lives in a special folder, depending on the operating system."
msgstr ""
#: ../../source/guides/configuration.rst:224
msgid "Windows: :code:`UserDirectory`/AppData/Roaming/Manim/manim.cfg"
msgstr ""
#: ../../source/guides/configuration.rst:225
msgid "MacOS: :code:`UserDirectory`/.config/manim/manim.cfg"
msgstr ""
#: ../../source/guides/configuration.rst:226
msgid "Linux: :code:`UserDirectory`/.config/manim/manim.cfg"
msgstr ""
#: ../../source/guides/configuration.rst:228
msgid "Here, :code:`UserDirectory` is the user's home folder."
msgstr ""
#: ../../source/guides/configuration.rst:231
msgid "A user may have many **folder-wide** config files, one per folder, but only one **user-wide** config file. Different users in the same computer may each have their own user-wide config file."
msgstr ""
#: ../../source/guides/configuration.rst:235
msgid "Do not store scene scripts in the same folder as the user-wide config file. In this case, the behavior is undefined."
msgstr ""
#: ../../source/guides/configuration.rst:238
msgid "Whenever you use Manim from anywhere in the system, Manim will look for a user-wide config file and read its configuration."
msgstr ""
#: ../../source/guides/configuration.rst:243
msgid "Cascading config files"
msgstr ""
#: ../../source/guides/configuration.rst:245
msgid "What happens if you execute Manim and it finds both a folder-wide config file and a user-wide config file? Manim will read both files, but if they are incompatible, **the folder-wide file takes precedence**."
msgstr ""
#: ../../source/guides/configuration.rst:249
msgid "For example, take the following user-wide config file"
msgstr ""
#: ../../source/guides/configuration.rst:259
msgid "and the following folder-wide file"
msgstr ""
#: ../../source/guides/configuration.rst:267
msgid "Then, executing :code:`manim <file.py> SceneName` will be equivalent to not using any config files and executing"
msgstr ""
#: ../../source/guides/configuration.rst:274
msgid "Any command-line flags have precedence over any config file. For example, using the previous two config files and executing :code:`manim -c RED <file.py> SceneName` is equivalent to not using any config files and executing"
msgstr ""
#: ../../source/guides/configuration.rst:283
msgid "There is also a **library-wide** config file that determines Manim's default behavior and applies to every user of the library. It has the least precedence, so any config options in the user-wide and any folder-wide files will override the library-wide file. This is referred to as the *cascading* config file system."
msgstr ""
#: ../../source/guides/configuration.rst:289
msgid "**The user should not try to modify the library-wide file**. Contributors should receive explicit confirmation from the core developer team before modifying it."
msgstr ""
#: ../../source/guides/configuration.rst:295
msgid "Order of operations"
msgstr ""
#: ../../source/guides/configuration.rst:304
msgid "With so many different ways of configuring Manim, it can be difficult to know when each config option is being set. In fact, this will depend on how Manim is being used."
msgstr ""
#: ../../source/guides/configuration.rst:308
msgid "If Manim is imported from a module, then the configuration system will follow these steps:"
msgstr ""
#: ../../source/guides/configuration.rst:311
msgid "The library-wide config file is loaded."
msgstr ""
#: ../../source/guides/configuration.rst:312
msgid "The user-wide and folder-wide files are loaded if they exist."
msgstr ""
#: ../../source/guides/configuration.rst:313
msgid "All files found in the previous two steps are parsed in a single :class:`ConfigParser` object, called ``parser``. This is where *cascading* happens."
msgstr ""
#: ../../source/guides/configuration.rst:316
msgid ":class:`logging.Logger` is instantiated to create Manim's global ``logger`` object. It is configured using the \"logger\" section of the parser, i.e. ``parser['logger']``."
msgstr ""
#: ../../source/guides/configuration.rst:319
msgid ":class:`ManimConfig` is instantiated to create the global ``config`` object."
msgstr ""
#: ../../source/guides/configuration.rst:320
msgid "The ``parser`` from step 3 is fed into the ``config`` from step 5 via :meth:`ManimConfig.digest_parser`."
msgstr ""
#: ../../source/guides/configuration.rst:322
msgid "Both ``logger`` and ``config`` are exposed to the user."
msgstr ""
#: ../../source/guides/configuration.rst:324
msgid "If Manim is being invoked from the command line, all of the previous steps happen, and are complemented by:"
msgstr ""
#: ../../source/guides/configuration.rst:327
msgid "The CLI flags are parsed and fed into ``config`` via :meth:`~ManimConfig.digest_args`."
msgstr ""
#: ../../source/guides/configuration.rst:329
msgid "If the ``--config_file`` flag was used, a new :class:`ConfigParser` object is created with the contents of the library-wide file, the user-wide file if it exists, and the file passed via ``--config_file``. In this case, the folder-wide file, if it exists, is ignored."
msgstr ""
#: ../../source/guides/configuration.rst:333
msgid "The new parser is fed into ``config``."
msgstr ""
#: ../../source/guides/configuration.rst:334
msgid "The rest of the CLI flags are processed."
msgstr ""
#: ../../source/guides/configuration.rst:336
msgid "To summarize, the order of precedence for configuration options, from lowest to highest precedence is:"
msgstr ""
#: ../../source/guides/configuration.rst:339
msgid "Library-wide config file,"
msgstr ""
#: ../../source/guides/configuration.rst:340
msgid "user-wide config file, if it exists,"
msgstr ""
#: ../../source/guides/configuration.rst:341
msgid "folder-wide config file, if it exists OR custom config file, if passed via ``--config_file``,"
msgstr ""
#: ../../source/guides/configuration.rst:343
msgid "other CLI flags, and"
msgstr ""
#: ../../source/guides/configuration.rst:344
msgid "any programmatic changes made after the config system is set."
msgstr ""
#: ../../source/guides/configuration.rst:348
msgid "A list of all config options"
msgstr ""
#: ../../source/guides/configuration.rst:369
msgid "Accessing CLI command options"
msgstr ""
#: ../../source/guides/configuration.rst:371
msgid "Entering ``manim``, or ``manim --help``, will open the main help page."
msgstr ""

View file

@ -0,0 +1,633 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/guides/deep_dive.rst:2
msgid "A deep dive into Manim's internals"
msgstr ""
#: ../../source/guides/deep_dive.rst:4
msgid "**Author:** `Benjamin Hackl <https://benjamin-hackl.at>`__"
msgstr ""
#: ../../source/guides/deep_dive.rst:6
msgid "Disclaimer"
msgstr ""
#: ../../source/guides/deep_dive.rst:8
msgid "This guide reflects the state of the library as of version ``v0.16.0`` and primarily treats the Cairo renderer. The situation in the latest version of Manim might be different; in case of substantial deviations we will add a note below."
msgstr ""
#: ../../source/guides/deep_dive.rst:14
msgid "Introduction"
msgstr ""
#: ../../source/guides/deep_dive.rst:16
msgid "Manim can be a wonderful library, if it behaves the way you would like it to, and/or the way you expect it to. Unfortunately, this is not always the case (as you probably know if you have played with some manimations yourself already). To understand where things *go wrong*, digging through the library's source code is sometimes the only option -- but in order to do that, you need to know where to start digging."
msgstr ""
#: ../../source/guides/deep_dive.rst:23
msgid "This article is intended as some sort of life line through the render process. We aim to give an appropriate amount of detail describing what happens when Manim reads your scene code and produces the corresponding animation. Throughout this article, we will focus on the following toy example::"
msgstr ""
#: ../../source/guides/deep_dive.rst:43
msgid "Before we go into details or even look at the rendered output of this scene, let us first describe verbally what happens in this *manimation*. In the first three lines of the ``construct`` method, a :class:`.Square` and a :class:`.Circle` are initialized, then the square is added to the scene. The first frame of the rendered output should thus show an orange square."
msgstr ""
#: ../../source/guides/deep_dive.rst:49
msgid "Then the actual animations happen: the square first transforms into a circle, then a :class:`.Dot` is created (Where do you guess the dot is located when it is first added to the scene? Answering this already requires detailed knowledge about the render process.). The dot has an updater attached to it, and as the circle moves right, the dot moves with it. In the end, all mobjects are faded out."
msgstr ""
#: ../../source/guides/deep_dive.rst:56
msgid "Actually rendering the code yields the following video:"
msgstr ""
#: ../../source/guides/deep_dive.rst:75
msgid "For this example, the output (fortunately) coincides with our expectations."
msgstr ""
#: ../../source/guides/deep_dive.rst:78
msgid "Overview"
msgstr ""
#: ../../source/guides/deep_dive.rst:80
msgid "Because there is a lot of information in this article, here is a brief overview discussing the contents of the following chapters on a very high level."
msgstr ""
#: ../../source/guides/deep_dive.rst:83
msgid "`Preliminaries`_: In this chapter we unravel all the steps that take place to prepare a scene for rendering; right until the point where the user-overridden ``construct`` method is ran. This includes a brief discussion on using Manim's CLI versus other means of rendering (e.g., via Jupyter notebooks, or in your Python script by calling the :meth:`.Scene.render` method yourself)."
msgstr ""
#: ../../source/guides/deep_dive.rst:88
msgid "`Mobject Initialization`_: For the second chapter we dive into creating and handling Mobjects, the basic elements that should be displayed in our scene. We discuss the :class:`.Mobject` base class, how there are essentially three different types of Mobjects, and then discuss the most important of them, vectorized Mobjects. In particular, we describe the internal point data structure that governs how the mechanism responsible for drawing the vectorized Mobject to the screen sets the corresponding Bézier curves. We conclude the chapter with a tour into :meth:`.Scene.add`, the bookkeeping mechanism controlling which mobjects should be rendered."
msgstr ""
#: ../../source/guides/deep_dive.rst:97
msgid "`Animations and the Render Loop`_: And finally, in the last chapter we walk through the instantiation of :class:`.Animation` objects (the blueprints that hold information on how Mobjects should be modified when the render loop runs), followed by a investigation of the infamous :meth:`.Scene.play` call. We will see that there are three relevant parts in a :meth:`.Scene.play` call; a part in which the passed animations and keyword arguments are processed and prepared, followed by the actual \"render loop\" in which the library steps through a time line and renders frame by frame. The final part does some post-processing to save a short video segment (\"partial movie file\") and cleanup for the next call to :meth:`.Scene.play`. In the end, after all of :meth:`.Scene.construct` has been run, the library combines the partial movie files to one video."
msgstr ""
#: ../../source/guides/deep_dive.rst:110
msgid "And with that, let us get *in medias res*."
msgstr ""
#: ../../source/guides/deep_dive.rst:113
msgid "Preliminaries"
msgstr ""
#: ../../source/guides/deep_dive.rst:116
msgid "Importing the library"
msgstr ""
#: ../../source/guides/deep_dive.rst:118
msgid "Independent of how exactly you are telling your system to render the scene, i.e., whether you run ``manim -qm -p file_name.py ToyExample``, or whether you are rendering the scene directly from the Python script via a snippet like"
msgstr ""
#: ../../source/guides/deep_dive.rst:129
msgid "or whether you are rendering the code in a Jupyter notebook, you are still telling your python interpreter to import the library. The usual pattern used to do this is"
msgstr ""
#: ../../source/guides/deep_dive.rst:136
msgid "which (while being a debatable strategy in general) imports a lot of classes and functions shipped with the library and makes them available in your global name space. I explicitly avoided stating that it imports **all** classes and functions of the library, because it does not do that: Manim makes use of the practice described in `Section 6.4.1 of the Python tutorial <https://docs.python.org/3/tutorial/modules.html#importing-from-a-package>`__, and all module members that should be exposed to the user upon running the ``*``-import are explicitly declared in the ``__all__`` variable of the module."
msgstr ""
#: ../../source/guides/deep_dive.rst:144
msgid "Manim also uses this strategy internally: taking a peek at the file that is run when the import is called, ``__init__.py`` (see `here <https://github.com/ManimCommunity/manim/blob/main/manim/__init__.py>`__), you will notice that most of the code in that module is concerned with importing members from various different submodules, again using ``*``-imports."
msgstr ""
#: ../../source/guides/deep_dive.rst:152
msgid "If you would ever contribute a new submodule to Manim, the main ``__init__.py`` is where it would have to be listed in order to make its members accessible to users after importing the library."
msgstr ""
#: ../../source/guides/deep_dive.rst:156
msgid "In that file, there is one particular import at the beginning of the file however, namely::"
msgstr ""
#: ../../source/guides/deep_dive.rst:161
msgid "This initializes Manim's global configuration system, which is used in various places throughout the library. After the library runs this line, the current configuration options are set. The code in there takes care of reading the options in your ``.cfg`` files (all users have at least the global one that is shipped with the library) as well as correctly handling command line arguments (if you used the CLI to render)."
msgstr ""
#: ../../source/guides/deep_dive.rst:167
msgid "You can read more about the config system in the :doc:`corresponding thematic guide </guides/configuration>`, and if you are interested in learning more about the internals of the configuration system and how it is initialized, follow the code flow starting in `the config module's init file <https://github.com/ManimCommunity/manim/blob/main/manim/_config/__init__.py>`__."
msgstr ""
#: ../../source/guides/deep_dive.rst:173
msgid "Now that the library is imported, we can turn our attention to the next step: reading your scene code (which is not particularly exciting, Python just creates a new class ``ToyExample`` based on our code; Manim is virtually not involved in that step, with the exception that ``ToyExample`` inherits from ``Scene``)."
msgstr ""
#: ../../source/guides/deep_dive.rst:178
msgid "However, with the ``ToyExample`` class created and ready to go, there is a new excellent question to answer: how is the code in our ``construct`` method actually executed?"
msgstr ""
#: ../../source/guides/deep_dive.rst:183
msgid "Scene instantiation and rendering"
msgstr ""
#: ../../source/guides/deep_dive.rst:185
msgid "The answer to this question depends on how exactly you are running the code. To make things a bit clearer, let us first consider the case that you have created a file ``toy_example.py`` which looks like this::"
msgstr ""
#: ../../source/guides/deep_dive.rst:208
msgid "With such a file, the desired scene is rendered by simply running this Python script via ``python toy_example.py``. Then, as described above, the library is imported and Python has read and defined the ``ToyExample`` class (but, read carefully: *no instance of this class has been created yet*)."
msgstr ""
#: ../../source/guides/deep_dive.rst:213
msgid "At this point, the interpreter is about to enter the ``tempconfig`` context manager. Even if you have not seen Manim's ``tempconfig`` before, it's name already suggests what it does: it creates a copy of the current state of the configuration, applies the changes to the key-value pairs in the passed dictionary, and upon leaving the context the original version of the configuration is restored. TL;DR: it provides a fancy way of temporarily setting configuration options."
msgstr ""
#: ../../source/guides/deep_dive.rst:221
msgid "Inside the context manager, two things happen: an actual ``ToyExample``-scene object is instantiated, and the ``render`` method is called. Every way of using Manim ultimately does something along of these lines, the library always instantiates the scene object and then calls its ``render`` method. To illustrate that this really is the case, let us briefly look at the two most common ways of rendering scenes:"
msgstr ""
#: ../../source/guides/deep_dive.rst:228
msgid "**Command Line Interface.** When using the CLI and running the command ``manim -qm -p toy_example.py ToyExample`` in your terminal, the actual entry point is Manim's ``__main__.py`` file (located `here <https://github.com/ManimCommunity/manim/blob/main/manim/__main__.py>`__. Manim uses `Click <https://click.palletsprojects.com/en/8.0.x/>`__ to implement the command line interface, and the corresponding code is located in Manim's ``cli`` module (https://github.com/ManimCommunity/manim/tree/main/manim/cli). The corresponding code creating the scene class and calling its render method is located `here <https://github.com/ManimCommunity/manim/blob/ac1ee9a683ce8b92233407351c681f7d71a4f2db/manim/cli/render/commands.py#L139-L141>`__."
msgstr ""
#: ../../source/guides/deep_dive.rst:238
msgid "**Jupyter notebooks.** In Jupyter notebooks, the communication with the library is handled by the ``%%manim`` magic command, which is implemented in the ``manim.utils.ipython_magic`` module. There is :meth:`some documentation <.ManimMagic.manim>` available for the magic command, and the code creating the scene class and calling its render method is located `here <https://github.com/ManimCommunity/manim/blob/ac1ee9a683ce8b92233407351c681f7d71a4f2db/manim/utils/ipython_magic.py#L137-L138>`__."
msgstr ""
#: ../../source/guides/deep_dive.rst:246
msgid "Now that we know that either way, a :class:`.Scene` object is created, let us investigate what Manim does when that happens. When instantiating our scene object"
msgstr ""
#: ../../source/guides/deep_dive.rst:253
msgid "the ``Scene.__init__`` method is called, given that we did not implement our own initialization method. Inspecting the corresponding code (see `here <https://github.com/ManimCommunity/manim/blob/main/manim/scene/scene.py>`__) reveals that ``Scene.__init__`` first sets several attributes of the scene objects that do not depend on any configuration options set in ``config``. Then the scene inspects the value of ``config.renderer``, and based on its value, either instantiates a ``CairoRenderer`` or an ``OpenGLRenderer`` object and assigns it to its ``renderer`` attribute."
msgstr ""
#: ../../source/guides/deep_dive.rst:261
msgid "The scene then asks its renderer to initialize the scene by calling"
msgstr ""
#: ../../source/guides/deep_dive.rst:267
msgid "Inspecting both the default Cairo renderer and the OpenGL renderer shows that the ``init_scene`` method effectively makes the renderer instantiate a :class:`.SceneFileWriter` object, which basically is Manim's interface to ``ffmpeg`` and actually writes the movie file. The Cairo renderer (see the implementation `here <https://github.com/ManimCommunity/manim/blob/main/manim/renderer/cairo_renderer.py>`__) does not require any further initialization. The OpenGL renderer does some additional setup to enable the realtime rendering preview window, which we do not go into detail further here."
msgstr ""
#: ../../source/guides/deep_dive.rst:276
msgid "Currently, there is a lot of interplay between a scene and its renderer. This is a flaw in Manim's current architecture, and we are working on reducing this interdependency to achieve a less convoluted code flow."
msgstr ""
#: ../../source/guides/deep_dive.rst:280
msgid "After the renderer has been instantiated and initialized its file writer, the scene populates further initial attributes (notable mention: the ``mobjects`` attribute which keeps track of the mobjects that have been added to the scene). It is then done with its instantiation and ready to be rendered."
msgstr ""
#: ../../source/guides/deep_dive.rst:285
msgid "The rest of this article is concerned with the last line in our toy example script::"
msgstr ""
#: ../../source/guides/deep_dive.rst:289
msgid "This is where the actual magic happens."
msgstr ""
#: ../../source/guides/deep_dive.rst:291
msgid "Inspecting the `implementation of the render method <https://github.com/ManimCommunity/manim/blob/df1a60421ea1119cbbbd143ef288d294851baaac/manim/scene/scene.py#L211>`__ reveals that there are several hooks that can be used for pre- or postprocessing a scene. Unsurprisingly, :meth:`.Scene.render` describes the full *render cycle* of a scene. During this life cycle, there are three custom methods whose base implementation is empty and that can be overwritten to suit your purposes. In the order they are called, these customizable methods are:"
msgstr ""
#: ../../source/guides/deep_dive.rst:298
msgid ":meth:`.Scene.setup`, which is intended for preparing and, well, *setting up* the scene for your animation (e.g., adding initial mobjects, assigning custom attributes to your scene class, etc.),"
msgstr ""
#: ../../source/guides/deep_dive.rst:301
msgid ":meth:`.Scene.construct`, which is the *script* for your screen play and contains programmatic descriptions of your animations, and"
msgstr ""
#: ../../source/guides/deep_dive.rst:303
msgid ":meth:`.Scene.tear_down`, which is intended for any operations you might want to run on the scene after the last frame has already been rendered (for example, this could run some code that generates a custom thumbnail for the video based on the state of the objects in the scene -- this hook is more relevant for situations where Manim is used within other Python scripts)."
msgstr ""
#: ../../source/guides/deep_dive.rst:310
msgid "After these three methods are run, the animations have been fully rendered, and Manim calls :meth:`.CairoRenderer.scene_finished` to gracefully complete the rendering process. This checks whether any animations have been played -- and if so, it tells the :class:`.SceneFileWriter` to close the pipe to ``ffmpeg``. If not, Manim assumes that a static image should be output which it then renders using the same strategy by calling the render loop (see below) once."
msgstr ""
#: ../../source/guides/deep_dive.rst:318
msgid "**Back in our toy example,** the call to :meth:`.Scene.render` first triggers :meth:`.Scene.setup` (which only consists of ``pass``), followed by a call of :meth:`.Scene.construct`. At this point, our *animation script* is run, starting with the initialization of ``orange_square``."
msgstr ""
#: ../../source/guides/deep_dive.rst:325
msgid "Mobject Initialization"
msgstr ""
#: ../../source/guides/deep_dive.rst:327
msgid "Mobjects are, in a nutshell, the Python objects that represent all the *things* we want to display in our scene. Before we follow our debugger into the depths of mobject initialization code, it makes sense to discuss Manim's different types of Mobjects and their basic data structure."
msgstr ""
#: ../../source/guides/deep_dive.rst:334
msgid "What even is a Mobject?"
msgstr ""
#: ../../source/guides/deep_dive.rst:336
msgid ":class:`.Mobject` stands for *mathematical object* or *Manim object* (depends on who you ask 😄). The Python class :class:`.Mobject` is the base class for all objects that should be displayed on screen. Looking at the `initialization method <https://github.com/ManimCommunity/manim/blob/5d72d9cfa2e3dd21c844b1da807576f5a7194fda/manim/mobject/mobject.py#L94>`__ of :class:`.Mobject`, you will find that not too much happens in there:"
msgstr ""
#: ../../source/guides/deep_dive.rst:343
msgid "some initial attribute values are assigned, like ``name`` (which makes the render logs mention the name of the mobject instead of its type), ``submobjects`` (initially an empty list), ``color``, and some others."
msgstr ""
#: ../../source/guides/deep_dive.rst:346
msgid "Then, two methods related to *points* are called: ``reset_points`` followed by ``generate_points``,"
msgstr ""
#: ../../source/guides/deep_dive.rst:348
msgid "and finally, ``init_colors`` is called."
msgstr ""
#: ../../source/guides/deep_dive.rst:350
msgid "Digging deeper, you will find that :meth:`.Mobject.reset_points` simply sets the ``points`` attribute of the mobject to an empty NumPy vector, while the other two methods, :meth:`.Mobject.generate_points` and :meth:`.Mobject.init_colors` are just implemented as ``pass``."
msgstr ""
#: ../../source/guides/deep_dive.rst:355
msgid "This makes sense: :class:`.Mobject` is not supposed to be used as an *actual* object that is displayed on screen; in fact the camera (which we will discuss later in more detail; it is the class that is, for the Cairo renderer, responsible for \"taking a picture\" of the current scene) does not process \"pure\" :class:`Mobjects <.Mobject>` in any way, they *cannot* even appear in the rendered output."
msgstr ""
#: ../../source/guides/deep_dive.rst:362
msgid "This is where different types of mobjects come into play. Roughly speaking, the Cairo renderer setup knows three different types of mobjects that can be rendered:"
msgstr ""
#: ../../source/guides/deep_dive.rst:366
msgid ":class:`.ImageMobject`, which represent images that you can display in your scene,"
msgstr ""
#: ../../source/guides/deep_dive.rst:368
msgid ":class:`.PMobject`, which are very special mobjects used to represent point clouds; we will not discuss them further in this guide,"
msgstr ""
#: ../../source/guides/deep_dive.rst:370
msgid ":class:`.VMobject`, which are *vectorized mobjects*, that is, mobjects that consist of points that are connected via curves. These are pretty much everywhere, and we will discuss them in detail in the next section."
msgstr ""
#: ../../source/guides/deep_dive.rst:375
msgid "... and what are VMobjects?"
msgstr ""
#: ../../source/guides/deep_dive.rst:377
msgid "As just mentioned, :class:`VMobjects <.VMobject>` represent vectorized mobjects. To render a :class:`.VMobject`, the camera looks at the ``points`` attribute of a :class:`.VMobject` and divides it into sets of four points each. Each of these sets is then used to construct a cubic Bézier curve with the first and last entry describing the end points of the curve (\"anchors\"), and the second and third entry describing the control points in between (\"handles\")."
msgstr ""
#: ../../source/guides/deep_dive.rst:386
msgid "To learn more about Bézier curves, take a look at the excellent online textbook `A Primer on Bézier curves <https://pomax.github.io/bezierinfo/>`__ by `Pomax <https://twitter.com/TheRealPomax>`__ -- there is an playground representing cubic Bézier curves `in §1 <https://pomax.github.io/bezierinfo/#introduction>`__, the red and yellow points are \"anchors\", and the green and blue points are \"handles\"."
msgstr ""
#: ../../source/guides/deep_dive.rst:393
msgid "In contrast to :class:`.Mobject`, :class:`.VMobject` can be displayed on screen (even though, technically, it is still considered a base class). To illustrate how points are processed, consider the following short example of a :class:`.VMobject` with 8 points (and thus made out of 8/4 = 2 cubic Bézier curves). The resulting :class:`.VMobject` is drawn in green. The handles are drawn as red dots with a line to their closest anchor."
msgstr ""
#: ../../source/guides/deep_dive.rst:433
msgid "Manually setting the points of your :class:`.VMobject` is usually discouraged; there are specialized methods that can take care of that for you -- but it might be relevant when implementing your own, custom :class:`.VMobject`."
msgstr ""
#: ../../source/guides/deep_dive.rst:441
msgid "Squares and Circles: back to our Toy Example"
msgstr ""
#: ../../source/guides/deep_dive.rst:443
msgid "With a basic understanding of different types of mobjects, and an idea of how vectorized mobjects are built we can now come back to our toy example and the execution of the :meth:`.Scene.construct` method. In the first two lines of our animation script, the ``orange_square`` and the ``blue_circle`` are initialized."
msgstr ""
#: ../../source/guides/deep_dive.rst:450
msgid "When creating the orange square by running"
msgstr ""
#: ../../source/guides/deep_dive.rst:456
msgid "the initialization method of :class:`.Square`, ``Square.__init__``, is called. `Looking at the implementation <https://github.com/ManimCommunity/manim/blob/5d72d9cfa2e3dd21c844b1da807576f5a7194fda/manim/mobject/geometry/polygram.py#L607>`__, we can see that the ``side_length`` attribute of the square is set, and then"
msgstr ""
#: ../../source/guides/deep_dive.rst:466
msgid "is called. This ``super`` call is the Python way of calling the initialization function of the parent class. As :class:`.Square` inherits from :class:`.Rectangle`, the next method called is ``Rectangle.__init__``. There, only the first three lines are really relevant for us::"
msgstr ""
#: ../../source/guides/deep_dive.rst:476
msgid "First, the initialization function of the parent class of :class:`.Rectangle` -- :class:`.Polygon` -- is called. The four positional arguments passed are the four corners of the polygon: ``UR`` is up right (and equal to ``UP + RIGHT``), ``UL`` is up left (and equal to ``UP + LEFT``), and so forth. Before we follow our debugger deeper, let us observe what happens with the constructed polygon: the remaining two lines stretch the polygon to fit the specified width and height such that a rectangle with the desired measurements is created."
msgstr ""
#: ../../source/guides/deep_dive.rst:486
msgid "The initialization function of :class:`.Polygon` is particularly simple, it only calls the initialization function of its parent class, :class:`.Polygram`. There, we have almost reached the end of the chain: :class:`.Polygram` inherits from :class:`.VMobject`, whose initialization function mainly sets the values of some attributes (quite similar to ``Mobject.__init__``, but more specific to the Bézier curves that make up the mobject)."
msgstr ""
#: ../../source/guides/deep_dive.rst:494
msgid "After calling the initialization function of :class:`.VMobject`, the constructor of :class:`.Polygram` also does something somewhat odd: it sets the points (which, you might remember above, should actually be set in a corresponding ``generate_points`` method of :class:`.Polygram`)."
msgstr ""
#: ../../source/guides/deep_dive.rst:501
msgid "In several instances, the implementation of mobjects does not really stick to all aspects of Manim's interface. This is unfortunate, and increasing consistency is something that we actively work on. Help is welcome!"
msgstr ""
#: ../../source/guides/deep_dive.rst:506
msgid "Without going too much into detail, :class:`.Polygram` sets its ``points`` attribute via :meth:`.VMobject.start_new_path`, :meth:`.VMobject.add_points_as_corners`, which take care of setting the quadruples of anchors and handles appropriately. After the points are set, Python continues to process the call stack until it reaches the method that was first called; the initialization method of :class:`.Square`. After this, the square is initialized and assigned to the ``orange_square`` variable."
msgstr ""
#: ../../source/guides/deep_dive.rst:516
msgid "The initialization of ``blue_circle`` is similar to the one of ``orange_square``, with the main difference being that the inheritance chain of :class:`.Circle` is different. Let us briefly follow the trace of the debugger:"
msgstr ""
#: ../../source/guides/deep_dive.rst:521
msgid "The implementation of :meth:`.Circle.__init__` immediately calls the initialization method of :class:`.Arc`, as a circle in Manim is simply an arc with an angle of :math:`\\tau = 2\\pi`. When initializing the arc, some basic attributes are set (like ``Arc.radius``, ``Arc.arc_center``, ``Arc.start_angle``, and ``Arc.angle``), and then the initialization method of its parent class, :class:`.TipableVMobject`, is called (which is a rather abstract base class for mobjects which a arrow tip can be attached to). Note that in contrast to :class:`.Polygram`, this class does **not** preemptively generate the points of the circle."
msgstr ""
#: ../../source/guides/deep_dive.rst:532
msgid "After that, things are less exciting: :class:`.TipableVMobject` again sets some attributes relevant for adding arrow tips, and afterwards passes to the initialization method of :class:`.VMobject`. From there, :class:`.Mobject` is initialized and :meth:`.Mobject.generate_points` is called, which actually runs the method implemented in :meth:`.Arc.generate_points`."
msgstr ""
#: ../../source/guides/deep_dive.rst:539
msgid "After both our ``orange_square`` and the ``blue_circle`` are initialized, the square is actually added to the scene. The :meth:`.Scene.add` method is actually doing a few interesting things, so it is worth to dig a bit deeper in the next section."
msgstr ""
#: ../../source/guides/deep_dive.rst:546
msgid "Adding Mobjects to the Scene"
msgstr ""
#: ../../source/guides/deep_dive.rst:548
msgid "The code in our ``construct`` method that is run next is"
msgstr ""
#: ../../source/guides/deep_dive.rst:554
msgid "From a high-level point of view, :meth:`.Scene.add` adds the ``orange_square`` to the list of mobjects that should be rendered, which is stored in the ``mobjects`` attribute of the scene. However, it does so in a very careful way to avoid the situation that a mobject is being added to the scene more than once. At a first glance, this sounds like a simple task -- the problem is that ``Scene.mobjects`` is not a \"flat\" list of mobjects, but a list of mobjects which might contain mobjects themselves, and so on."
msgstr ""
#: ../../source/guides/deep_dive.rst:563
msgid "Stepping through the code in :meth:`.Scene.add`, we see that first it is checked whether we are currently using the OpenGL renderer (which we are not) -- adding mobjects to the scene works slightly different (and actually easier!) for the OpenGL renderer. Then, the code branch for the Cairo renderer is entered and the list of so-called foreground mobjects (which are rendered on top of all other mobjects) is added to the list of passed mobjects. This is to ensure that the foreground mobjects will stay above of the other mobjects, even after adding the new ones. In our case, the list of foreground mobjects is actually empty, and nothing changes."
msgstr ""
#: ../../source/guides/deep_dive.rst:574
msgid "Next, :meth:`.Scene.restructure_mobjects` is called with the list of mobjects to be added as the ``to_remove`` argument, which might sound odd at first. Practically, this ensures that mobjects are not added twice, as mentioned above: if they were present in the scene ``Scene.mobjects`` list before (even if they were contained as a child of some other mobject), they are first removed from the list. The way :meth:`.Scene.restrucutre_mobjects` works is rather aggressive: It always operates on a given list of mobjects; in the ``add`` method two different lists occur: the default one, ``Scene.mobjects`` (no extra keyword argument is passed), and ``Scene.moving_mobjects`` (which we will discuss later in more detail). It iterates through all of the members of the list, and checks whether any of the mobjects passed in ``to_remove`` are contained as children (in any nesting level). If so, **their parent mobject is deconstructed** and their siblings are inserted directly one level higher. Consider the following example::"
msgstr ""
#: ../../source/guides/deep_dive.rst:604
msgid "Note that the group is disbanded and the circle moves into the root layer of mobjects in ``test_scene.mobjects``."
msgstr ""
#: ../../source/guides/deep_dive.rst:607
msgid "After the mobject list is \"restructured\", the mobject to be added are simply appended to ``Scene.mobjects``. In our toy example, the ``Scene.mobjects`` list is actually empty, so the ``restructure_mobjects`` method does not actually do anything. The ``orange_square`` is simply added to ``Scene.mobjects``, and as the aforementioned ``Scene.moving_mobjects`` list is, at this point, also still empty, nothing happens and :meth:`.Scene.add` returns."
msgstr ""
#: ../../source/guides/deep_dive.rst:615
msgid "We will hear more about the ``moving_mobject`` list when we discuss the render loop. Before we do that, let us look at the next line of code in our toy example, which includes the initialization of an animation class, ::"
msgstr ""
#: ../../source/guides/deep_dive.rst:623
msgid "Hence it is time to talk about :class:`.Animation`."
msgstr ""
#: ../../source/guides/deep_dive.rst:627
msgid "Animations and the Render Loop"
msgstr ""
#: ../../source/guides/deep_dive.rst:630
msgid "Initializing animations"
msgstr ""
#: ../../source/guides/deep_dive.rst:632
msgid "Before we follow the trace of the debugger, let us briefly discuss the general structure of the (abstract) base class :class:`.Animation`. An animation object holds all the information necessary for the renderer to generate the corresponding frames. Animations (in the sense of animation objects) in Manim are *always* tied to a specific mobject; even in the case of :class:`.AnimationGroup` (which you should actually think of as an animation on a group of mobjects rather than a group of animations). Moreover, except for in a particular special case, the run time of animations is also fixed and known beforehand."
msgstr ""
#: ../../source/guides/deep_dive.rst:642
msgid "The initialization of animations actually is not very exciting, :meth:`.Animation.__init__` merely sets some attributes derived from the passed keyword arguments and additionally ensures that the ``Animation.starting_mobject`` and ``Animation.mobject`` attributes are populated. Once the animation is played, the ``starting_mobject`` attribute holds an unmodified copy of the mobject the animation is attached to; during the initialization it is set to a placeholder mobject. The ``mobject`` attribute is set to the mobject the animation is attached to."
msgstr ""
#: ../../source/guides/deep_dive.rst:652
msgid "Animations have a few special methods which are called during the render loop:"
msgstr ""
#: ../../source/guides/deep_dive.rst:655
msgid ":meth:`.Animation.begin`, which is called (as hinted by its name) at the beginning of every animation, so before the first frame is rendered. In it, all the required setup for the animation happens."
msgstr ""
#: ../../source/guides/deep_dive.rst:658
msgid ":meth:`.Animation.finish` is the counterpart to the ``begin`` method which is called at the end of the life cycle of the animation (after the last frame has been rendered)."
msgstr ""
#: ../../source/guides/deep_dive.rst:661
msgid ":meth:`.Animation.interpolate` is the method that updates the mobject attached to the animation to the corresponding animation completion percentage. For example, if in the render loop, ``some_animation.interpolate(0.5)`` is called, the attached mobject will be updated to the state where 50% of the animation are completed."
msgstr ""
#: ../../source/guides/deep_dive.rst:667
msgid "We will discuss details about these and some further animation methods once we walk through the actual render loop. For now, we continue with our toy example and the code that is run when initializing the :class:`.ReplacementTransform` animation."
msgstr ""
#: ../../source/guides/deep_dive.rst:672
msgid "The initialization method of :class:`.ReplacementTransform` only consists of a call to the constructor of its parent class, :class:`.Transform`, with the additional keyword argument ``replace_mobject_with_target_in_scene`` set to ``True``. :class:`.Transform` then sets attributes that control how the points of the starting mobject are deformed into the points of the target mobject, and then passes on to the initialization method of :class:`.Animation`. Other basic properties of the animation (like its ``run_time``, the ``rate_func``, etc.) are processed there -- and then the animation object is fully initialized and ready to be played."
msgstr ""
#: ../../source/guides/deep_dive.rst:685
msgid "The ``play`` call: preparing to enter Manim's render loop"
msgstr ""
#: ../../source/guides/deep_dive.rst:687
msgid "We are finally there, the render loop is in our reach. Let us walk through the code that is run when :meth:`.Scene.play` is called."
msgstr ""
#: ../../source/guides/deep_dive.rst:692
msgid "Recall that this article is specifically about the Cairo renderer. Up to here, things were more or less the same for the OpenGL renderer as well; while some base mobjects might be different, the control flow and lifecycle of mobjects is still more or less the same. There are more substantial differences when it comes to the rendering loop."
msgstr ""
#: ../../source/guides/deep_dive.rst:698
msgid "As you will see when inspecting the method, :meth:`.Scene.play` almost immediately passes over to the ``play`` method of the renderer, in our case :class:`.CairoRenderer.play`. The one thing :meth:`.Scene.play` takes care of is the management of subcaptions that you might have passed to it (see the the documentation of :meth:`.Scene.play` and :meth:`.Scene.add_subcaption` for more information)."
msgstr ""
#: ../../source/guides/deep_dive.rst:707
msgid "As has been said before, the communication between scene and renderer is not in a very clean state at this point, so the following paragraphs might be confusing if you don't run a debugger and step through the code yourself a bit."
msgstr ""
#: ../../source/guides/deep_dive.rst:712
msgid "Inside :meth:`.CairoRenderer.play`, the renderer first checks whether it may skip rendering of the current play call. This might happen, for example, when ``-s`` is passed to the CLI (i.e., only the last frame should be rendered), or when the ``-n`` flag is passed and the current play call is outside of the specified render bounds. The \"skipping status\" is updated in form of the call to :meth:`.CairoRenderer.update_skipping_status`."
msgstr ""
#: ../../source/guides/deep_dive.rst:719
msgid "Next, the renderer asks the scene to process the animations in the play call so that renderer obtains all of the information it needs. To be more concrete, :meth:`.Scene.compile_animation_data` is called, which then takes care of several things:"
msgstr ""
#: ../../source/guides/deep_dive.rst:724
msgid "The method processes all animations and the keyword arguments passed to the initial :meth:`.Scene.play` call. In particular, this means that it makes sure all arguments passed to the play call are actually animations (or ``.animate`` syntax calls, which are also assembled to be actual :class:`.Animation`-objects at that point). It also propagates any animation-related keyword arguments (like ``run_time``, or ``rate_func``) passed to :class:`.Scene.play` to each individual animation. The processed animations are then stored in the ``animations`` attribute of the scene (which the renderer later reads...)."
msgstr ""
#: ../../source/guides/deep_dive.rst:733
msgid "It adds all mobjects to which the animations that are played are bound to to the scene (provided the animation is not an mobject-introducing animation -- for these, the addition to the scene happens later)."
msgstr ""
#: ../../source/guides/deep_dive.rst:736
msgid "In case the played animation is a :class:`.Wait` animation (this is the case in a :meth:`.Scene.wait` call), the method checks whether a static image should be rendered, or whether the render loop should be processed as usual (see :meth:`.Scene.should_update_mobjects` for the exact conditions, basically it checks whether there are any time-dependent updater functions and so on)."
msgstr ""
#: ../../source/guides/deep_dive.rst:742
msgid "Finally, the method determines the total run time of the play call (which at this point is computed as the maximum of the run times of the passed animations). This is stored in the ``duration`` attribute of the scene."
msgstr ""
#: ../../source/guides/deep_dive.rst:747
msgid "After the animation data has been compiled by the scene, the renderer continues to prepare for entering the render loop. It now checks the skipping status which has been determined before. If the renderer can skip this play call, it does so: it sets the current play call hash (which we will get back to in a moment) to ``None`` and increases the time of the renderer by the determined animation run time."
msgstr ""
#: ../../source/guides/deep_dive.rst:754
msgid "Otherwise, the renderer checks whether or not Manim's caching system should be used. The idea of the caching system is simple: for every play call, a hash value is computed, which is then stored and upon re-rendering the scene, the hash is generated again and checked against the stored value. If it is the same, the cached output is reused, otherwise it is fully rerendered again. We will not go into details of the caching system here; if you would like to learn more, the :func:`.get_hash_from_play_call` function in the :mod:`.utils.hashing` module is essentially the entry point to the caching mechanism."
msgstr ""
#: ../../source/guides/deep_dive.rst:764
msgid "In the event that the animation has to be rendered, the renderer asks its :class:`.SceneFileWriter` to start a writing process. The process is started by a call to ``ffmpeg`` and opens a pipe to which rendered raw frames can be written. As long as the pipe is open, the process can be accessed via the ``writing_process`` attribute of the file writer. With the writing process in place, the renderer then asks the scene to \"begin\" the animations."
msgstr ""
#: ../../source/guides/deep_dive.rst:772
msgid "First, it literally *begins* all of the animations by calling their setup methods (:meth:`.Animation._setup_scene`, :meth:`.Animation.begin`). In doing so, the mobjects that are newly introduced by an animation (like via :class:`.Create` etc.) are added to the scene. Furthermore, the animation suspends updater functions being called on its mobject, and it sets its mobject to the state that corresponds to the first frame of the animation."
msgstr ""
#: ../../source/guides/deep_dive.rst:780
msgid "After this has happened for all animations in the current ``play`` call, the Cairo renderer determines which of the scene's mobjects can be painted statically to the background, and which ones have to be redrawn every frame. It does so by calling :meth:`.Scene.get_moving_and_static_mobjects`, and the resulting partition of mobjects is stored in the corresponding ``moving_mobjects`` and ``static_mobjects`` attributes."
msgstr ""
#: ../../source/guides/deep_dive.rst:790
msgid "The mechanism that determines static and moving mobjects is specific for the Cairo renderer, the OpenGL renderer works differently. Basically, moving mobjects are determined by checking whether they, any of their children, or any of the mobjects \"below\" them (in the sense of the order in which mobjects are processed in the scene) either have an update function attached, or whether they appear in one of the current animations. See the implementation of :meth:`.Scene.get_moving_mobjects` for more details."
msgstr ""
#: ../../source/guides/deep_dive.rst:799
msgid "Up to this very point, we did not actually render any (partial) image or movie files from the scene yet. This is, however, about to change. Before we enter the render loop, let us briefly revisit our toy example and discuss how the generic :meth:`.Scene.play` call setup looks like there."
msgstr ""
#: ../../source/guides/deep_dive.rst:805
msgid "For the call that plays the :class:`.ReplacementTransform`, there is no subcaption to be taken care of. The renderer then asks the scene to compile the animation data: the passed argument already is an animation (no additional preparations needed), there is no need for processing any keyword arguments (as we did not specify any additional ones to ``play``). The mobject bound to the animation, ``orange_square``, is already part of the scene (so again, no action taken). Finally, the run time is extracted (3 seconds long) and stored in ``Scene.duration``. The renderer then checks whether it should skip (it should not), then whether the animation is already cached (it is not). The corresponding animation hash value is determined and passed to the file writer, which then also calls ``ffmpeg`` to start the writing process which waits for rendered frames from the library."
msgstr ""
#: ../../source/guides/deep_dive.rst:821
msgid "The scene then ``begin``\\ s the animation: for the :class:`.ReplacementTransform` this means that the animation populates all of its relevant animation attributes (i.e., compatible copies of the starting and the target mobject so that it can safely interpolate between the two)."
msgstr ""
#: ../../source/guides/deep_dive.rst:827
msgid "The mechanism determining static and moving mobjects considers all of the scenes mobjects (at this point only the ``orange_square``), and determines that the ``orange_square`` is bound to an animation that is currently played. As a result, the square is classified as a \"moving mobject\"."
msgstr ""
#: ../../source/guides/deep_dive.rst:833
msgid "Time to render some frames."
msgstr ""
#: ../../source/guides/deep_dive.rst:837
msgid "The render loop (for real this time)"
msgstr ""
#: ../../source/guides/deep_dive.rst:839
msgid "As mentioned above, due to the mechanism that determines static and moving mobjects in the scene, the renderer knows which mobjects it can paint statically to the background of the scene. Practically, this means that it partially renders a scene (to produce a background image), and then when iterating through the time progression of the animation only the \"moving mobjects\" are re-painted on top of the static background."
msgstr ""
#: ../../source/guides/deep_dive.rst:846
msgid "The renderer calls :meth:`.CairoRenderer.save_static_frame_data`, which first checks whether there are currently any static mobjects, and if there are, it updates the frame (only with the static mobjects; more about how exactly this works in a moment) and then saves a NumPy array representing the rendered frame in the ``static_image`` attribute. In our toy example, there are no static mobjects, and so the ``static_image`` attribute is simply set to ``None``."
msgstr ""
#: ../../source/guides/deep_dive.rst:854
msgid "Next, the renderer asks the scene whether the current animation is a \"frozen frame\" animation, which would mean that the renderer actually does not have to repaint the moving mobjects in every frame of the time progression. It can then just take the latest static frame, and display it throughout the animation."
msgstr ""
#: ../../source/guides/deep_dive.rst:862
msgid "An animation is considered a \"frozen frame\" animation if only a static :class:`.Wait` animation is played. See the description of :meth:`.Scene.compile_animation_data` above, or the implementation of :meth:`.Scene.should_update_mobjects` for more details."
msgstr ""
#: ../../source/guides/deep_dive.rst:868
msgid "If this is not the case (just as in our toy example), the renderer then calls the :meth:`.Scene.play_internal` method, which is the integral part of the render loop (in which the library steps through the time progression of the animation and renders the corresponding frames)."
msgstr ""
#: ../../source/guides/deep_dive.rst:874
msgid "Within :meth:`.Scene.play_internal`, the following steps are performed:"
msgstr ""
#: ../../source/guides/deep_dive.rst:876
msgid "The scene determines the run time of the animations by calling :meth:`.Scene.get_run_time`. This method basically takes the maximum ``run_time`` attribute of all of the animations passed to the :meth:`.Scene.play` call."
msgstr ""
#: ../../source/guides/deep_dive.rst:880
msgid "Then the *time progression* is constructed via the (internal) :meth:`.Scene._get_animation_time_progression` method, which wraps the actual :meth:`.Scene.get_time_progression` method. The time progression is a ``tqdm`` `progress bar object <https://tqdm.github.io>`__ for an iterator over ``np.arange(0, run_time, 1 / config.frame_rate)``. In other words, the time progression holds the time stamps (relative to the current animations, so starting at 0 and ending at the total animation run time, with the step size determined by the render frame rate) of the timeline where a new animation frame should be rendered."
msgstr ""
#: ../../source/guides/deep_dive.rst:889
msgid "Then the scene iterates over the time progression: for each time stamp ``t``, :meth:`.Scene.update_to_time` is called, which ..."
msgstr ""
#: ../../source/guides/deep_dive.rst:892
msgid "... first computes the time passed since the last update (which might be 0, especially for the initial call) and references it as ``dt``,"
msgstr ""
#: ../../source/guides/deep_dive.rst:894
msgid "then (in the order in which the animations are passed to :meth:`.Scene.play`) calls :meth:`.Animation.update_mobjects` to trigger all updater functions that are attached to the respective animation except for the \"main mobject\" of the animation (that is, for example, for :class:`.Transform` the unmodified copies of start and target mobject -- see :meth:`.Animation.get_all_mobjects_to_update` for more details),"
msgstr ""
#: ../../source/guides/deep_dive.rst:900
msgid "then the relative time progression with respect to the current animation is computed (``alpha = t / animation.run_time``), which is then used to update the state of the animation with a call to :meth:`.Animation.interpolate`."
msgstr ""
#: ../../source/guides/deep_dive.rst:903
msgid "After all of the passed animations have been processed, the updater functions of all mobjects in the scene, all meshes, and finally those attached to the scene itself are run."
msgstr ""
#: ../../source/guides/deep_dive.rst:907
msgid "At this point, the internal (Python) state of all mobjects has been updated to match the currently processed timestamp. If rendering should not be skipped, then it is now time to *take a picture*!"
msgstr ""
#: ../../source/guides/deep_dive.rst:913
msgid "The update of the internal state (iteration over the time progression) happens *always* once :meth:`.Scene.play_internal` is entered. This ensures that even if frames do not need to be rendered (because, e.g., the ``-n`` CLI flag has been passed, something has been cached, or because we might be in a *Section* with skipped rendering), updater functions still run correctly, and the state of the first frame that *is* rendered is kept consistent."
msgstr ""
#: ../../source/guides/deep_dive.rst:920
msgid "To render an image, the scene calls the corresponding method of its renderer, :meth:`.CairoRenderer.render` and passes just the list of *moving mobjects* (remember, the *static mobjects* are assumed to have already been painted statically to the background of the scene). All of the hard work then happens when the renderer updates its current frame via a call to :meth:`.CairoRenderer.update_frame`:"
msgstr ""
#: ../../source/guides/deep_dive.rst:926
msgid "First, the renderer prepares its :class:`.Camera` by checking whether the renderer has a ``static_image`` different from ``None`` stored already. If so, it sets the image as the *background image* of the camera via :meth:`.Camera.set_frame_to_background`, and otherwise it just resets the camera via :meth:`.Camera.reset`. The camera is then asked to capture the scene with a call to :meth:`.Camera.camture_mobjects`."
msgstr ""
#: ../../source/guides/deep_dive.rst:932
msgid "Things get a bit technical here, and at some point it is more efficient to delve into the implementation -- but here is a summary of what happens once the camera is asked to capture the scene:"
msgstr ""
#: ../../source/guides/deep_dive.rst:936
msgid "First, a flat list of mobjects is created (so submobjects get extracted from their parents). This list is then processed in groups of the same type of mobjects (e.g., a batch of vectorized mobjects, followed by a batch of image mobjects, followed by more vectorized mobjects, etc. -- in many cases there will just be one batch of vectorized mobjects)."
msgstr ""
#: ../../source/guides/deep_dive.rst:941
msgid "Depending on the type of the currently processed batch, the camera uses dedicated *display functions* to convert the :class:`.Mobject` Python object to a NumPy array stored in the camera's ``pixel_array`` attribute. The most important example in that context is the display function for vectorized mobjects, :meth:`.Camera.display_multiple_vectorized_mobjects`, or the more particular (in case you did not add a background image to your :class:`.VMobject`), :meth:`.Camera.display_multiple_non_background_colored_vmobjects`. This method first gets the current Cairo context, and then, for every (vectorized) mobject in the batch, calls :meth:`.Camera.display_vectorized`. There, the actual background stroke, fill, and then stroke of the mobject is drawn onto the context. See :meth:`.Camera.apply_stroke` and :meth:`.Camera.set_cairo_context_color` for more details -- but it does not get much deeper than that, in the latter method the actual Bézier curves determined by the points of the mobject are drawn; this is where the low-level interaction with Cairo happens."
msgstr ""
#: ../../source/guides/deep_dive.rst:957
msgid "After all batches have been processed, the camera has an image representation of the Scene at the current time stamp in form of a NumPy array stored in its ``pixel_array`` attribute. The renderer then takes this array and passes it to its :class:`.SceneFileWriter`. This concludes one iteration of the render loop, and once the time progression has been processed completely, a final bit of cleanup is performed before the :meth:`.Scene.play_internal` call is completed."
msgstr ""
#: ../../source/guides/deep_dive.rst:964
msgid "A TL;DR for the render loop, in the context of our toy example, reads as follows:"
msgstr ""
#: ../../source/guides/deep_dive.rst:966
msgid "The scene finds that a 3 second long animation (the :class:`.ReplacementTransform` changing the orange square to the blue circle) should be played. Given the requested medium render quality, the frame rate is 30 frames per second, and so the time progression with steps ``[0, 1/30, 2/30, ..., 89/30]`` is created."
msgstr ""
#: ../../source/guides/deep_dive.rst:970
msgid "In the internal render loop, each of these time stamps is processed: there are no updater functions, so effectively the scene updates the state of the transformation animation to the desired time stamp (for example, at time stamp ``t = 45/30``, the animation is completed to a rate of ``alpha = 0.5``)."
msgstr ""
#: ../../source/guides/deep_dive.rst:975
msgid "Then the scene asks the renderer to do its job. The renderer asks its camera to capture the scene, the only mobject that needs to be processed at this point is the main mobject attached to the transformation; the camera converts the current state of the mobject to entries in a NumPy array. The renderer passes this array to the file writer."
msgstr ""
#: ../../source/guides/deep_dive.rst:980
msgid "At the end of the loop, 90 frames have been passed to the file writer."
msgstr ""
#: ../../source/guides/deep_dive.rst:983
msgid "Completing the render loop"
msgstr ""
#: ../../source/guides/deep_dive.rst:985
msgid "The last few steps in the :meth:`.Scene.play_internal` call are not too exciting: for every animation, the corresponding :meth:`.Animation.finish` and :meth:`.Animation.clean_up_from_scene` methods are called."
msgstr ""
#: ../../source/guides/deep_dive.rst:991
msgid "Note that as part of :meth:`.Animation.finish`, the :meth:`.Animation.interpolate` method is called with an argument of 1.0 -- you might have noticed already that the last frame of an animation can sometimes be a bit off or incomplete. This is by current design! The last frame rendered in the render loop (and displayed for a duration of ``1 / frame_rate`` seconds in the rendered video) corresponds to the state of the animation ``1 / frame_rate`` seconds before it ends. To display the final frame as well in the video, we would need to append another ``1 / frame_rate`` seconds to the video -- which would then mean that a 1 second rendered Manim video would be slightly longer than 1 second. We decided against this at some point."
msgstr ""
#: ../../source/guides/deep_dive.rst:1001
msgid "In the end, the time progression is closed (which completes the displayed progress bar) in the terminal. With the closing of the time progression, the :meth:`.Scene.play_internal` call is completed, and we return to the renderer, which now orders the :class:`.SceneFileWriter` to close the movie pipe that has been opened for this animation: a partial movie file is written."
msgstr ""
#: ../../source/guides/deep_dive.rst:1007
msgid "This pretty much concludes the walkthrough of a :class:`.Scene.play` call, and actually there is not too much more to say for our toy example either: at this point, a partial movie file that represents playing the :class:`.ReplacementTransform` has been written. The initialization of the :class:`.Dot` happens analogous to the initialization of ``blue_circle``, which has been discussed above. The :meth:`.Mobject.add_updater` call literally just attaches a function to the ``updaters`` attribute of the ``small_dot``. And the remaining :meth:`.Scene.play` and :meth:`.Scene.wait` calls follow the exact same procedure as discussed in the render loop section above; each such call produces a corresponding partial movie file."
msgstr ""
#: ../../source/guides/deep_dive.rst:1018
msgid "Once the :meth:`.Scene.construct` method has been fully processed (and thus all of the corresponding partial movie files have been written), the scene calls its cleanup method :meth:`.Scene.tear_down`, and then asks its renderer to finish the scene. The renderer, in turn, asks its scene file writer to wrap things up by calling :meth:`.SceneFileWriter.finish`, which triggers the combination of the partial movie files into the final product."
msgstr ""

View file

@ -0,0 +1,14 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/guides/index.rst:4
#: ../../source/guides/index.rst:4
msgid "Table of Contents"
msgstr ""

View file

@ -0,0 +1,269 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/guides/using_text.rst:3
msgid "Rendering Text and Formulas"
msgstr ""
#: ../../source/guides/using_text.rst:5
msgid "There are two different ways by which you can render **Text** in videos:"
msgstr ""
#: ../../source/guides/using_text.rst:7
msgid "Using Pango (:mod:`~.text_mobject`)"
msgstr ""
#: ../../source/guides/using_text.rst:8
msgid "Using LaTeX (:mod:`~.tex_mobject`)"
msgstr ""
#: ../../source/guides/using_text.rst:10
msgid "If you want to render simple text, you should use either :class:`~.Text` or :class:`~.MarkupText`, or one of its derivatives like :class:`~.Paragraph`. See :ref:`using-text-objects` for more information."
msgstr ""
#: ../../source/guides/using_text.rst:14
msgid "LaTeX should be used when you need mathematical typesetting. See :ref:`rendering-with-latex` for more information."
msgstr ""
#: ../../source/guides/using_text.rst:20
msgid "Text Without LaTeX"
msgstr ""
#: ../../source/guides/using_text.rst:22
msgid "The simplest way to add text to your animations is to use the :class:`~.Text` class. It uses the `Pango library`_ to render text. With Pango, you can also render non-English alphabets like 你好 or こんにちは or 안녕하세요 or مرحبا بالعالم."
msgstr ""
#: ../../source/guides/using_text.rst:27
msgid "Here is a simple *Hello World* animation."
msgstr ""
#: ../../source/guides/using_text.rst:38
msgid "You can also use :class:`~.MarkupText` which allows the use of PangoMarkup (see the documentation of :class:`~.MarkupText` for details) to render text. For example:"
msgstr ""
#: ../../source/guides/using_text.rst:56
msgid "Working with :class:`~.Text`"
msgstr ""
#: ../../source/guides/using_text.rst:58
msgid "This section explains the properties of :class:`~.Text` and how can it be used in your animations."
msgstr ""
#: ../../source/guides/using_text.rst:62
msgid "Using Fonts"
msgstr ""
#: ../../source/guides/using_text.rst:64
msgid "You can set a different font using :attr:`~.Text.font`."
msgstr ""
#: ../../source/guides/using_text.rst:68
msgid "The font used must be installed in your system, and Pango should know about it. You can get a list of fonts using :func:`manimpango.list_fonts`."
msgstr ""
#: ../../source/guides/using_text.rst:85
msgid "Setting Slant and Weight"
msgstr ""
#: ../../source/guides/using_text.rst:86
msgid "Slant is the style of the Text, and it can be ``NORMAL`` (the default), ``ITALIC`` or ``OBLIQUE``. Usually, for many fonts both ``ITALIC`` and ``OBLIQUE`` look similar, but ``ITALIC`` uses **Roman Style**, whereas ``OBLIQUE`` uses **Italic Style**."
msgstr ""
#: ../../source/guides/using_text.rst:91
msgid "Weight specifies the boldness of a font. You can see a list of weights in :class:`manimpango.Weight`."
msgstr ""
#: ../../source/guides/using_text.rst:126
msgid "Using Colors"
msgstr ""
#: ../../source/guides/using_text.rst:128
msgid "You can set the color of the text using :attr:`~.Text.color`:"
msgstr ""
#: ../../source/guides/using_text.rst:138
msgid "You can use utilities like :attr:`~.Text.t2c` for coloring specific characters. This may be problematic if your text contains ligatures as explained in :ref:`iterating-text`."
msgstr ""
#: ../../source/guides/using_text.rst:142
msgid ":attr:`~Text.t2c` accepts two types of dictionaries,"
msgstr ""
#: ../../source/guides/using_text.rst:144
msgid "The keys can contain indices like ``[2:-1]`` or ``[4:8]``, this works similar to how `slicing <https://realpython.com/python-strings/#string-slicing>`_ works in Python. The values should be the color of the Text from :class:`~.Color`."
msgstr ""
#: ../../source/guides/using_text.rst:149
msgid "The keys contain words or characters which should be colored separately and the values should be the color from :class:`~.Color`:"
msgstr ""
#: ../../source/guides/using_text.rst:161
msgid "If you want to avoid problems when using colors (due to ligatures), consider using :class:`MarkupText`."
msgstr ""
#: ../../source/guides/using_text.rst:166
msgid "Using Gradients"
msgstr ""
#: ../../source/guides/using_text.rst:168
msgid "You can add a gradient using :attr:`~.Text.gradient`. The value must be an iterable of any length:"
msgstr ""
#: ../../source/guides/using_text.rst:179
msgid "You can also use :attr:`~.Text.t2g` for gradients with specific characters of the text. It shares a similar syntax to :ref:`the interface for colors <using-colors>`:"
msgstr ""
#: ../../source/guides/using_text.rst:203
msgid "Setting Line Spacing"
msgstr ""
#: ../../source/guides/using_text.rst:205
msgid "You can set the line spacing using :attr:`~.Text.line_spacing`:"
msgstr ""
#: ../../source/guides/using_text.rst:220
msgid "Disabling Ligatures"
msgstr ""
#: ../../source/guides/using_text.rst:222
msgid "By disabling ligatures you would get a one-to-one mapping between characters and submobjects. This fixes the issues with coloring text."
msgstr ""
#: ../../source/guides/using_text.rst:228
msgid "Be aware that using this method with text that heavily depends on ligatures (Arabic text) may yield unexpected results."
msgstr ""
#: ../../source/guides/using_text.rst:231
msgid "You can disable ligatures by passing ``disable_ligatures`` to :class:`Text`. For example:"
msgstr ""
#: ../../source/guides/using_text.rst:246
msgid "Iterating :class:`~.Text`"
msgstr ""
#: ../../source/guides/using_text.rst:248
msgid "Text objects behave like :class:`VGroups <.VGroup>`. Therefore, you can slice and index the text."
msgstr ""
#: ../../source/guides/using_text.rst:251
msgid "For example, you can set each letter to different color by iterating it."
msgstr ""
#: ../../source/guides/using_text.rst:265
msgid "Please note that `Ligature`_ can cause problems here. If you need a one-to-one mapping of characters to submobjects you should pass the ``disable_ligatures`` parameter to :class:`~.Text`. See :ref:`disable-ligatures`."
msgstr ""
#: ../../source/guides/using_text.rst:273
msgid "Working with :class:`~.MarkupText`"
msgstr ""
#: ../../source/guides/using_text.rst:275
msgid "MarkupText is similar to :class:`~.Text`, the only difference between them is that this accepts and processes PangoMarkup (which is similar to html), instead of just rendering plain text."
msgstr ""
#: ../../source/guides/using_text.rst:279
msgid "Consult the documentation of :class:`~.MarkupText` for more details and further references about PangoMarkup."
msgstr ""
#: ../../source/guides/using_text.rst:297
msgid "Text With LaTeX"
msgstr ""
#: ../../source/guides/using_text.rst:299
msgid "Just as you can use :class:`~.Text` to add text to your videos, you can use :class:`~.Tex` to insert LaTeX."
msgstr ""
#: ../../source/guides/using_text.rst:302
msgid "For example,"
msgstr ""
#: ../../source/guides/using_text.rst:314
msgid "Note that we are using a raw string (``r'...'``) instead of a regular string (``'...'``). This is because TeX code uses a lot of special characters - like ``\\`` for example - that have special meaning within a regular python string. An alternative would have been to write ``\\\\`` to escape the backslash: ``Tex('\\\\LaTeX')``."
msgstr ""
#: ../../source/guides/using_text.rst:320
msgid "Working with :class:`~.MathTex`"
msgstr ""
#: ../../source/guides/using_text.rst:322
msgid "Everything passed to :class:`~.MathTex` is in math mode by default. To be more precise, :class:`~.MathTex` is processed within an ``align*`` environment. You can achieve a similar effect with :class:`~.Tex` by enclosing your formula with ``$`` symbols: ``$\\xrightarrow{x^6y^8}$``:"
msgstr ""
#: ../../source/guides/using_text.rst:339
msgid "LaTeX commands and keyword arguments"
msgstr ""
#: ../../source/guides/using_text.rst:341
msgid "We can use any standard LaTeX commands in the AMS maths packages. Such as the ``mathtt`` math-text type or the ``looparrowright`` arrow."
msgstr ""
#: ../../source/guides/using_text.rst:352
msgid "On the Manim side, the :class:`~.Tex` class also accepts attributes to change the appearance of the output. This is very similar to the :class:`~.Text` class. For example, the ``color`` keyword changes the color of the TeX mobject."
msgstr ""
#: ../../source/guides/using_text.rst:366
msgid "Extra LaTeX Packages"
msgstr ""
#: ../../source/guides/using_text.rst:368
msgid "Some commands require special packages to be loaded into the TeX template. For example, to use the ``mathscr`` script, we need to add the ``mathrsfs`` package. Since this package isn't loaded into Manim's tex template by default, we have to add it manually."
msgstr ""
#: ../../source/guides/using_text.rst:388
msgid "Substrings and parts"
msgstr ""
#: ../../source/guides/using_text.rst:390
msgid "The TeX mobject can accept multiple strings as arguments. Afterwards you can refer to the individual parts either by their index (like ``tex[1]``), or by selecting parts of the tex code. In this example, we set the color of the ``\\bigstar`` using :func:`~.set_color_by_tex`:"
msgstr ""
#: ../../source/guides/using_text.rst:404
msgid "Note that :func:`~.set_color_by_tex` colors the entire substring containing the Tex, not just the specific symbol or Tex expression. Consider the following example:"
msgstr ""
#: ../../source/guides/using_text.rst:418
msgid "As you can see, this colors the entire equation yellow, contrary to what may be expected. To color only ``x`` yellow, we have to do the following:"
msgstr ""
#: ../../source/guides/using_text.rst:433
msgid "By setting ``substrings_to_isolate`` to ``x``, we split up the :class:`~.MathTex` into substrings automatically and isolate the ``x`` components into individual substrings. Only then can :meth:`~.set_color_by_tex` be used to achieve the desired result."
msgstr ""
#: ../../source/guides/using_text.rst:438
msgid "Note that Manim also supports a custom syntax that allows splitting a TeX string into substrings easily: simply enclose parts of your formula that you want to isolate with double braces. In the string ``MathTex(r\"{{ a^2 }} + {{ b^2 }} = {{ c^2 }}\")``, the rendered mobject will consist of the substrings ``a^2``, ``+``, ``b^2``, ``=``, and ``c^2``. This makes transformations between similar text fragments easy to write using :class:`~.TransformMatchingTex`."
msgstr ""
#: ../../source/guides/using_text.rst:447
msgid "Using ``index_labels`` to work with complicated strings"
msgstr ""
#: ../../source/guides/using_text.rst:449
msgid "You might sometimes be working with a very complicated :class:`~.MathTex` mobject that makes it difficult to work with its individual components. This is where the debugging function :func:`.index_labels` is very useful."
msgstr ""
#: ../../source/guides/using_text.rst:453
msgid "The method shows the index of a mobject's submobjects, allowing you to easily find the components of the mobject you would like to change."
msgstr ""
#: ../../source/guides/using_text.rst:472
msgid "LaTeX Maths Fonts - The Template Library"
msgstr ""
#: ../../source/guides/using_text.rst:474
msgid "Changing fonts in LaTeX when typesetting mathematical formulae is trickier than regular text. It requires changing the template that is used to compile the TeX. Manim comes with a collection of :class:`~.TexFontTemplates` ready for you to use. These templates will all work in math mode:"
msgstr ""
#: ../../source/guides/using_text.rst:491
msgid "Manim also has a :class:`~.TexTemplateLibrary` containing the TeX templates used by 3Blue1Brown. One example is the ctex template, used for typesetting Chinese script. For this to work, the ctex LaTeX package must be installed on your system. Furthermore, if you are only typesetting Text, you probably do not need :class:`~.Tex` at all, and should use :class:`~.Text` instead."
msgstr ""
#: ../../source/guides/using_text.rst:508
msgid "Aligning formulae"
msgstr ""

View file

@ -7,15 +7,107 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/index.rst:7
msgid "Manim Community Overview"
msgid "Manim Community Edition"
msgstr ""
#: ../../source/index.rst:9
msgid "Animating technical concepts is traditionally pretty tedious since it can be difficult to make the animations precise enough to convey them accurately. Manim relies on Python's simplicity to generate animations programmatically, making it convenient to specify exactly how each one should run. Take a look at the :doc:`Example Gallery <../examples>` for some inspiration on how to create beautiful images and videos with Manim."
msgstr ""
#: ../../source/index.rst:16
#: ../../source/index.rst:17
msgid "First Steps"
msgstr ""
#: ../../source/index.rst:19
msgid "Are you new to Manim and are looking for where to get started? Then you are in the right place!"
msgstr ""
#: ../../source/index.rst:24
msgid "Please be aware that there are different, incompatible versions of Manim available. Check our :ref:`installation FAQ <different-versions>` to learn more!"
msgstr ""
#: ../../source/index.rst:28
msgid "The :doc:`Installation <installation>` section has the latest and up-to-date installation instructions for Windows, MacOS, and Linux. You can also find information on Manim's docker images and (online) notebook environments there."
msgstr ""
#: ../../source/index.rst:32
msgid "Want to try the library before installing it? Take a look at our interactive online playground at https://try.manim.community in form of a Jupyter notebook."
msgstr ""
#: ../../source/index.rst:35
msgid "In our :doc:`Tutorials <tutorials/index>` section you will find a collection of resources that will teach you how to use Manim. In particular, the :doc:`tutorials/quickstart` tutorial teaches you Manim's basics, and in :doc:`tutorials/building_blocks` the classes used to compose your animations are described in more detail."
msgstr ""
#: ../../source/index.rst:43
msgid "Finding Help"
msgstr ""
#: ../../source/index.rst:45
msgid "Are you struggling with installing or using Manim? Don't worry, we've all been there. Here are some good resources to help you out:"
msgstr ""
#: ../../source/index.rst:48
msgid "Perhaps your problem is one that occurs frequently, then chances are it is addressed in our :doc:`collection of FAQs <faq/index>`."
msgstr ""
#: ../../source/index.rst:50
msgid "If you are looking for information on some specific class, look for it in the :doc:`reference manual <reference>` and/or use the search feature of the documentation."
msgstr ""
#: ../../source/index.rst:53
msgid "Still no luck? Then you are welcome to ask the community for help, together we usually manage to find a solution for your problem! Consult the :doc:`FAQ page on getting help <faq/help>` for instructions."
msgstr ""
#: ../../source/index.rst:59
msgid "Navigating the Documentation"
msgstr ""
#: ../../source/index.rst:61
msgid "Here are some short summaries for all of the sections in this documentation:"
msgstr ""
#: ../../source/index.rst:63
msgid "The :doc:`Example Gallery </examples>` is a collection of examples (rendered videos and images together with the code they were generated from) that show a few different, simple things that you can do with Manim."
msgstr ""
#: ../../source/index.rst:66
msgid "The :doc:`Installation </installation>` section has information on installing Manim."
msgstr ""
#: ../../source/index.rst:67
msgid "In :doc:`Tutorials & Guides </tutorials_guides>` you can find learning resources: proper tutorials that guide you through the process of creating a video are in the :doc:`Tutorial </tutorials/index>` section; guides on specific topics are in the :doc:`Guides </guides/index>` section, and the answers to frequently asked questions can be found in the :doc:`FAQ </faq/index>` section."
msgstr ""
#: ../../source/index.rst:72
msgid "The :doc:`Reference Manual </reference>` contains a comprehensive list of all of Manim's (documented) modules, classes, and functions. If you are somewhat familiar with Manim's module structure feel free to browse the manual directly. If you are searching for something specific, feel free to use the documentation's search feature in the sidebar. Many classes and methods come with their own illustrated examples too!"
msgstr ""
#: ../../source/index.rst:77
msgid "The :doc:`Plugins </plugins>` page documents how to install, write, and distribute plugins (that is, separate Python packages that extend the feature set of the core library)."
msgstr ""
#: ../../source/index.rst:79
msgid "Changes between versions are documented in our :doc:`Changelog </changelog>`."
msgstr ""
#: ../../source/index.rst:80
msgid "If you are looking into contributing to the development of Manim, you can find information on how to get involved in our :doc:`Contributing </contributing>` section."
msgstr ""
#: ../../source/index.rst:82
msgid "And finally, the :doc:`Code of Conduct </conduct>` page has a formal description of the rules you should abide by when interacting within our community."
msgstr ""
#: ../../source/index.rst:86
msgid "Sharing Your Work"
msgstr ""
#: ../../source/index.rst:88
msgid "We'd love to hear from you and see your manimations `on Twitter <https://twitter.com/manim_community>`_, `Reddit <https://www.reddit.com/r/manim/>`_, or `Discord <https://www.manim.community/discord/>`_. If you're using Manim in a scientific context, instructions on how to cite a particular release can be found `in our README <https://github.com/ManimCommunity/manim/blob/main/README.md>`_."
msgstr ""
#: ../../source/index.rst:95
msgid "Index"
msgstr ""

View file

@ -19,7 +19,7 @@ msgid "Otherwise, if you intend to use Manim to work on an animation project, we
msgstr ""
#: ../../source/installation.rst:16
msgid "Note that there are several different versions of Manim. The instructions on this website are **only** for the *community edition*. Find out more about the :doc:`differences between Manim versions <installation/versions>` if you are unsure which version you should install."
msgid "Note that there are several different versions of Manim. The instructions on this website are **only** for the *community edition*. Find out more about the :ref:`differences between Manim versions <different-versions>` if you are unsure which version you should install."
msgstr ""
#: ../../source/installation.rst:22
@ -50,47 +50,47 @@ msgstr ""
msgid "Depending on your particular setup, the installation process might be slightly different. Make sure that you have tried to follow the steps on the following pages carefully, but in case you hit a wall we are happy to help: either `join our Discord <https://www.manim.community/discord/>`__, or start a new Discussion `directly on GitHub <https://github.com/ManimCommunity/manim/discussions>`__."
msgstr ""
#: ../../source/installation.rst:59
#: ../../source/installation.rst:58
msgid "Once Manim is installed locally, you can proceed to our :doc:`quickstart guide <tutorials/quickstart>` which walks you through rendering a first simple scene."
msgstr ""
#: ../../source/installation.rst:63
msgid "As mentioned above, do not worry if there are errors or other problems: consult our :doc:`troubleshooting guide <installation/troubleshooting>` for help, or get in touch with the community via `GitHub discussions <https://github.com/ManimCommunity/manim/discussions>`__ or `Discord <https://www.manim.community/discord/>`__."
#: ../../source/installation.rst:62
msgid "As mentioned above, do not worry if there are errors or other problems: consult our :doc:`FAQ section </faq/index>` for help (including instructions for how to ask Manim's community for help)."
msgstr ""
#: ../../source/installation.rst:75
#: ../../source/installation.rst:71
msgid "Using Manim via Docker"
msgstr ""
#: ../../source/installation.rst:77
#: ../../source/installation.rst:73
msgid "`Docker <https://www.docker.com>`__ is a virtualization tool that allows the distribution of encapsulated software environments (containers)."
msgstr ""
#: ../../source/installation.rst:80
#: ../../source/installation.rst:76
msgid "The following pages contain more information about the docker image maintained by the community, ``manimcommunity/manim``:"
msgstr ""
#: ../../source/installation.rst:91
#: ../../source/installation.rst:87
msgid "Interactive Jupyter notebooks for your browser"
msgstr ""
#: ../../source/installation.rst:93
#: ../../source/installation.rst:89
msgid "Manim ships with a built-in ``%%manim`` IPython magic command designed for the use within `Jupyter notebooks <https://jupyter.org>`__. Our interactive tutorial over at https://try.manim.community illustrates how Manim can be used from within a Jupyter notebook."
msgstr ""
#: ../../source/installation.rst:98
#: ../../source/installation.rst:94
msgid "The following pages explain how you can setup interactive environments like that yourself:"
msgstr ""
#: ../../source/installation.rst:108
#: ../../source/installation.rst:104
msgid "Editors"
msgstr ""
#: ../../source/installation.rst:110
#: ../../source/installation.rst:106
msgid "If you're using Visual Studio Code you can install an extension called *Manim Sideview* which provides automated rendering and an integrated preview of the animation inside the editor. The extension can be installed through the `marketplace of VS Code <https://marketplace.visualstudio.com/items?itemName=Rickaym.manim-sideview>`__."
msgstr ""
#: ../../source/installation.rst:117
#: ../../source/installation.rst:113
msgid "Installation for developers"
msgstr ""

View file

@ -1,305 +1 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/installation/troubleshooting.rst:2
msgid "Troubleshooting"
msgstr ""
#: ../../source/installation/troubleshooting.rst:5
msgid "Version incompatibility"
msgstr ""
#: ../../source/installation/troubleshooting.rst:7
msgid "Confusion and conflict between versions is by far the most common reason for installation failures. Some signs and errors resulting from this are as follows:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:11
msgid "``There are no scenes in that module``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:12
msgid "``ModuleNotFoundError: No module named 'manim'``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:13
msgid "``ModuleNotFoundError: No module named 'manimlib'``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:14
msgid "You followed any tutorial created before October 2020 (because the community edition did not exist before then)"
msgstr ""
#: ../../source/installation/troubleshooting.rst:15
msgid "You cloned a repository on GitHub (installation of the community version for normal use does not require the cloning of any repository)"
msgstr ""
#: ../../source/installation/troubleshooting.rst:16
msgid "Different import statements (explained below)"
msgstr ""
#: ../../source/installation/troubleshooting.rst:17
msgid "You used documentation for multiple versions (such as the readme for 3b1b/manim and this documentation)"
msgstr ""
#: ../../source/installation/troubleshooting.rst:20
msgid "As this is the documentation for the community version, we can only help with the installation of this library. If you would like to install other versions of manim, please refer to their documentation."
msgstr ""
#: ../../source/installation/troubleshooting.rst:25
msgid "Identifying files written for a different version of manim"
msgstr ""
#: ../../source/installation/troubleshooting.rst:27
msgid "There are some distinctive features of different versions of manim that can help in identifying what version of manim files are written for:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:31
msgid "Feature"
msgstr ""
#: ../../source/installation/troubleshooting.rst:31
msgid "ManimCE (this version)"
msgstr ""
#: ../../source/installation/troubleshooting.rst:31
msgid "ManimGL"
msgstr ""
#: ../../source/installation/troubleshooting.rst:31
msgid "ManimCairo"
msgstr ""
#: ../../source/installation/troubleshooting.rst:33
msgid "Import statement"
msgstr ""
#: ../../source/installation/troubleshooting.rst:33
msgid "``from manim import *``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:33
msgid "``from manimlib import *``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:33
msgid "``from manimlib.imports import *``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:37
msgid "If you are a beginner, you should only attempt to run files written for your version. Files written for a different version of manim will generally not work without some modification."
msgstr ""
#: ../../source/installation/troubleshooting.rst:42
msgid "Identifying the version you are running"
msgstr ""
#: ../../source/installation/troubleshooting.rst:44
msgid "The community edition of manim should always state `Manim Community <version_number>` as its first line of any command you run."
msgstr ""
#: ../../source/installation/troubleshooting.rst:48
msgid "Identifying and removing conflicting versions of manim"
msgstr ""
#: ../../source/installation/troubleshooting.rst:50
msgid "Within the system or environment you are using to run manim, run the following command in the terminal:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:57
msgid "The correct package for the community edition is simply ``manim``. If you do not see this package listed, please refer back to our installation guide to install it. If you see ``manimlib`` or ``manimce`` (actually an old version of the community edition), you should remove them with:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:68
msgid "If you have cloned a repository from GitHub, you should either remove it or run manim outside that folder."
msgstr ""
#: ../../source/installation/troubleshooting.rst:72
msgid "Other errors"
msgstr ""
#: ../../source/installation/troubleshooting.rst:75
msgid "``pip install manim`` fails when installing manimpango?"
msgstr ""
#: ../../source/installation/troubleshooting.rst:76
msgid "Most likely this means that pip was not able to use our pre-built wheels of ``manimpango``. Let us know (via our `Discord <https://www.manim.community/discord/>`_ or by opening a `new issue on GitHub <https://github.com/ManimCommunity/ManimPango/issues/new>`_) which architecture you would like to see supported, and we'll see what we can do about it."
msgstr ""
#: ../../source/installation/troubleshooting.rst:83
msgid "To fix errors when installing ``manimpango``, you need to make sure you have all the necessary build requirements. Check out the detailed instructions given in `the BUILDING section <https://github.com/ManimCommunity/ManimPango#BUILDING>`_ of the corresponding `GitHub repository <https://github.com/ManimCommunity/ManimPango>`_."
msgstr ""
#: ../../source/installation/troubleshooting.rst:91
msgid "(Windows) OSError: dlopen() failed to load a library: pango?"
msgstr ""
#: ../../source/installation/troubleshooting.rst:93
msgid "This should be fixed in Manim's latest version, update using ``pip install --upgrade manim``."
msgstr ""
#: ../../source/installation/troubleshooting.rst:99
msgid "Some letters are missing from Text/Tex output?"
msgstr ""
#: ../../source/installation/troubleshooting.rst:101
msgid "If you have recently installed TeX you may need to build the fonts it uses. Which can be done by running:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:112
msgid "Installation does not support converting PDF to SVG?"
msgstr ""
#: ../../source/installation/troubleshooting.rst:114
msgid "First, make sure your ``dvisvgm`` version is at least 2.4:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:121
msgid "If you do not know how to update ``dvisvgm``, please refer to your operating system's documentation."
msgstr ""
#: ../../source/installation/troubleshooting.rst:123
msgid "Second, check whether your ``dvisvgm`` supports PostScript specials. This is needed to convert from PDF to SVG."
msgstr ""
#: ../../source/installation/troubleshooting.rst:131
msgid "If the output to this command does **not** contain ``ps dvips PostScript specials``, this is a bad sign. In this case, run"
msgstr ""
#: ../../source/installation/troubleshooting.rst:139
msgid "If the output does **not** contain ``--libgs=filename``, this means your ``dvisvgm`` does not currently support PostScript. You must get another binary."
msgstr ""
#: ../../source/installation/troubleshooting.rst:142
msgid "If, however, ``--libgs=filename`` appears in the help, that means that your ``dvisvgm`` needs the Ghostscript library to support PostScript. Search for ``libgs.so`` (on Linux, probably in ``/usr/local/lib`` or ``/usr/lib``) or ``gsdll32.dll`` (on 32-bit Windows, probably in ``C:\\windows\\system32``) or ``gsdll64.dll`` (on 64-bit Windows, probably in ``c:\\windows\\system32`` -- yes 32) or ``libgsl.dylib`` (on Mac OS, probably in ``/usr/local/lib`` or ``/opt/local/lib``). Please look carefully, as the file might be located elsewhere, e.g. in the directory where Ghostscript is installed."
msgstr ""
#: ../../source/installation/troubleshooting.rst:151
msgid "As soon as you have found the library, try (on Mac OS or Linux)"
msgstr ""
#: ../../source/installation/troubleshooting.rst:158
msgid "or (on Windows)"
msgstr ""
#: ../../source/installation/troubleshooting.rst:166
msgid "You should now see ``ps dvips PostScript specials`` in the output. Refer to your operating system's documentation to find out how you can set or export the environment variable ``LIBGS`` automatically whenever you open a shell."
msgstr ""
#: ../../source/installation/troubleshooting.rst:170
msgid "As a last check, you can run"
msgstr ""
#: ../../source/installation/troubleshooting.rst:176
msgid "while still having ``LIBGS`` set to the correct path, of course. If ``dvisvgm`` can find your Ghostscript installation, it will be shown in the output together with the version number."
msgstr ""
#: ../../source/installation/troubleshooting.rst:180
msgid "If you do not have the necessary library on your system, please refer to your operating system's documentation to find out where you can get it and how you have to install it."
msgstr ""
#: ../../source/installation/troubleshooting.rst:184
msgid "If you are unable to solve your problem, check out the `dvisvgm FAQ <https://dvisvgm.de/FAQ/>`_."
msgstr ""
#: ../../source/installation/troubleshooting.rst:187
msgid "(Windows) ``Python is not recognized as an internal or external command, operable program or batch file.``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:189
msgid "To fix this, you need to add the Python executable to your ``PATH`` environment variable. Follow the steps in `this StackExchange answer <https://superuser.com/questions/143119/how-do-i-add-python-to-the-windows-path/143121#143121>`__."
msgstr ""
#: ../../source/installation/troubleshooting.rst:193
msgid "``choco install manimce`` failed"
msgstr ""
#: ../../source/installation/troubleshooting.rst:195
msgid "If ``choco install manimce`` failed, it is likely being caused by Python not being added to your ``PATH`` variable properly. Try running the following commands in your terminal:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:199
msgid "``py --version``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:200
msgid "``python --version``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:201
msgid "``py3 --version``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:202
msgid "``python3 --version``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:204
msgid "Minimally, ``py --version`` and ``python --version`` should return a version. If none of these commands are recognized, this means that Python was installed on your system, but was not added to PATH. See above for directions to add it to your PATH variable."
msgstr ""
#: ../../source/installation/troubleshooting.rst:209
msgid "If any of these commands opens up the Windows store, this is likely interfering with the process. This is because Chocolatey runs a command that calls python or python3, and opening up the Windows store is not the expected behavior. See below to fix aliases."
msgstr ""
#: ../../source/installation/troubleshooting.rst:216
msgid "(Windows) Fix Aliases"
msgstr ""
#: ../../source/installation/troubleshooting.rst:218
msgid "Go to the Windows Settings."
msgstr ""
#: ../../source/installation/troubleshooting.rst:219
msgid "Under Apps and Features, there are an application execution aliases."
msgstr ""
#: ../../source/installation/troubleshooting.rst:220
msgid "Within this menu disable the alias(es) that is causing the issue (``python`` and/or ``python3``)."
msgstr ""
#: ../../source/installation/troubleshooting.rst:223
msgid "``IndexError: List index out of range``"
msgstr ""
#: ../../source/installation/troubleshooting.rst:225
msgid "Did you install LaTeX using MiKTeX? If so, open the MiKTeX console, install the ``cm-super`` package, then delete the ``media`` directory and try to render the scene again."
msgstr ""
#: ../../source/installation/troubleshooting.rst:230
msgid "Config"
msgstr ""
#: ../../source/installation/troubleshooting.rst:232
msgid "We've dropped the use of CONFIG in the Community Version :doc:`version 0.2.0<../changelog/0.2.0-changelog>`, released in January 2021. This means parameters that were previously specified in the CONFIG dictionary should now be passed directly into the constructor. Practically, this means that old constructions like:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:249
msgid "should now be defined like:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:269
msgid "For scenes, this is even easier:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:276
msgid "becomes:"
msgstr ""
#: ../../source/installation/troubleshooting.rst:286
msgid "A python command does not work"
msgstr ""
#: ../../source/installation/troubleshooting.rst:288
msgid "If a python command does not work, try adding ``python -m`` in front of it. For example, if ``pip install manim`` does not work, you can try ``python -m pip install manim``."
msgstr ""
#: ../../source/installation/troubleshooting.rst:293
msgid "undefined symbol"
msgstr ""

View file

@ -1,69 +1 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/installation/versions.rst:2
msgid "Differences between Manim Versions"
msgstr ""
#: ../../source/installation/versions.rst:4
msgid "While originally a single library, there are now three main versions of manim, each with their own advantages, disadvantages, and ideal use cases. It is important to understand these differences in order to select the best version for your use case and avoid confusion arising from version mismatches."
msgstr ""
#: ../../source/installation/versions.rst:10
msgid "A brief history of Manim"
msgstr ""
#: ../../source/installation/versions.rst:12
msgid "Manim was originally created by Grant Sanderson as a personal project and for use in his YouTube channel, `3Blue1Brown <https://www.youtube.com/channel/UCYO_jab_esuFRV4b17AJtAw>`_. As his channel gained popularity, many grew to like the style of his animations and wanted to use manim for their own projects. However, as manim was only intended for personal use, it was very difficult for other users to install and use it."
msgstr ""
#: ../../source/installation/versions.rst:18
msgid "In late 2019, Grant started working on faster OpenGL rendering in a new branch, known as the shaders branch. In mid-2020, a group of developers forked it into what is now the community edition; this is the version documented on this website. In early 2021, Grant merged the shaders branch back into master, making it the default branch in his repository. The old version is still available as the branch ``cairo-backend``."
msgstr ""
#: ../../source/installation/versions.rst:25
msgid "The three versions of Manim"
msgstr ""
#: ../../source/installation/versions.rst:27
msgid "There are currently three main versions of manim. They are as follows:"
msgstr ""
#: ../../source/installation/versions.rst:29
msgid "**ManimCE**: The community edition of manim. This is the version documented by this website, and is named `manim <https://pypi.org/project/manim/>`_ on pip."
msgstr ""
#: ../../source/installation/versions.rst:30
msgid "`ManimGL <https://github.com/3b1b/manim>`_: The current version of manim that is used by 3blue1brown. It supports OpenGL rendering and interactivity, and is named ``manimgl`` on pip. You can find documentation for it `here <https://3b1b.github.io/manim/index.html>`_."
msgstr ""
#: ../../source/installation/versions.rst:31
msgid "`ManimCairo <https://github.com/3b1b/manim/tree/cairo-backend>`_: The old version of manim originally used by 3blue1brown. It is not available on pip."
msgstr ""
#: ../../source/installation/versions.rst:34
msgid "Which version to use"
msgstr ""
#: ../../source/installation/versions.rst:35
msgid "We recommend using the community edition for most purposes, as it has been developed to be more stable, better tested, quicker to respond to community contributions, and easier for beginners to use. It also has partial experimental OpenGL support and should have full support shortly (as of April 2021)."
msgstr ""
#: ../../source/installation/versions.rst:39
msgid "If you would like to use a version with full OpenGL support or render recent 3Blue1Brown videos (2020 onwards), you should use ManimGL."
msgstr ""
#: ../../source/installation/versions.rst:41
msgid "If you would like to render old 3Blue1Brown projects (2019 and before), you should use ManimCairo."
msgstr ""
#: ../../source/installation/versions.rst:44
msgid "Notes on installation, documentation, and use"
msgstr ""

View file

@ -1,17 +1 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/internals.rst:2
msgid "Internal structure"
msgstr ""
#: ../../source/internals.rst:4
msgid "Efforts to document the internal structure of Manim is ongoing on our `wiki <https://github.com/ManimCommunity/manim/wiki/Developer-documentation-(WIP)>`_."
msgstr ""

View file

@ -11,7 +11,7 @@ msgid "Reference Manual"
msgstr ""
#: ../../source/reference.rst:4
msgid "This reference manual details modules, functions, and variables included in Manim, describing what they are and what they do. For learning how to use Manim, see :doc:`tutorials`. For a list of changes since the last release, see the :doc:`changelog`."
msgid "This reference manual details modules, functions, and variables included in Manim, describing what they are and what they do. For learning how to use Manim, see :doc:`tutorials/index`. For a list of changes since the last release, see the :doc:`changelog`."
msgstr ""
#: ../../source/reference.rst:9
@ -26,15 +26,15 @@ msgstr ""
msgid "Animations"
msgstr ""
#: ../../source/reference.rst:37
#: ../../source/reference.rst:38
msgid "Cameras"
msgstr ""
#: ../../source/reference.rst:49
#: ../../source/reference.rst:50
msgid "Mobjects"
msgstr ""
#: ../../source/reference.rst:87
#: ../../source/reference.rst:88
msgid "Scenes"
msgstr ""

View file

@ -50,7 +50,6 @@ msgid "A parser containing any .cfg files in use."
msgstr ""
#: ../../../manim/_config/logger_utils.py:docstring of manim._config.logger_utils.make_logger:5
#: ../../../manim/_config/logger_utils.py:docstring of manim._config.logger_utils.set_file_logger:7
msgid "The verbosity level of the logger."
msgstr ""
@ -70,7 +69,6 @@ msgid "Return type"
msgstr ""
#: ../../../manim/_config/logger_utils.py:docstring of manim._config.logger_utils.make_logger:16
#: ../../../manim/_config/logger_utils.py:docstring of manim._config.logger_utils.set_file_logger:11
msgid "Notes"
msgstr ""
@ -94,8 +92,4 @@ msgstr ""
msgid "The path to the file is built using ``config.log_dir``."
msgstr ""
#: ../../../manim/_config/logger_utils.py:docstring of manim._config.logger_utils.set_file_logger:5
msgid "The global config, used to determine the log file path."
msgstr ""

View file

@ -54,50 +54,54 @@ msgid "Examples"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:25
msgid "We use a copy of the global configuration object in the following examples for the sake of demonstration; you can skip these lines and just import ``config`` directly if you actually want to modify the configuration:"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:35
msgid "Each config option allows for dict syntax and attribute syntax. For example, the following two lines are equivalent,"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:34
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:44
msgid "The former is preferred; the latter is provided mostly for backwards compatibility."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:37
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:47
msgid "The config options are designed to keep internal consistency. For example, setting ``frame_y_radius`` will affect ``frame_height``:"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:48
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:58
msgid "There are many ways of interacting with config options. Take for example the config option ``background_color``. There are three ways to change it: via a config file, via CLI flags, or programmatically."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:52
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:62
msgid "To set the background color via a config file, save the following ``manim.cfg`` file with the following contents."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:60
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:70
msgid "In order to have this ``.cfg`` file apply to a manim scene, it needs to be placed in the same directory as the script,"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:69
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:79
msgid "Now, when the user executes"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:75
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:85
msgid "the background of the scene will be set to ``WHITE``. This applies regardless of where the manim command is invoked from."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:78
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:88
msgid "Command line arguments override ``.cfg`` files. In the previous example, executing"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:85
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:95
msgid "will set the background color to BLUE, regardless of the contents of ``manim.cfg``."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:88
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:98
msgid "Finally, any programmatic changes made within the scene script itself will override the command line arguments. For example, if ``scene.py`` contains the following"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:101
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig:111
msgid "the background color will be set to RED, regardless of the contents of ``manim.cfg`` or the CLI arguments used when invoking manim."
msgstr ""
@ -196,6 +200,11 @@ msgstr ""
msgid "Enable wireframe debugging mode in opengl."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.ffmpeg_executable:1
msgid "Manually specify the path to the ffmpeg executable"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.ffmpeg_loglevel:1
msgid "Verbosity level of ffmpeg (no flag)."
@ -348,7 +357,7 @@ msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.renderer:1
msgid "\"cairo\", \"opengl\", \"webgl"
msgid "\"cairo\", \"opengl"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
@ -435,11 +444,6 @@ msgstr ""
msgid "Use shaders for OpenGLVMobject stroke which are compatible with transformation matrices."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.use_webgl_renderer:1
msgid "Whether or not to use WebGL renderer."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.verbosity:1
msgid "Logger verbosity; \"DEBUG\", \"INFO\", \"WARNING\", \"ERROR\", or \"CRITICAL\" (-v)."
@ -449,11 +453,6 @@ msgstr ""
msgid "Directory to place videos (no flag)."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.webgl_renderer_path:1
msgid "Path to WebGL renderer."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.aspect_ratio:1:<autosummary>:1
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.window_monitor:1
msgid "The monitor on which the scene will be rendered"
@ -597,23 +596,23 @@ msgstr ""
msgid "The value of ``config.tex_dir`` is ``'{media_dir}/Tex'`` by default, i.e. it is a subfolder of wherever ``config.media_dir`` is located. In order to get the *actual* directory, use :meth:`~ManimConfig.get_dir`."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:40
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:41
msgid "Resolving directories is done in a lazy way, at the last possible moment, to reflect any changes in other config options:"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:49
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:50
msgid "Some directories depend on information that is not available to :class:`ManimConfig`. For example, the default value of `video_dir` includes the name of the input file and the video quality (e.g. 480p15). This informamtion has to be supplied via ``kwargs``:"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:64
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:65
msgid "Note the quality does not need to be passed as keyword argument since :class:`ManimConfig` does store information about quality."
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:67
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:68
msgid "Directories may be recursively defined. For example, the config option ``partial_movie_dir`` depends on ``video_dir``, which in turn depends on ``media_dir``:"
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:83
#: ../../../manim/_config/utils.py:docstring of manim._config.utils.ManimConfig.get_dir:84
msgid "Standard f-string syntax is used. Arbitrary names can be used when defining directories, as long as the corresponding values are passed to :meth:`ManimConfig.get_dir` via ``kwargs``."
msgstr ""

View file

@ -19,7 +19,7 @@ msgid "The main class exported by this module is :class:`ManimConfig`. This cla
msgstr ""
#: ../../../manim/_config/utils.py:docstring of manim._config.utils:9
msgid "See :doc:`/tutorials/configuration` for an introduction to Manim's configuration system."
msgid "See :doc:`/guides/configuration` for an introduction to Manim's configuration system."
msgstr ""
#: ../../source/reference/manim._config.utils.rst:15

View file

@ -70,23 +70,43 @@ msgstr ""
msgid "For example ``rate_func(0.5)`` is the proportion of the animation that is done after half of the animations run time."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:17
msgid "The name of the animation. This gets displayed while rendering the animation. Defaults to <class-name>(<Mobject-name>)."
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:21
msgid "reverse_rate_function"
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:19
msgid "Whether the given mobject should be removed from the scene after this animation."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:20
msgid "Whether updaters of the mobject should be suspended during the animation."
msgid "Reverses the rate function of the animation. Setting ``reverse_rate_function`` does not have any effect on ``remover`` or ``introducer``. These need to be set explicitly if an introducer-animation should be turned into a remover one and vice versa."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:24
msgid "name"
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:24
msgid "The name of the animation. This gets displayed while rendering the animation. Defaults to <class-name>(<Mobject-name>)."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:26
msgid "remover"
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:27
msgid "Whether the given mobject should be removed from the scene after this animation."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:30
msgid "suspend_mobject_updating"
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:29
msgid "Whether updaters of the mobject should be suspended during the animation."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:34
msgid "In the current implementation of this class, the specified rate function is applied within :meth:`.Animation.interpolate_mobject` call as part of the call to :meth:`.Animation.interpolate_submobject`. For subclasses of :class:`.Animation` that are implemented by overriding :meth:`interpolate_mobject`, the rate function has to be applied manually (e.g., by passing ``self.rate_func(alpha)`` instead of just ``alpha``)."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:33
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation:43
msgid "Examples"
msgstr ""
@ -149,11 +169,14 @@ msgstr ""
msgid "Interpolates the mobject of the :class:`Animation` based on alpha value."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.begin:1:<autosummary>:1
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.begin:1:<autosummary>:1
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.is_introducer:1
msgid "Test if the animation is an introducer."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.begin:1:<autosummary>:1
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.is_remover:1
msgid "Test if a the animation is a remover."
msgid "Test if the animation is a remover."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.begin:1:<autosummary>:1
@ -278,6 +301,9 @@ msgid "A float between 0 and 1 expressing the ratio to which the animation is co
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.is_introducer:3
msgid "``True`` if the animation is an introducer, ``False`` otherwise."
msgstr ""
#: ../../../manim/animation/animation.py:docstring of manim.animation.animation.Animation.is_remover:3
msgid "``True`` if the animation is a remover, ``False`` otherwise."
msgstr ""

View file

@ -56,14 +56,10 @@ msgstr ""
msgid "Updates things like starting_mobject, and (for Transforms) target_mobject."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.clean_up_from_scene:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.interpolate:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.update_mobjects:0
msgid "Parameters"
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.begin:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.build_animations_with_timings:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.clean_up_from_scene:0
@ -74,14 +70,16 @@ msgstr ""
msgid "Return type"
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.clean_up_from_scene:3
msgid "This includes to :meth:`~.Scene.remove` the Animation's :class:`~.Mobject` if the animation is a remover."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.clean_up_from_scene:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.interpolate:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.update_mobjects:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.AnimationGroup.clean_up_from_scene:6
msgid "The scene the animation should be cleaned up from."
msgstr ""

View file

@ -18,8 +18,4 @@ msgstr ""
msgid "Bases: :py:class:`manim.animation.composition.AnimationGroup`"
msgstr ""
#: ../../source/reference/manim.animation.composition.LaggedStart.rst:14
msgid "Methods"
msgstr ""

View file

@ -18,12 +18,4 @@ msgstr ""
msgid "Bases: :py:class:`manim.animation.composition.LaggedStart`"
msgstr ""
#: ../../source/reference/manim.animation.composition.LaggedStartMap.rst:14
msgid "Methods"
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.LaggedStartMap:0
msgid "Parameters"
msgstr ""

View file

@ -41,13 +41,10 @@ msgstr ""
msgid "Updates things like starting_mobject, and (for Transforms) target_mobject."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.interpolate:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.update_mobjects:0
msgid "Parameters"
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.begin:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.finish:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.interpolate:0
@ -55,10 +52,6 @@ msgstr ""
msgid "Return type"
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.finish:3
msgid "This method gets called when the animation is over."
msgstr ""
@ -67,6 +60,11 @@ msgstr ""
msgid "This method gets called for every frame during an animation."
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.interpolate:0
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.update_mobjects:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/composition.py:docstring of manim.animation.composition.Succession.interpolate:5
msgid "The relative time to set the animation to, 0 meaning the start, 1 meaning the end."
msgstr ""

View file

@ -34,8 +34,4 @@ msgstr ""
msgid "This is currently only possible for class:`~.Text` and not for class:`~.MathTex`"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.AddTextLetterByLetter:0
msgid "Return type"
msgstr ""

View file

@ -22,12 +22,4 @@ msgstr ""
msgid "Show a :class:`~.Text` word by word on the scene. Note: currently broken."
msgstr ""
#: ../../source/reference/manim.animation.creation.AddTextWordByWord.rst:14
msgid "Methods"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.AddTextWordByWord:0
msgid "Parameters"
msgstr ""

View file

@ -38,10 +38,6 @@ msgstr ""
msgid "If ``mobject`` is not an instance of :class:`~.VMobject`."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Create:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Create:9
msgid "Examples"
msgstr ""

View file

@ -40,20 +40,15 @@ msgstr ""
msgid "Get all mobjects involved in the animation."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.DrawBorderThenFill:0
msgid "Parameters"
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.DrawBorderThenFill.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.DrawBorderThenFill:0
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.DrawBorderThenFill.begin:0
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.DrawBorderThenFill.get_all_mobjects:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.DrawBorderThenFill.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.DrawBorderThenFill.get_all_mobjects:3
msgid "Ordering must match the ordering of arguments to interpolate_submobject"
msgstr ""

View file

@ -35,14 +35,12 @@ msgstr ""
msgid "Interpolates the mobject of the :class:`Animation` based on alpha value."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.ShowIncreasingSubsets:0
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.ShowIncreasingSubsets.interpolate_mobject:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.ShowIncreasingSubsets:0
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.ShowIncreasingSubsets.interpolate_mobject:0
msgid "Return type"
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.ShowIncreasingSubsets.interpolate_mobject:3
msgid "A float between 0 and 1 expressing the ratio to which the animation is completed. For example, alpha-values of 0, 0.5, and 1 correspond to the animation being completed 0%, 50%, and 100%, respectively."
msgstr ""

View file

@ -30,10 +30,6 @@ msgstr ""
msgid "If ``mobject`` is not an instance of :class:`~.VMobject`."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.ShowPartial:0
msgid "Parameters"
msgstr ""
#: ../../source/reference/manim.animation.creation.ShowPartial.rst:14
msgid "Methods"
msgstr ""

View file

@ -26,8 +26,4 @@ msgstr ""
msgid "Methods"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.ShowSubmobjectsOneByOne:0
msgid "Parameters"
msgstr ""

View file

@ -0,0 +1,59 @@
msgid ""
msgstr ""
"Project-Id-Version: Manim \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../../source/reference/manim.animation.creation.SpiralIn.rst:2
msgid "SpiralIn"
msgstr ""
#: ../../source/reference/manim.animation.creation.SpiralIn.rst:4
msgid "Qualified name: ``manim.animation.creation.SpiralIn``"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn:1
msgid "Bases: :py:class:`manim.animation.animation.Animation`"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn:1
msgid "Create the Mobject with sub-Mobjects flying in on spiral trajectories."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn:0
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn.interpolate_mobject:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn:3
msgid "The Mobject on which to be operated."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn:4
msgid "The factor used for scaling the effect."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn:5
msgid "Fractional duration of initial fade-in of sub-Mobjects as they fly inward."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn:8
msgid "Examples"
msgstr ""
#: ../../source/reference/manim.animation.creation.SpiralIn.rst:14
msgid "Methods"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn.interpolate_mobject:1:<autosummary>:1
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn.interpolate_mobject:1
msgid "Interpolates the mobject of the :class:`Animation` based on alpha value."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.SpiralIn.interpolate_mobject:3
msgid "A float between 0 and 1 expressing the ratio to which the animation is completed. For example, alpha-values of 0, 0.5, and 1 correspond to the animation being completed 0%, 50%, and 100%, respectively."
msgstr ""

View file

@ -26,12 +26,4 @@ msgstr ""
msgid "Examples"
msgstr ""
#: ../../source/reference/manim.animation.creation.Uncreate.rst:14
msgid "Methods"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Uncreate:0
msgid "Parameters"
msgstr ""

View file

@ -30,10 +30,6 @@ msgstr ""
msgid "Set True to have the animation start erasing from the last submobject first."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Unwrite:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Unwrite:7
msgid "Examples"
msgstr ""

View file

@ -40,18 +40,13 @@ msgstr ""
msgid "Finish the animation."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Write:0
msgid "Parameters"
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Write.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Write:0
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Write.begin:0
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Write.finish:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/creation.py:docstring of manim.animation.creation.Write.begin:3
msgid "This method is called right as an animation is being played. As much initialization as possible, especially any mobject copying, should live in this method."
msgstr ""

View file

@ -18,39 +18,43 @@ msgstr ""
msgid "Classes"
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Show a :class:`~.Text` letter by letter on the scene."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Show a :class:`~.Text` word by word on the scene."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Incrementally show a VMobject."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Draw the border first and then show the fill."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Show one submobject at a time, leaving all previous ones displayed on screen."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Abstract class for Animations that show the VMobject partially."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Show one submobject at a time, removing all previously displayed ones from screen."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Create the Mobject with sub-Mobjects flying in on spiral trajectories."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Like :class:`Create` but in reverse."
msgstr ""
#: ../../source/reference/manim.animation.creation.rst:38:<autosummary>:1
#: ../../source/reference/manim.animation.creation.rst:40:<autosummary>:1
msgid "Simulate erasing by hand a :class:`~.Text` or a :class:`~.VMobject`."
msgstr ""

View file

@ -42,10 +42,6 @@ msgstr ""
msgid "The factor by which the mobject is scaled initially before being rescaling to its original size while being faded in."
msgstr ""
#: ../../../manim/animation/fading.py:docstring of manim.animation.fading.FadeIn:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/fading.py:docstring of manim.animation.fading.FadeIn:11
msgid "Examples"
msgstr ""

View file

@ -43,11 +43,6 @@ msgstr ""
msgid "The factor by which the mobject is scaled while being faded out."
msgstr ""
#: ../../../manim/animation/fading.py:docstring of manim.animation.fading.FadeOut:0
#: ../../../manim/animation/fading.py:docstring of manim.animation.fading.FadeOut.clean_up_from_scene:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/fading.py:docstring of manim.animation.fading.FadeOut:10
msgid "Examples"
msgstr ""
@ -69,4 +64,8 @@ msgstr ""
msgid "This includes to :meth:`~.Scene.remove` the Animation's :class:`~.Mobject` if the animation is a remover."
msgstr ""
#: ../../../manim/animation/fading.py:docstring of manim.animation.fading.FadeOut.clean_up_from_scene:6
msgid "The scene the animation should be cleaned up from."
msgstr ""

View file

@ -34,10 +34,6 @@ msgstr ""
msgid "Initial color of the arrow before growing to its full size. Leave empty to match arrow's color."
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowArrow:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowArrow:7
msgid "Examples"
msgstr ""

View file

@ -34,10 +34,6 @@ msgstr ""
msgid "Initial color of the mobject before growing to its full size. Leave empty to match mobject's color."
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowFromCenter:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowFromCenter:7
msgid "Examples"
msgstr ""

View file

@ -38,10 +38,6 @@ msgstr ""
msgid "Initial color of the mobject before growing to its full size. Leave empty to match mobject's color."
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowFromEdge:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowFromEdge:8
msgid "Examples"
msgstr ""

View file

@ -38,10 +38,6 @@ msgstr ""
msgid "Initial color of the mobject before growing to its full size. Leave empty to match mobject's color."
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowFromPoint:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.GrowFromPoint:8
msgid "Examples"
msgstr ""

View file

@ -38,10 +38,6 @@ msgstr ""
msgid "Initial color of the mobject before growing to its full size. Leave empty to match mobject's color."
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.SpinInFromNothing:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/growing.py:docstring of manim.animation.growing.SpinInFromNothing:9
msgid "Examples"
msgstr ""

View file

@ -54,16 +54,8 @@ msgstr ""
msgid "The duration of the animation."
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ApplyWave:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ApplyWave:12
msgid "Examples"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ApplyWave:31
msgid "Homotopy is a function from (x, y, z, t) to (x', y', z')"
msgstr ""

View file

@ -62,10 +62,6 @@ msgstr ""
msgid "Additional arguments to be passed to the :class:`~.Succession` constructor"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.Flash:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.Flash:15
msgid "Examples"
msgstr ""

View file

@ -46,10 +46,6 @@ msgstr ""
msgid "Additional arguments to be passed to the :class:`~.Succession` constructor"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.FocusOn:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.FocusOn:11
msgid "Examples"
msgstr ""

View file

@ -46,10 +46,6 @@ msgstr ""
msgid "Additional arguments to be passed to the :class:`~.Succession` constructor"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.Indicate:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.Indicate:11
msgid "Examples"
msgstr ""

View file

@ -19,19 +19,7 @@ msgid "Bases: :py:class:`manim.animation.composition.Succession`"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ShowCreationThenFadeOut:1
msgid "Deprecated"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ShowCreationThenFadeOut:4
msgid "The class ShowCreationThenFadeOut has been deprecated since v0.15.0 and is expected to be removed after v0.16.0. Use Create then FadeOut to achieve this effect."
msgstr ""
#: ../../source/reference/manim.animation.indication.ShowCreationThenFadeOut.rst:14
msgid "Methods"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ShowCreationThenFadeOut:0
msgid "Parameters"
msgid "Deprecated The class ShowCreationThenFadeOut has been deprecated since v0.15.0 and is expected to be removed after v0.16.0. Use Create then FadeOut to achieve this effect."
msgstr ""

View file

@ -35,11 +35,6 @@ msgstr ""
msgid "The length of the sliver relative to the length of the stroke."
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ShowPassingFlash:0
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ShowPassingFlash.clean_up_from_scene:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ShowPassingFlash:7
msgid "Examples"
msgstr ""
@ -57,4 +52,8 @@ msgstr ""
msgid "This includes to :meth:`~.Scene.remove` the Animation's :class:`~.Mobject` if the animation is a remover."
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.ShowPassingFlash.clean_up_from_scene:6
msgid "The scene the animation should be cleaned up from."
msgstr ""

View file

@ -54,10 +54,6 @@ msgstr ""
msgid "The duration of the animation"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.Wiggle:0
msgid "Return type"
msgstr ""
#: ../../../manim/animation/indication.py:docstring of manim.animation.indication.Wiggle:13
msgid "Examples"
msgstr ""

View file

@ -42,6 +42,10 @@ msgstr ""
msgid "Indicate a Mobject by temporarily resizing and recoloring it."
msgstr ""
#: ../../source/reference/manim.animation.indication.rst:36:<autosummary>:1
msgid "Deprecated"
msgstr ""
#: ../../source/reference/manim.animation.indication.rst:36:<autosummary>:1
msgid "Show only a sliver of the VMobject each frame."
msgstr ""

View file

@ -22,12 +22,4 @@ msgstr ""
msgid "Complex Homotopy a function Cx[0, 1] to C"
msgstr ""
#: ../../source/reference/manim.animation.movement.ComplexHomotopy.rst:14
msgid "Methods"
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.ComplexHomotopy:0
msgid "Parameters"
msgstr ""

View file

@ -19,15 +19,39 @@ msgid "Bases: :py:class:`manim.animation.animation.Animation`"
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:1
msgid "Homotopy is a function from (x, y, z, t) to (x', y', z')"
msgid "A Homotopy."
msgstr ""
#: ../../source/reference/manim.animation.movement.Homotopy.rst:14
msgid "Methods"
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:3
msgid "This is an animation transforming the points of a mobject according to the specified transformation function. With the parameter :math:`t` moving from 0 to 1 throughout the animation and :math:`(x, y, z)` describing the coordinates of the point of a mobject, the function passed to the ``homotopy`` keyword argument should transform the tuple :math:`(x, y, z, t)` to :math:`(x', y', z')`, the coordinates the original point is transformed to at time :math:`t`."
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:11
msgid "A function mapping :math:`(x, y, z, t)` to :math:`(x', y', z')`."
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:12
msgid "The mobject transformed under the given homotopy."
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:13
msgid "The run time of the animation."
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:14
msgid "Keyword arguments propagated to :meth:`.Mobject.apply_function`."
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.Homotopy:15
msgid "Further keyword arguments passed to the parent class."
msgstr ""
#: ../../source/reference/manim.animation.movement.Homotopy.rst:14
msgid "Methods"
msgstr ""

View file

@ -31,14 +31,12 @@ msgstr ""
msgid "Interpolates the mobject of the :class:`Animation` based on alpha value."
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.MoveAlongPath:0
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.MoveAlongPath.interpolate_mobject:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.MoveAlongPath:0
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.MoveAlongPath.interpolate_mobject:0
msgid "Return type"
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.MoveAlongPath.interpolate_mobject:3
msgid "A float between 0 and 1 expressing the ratio to which the animation is completed. For example, alpha-values of 0, 0.5, and 1 correspond to the animation being completed 0%, 50%, and 100%, respectively."
msgstr ""

View file

@ -27,14 +27,12 @@ msgstr ""
msgid "Interpolates the mobject of the :class:`Animation` based on alpha value."
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.PhaseFlow:0
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.PhaseFlow.interpolate_mobject:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.PhaseFlow:0
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.PhaseFlow.interpolate_mobject:0
msgid "Return type"
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.PhaseFlow.interpolate_mobject:3
msgid "A float between 0 and 1 expressing the ratio to which the animation is completed. For example, alpha-values of 0, 0.5, and 1 correspond to the animation being completed 0%, 50%, and 100%, respectively."
msgstr ""

View file

@ -18,10 +18,6 @@ msgstr ""
msgid "Bases: :py:class:`manim.animation.movement.Homotopy`"
msgstr ""
#: ../../../manim/animation/movement.py:docstring of manim.animation.movement.SmoothedVectorizedHomotopy:1
msgid "Homotopy is a function from (x, y, z, t) to (x', y', z')"
msgstr ""
#: ../../source/reference/manim.animation.movement.SmoothedVectorizedHomotopy.rst:14
msgid "Methods"
msgstr ""

View file

@ -23,8 +23,7 @@ msgid "Complex Homotopy a function Cx[0, 1] to C"
msgstr ""
#: ../../source/reference/manim.animation.movement.rst:28:<autosummary>:1
#: ../../source/reference/manim.animation.movement.rst:28:<autosummary>:1
msgid "Homotopy is a function from (x, y, z, t) to (x', y', z')"
msgid "A Homotopy."
msgstr ""
#: ../../source/reference/manim.animation.movement.rst:28:<autosummary>:1

View file

@ -18,12 +18,4 @@ msgstr ""
msgid "Bases: :py:class:`manim.animation.numbers.ChangingDecimal`"
msgstr ""
#: ../../source/reference/manim.animation.numbers.ChangeDecimalToValue.rst:14
msgid "Methods"
msgstr ""
#: ../../../manim/animation/numbers.py:docstring of manim.animation.numbers.ChangeDecimalToValue:0
msgid "Parameters"
msgstr ""

View file

@ -27,14 +27,12 @@ msgstr ""
msgid "Interpolates the mobject of the :class:`Animation` based on alpha value."
msgstr ""
#: ../../../manim/animation/numbers.py:docstring of manim.animation.numbers.ChangingDecimal:0
#: ../../../manim/animation/numbers.py:docstring of manim.animation.numbers.ChangingDecimal.interpolate_mobject:0
msgid "Parameters"
msgstr ""
#: ../../../manim/animation/numbers.py:docstring of manim.animation.numbers.ChangingDecimal:0
#: ../../../manim/animation/numbers.py:docstring of manim.animation.numbers.ChangingDecimal.interpolate_mobject:0
msgid "Return type"
#: ../../../manim/animation/numbers.py:docstring of manim.animation.numbers.ChangingDecimal.interpolate_mobject:3
msgid "A float between 0 and 1 expressing the ratio to which the animation is completed. For example, alpha-values of 0, 0.5, and 1 correspond to the animation being completed 0%, 50%, and 100%, respectively."
msgstr ""

Some files were not shown because too many files have changed in this diff Show more