Hello, I am trying to set up ConTeXt to work properly with Chinese. Everything seemed fine until I discovered that there is some problem with the Chinese numbers. I have a TeX file with several chapters. I used texexec and dvipdfmx generated the PDF file without problems. But I found there are two things wrong (which supposed to be working). The first is that the two Chinese charaters before the list of contents (corresponding to the 'Contents' before English text) are missing. The second, all the chinese characters before the chapter titles in the list of contents are missing (corresponding to the English text 1 or 1.1, etc.). I tried to figure out what the problem is myself without success. I read file font-chi.tex and found some commands like: \def\chinesedigit#1#2% #2: suffix, here * or \empty {\udigit{\chineseencoding}{\number#1#2}} \def\normalchinesenumber#1% {\expandafter\dochinesenumber\number#1\relax\empty} I tried to use these commands in my file directly. But they didn't produce any output there, even no space left for the numbers inside {}. I am using MikTeX under Windows XP. I am using the latest ConTeXt beta to get the dvipdfmx working. Your help will be appreciated greatly! Guo --
Or maybe somebody can point me to the files and manuals that can lead me to solve this problem myself? Thanks alot! Guo Guo Yang wrote:
Hello,
I am trying to set up ConTeXt to work properly with Chinese. Everything seemed fine until I discovered that there is some problem with the Chinese numbers. I have a TeX file with several chapters. I used texexec and dvipdfmx generated the PDF file without problems. But I found there are two things wrong (which supposed to be working). The first is that the two Chinese charaters before the list of contents (corresponding to the 'Contents' before English text) are missing. The second, all the chinese characters before the chapter titles in the list of contents are missing (corresponding to the English text 1 or 1.1, etc.).
I tried to figure out what the problem is myself without success. I read file font-chi.tex and found some commands like:
\def\chinesedigit#1#2% #2: suffix, here * or \empty {\udigit{\chineseencoding}{\number#1#2}} \def\normalchinesenumber#1% {\expandafter\dochinesenumber\number#1\relax\empty}
I tried to use these commands in my file directly. But they didn't produce any output there, even no space left for the numbers inside {}.
I am using MikTeX under Windows XP. I am using the latest ConTeXt beta to get the dvipdfmx working.
Your help will be appreciated greatly!
Guo
Are you use the same font name as that in font-chi.tex? if not,
try edit font-chi.tex and change the font name as those used in
your system instead of using the \definefontsynonym in your
cont-usr.tex or cont-sys.tex may solve the problem. It seems
use the \definefontsynonym to redefine the font name will cause
context ignore the encoding settings.
Wang
----- Original Message -----
From: "Guo Yang"
Or maybe somebody can point me to the files and manuals that can lead me to solve this problem myself? Thanks alot!
Guo
Guo Yang wrote:
Hello,
I am trying to set up ConTeXt to work properly with Chinese. Everything seemed fine until I discovered that there is some problem with the Chinese numbers. I have a TeX file with several chapters. I used texexec and dvipdfmx generated the PDF file without problems. But I found there are two things wrong (which supposed to be working). The first is that the two Chinese charaters before the list of contents (corresponding to the 'Contents' before English text) are missing. The second, all the chinese characters before the chapter titles in the list of contents are missing (corresponding to the English text 1 or 1.1, etc.).
I tried to figure out what the problem is myself without success. I read file font-chi.tex and found some commands like:
\def\chinesedigit#1#2% #2: suffix, here * or \empty {\udigit{\chineseencoding}{\number#1#2}} \def\normalchinesenumber#1% {\expandafter\dochinesenumber\number#1\relax\empty}
I tried to use these commands in my file directly. But they didn't produce any output there, even no space left for the numbers inside {}.
I am using MikTeX under Windows XP. I am using the latest ConTeXt beta to get the dvipdfmx working.
Your help will be appreciated greatly!
Guo
_______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
At 09:15 PM 2/5/2003 -0600, you wrote:
Are you use the same font name as that in font-chi.tex? if not, try edit font-chi.tex and change the font name as those used in your system instead of using the \definefontsynonym in your cont-usr.tex or cont-sys.tex may solve the problem. It seems use the \definefontsynonym to redefine the font name will cause context ignore the encoding settings.
unless you define the encoding with it Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com ------------------------------------------------------------------------- information: http://www.pragma-ade.com/roadmap.pdf documentation: http://www.pragma-ade.com/showcase.pdf -------------------------------------------------------------------------
Hans Your suggestion sovled my problem too. Thank you very much! I don't know if anybody mentioned it here or not, I did have a couple issues using texexec.pl and texutil.pl under cygwin enviroment. For the texexec.pl case, it turned out that it caused by the different naming scheme for the path, i.e., '\' and '/'. So I added a conditional test in the RunPerlScript subrouting in texexec.pl to make it work in both cmd and cygwin. For texutil, I found that somehow it writes a '^M' in the middle of a comment line and leaves strange number in the list of contents page. So I commented these two lines out in texutil.tex and 'sovled' the problem: sub FlushFiles {print TUO "%\n" . "% $Program / Files\n" . "%\n" ; # foreach $FILE (keys %Files) # { print TUO "% $File ($File{$File})\n" } I am wondering these problem, if they are, can be corrected in the future release. Or if they are not, how to solve them without chaning the programs. I understand that most of people using integrated enviroment. But I believe there are still some people like using command line :)) Thanks, Guo Hans Hagen wrote:
At 09:15 PM 2/5/2003 -0600, you wrote:
Are you use the same font name as that in font-chi.tex? if not, try edit font-chi.tex and change the font name as those used in your system instead of using the \definefontsynonym in your cont-usr.tex or cont-sys.tex may solve the problem. It seems use the \definefontsynonym to redefine the font name will cause context ignore the encoding settings.
unless you define the encoding with it
Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com ------------------------------------------------------------------------- information: http://www.pragma-ade.com/roadmap.pdf documentation: http://www.pragma-ade.com/showcase.pdf -------------------------------------------------------------------------
_______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
At 02:44 PM 2/6/2003 -0500, Guo Yang wrote:
Hans
Your suggestion sovled my problem too. Thank you very much!
I don't know if anybody mentioned it here or not, I did have a couple issues using texexec.pl and texutil.pl under cygwin enviroment. For the texexec.pl case, it turned out that it caused by the different naming scheme for the path, i.e., '\' and '/'. So I added a conditional test in the RunPerlScript subrouting in texexec.pl to make it work in both cmd and cygwin. For texutil, I found that somehow it writes a '^M' in the middle of a comment line and leaves strange number in the list of contents page. So I commented these two lines out in texutil.tex and 'sovled' the problem:
sub FlushFiles {print TUO "%\n" . "% $Program / Files\n" . "%\n" ; # foreach $FILE (keys %Files) # { print TUO "% $File ($File{$File})\n" }
I am wondering these problem, if they are, can be corrected in the future release. Or if they are not, how to solve them without chaning the programs. I understand that most of people using integrated enviroment. But I believe there are still some people like using command line :))
I don't understand this since it's just a message you comment. What is the error message? maybe fabrice (windows path expert) know what is goidn on Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com ------------------------------------------------------------------------- information: http://www.pragma-ade.com/roadmap.pdf documentation: http://www.pragma-ade.com/showcase.pdf -------------------------------------------------------------------------
The first one is just gone suddenly without the change. Originally it had such error message: Can't open perl script "C:texmfcontextperltktexexec.pl": No such file or directory. (All '\'s in the path were striped away) Anyway, I am very glad it just disappeared. For the second one, it demonstrates itself as one or several '(2)' (for the files I tested, only text in them, no pictures) before or after the list of contents page in both the dvi files or pdf files. I found that in the .tuo file produced by texutil.pl, there was an extra ^M (one charater) in this line: % TeXUtil 7.4 - ConTeXt / PRAGMA ADE 1992-2002 / Files ->% chap^M (2) , which caused the problem. But I couldn't figure out where this ^M came from. So I just commented the two lines produce these comments out and made annoying numbers gone. Guo Hans Hagen wrote:
At 02:44 PM 2/6/2003 -0500, Guo Yang wrote:
Hans
Your suggestion sovled my problem too. Thank you very much!
I don't know if anybody mentioned it here or not, I did have a couple issues using texexec.pl and texutil.pl under cygwin enviroment. For the texexec.pl case, it turned out that it caused by the different naming scheme for the path, i.e., '\' and '/'. So I added a conditional test in the RunPerlScript subrouting in texexec.pl to make it work in both cmd and cygwin. For texutil, I found that somehow it writes a '^M' in the middle of a comment line and leaves strange number in the list of contents page. So I commented these two lines out in texutil.tex and 'sovled' the problem:
sub FlushFiles {print TUO "%\n" . "% $Program / Files\n" . "%\n" ; # foreach $FILE (keys %Files) # { print TUO "% $File ($File{$File})\n" }
I am wondering these problem, if they are, can be corrected in the future release. Or if they are not, how to solve them without chaning the programs. I understand that most of people using integrated enviroment. But I believe there are still some people like using command line :))
I don't understand this since it's just a message you comment. What is the error message?
maybe fabrice (windows path expert) know what is goidn on
Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com ------------------------------------------------------------------------- information: http://www.pragma-ade.com/roadmap.pdf documentation: http://www.pragma-ade.com/showcase.pdf -------------------------------------------------------------------------
_______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
At 11:13 AM 2/7/2003 -0500, you wrote:
The first one is just gone suddenly without the change. Originally it had such error message:
Can't open perl script "C:texmfcontextperltktexexec.pl": No such file or directory. (All '\'s in the path were striped away)
Anyway, I am very glad it just disappeared.
For the second one, it demonstrates itself as one or several '(2)' (for the files I tested, only text in them, no pictures) before or after the list of contents page in both the dvi files or pdf files. I found that in the .tuo file produced by texutil.pl, there was an extra ^M (one charater) in this line:
% TeXUtil 7.4 - ConTeXt / PRAGMA ADE 1992-2002 / Files ->% chap^M (2)
maybe a dos2unix texutil.pl helps Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com ------------------------------------------------------------------------- information: http://www.pragma-ade.com/roadmap.pdf documentation: http://www.pragma-ade.com/showcase.pdf -------------------------------------------------------------------------
Thank you very much! It indeed solved the problem:) Guo Lei Wang wrote:
Are you use the same font name as that in font-chi.tex? if not, try edit font-chi.tex and change the font name as those used in your system instead of using the \definefontsynonym in your cont-usr.tex or cont-sys.tex may solve the problem. It seems use the \definefontsynonym to redefine the font name will cause context ignore the encoding settings.
Wang
participants (4)
-
Guo Yang
-
Guo Yang
-
Hans Hagen
-
Lei Wang