We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
如题,当使用ctex宏包并在xelatex引擎下编译时,无法得到正确的数学公式,MWE如下:
ctex
xelatex
MWE
\documentclass{article} \usepackage[scheme=plain,UTF8, fontset=none, zhmap=false]{ctex} \usepackage{stix} \usepackage{amsmath} \begin{document} \begin{align} i\hbar \partial_t \psi(\boldsymbol{r},t) = H\psi(\boldsymbol{r},t) \\ = \left[-\frac{\hbar^2}{2m}\nabla^2+U(\boldsymbol{r})\right]\psi(\boldsymbol{r},t) \end{align} \end{document}
其中,不管是否关闭zhmap,得到的结果都不正确: 可以看到,此时的中括号的减号都不正确,并且数字也没有变成stix中的字体,但是如果使用pdflatex引擎编译,则能得到正确的结果: 请问这是否是一个bug呢?
zhmap
pdflatex
The text was updated successfully, but these errors were encountered:
ctex 换成 xeCJK + $\left[ \frac12 \right]$ 就能复现问题,$[ a ]$ 不复现。像是长版括号的映射错了。我不了解字体相关……
xeCJK
$\left[ \frac12 \right]$
$[ a ]$
% !TeX program = xelatex \documentclass{article} \usepackage{xeCJK} \usepackage{amsmath} \usepackage{stix2} \begin{document} \[ [\frac12] \quad \left[ \frac12 \right] \] \end{document}
一些尝试(注意力主要在括号是否正确上,没太关注其他字符)
stix
stix2
\PassOptionsToClass{no-math}{fontspec}
\xeCJKsetup{xeCJKactive=false}
\usepackage[LoadFandol=false]{xeCJK}
lmodern
unicode-math
\setmathfont{STIX Two Math}
luatexja
像是 xeCJK 和「ctex + lualatex」的公共部分导致的。
Sorry, something went wrong.
应该是 \PassOptionsToPackage{no-math}{fontspec} 就可以,你错写成 \PassOptionsToClass 就没作用了
\PassOptionsToPackage{no-math}{fontspec}
\PassOptionsToClass
No branches or pull requests
如题,当使用
ctex
宏包并在xelatex
引擎下编译时,无法得到正确的数学公式,MWE
如下:其中,不管是否关闭
zhmap
,得到的结果都不正确:可以看到,此时的中括号的减号都不正确,并且数字也没有变成stix中的字体,但是如果使用
pdflatex
引擎编译,则能得到正确的结果:请问这是否是一个bug呢?
The text was updated successfully, but these errors were encountered: