This post is outdated, please refer to: Chinese fonts for iPhone 3.0

New Toy at Home
I finally got a 2nd generation iPod touch 8GB after Apple previewed the iPhone OS 3.0. Though I’m not quite interested in testing the early beta of 3.0 OS bugs despite of the “copy, cut, paste” tempting, the OS 2.x is enough fun to play with (even more fun when jailbreakable!).
I jailbroke it using VMWare Fusion because the tutorial on OSX 10.5.6 looks not so friendly. And after installed OpenSSH with Cydia, changing the file system can be easily done with any SFTP apps (meet the possibilities!).
Chinese Fonts Headache
Besides games and internet browsing, e-book reading is quite a good deal for iPod Touch/iPhone. I use Stanza and there is many choices of books. Although iPhone OS is multi-lingual by design, but there is only one Chinese font on iPhone OS, the sans-serif STHeiti. But a book needs a SERIF font to read!
It’s not hard to figure out that the font settings on iPhone OS are actually stored at /System/Library/Fonts/. The CGFontCache.plist is for the font list, and TTF format fonts are at /System/Library/Fonts/Cache. So I tried to just copy into the folder and modify the plist file. Maybe for English fonts it will just work, but it did not always work for my Chinese serif fonts except the one with Mac OS, the STSong.
But STSong is not good enough for reading because it is too light on screen, I need a bolder font. Any font that looked better wouldn’t work and it drove me crazy! I can not find out what’s special, so I just try to “substitute the shapes” with FontForge.
Perpetrate a Fraud
This is my steps:
- Open STSong with Fontforge, select all, clear. (There is no shapes in it now)
- Open another (better looking) font with Fontforge, change the resolution setting (Element>Font Info>General. STSong has a Em Size of 1000, so match this and click OK.) Fontforge will take a few seconds for transforming. If you don’t change this, it won’t look right after “pasting” into STSong.
- Then you navigate to the STSong window and choose Element>Merge Font. There you go, then don’t forget to generate the TTF Font (you can’t use File>Save, you need to File>Generate)
- Then copy to iPhone/iPod Touch and enjoy.
不折腾不舒服斯基
上周实在抗拒不了iPhone OS 3演示的诱惑,买了一个iPod Touch二代,现在8G的只要1500块,想当年我买了个红色的iPod nano 4G还花了1600来块啊,都是港货,时代真的不同了。然后折腾了半天破解,装游戏,最后卡在是想往上面安装中文字体上面。
iPhone(以下提到都同时包含iPod Touch) 的屏幕看电子书虽然比不上kindle, 但是在手机和MP4圈里也算是相当不错了。但是最大的麻烦莫过于我想用宋体看书,iPhone上面只有一个中文字体就是华文黑体,这个虽然将就看,但是看小说不是看杂志,不用宋体眼睛就是不舒服。
然后就折腾呗……iPhone的字体设置想改也容易,随便一找就找着了,/System/Library/Fonts/,一个plist是字体列表,和一个子文件夹放字体,可能英文字体直接扔进去改改plist也就可以了,但是中文字体就是这么不靠谱,随便扔个字体进去,Stanza根本不认,甚至一进入字体设置界面都能崩溃。
知其然不知其所以然──掉包计
我试了无数组合方式,发现只有华文宋体这一个字体能用,但是装在里面字体显示也太虚了。华文中宋也是华文公司的,也比华文宋体好看,但是扔进去就是不好使。怎么办?我先试了试简单的办法,比如改文件信息之类的,结果依然不好使,最后只好用最土的办法,复制粘贴……
步骤:
- 用Fontforge打开华文宋体,全选,清除
- 用Fontforge打开别的字体,我换了方正宋三。注意也不能直接粘过去,因为字体的分辨率不一样。华文宋体是1000,宋三是256,这就必须对应一致才行。我一开始没注意这个事情,结果字体粘过去都小两三号。在Element>Font Info>General找Em Size改好就可以。
- 然后我们也没必要去粘贴,直接在华文宋体的窗口里面选Element>Merge Font. 然后把字体的形状粘过来就行了,我们只需要华文宋体这个容器而已。最后保存字体,要用File>Generate)
- 最后直接拷过去就好了。可以看效果图
如果有人刚好感兴趣而且不想再重复折腾一次,可以在这里下载我的小成果,用任意支持SFTP的软件复制到相应的地方即可。
8 Comments
benny7874:
July 20, 2009如果有時間,希望版主能夠做多一個支持繁體中文的字體。支持GBK下的繁體即可,謝謝
Xiaoding:
April 5, 2009发现 Adobe Reader 中的 AdobeSongStd-Light 这个字体不错,已经装到 iPod Touch 上了。
我也写了一下,给你发了 Trackback 不知道发成功没有。。 你这个页面上找不到 trackback url …
Xiaoding:
March 30, 2009Thanks!
不过这个字体缺少繁体中文字符,有的电子书是繁体的,结果显示繁体字的时候就 STHei 和 STSong 一齐上了。。
Cheng:
March 31, 2009我也发现了,方正明明写的GBK,真是不靠谱……
Jewel:
March 23, 2009就是华文中宋好看!不管不管……