当我使用 sublime3 在 Ubuntu 中构建时出现这个 Latex 错误该怎么办?

当我使用 sublime3 在 Ubuntu 中构建时出现这个 Latex 错误该怎么办?

我想在 Ubuntu 16.04 上使用 LaTeX,并且我已经安装了 texlive2017、sublimeText3 和 sublime 插件:latexTools。但是当我创建一个新文件,使用CtrlShiftB选择“ Latex-pdfLatex”,然后使用CtrlB构建文件时,它会抛出一个错误,如下所示:

/usr/local/texlive/2017/texmf-dist/tex/latex/ctex/fontset/ctex-fontset-fandol.def:109: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! [  }]

pdfTeX error: pdflatex (file cyberb65): Font cyberb65 at 723 not found
Check the TeX log file for more information

这是我的配置LatexTools.sublime.settings

"linux" : {
// Path used when invoking tex & friends; MUST include $PATH
"texpath" : "$PATH:/usr/local/texlive/2017/bin/x86_64-linux",
// Command to invoke Python. Useful if you have Python installed in a
// non-standard location or want to use a particular version of python.
// Both Python2 and Python3 are supported, but must have the DBus bindings
// installed.
"python": "/usr/bin/Python3",
// The name of the ST2 or ST3 executable. On Ubuntu, both subl and sublime-text are
// available for ST2; adjust as needed for other platforms, and for ST3
"sublime": "sublime-text",
// How long to wait after evince or okular has launched before sending a sync message
// in seconds, floating point; choose 2.0 or 3.0 on a slower machine, 0.5 on a fast one
// Note: only tweak this if sync after launching the PDF viewer does not seem to work,
// or if the PDF viewer opens instantly and you don't want to wait.
// Default: 1.5 (works on my MBP4,1...)
"sync_wait": 0.5,
// Command to invoke Sublime Text. Used if the keep_focus toggle is true.
// If blank, "subl" or "sublime_text" will be used.
"sublime_executable": "",
// how long (in ms) to wait after the jump_to_pdf command completes
// before switching focus back to Sublime Text. This may need to be
// adjusted depending on your machine and configuration.
"keep_focus_delay": 0.5
},

此外,当我使用CtrlShiftB设置“ Latex-XeLatex”然后构建文件时,它没有抛出错误,但没有创建 pdf 文件。

我也安装了dbus,但是好像不起作用。

这是否意味着我需要安装一些字体?我现在应该怎么做才能生成文件并获取 pdf 文件?

答案1

\documentclass[UTF8]{ctexart}哦,我已经通过将第一行从改为解决了这个问题\documentclass{article}。看来 sublime 抛出这个错误是因为缺少一些支持中文字符的东西。

相关内容