Skip to content

Error when trying to add Chinese text #1027

Open
@mokkinghang

Description

@mokkinghang

Basically it is the same issue as in #570, however it was not clear how the person solved the issue, for he stated that he didn't know how he managed to solve it. I am using Windows 10 and MiKTeX.
I tried to edit constants.py, TEX_USE_CTEX = False was changed to True and it returns the error:

 File "D:\Programs\manim\manim\manimlib\extract_scene.py", line 153, in main
    scene = SceneClass(**scene_kwargs)
  File "D:\Programs\manim\manim\manimlib\scene\scene.py", line 54, in __init__
    self.construct()
  File "tutorial/1_text_format.py", line 5, in construct
    text = TextMobject("你好")
  File "D:\Programs\manim\manim\manimlib\mobject\svg\tex_mobject.py", line 144, in __init__
    self, self.arg_separator.join(tex_strings), **kwargs
  File "D:\Programs\manim\manim\manimlib\mobject\svg\tex_mobject.py", line 45, in __init__
    self.template_tex_file_body
  File "D:\Programs\manim\manim\manimlib\utils\tex_file_writing.py", line 19, in tex_to_svg_file
    dvi_file = tex_to_dvi(tex_file)
  File "D:\Programs\manim\manim\manimlib\utils\tex_file_writing.py", line 67, in tex_to_dvi
    "See log output above or the log file: %s" % log_file)
Exception: Xelatex error converting to xdv. See log output above or the log file: D:\Programs\manim\manim\manimlib\files\Tex\6d518d13918960fc.log

And the command is extremely simple:

class WriteText(Scene): 
    def construct(self): 
        text = TextMobject("你好")
        self.play(Write(text))
        self.wait(3)

Anyway that has proven to work to solve the issue? For I am not the first one encountering this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions