ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Richard Gabriel <rgabriel@kerio.com>
Subject: Re: Chinese
Date: Tue, 13 Dec 2005 10:14:46 +0100	[thread overview]
Message-ID: <20051213091446.283c7ce3@mx1.kerio.com> (raw)
In-Reply-To: <439D9D0F.6080406@wxs.nl>


[-- Attachment #1.1: Type: text/plain, Size: 3228 bytes --]

Hello Hans,

to be honest: I don't speak Chinese and don't know much about it.
A few days ago, I was told that we'll let translate some of our documents (XML) into Chinese and Japanese and I 'll have to typeset them. 
So I started playing with Chinese in ConTeXt. I've reported the results which other users (e.g. Tobias) have also noticed. 
In fact, all the sample Simplified Chinese documents I've tested it on were easily convertible to CP936 (GBK) and could be typeset. This doesn't mean that you shall not extend the Unicode support, I only think I will not hardly require it... :-)

But yet another question: What about Japanese? I've made only small research so far, but unlike Chinese, there's almost no information about Japanese in TeX. How much of work would be to adjust the current "chinese" ConTeXt module for Japanese? What would you need for it?
[Of course, meanwhile I'll investigate some other ways of typesetting Japanese...]

Thanks,
Richard



  _____  

From: Hans Hagen [mailto:pragma@wxs.nl]
To: mailing list for ConTeXt users [mailto:ntg-context@ntg.nl]
Sent: Mon, 12 Dec 2005 16:53:51 +0100
Subject: Re: [NTG-context] Chinese

Richard Gabriel wrote:

> Hi guys,
>
> I can confirm that the UTF-8 input doesn't work for me too.
> If I convert the file info GBK (CP936), it works fine [I suggest to 
> use the 'iconv' utility for the conversion :-)].
>
> I tested the UTF-8 output the followin ways:
>
> 1)
> \enableregime[utf]
> \usemodule[chinese]
>

chinese is not yet defined in utf so if you want that, we need to do it

now, since the chinese remapping stuff is rather complex, the best 
method is to consider a dedicated mechanism

question: do the unicode tables cover gbk and big 5 well?

assuming this, how about making a set of tfm,enc,map files that match 
the unicode positions (volunteers ...)

we can extend the utf handler with a kind of plugin mechanism:

\unprotect

\def\utfunihashglyph#1%
  {\@EA\doutfunihashglyph\@EA{\number\utfdiv{#1}}{#1}} % only div once

\def\doutfunihashglyph#1#2% div raw
  {\csname
     \ifnum#2<\utf@i
       \strippedcsname\unicodeasciicharacter
     \else\ifcsname\@@unicommand#1\endcsname
       \@@unicommand#1%
     \else\ifcsname\@@univector#1\endcsname
       \@@univector#1%
     \else
       \strippedcsname\unicodeunknowncharacter
     \fi\fi\fi
     \@EA\endcsname\@EA{\number\utfmod{#2}}} % only mod once

\def\unicodeunknowncharacter#1%
  {\unknownchar}

\let\utfunihash\utfunihashglyph

\def\@@unicommand{@@unicommand}

\def\defineutfcommand #1 #2%
  {\setvalue{\@@unicommand#1}##1{#2{#1}{##1}}}

so we can define pluig in handlers for e.g. chinese

\defineutfcommand 81 {\uchar}

(bombs due to missing fonts, so for testing)

\def\NotYet#1#2{[#1 #2]}

\defineutfcommand 81 {\NotYet}

(next comes adapting the chinese files; i can imagine that we redo the 
big5 and gbk definitions so that they remap to ut8 as common encoding)

so .. the question is ... who is going to make the tfm/enc/map files

Hans

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context
  

[-- Attachment #1.2: Type: text/html, Size: 4029 bytes --]

[-- Attachment #2: Type: text/plain, Size: 139 bytes --]

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

  parent reply	other threads:[~2005-12-13  9:14 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-05  7:36 strange behavior of startbackground Xiao Jianfeng
2005-12-05  7:43 ` Xiao Jianfeng
2005-12-05  9:07   ` Hans Hagen
2005-12-05 12:46     ` Xiao Jianfeng
2005-12-05 14:33       ` Hans Hagen
2005-12-06  2:04         ` Xiao Jianfeng
2005-12-06  2:29           ` Xiao Jianfeng
2005-12-08 12:36             ` Patrick Gundlach
2005-12-08 15:35               ` Chinese (was:Re: strange behavior of startbackground) Tobias Burnus
2005-12-08 20:26                 ` Chinese Tobias Burnus
2005-12-08 22:11                   ` Chinese Patrick Gundlach
2005-12-09  2:19                   ` Chinese Xiao Jianfeng
2005-12-09 10:53                     ` Chinese Tobias Burnus
2005-12-09 13:46                       ` Chinese Xiao Jianfeng
2005-12-09 14:03                         ` Chinese Tobias Burnus
2005-12-09 14:19                           ` Chinese Xiao Jianfeng
2005-12-09 14:24                           ` Chinese Xiao Jianfeng
2005-12-09 15:01                             ` Chinese Tobias Burnus
2005-12-09 15:24                             ` Chinese Richard Gabriel
2005-12-12 15:53                               ` Chinese Hans Hagen
2005-12-12 21:15                                 ` Chinese Tobias Burnus
2005-12-14 22:19                                   ` Chinese Hans Hagen
2005-12-13  9:14                                 ` Richard Gabriel [this message]
2005-12-13  9:55                                   ` Chinese Hans Hagen
2005-12-13 10:31                                   ` Chinese Xiao Jianfeng
2005-12-09 14:43                           ` Chinese Adam Lindsay
2005-12-09 15:30                             ` Chinese Tobias Burnus
2005-12-12 12:29                               ` Chinese Hans Hagen
2005-12-06  2:29           ` strange behavior of startbackground Xiao Jianfeng
2005-12-05  7:48 ` Xiao Jianfeng
2005-12-05  7:52 ` Xiao Jianfeng
2005-12-05  8:50 ` Taco Hoekwater
2005-12-05  9:05 ` Hans Hagen
2005-12-05 12:37   ` Xiao Jianfeng
2005-12-05 14:35     ` Hans Hagen
     [not found] <20051212173143.94765127FA@ronja.ntg.nl>
2005-12-13  8:07 ` Chinese Duncan Hothersall
     [not found] <20051209110003.CF289127DF@ronja.ntg.nl>
2005-12-09 11:06 ` Chinese Duncan Hothersall
  -- strict thread matches above, loose matches on Subject: below --
2002-05-18  0:42 chinese Jens-Uwe Morawski
2002-05-19 22:29 ` chinese Hans Hagen
     [not found]   ` <5.1.0.14.1.20020521085937.0405c110@server-1>
     [not found]     ` <001801c20415$4fe46e30$04c7fea9@wanglei>
2002-05-25 20:25       ` chinese Hans Hagen
2002-05-26 18:42         ` chinese Mr. Lei Wang
2002-05-26 19:28           ` chinese Hans Hagen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20051213091446.283c7ce3@mx1.kerio.com \
    --to=rgabriel@kerio.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).