atom feed4 messages in com.redhat.fedora-fonts-listRequest for review and advice on wqy-...
FromSent OnAttachments
Qianqian FangNov 23, 2007 8:24 pm.conf
Nicolas MailhotNov 24, 2007 6:21 am 
Qianqian FangNov 28, 2007 11:08 pm 
Qianqian FangNov 29, 2007 4:08 pm.conf
Subject:Request for review and advice on wqy-bitmap-fonts fontconfig settings
From:Qianqian Fang (fan@gmail.com)
Date:Nov 23, 2007 8:24:53 pm
List:com.redhat.fedora-fonts-list
Attachments:

hi

I am quite new as a Fedora package maintainer. I submitted a few Chinese font packages to Fedora, and luckily, Jens Petersen has been extremely patient and guided me through package submission processes. I am glad that these fonts are now serving the Chinese Fedora users and we got quite good feedbacks from them.

Today, I would like to ask for your help to create a robust fontconfig file for wqy-bitmap-fonts. This font was installed by default in Fedora 8 for Chinese users. It recently caused some problems displaying Latins for non-Chinese users. Please see bug #381311 for more details. https://bugzilla.redhat.com/show_bug.cgi?id=381311

I will describe my goals, the achieved results and the problems.

=================================== 1. Motivations and goals

As an active developer and Linux user for couple of years, I strongly feel that there is a consensus among most Chinese users (both Mainland and Taiwan) for font rendering. These consensus can be summarized as the followings:

1. given the fact that most Chinese vector font rendering are quite blurry on nearly all Linux distributions, plus the fact that there is no free Chinese fonts with high quality hinting, hand-tuned bitmap glyphs are preferred for on screen display of Chinese characters 2. Latin glyphs has low stroke density and autohinting is becoming sufficient, using vector glyphs of these non-CJK characters is preferred 3. ideally, the requirement #1 should be locale independent (maybe exclude ko/ja users, if it conflicts with their consensus); requirement #2 is virtually true for most modern Linux desktops nowadays (for non-CJK locales)

The following two pictures may shine some light on what a normal Chinese user considers as a "good" font rendering:

* under non-Chinese locales (use en_US as an example) [can not be achieved for now, used post-processing] http://wenq.org/gallery/albums/userpics/10002/confopt_preferred_rendering_en-us.png

* under Chinese locales (use zh_TW as an example) [achieved on F8 with wqy-bitmap-fonts 0.9.9-1] http://wenq.org/gallery/albums/userpics/10002/confopt_preferred_rendering_zh.png

the main features include: A. when rendering Hanzi for generic aliases (i.e. sans/serif/mono): A.1: if font sizes are common on screen, such as 8pt-12pt, use bitmap Chinese font A.2: for sizes above or below, use the first preferred vector Chinese font B. when rendering non-Hanzi (or non-CJK) glyphs, use the preferred fonts determined by fontconfig C. when a specific Chinese font was chosen, exclusively use this font for all covered characters

=================================== 2. Default rendering of Hanzi on F8 without wqy-bitmap-fonts

Without installing wqy-bitmap-fonts, the screenshots of F8 is shown below:

* under non-Chinese locales (use en_US as an example) http://wenq.org/gallery/albums/userpics/10002/confopt_F8_no_wqy-bitmap_en-us.png

unsatisfactories: 1) no bitmap fonts were used for screen-sized Hanzi 2) garbled text with a mixture of Japanese and Chinese fonts (the headings) 3) Hanzi glyphs are blurry, getting worse for large blocks of text

* under Chinese locales (use zh_TW as an example) http://wenq.org/gallery/albums/userpics/10002/confopt_F8_no_wqy-bitmap_zh.png

unsatisfactories: 1) generally looks OK if Uming is installed 2) for mono, the Latins in Uming were used, rather than Dejavu/Vera 3) for serif, no bitmap glyphs because UKai has no embedded bitmaps

=================================== 3. Hanzi rendering on F8 with 85-wqy-bitmapsong.conf

The devel. of wqy-bitmap-fonts started from expanding the embedded bitmap fonts in Uming (both originated from firefly-bitmap-font) 3 years ago. After 3 years development at wenq.org, our project website, we have completed all bitmap glyphs for CJK Basic (U4E00-U9FA5) and CJK Extension A (U3400-U4DB5), covering 27,484 characters at 4 point sizes, nearly twice of the Uming's embed bitmaps (only ~15,000 characters). In addition, 80% of the old firefly(uming) glyphs were fine-tuned. The improvements are quite significant, making the font a popular choice among Chinese users. The following sample shows the difference between uming and wqy-bitmap-fonts:

http://wenq.org/gallery/albums/userpics/10002/confopt_wqy-bitmap_vs_uming.png

In package wqy-bitmap-fonts, we provided a default fontconfig file, 85-wqy-bitmapsong.conf (see attachment). Using this file, we raised the priority of wqy-bitmap-fonts for rendering Hanzi, while trying to keep it lower than the default sans/serif/mono Latin fonts. With this file, Chinese users are able to get the preferred rendering as shown above, i.e. http://wenq.org/gallery/albums/userpics/10002/confopt_preferred_rendering_zh.png

however, for English locales, it did not seem to improve the situation, nor make it worse (at least with my copy) http://wenq.org/gallery/albums/userpics/10002/en_US_with_wqy-bitmap-fonts.png

I do noticed that this file has side effects, the bug thread (#381311) as an example, however, so far I have not yet been able to identify the exact cause. These reports are rather random and mostly non-repeatable. Debugging fontconfig outputs constantly gives me confusing results. My guess is that we might use some fragile fontconfig syntax and are not consistently executed over different systems.

=================================== 4. Questions

That's all I want to learn from you: do you see a robust implementation of fontconfig font selection mechanism to achieve my goals above? if yes, how? if no, to whom should I file bug reports to?

I apologize for the long email, I wish you read to this line before giving up.

thank you so much and looking forward to hearing back from you.

Qianqian