如题,一个困扰了比较久的BUG。之前在Linux上参考了这个评论的配置在Linux上使用中文LaTeX preview,但生成的预览中的中文都向下偏移了,如图:
Emacs版本为30.1,Texlive版本为2022。
配置:
(setq org-latex-packages-alist '(("" "mhchem" t)
("" "ctex" t)))
(add-to-list 'org-preview-latex-process-alist
'(xelatex-ch
:programs ("xelatex" "dvisvgm")
:description "xdv > svg"
:message "You need to install xelatex & dvisvgm"
:image-input-type "xdv"
:image-output-type "svg"
:image-size-adjust (1.7 . 1.5)
:latex-compiler
("xelatex -no-pdf -interaction nonstopmode -output-directory %o %f")
:image-converter
("dvisvgm %f --no-fonts --exact-bbox --scale=%S --output=%O")))