You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Maria2009 <ma...@shinoto.de> on 2009/03/11 11:46:01 UTC

Making East Asian text look good

Just some information for those few people who work with Chinese and Japanese
fonts, I was encouraged to write this in the forum, so I apologize to those
not being interested.  

In my last post I asked for a solution to print really justified text, and
the approach with the letter.spacing-property turned out to be excellent,
not just as regards justified alignment.

(1) Basically, Chinese characters often look too close together, and the
text layout is not as smooth as in East Asian word processors. With using
letter-spacing.minimum, optimum, maximum, the layout becomes more natural
and nicely justified. An expample that looks good in my eyes: 

font-size 10pt, letter-spacing.optimum 0.3pt, .minimum 0pt, .maximum 3pt. 

(2) There is a principal problem with colons, brackets etc. particularly in
Japanese text layout, they need to be pushed to the right border if they are
the last character in a line and need some space to the right or left
respectively if somewhere in the line. This problem is not solved with
simple letter-spacing, but a solution with values similar to those suggested
above produced rather good compromises in these cases. 

(3) I have not yet come across cases where colons etc. start a new line.
This is a problem that occurs frequently with text engines that are not used
to East Asian texts. If this problem turns up, it needs to be solved. 

(4) With the letter-spacing approach, letters of words written in Western
scripts become spaced although this is not the intention. Yet the only way
to avoid this is to mark up any string that belongs to a different script
system or to use some complicated filter for each glyph in the transforming
stylesheet by its unicode value (this is at least, how I see it with my
rather limited knowledge). 
-- 
View this message in context: http://www.nabble.com/Making-East-Asian-text-look-good-tp22452061p22452061.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Making East Asian text look good

Posted by Maria2009 <ma...@shinoto.de>.
Hello, 


Andreas Delmelle-2 wrote:
> 
> 
> On 11 Mar 2009, at 11:46, Maria2009 wrote:
> Just FYI:
> 
>> <snip />
>>
>> (3) I have not yet come across cases where colons etc. start a new  
>> line.
>> This is a problem that occurs frequently with text engines that are  
>> not used
>> to East Asian texts. If this problem turns up, it needs to be solved.
> 
> Don't worry. This should normally never present itself. This is part  
> of the Unicode Annex#14 tailorable line-breaking rules that FOP  
> implements. (see:
> http://unicode.org/reports/tr14/#TailorableBreakingRules)
> 
> Technically: a colon (U+003A) has line-breaking class IS (numeric  
> separator), and UAX#14 does not permit breaks before that class by  
> default (LB13).
> 
> OTOH, if I understand correctly, basic UAX#14 does not cover all  
> Japanese line-breaking rules, so it may be that a native reader will  
> find the layout to be suboptimal, or will at least notice some  
> oddities in this area...
> 

Thanks for the link. I am learning by doing. At the moment I cannot really
make sense of the document, but I am getting closer... Anyway, good to know
that the problem will not come up!

As far as small oddities are concerned, except for the real DTP software
packages, there is yet nothing really ideal. For the time being,
XML-documents together with print via FOP is a very good solution for
academic texts and data, the best I know. 




> 
> This all got me thinking: in the "normal" case, where letter-spacing  
> has its initial value, it should normally come from the font. I'll  
> have to check whether this means that either the font does not contain  
> this info, or maybe it's there but FOP does not find it in the place  
> it expects...
> 
> 

It is not that it looks bad the default way. Some additional space between
the characters make them more readable. I just checked with the same font in
a Mac text editor, and the result also looks a bit compressed -- though not
really "wrong". It seems to be a matter of some fonts rather than FOP. 

And it is great that one can easily adjust this with letter spacing. 

Best,
Maria
-- 
View this message in context: http://www.nabble.com/Making-East-Asian-text-look-good-tp22452061p22468160.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Making East Asian text look good

Posted by Maria2009 <ma...@shinoto.de>.
Hi,


Andreas Delmelle-2 wrote:
> 
> ...
> 
> This all got me thinking: in the "normal" case, where letter-spacing  
> has its initial value, it should normally come from the font. I'll  
> have to check whether this means that either the font does not contain  
> this info, or maybe it's there but FOP does not find it in the place  
> it expects...
> 
> 

I just checked a number of fonts now and realised that there are extremely
large differences as well as line height and spacing between each character
/letter is concerned. I seems to me that this is nothing that FOP can deal
with -- too many individual problems with each font. But it can be easily
controlled with absolute line-height values and the letter-spacing. 

Thanks for taking these rather "exotic" problems into account!

Maria
-- 
View this message in context: http://www.nabble.com/Making-East-Asian-text-look-good-tp22452061p22471247.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Making East Asian text look good

Posted by Andreas Delmelle <an...@telenet.be>.
On 11 Mar 2009, at 11:46, Maria2009 wrote:

Hi

>
> Just some information for those few people who work with Chinese and  
> Japanese
> fonts, I was encouraged to write this in the forum, so I apologize  
> to those
> not being interested.

Thanks for sharing this. I'm sure there will be plenty of interested  
folks out there.

Just FYI:

> <snip />
>
> (3) I have not yet come across cases where colons etc. start a new  
> line.
> This is a problem that occurs frequently with text engines that are  
> not used
> to East Asian texts. If this problem turns up, it needs to be solved.

Don't worry. This should normally never present itself. This is part  
of the Unicode Annex#14 tailorable line-breaking rules that FOP  
implements. (see: http://unicode.org/reports/tr14/#TailorableBreakingRules)

Technically: a colon (U+003A) has line-breaking class IS (numeric  
separator), and UAX#14 does not permit breaks before that class by  
default (LB13).

OTOH, if I understand correctly, basic UAX#14 does not cover all  
Japanese line-breaking rules, so it may be that a native reader will  
find the layout to be suboptimal, or will at least notice some  
oddities in this area...


This all got me thinking: in the "normal" case, where letter-spacing  
has its initial value, it should normally come from the font. I'll  
have to check whether this means that either the font does not contain  
this info, or maybe it's there but FOP does not find it in the place  
it expects...

Regards


Andreas

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org