mirror of
https://github.com/3b1b/manim.git
synced 2025-08-05 16:49:03 +00:00
Update some Text Mobject changes
This commit is contained in:
parent
0983fa11be
commit
9b3e60f5ce
2 changed files with 6 additions and 12 deletions
|
@ -38,7 +38,7 @@ def initialize_directories(config):
|
|||
"directory were both passed"
|
||||
)
|
||||
|
||||
TEX_DIR = config["tex_dir"] or os.path.join(MEDIA_DIR, "texs")
|
||||
TEX_DIR = config["tex_dir"] or os.path.join(MEDIA_DIR, "Tex")
|
||||
TEXT_DIR = os.path.join(MEDIA_DIR, "texts")
|
||||
if not video_path_specified:
|
||||
VIDEO_DIR = os.path.join(MEDIA_DIR, "videos")
|
||||
|
|
|
@ -286,17 +286,11 @@ class SVGMobject(VMobject):
|
|||
|
||||
def flatten(self, input_list):
|
||||
output_list = []
|
||||
while True:
|
||||
if input_list == []:
|
||||
break
|
||||
for index, i in enumerate(input_list):
|
||||
if type(i)== list:
|
||||
input_list = i + input_list[index+1:]
|
||||
break
|
||||
else:
|
||||
output_list.append(i)
|
||||
input_list.pop(index)
|
||||
break
|
||||
for i in input_list:
|
||||
if isinstance(i, list):
|
||||
output_list.extend(self.flatten(i))
|
||||
else:
|
||||
output_list.append(i)
|
||||
return output_list
|
||||
|
||||
def get_all_childNodes_have_id(self, element):
|
||||
|
|
Loading…
Add table
Reference in a new issue