alwintsui / scutthesis

Latex/Lyx templates for the thesis specifications of South China University of Technology (SCUT,华南理工大学)
218 stars 50 forks source link

CJKnumber failed #12

Open qnach opened 4 years ago

qnach commented 4 years ago

I bought a new computer with windows10, which I installed MikTeX2.9. The previous LaTeX file failed to compile in this new system. The follwing is a min. example:

\documentclass{book} \usepackage{fontspec} \usepackage[BoldFont,SlantFont,CheckSingle=true]{xeCJK} \usepackage{CJKnumb} \setmainfont{Times New Roman} \setCJKmainfont{DFT_HZ5.TTC} \begin{document} 請見本書第\CJKnumber{\ref{coding}}章)。 \end{document}

The following is the log file:

.... .... Font) TU/TimesNewRoman(0)/m/n --> TU/TimesNewRoman(0)/b/n on input line 7. LaTeX Font Info: Overwriting math alphabet \mathit' in versionbold' (Font) OT1/cmr/bx/it --> TU/TimesNewRoman(0)/b/it on input lin e 7. LaTeX Font Info: Overwriting math alphabet \mathsf' in versionbold' (Font) OT1/cmss/bx/n --> TU/lmss/b/n on input line 7. LaTeX Font Info: Overwriting math alphabet \mathtt' in versionbold' (Font) OT1/cmtt/m/n --> TU/lmtt/b/n on input line 7.

! Missing number, treated as zero.

\protect l.8 隢? It is not peculiar, because what is inside \CJKnumber is undefined. The program should popup and ask me, and I simple need to hit a return But it did not popup. The program simply break here. However, if I remove other Chinese characters, the program become \documentclass{book} \usepackage{fontspec} \usepackage[BoldFont,SlantFont,CheckSingle=true]{xeCJK} \usepackage{CJKnumb} \setmainfont{Times New Roman} \setCJKmainfont{DFT_HZ5.TTC} \begin{document} \CJKnumber{\ref{coding}} \end{document} It is fine. What is wrong with my system setup? I am sure this issue is related to CJKnumber because if I remove \CJKnumber with only \ref{coding} left, the issue disappeared.