Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/source/getting_started/example_scenes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ CoordinateSystemExample
# you can call call axes.coords_to_point, abbreviated to
# axes.c2p, to associate a set of coordinates with a point,
# like so:
dot = Dot(color=RED)
dot = Dot(fill_color=RED)
dot.move_to(axes.c2p(0, 0))
self.play(FadeIn(dot, scale=0.5))
self.play(dot.animate.move_to(axes.c2p(3, 2)))
Expand Down Expand Up @@ -537,7 +537,7 @@ GraphExample

# You can use axes.input_to_graph_point, abbreviated
# to axes.i2gp, to find a particular point on a graph
dot = Dot(color=RED)
dot = Dot(fill_color=RED)
dot.move_to(axes.i2gp(2, parabola))
self.play(FadeIn(dot, scale=0.5))

Expand Down
4 changes: 2 additions & 2 deletions example_scenes.py
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ def construct(self):
# you can call call axes.coords_to_point, abbreviated to
# axes.c2p, to associate a set of coordinates with a point,
# like so:
dot = Dot(color=RED)
dot = Dot(fill_color=RED)
dot.move_to(axes.c2p(0, 0))
self.play(FadeIn(dot, scale=0.5))
self.play(dot.animate.move_to(axes.c2p(3, 2)))
Expand Down Expand Up @@ -480,7 +480,7 @@ def construct(self):

# You can use axes.input_to_graph_point, abbreviated
# to axes.i2gp, to find a particular point on a graph
dot = Dot(color=RED)
dot = Dot(fill_color=RED)
dot.move_to(axes.i2gp(2, parabola))
self.play(FadeIn(dot, scale=0.5))

Expand Down
6 changes: 4 additions & 2 deletions manimlib/utils/file_ops.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,15 @@ def find_file(
extensions: Iterable[str] | None = None
) -> Path:
# Check if this is a file online first, and if so, download
# it to a temporary directory
# it to the configured downloads directory
if validators.url(file_name):
suffix = Path(file_name).suffix
file_hash = hash_string(file_name)
folder = manimlib.utils.directories.get_downloads_dir()

path = Path(folder, file_hash).with_suffix(suffix)

# ensure that the target folder exists before downloading
guarantee_existence(folder)
urllib.request.urlretrieve(file_name, path)
return path

Expand Down