[NTG-context] bugs found while trying to support utf-8 Korean Hangul under ConTeXt

Dohyun Kim nomosnomos at gmail.com
Sat Oct 21 06:19:42 CEST 2006

Hi, (3.4Mb)

Recently I have tried to support typesetting UTF-8 Korean document
under ConTeXt.

In the course of that trying, I found some possible bugs of recent
ConTeXt beta.
You can see most of the bugs (or missing features) I found in the file
named `testme.tex',
which is contained in the tarball linked above.

For those who do not want to download that large tarball,
I here replicate those bugs or missing features:

% should be added to unic-cjk.tex
% Hangul Syllables
\dostepwiserecurse{172}{215}{1}{\expanded{\defineunicodecommand {\recurselevel}}
% CJK Compatibility Ideographs
\dostepwiserecurse{249}{250}{1}{\expanded{\defineunicodecommand {\recurselevel}}

% modify \enableunicodefont in font-uni.tex
   \def\unicodescale             {\getvalue{\??uc#1\c!scale}}%
   \def\unicodeheight            {\getvalue{\??uc#1\c!height}}%
   \def\unicodedepth             {\getvalue{\??uc#1\c!depth}}%
   \def\unicodedigits            {\getvalue{\??uc#1\c!conversion}}%
   \def\handleunicodeglyph       {\getvalue{\??uc#1\c!command}}%
   % the following \relax's are realy needed
      {\setunicodestrut\unicodeheight\unicodedepth}% <- `%' inserted by nomos

% modify \sanitizePDFuniencoding in spec-tst.tex
   \simplifycommands                         % <- this line inserted by nomos
   \let\unicodechar\relax % prevent further expansion
   \retainlccodes\lccode32=255 % slooow
   \edef#2{\expandafter\doPDFuni#2\empty\empty}} % slooow

% modify mps file insertion code in spec-dpx.tex
\definefileinsertion{dpx}{mps}       % tpd -> dpx modified by nomos

Certainly, the last is not problem confined to Hangul typesetting.
As you know, however, CJK peoples do use heavily dvipdfmx to obtain PDF.

Anyway, I hope these four files be modified in the near future.

In addition, when I compiled LaTeX2ConTeXt.tex by Berend de Boer
( http://www.berenddeboer.net/tex/LaTeX2ConTeXt.tex ),
I found there being inserted unintended large vertical whitespace
in page 27 of resulting PDF.
Though it seems to be a bug related to \setupbackground,
I could not find the cause of problem as the code related to that command
is too complicated for me.

Dohyun Kim

More information about the ntg-context mailing list