On Thu, Feb 19, 2009 at 10:28 PM, Wolfgang Schuster
<schuster.wolfg...@googlemail.com> wrote:
> What method do you want to use.
>
> 1. Make a punctuation half width and insert space between them, e.g.
>   組版\hbox to .5em{」\hss}\hbox to .5em{。\hss}\hskip .5em\hbox to
> .5em{\hss「}原則
>
> 2. Let the punctuation full width and kern char combinations, e.g.
>   組版」\kern.5em。\kern.5em「原則
>

neither. the position of the bounding box of a certain punctuation
glyph is highly font-dependent.
if we use the half/full width and set all the parameters constant, we
will get ugly result when the font is changed.
It is easy to compare sim*.ttf and find that the punctuation glyph
positions in the metrics boxes of different fotns vary significantly.


Moreover, some glyphs in the font takes more than half-width. You can
open simli.ttf (distributed in windows xp), and find glyph
quotedblright 8821 (RIGHT DOUBLE QUOTATION MARK),  the max_y = 130
while a em=256. And these are not rare cases.

In the same font, different punctuation have very different bounding
box position in the font metrics too.
for quotedblright 8821 (RIGHT DOUBLE QUOTATION MARK) in simli.ttf,
max_y=130, while for uni3002 at 12290 (IDEOGRAPHIC FULL STOP) in
simli.ttf, max_y=82. it is not fair to set equal width for them.

So we should not cut a glyph into half and take the left part for typesetting.

Due to some reasons dates back from early days of computer typeface
design (at the old days, we have no idea about proportional width, all
the glyphs are set to square [for CJK]. Operating systems or Document
processing systems all use square or half of a square to position and
render glyphs), CJK fonts are usually designed with equal width, even
for punctuations. This is really bad: while typesetting, they do not
take up same space. So my idea is to convert the punctuation glyphs'
bounding box information into TFM width parameters (leave a little
space at left and right), so the CJK typesetting problem is reduced to
Latin typesetting problems. We can also position the glyph at the
begin or end of the line close to the margin (or even calculate the
exact space for margin kerning).

btw, we prefer typesetting Chinese document like this:

http://jjgod.org/docs/random/yt.pdf

This is a document produced using XeTeX and xeCJK package typeset by
Jiang Jiang.
All the glue/penalty rules are carefully optimized by the people from
local TeX community, although not using the bounding box information
(impossible to get from XeTeX).


Yue Wang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to