Open amalgame21 opened 11 months ago
To avoid the compiling error, change the 2727 line:
into
% \section{\protect\LuaLaTeX{} 下的中文支持方式}
I found the manual in
ctex/ctex.dtx
but I failed to build it myself. I can only compile the first 27 pages and hit an error withxelatex ctex.dtx
command.
See PR #670.
Thank you very much!
After manually modified in /usr/share/texmf-dist/tex/latex/ctex/ctxdoc.cls
, it can now be complied successfully!
However some of the font cannot be displayed properly after converting to Traditional Chinese.
This is the output of page 2:
So many broken character displayed as an F within a box. Do you know how to change to some Traditional Chinese compatible font, say, Noto Sans CJK TC? I have looked into the source code, seems line 10579-11073 are font-related, but I cannot locate which line is the one to modify.
By the way, at least it is readable to me now, thank you very much for your help!
I have looked into the source code, seems line 10579-11073 are font-related, but I cannot locate which line is the one to modify.
First, different (default) font configs are chosen per OS
https://github.com/CTeX-org/ctex-kit/blob/3dbff76e1d364aa7f82edfbba9a6ff97d2fae2e6/ctex/ctex.dtx#L10280-L10294
In each ctex-fontset-<name>.def
, the configs used under xelatex is the forth argument of \ctex_fontset_case:nnnn
.
For example for recent macOS (no older than 10.11), the related configs in ctex-fontset-macold.def
for xelatex is
https://github.com/CTeX-org/ctex-kit/blob/3dbff76e1d364aa7f82edfbba9a6ff97d2fae2e6/ctex/ctex.dtx#L10901-L10917
For a doc in traditional Chinese, you may also need to adapt ctex settings, such as https://github.com/CTeX-org/ctex-kit/blob/3dbff76e1d364aa7f82edfbba9a6ff97d2fae2e6/ctex/ctex.dtx#L9782-L9799
I found the manual in
ctex/ctex.dtx
but I failed to build it myself. I can only compile the first 27 pages and hit an error withxelatex ctex.dtx
command. Also, the formatting of the compiled pdf are way off.Also, after I translated it with opencc, some of the character are missing because the predefined font does not support Traditional Chinese.
It would be great if the Traditional Chinese version of the manual is provided, or just translate it with opencc or other tools.