
我必須使用 XeTeX,因為它有助於在文字和數學模式(或新TX數學在數學模式下)。
我注意到該polyglossia
軟體包有一個錯誤\normalfont
。這裡是@egreg對此錯誤的詳細描述。
在 MikTeX 中更新套件(到最新版本)後,polyglossia
問題已解決,但出現了以下錯誤:
Undefined control sequence. ...ctlanguage *[babelshorthands=true]{russian}
Undefined control sequence. ...ctlanguage *[babelshorthands=true]{russian}
Encoding scheme `' unknown. ...ctlanguage *[babelshorthands=true]{russian}
Undefined control sequence. ^^I\begin{document}
Undefined control sequence. ^^I\begin{document}
Encoding scheme `' unknown. ^^I\begin{document}
Undefined control sequence. ^^I\begin{abstr}
Undefined control sequence. ^^I^^I\par{\normalfont
Undefined control sequence. ^^I^^I\par{\normalfont
Encoding scheme `' unknown. ^^I^^I\par{\normalfont
Undefined control sequence. ^^I\end{abstr}
Undefined control sequence. ^^I\end{abstr}
Encoding scheme `' unknown. ^^I\end{abstr}
Undefined control sequence. ^^I\end{document}
Undefined control sequence. ^^I\end{document}
Encoding scheme `' unknown. ^^I\end{document}
Undefined control sequence. ...ctlanguage *[babelshorthands=true]{russian}
Undefined control sequence. ...ctlanguage *[babelshorthands=true]{russian}
Encoding scheme `' unknown. ...ctlanguage *[babelshorthands=true]{russian}
Overfull \hbox (29.36624pt too wide) in paragraph
在 MWE 中:
\documentclass[extrafontsizes,a4paper,*pt,oneside,openany]{memoir}
\usepackage{fontspec} %[no-math] How can I use the Newton instead of newtxmath?
%\usepackage{newtxmath} %math font of TNR type
\usepackage{polyglossia}[2014/05/21]
\setmainlanguage[babelshorthands=true]{russian} %
\setotherlanguage{english}
\setmainfont{Arial} %%
% \setsansfont{Newton}
% \setmonofont{Newton}
\newenvironment{abstr}{\small\itshape}{\normalfont\normalsize}
\begin{document}
\begin{abstr}
\par{\normalfont Key \textbf{words}.} Hey!
\end{abstr}
\newcommand{\fn}{\expandafter\string\the\font}
{\normalsize\selectfont ха-хаха Book\_name\_ch\_AuthorsSurnames\fn}
\fontname\font\\
$ a+b$
\end{document}
如何避免這些錯誤?拜託我需要你的幫忙!
最好的問候,弗拉基米爾
UPD1MWE 已更新。
UPD2TexStudio的截圖
更新3:我已按照@DavidCarlisle 和@UlrikeFischer 的建議查看完整的日誌檔案。之後我找到了解決方案這裡。