Back to Manim

set the maximum width for video outputs to a predefined value

example_scenes/manim_jupyter_example.ipynb

0.20.1623 B
Original Source
python
from manim import *
python
%%manim -v WARNING --disable_caching -ql -s Example1

class Example1(Scene):
    def construct(self):
        self.add(Circle())
python
%%manim -v WARNING --disable_caching -qm HelloManim

# set the maximum width for video outputs to a predefined value
config.media_width = "20vw"
# embed video
config.media_embed = True

class HelloManim(Scene):
    def construct(self):
        self.camera.background_color = "#ece6e2"
        banner_large = ManimBanner(dark_theme=False).scale(0.7)
        self.play(banner_large.create())
        self.play(banner_large.expand())