> On Mon, Feb 05, 2024 at 02:48:15PM +0000, > ralphli...@hotmail.com wrote: > > To whom it might concern: > > > > I have some problems on translating the Emacs manual, a > > texinfo document, to Chinese. > > > > Specifically, when I use the following command: > > > > texi2pdf emacs.texi -o emacs.pdf > > > > I have following errors: > > > > Unicode char @u8:找 not defined for Texinfo > > > > Where "找" is a Chinese character. > > > > And outputing the documentation in plain text and HTML > > works(theoretically also info), but > > not for everything TeX. > > You need the special support file texinfo-zh.tex that comes with > Texinfo; > moreover you cannot process your source files with regular > pdfetex. You > have to use XeTeX. Rather than the first line of the file being > > \input texinfo > > you must, instead, write > > \input texinfo-zh > > As well as XeTeX, you may need to install some other packages > for > TeX (zhspacing.sty). > > Some manuals have been translated into Japanese which is > supported the > same way, except it uses texinfo-ja.tex instead of texinfo- > zh.tex. > These files are distributed as part of Texinfo. > > > > > > and I also added following in emacs.texi: > > > > @documentencoding UTF-8 > > @documentlanguage zh_CN > > That should be ok. > > > Also I translated txi-en.tex in the Emacs source file to > > Chinese as > > txi-zh_CN.tex and it is included in the directory of the > > maunual. A > > brief description is included in the file: > > > > "This is read when a source document says > > @documentlanguage zh_CN." > > > > but the above output appeared for every Chinese character. > > > > > > > I tried to read the info manual and found out that using a > > unicode > > letter requires the use of "@u8{HEX}", which is not the > > way to go. > > > > The texinf-ja.tex probably has the answer... > > I don't know what that file refers to - there is a file > "texinfo-ja.tex" > but you need to use "texinfo-zh.tex".
> There is already a translation of txi-en.tex, txi-zh.tex, that > comes with > Texinfo. As you just said, I checked the texinfo source code, and the "txi- zh" and "texinfo-zh" do exist, but not for the texinfo v6.8 that I'm currently using. I added those files into the documentation source; and I run the texi2any command with argument "--pdf", it complains about the lack of XeTeX. My machine has XeTeX installed alongside TeX Live, but I don't know how to set it up as the default TeX engine. Thanks. -- Ralph Lin <ralphli...@hotmail.com>