[XeTeX] Add Tibe-tan typesetting ability

Lobsang Sonam sonamm at sohu.com
Sat Jan 5 17:48:15 CET 2008


On 4 Jan 2008 18:37:05 +0000,
Jonathan Kew <jonathan_kew at sil.org> wrote:

>Something like this might work, though the result will not be  
>entirely perfect, at least in theory -- I'm pretty sure that the line- 
>break routine assumes that the discretionary lists each have a fixed  
>width, and won't take account of any stretch or shrink in the glue  
>you put there. (Which means you might as well use kerns, which are  
>already allowed.)

   For simplicity, I just want the broken line looks better, though the line-break point may not be optimal when considering the strech & shrink of glue in discretionary, at least for the first step.

>Provided the stretch/shrink of your discretionary glue isn't  
>dramatically different from other glues in the line, though, you  
>might find that the "errors" in line break calculations don't really  
>matter in practice, and once the breaks are chosen, whichever glue  
>ends up in the final line would probably get re-set along with the  
>rest of the glue. So although it's not strictly correct, the result  
>might be good enough for practical purposes.

   Under certain circumstance, there's one glue in my discretionary which is as long as about 0.6cm and can shrink or strech half of that. When there're two or more of them in the same line, sometimes the kern in discretionary differs too much from the glues out of discretionary, and looks too uncomfortable for completist like me, and perhaps for Donald Knuth too, ;-).

>I think you should be able to use Unicode characters directly in  
>\discretionary, just like anywhere else; if not, it's a bug. (A  
>simple test seems to work fine here.)

I test it again, but got the following erro msg:

D:\Sonam> xetex "tdisc.tex"

This is XeTeXk, Version 3.141592-2.2-0.997 (Web2C 7.5.6)
 \write18 enabled.
 %&-line parsing enabled.
entering extended mode
(./tdisc.tex
! Improper discretionary list.
l.3 ...ry{pre-break}{post-中文break}{Whole text}
                                                  
?

I've include tdisc.tex in the attachment. My test environment is 
MikTeX 2.6 + XeTeX 0.997 on Windows XP.
 
------------------				 
Best Regards!
Lobsang Sonam

-------------- next part --------------
A non-text attachment was scrubbed...
Name: tdisc.tex
Type: application/octet-stream
Size: 188 bytes
Desc: not available
Url : http://tug.org/pipermail/xetex/attachments/20080106/97d8b741/attachment.obj 


More information about the XeTeX mailing list