Set up chinese fonts using Microsoft’s simsun.ttf in Ubuntu 7.1 (Gutsy)

By xgwang

Mostly, I follow http://www.fwolf.com/blog/post/170, but that is old (for Ubuntu dapper). They suggested modifying /etc/fonts/fonts.conf which is bad in case of upgrading since fonts.conf will be overwritten. A better way is to add /etc/fonst/local.conf

1) My laptop has XP/Ubuntu Gutsy dual boot. The XP partition is mounted on /c.

mkdir /home/xgwang/win-fonts
cd /home/xgwang/win-fonts
cp /c/WINDOWS/Fonts/simsun.ttc simsun.ttf
cp /c/WINDOWS/Fonts/simhei.ttf .
cp /c/WINDOWS/Fonts/tahoma.ttf .
cp /c/WINDOWS/Fonts/tahomabd.ttf .
cp /c/WINDOWS/Fonts/verdana.ttf .
cp /c/WINDOWS/Fonts/verdanab.ttf .
cp /c/WINDOWS/Fonts/verdanai.ttf .
cp /c/WINDOWS/Fonts/verdanaz.ttf .
chmod 644 *

2)
cd /usr/share/fonts/truetype
ln -s /home/xgwang/win-fonts/ win-fonts
cd win-fonts
mkfontscale
mkfontdir

3)
fc-cache

4)Edit two files (due to Feisty and Gutsy’s new way of mananaging /etc/fonts/)
/etc/fonts/conf.avail/40-generic.conf
/etc/fonts/conf.avail/60-latin.conf
append
<family>Simsun</family>
after
<family>Bitstream Vera Serif</family>
in fields of ’serif’, ’sans-serif’, ‘monospace’

5)do the same in a new file, /etc/fonts/local.conf
(For a starting local.conf, copy http://www.gnome.org/fonts/local.conf)
append
<family>Simsun</family>
after
<family>Bitstream Vera Serif</family>
in ’serif’, ’sans-serif’, ‘monospace’

4) and 5) may not be needed both. Any one to confirm ?

3 Responses to “Set up chinese fonts using Microsoft’s simsun.ttf in Ubuntu 7.1 (Gutsy)”

  1. ipsi Says:

    Thank you very much for this. I was having a huge amount of trouble getting my Chinese fonts to look right. This has fixed it.

    A couple of notes: This works with any arbitrary font. The only problem is that I didn’t specify the same font for each of Sans, Serif and Mono, and thus it looked bloody weird in Gedit, trying to type Chinese… Now it’s all nicely consistent which I’m pleased about. Might try and see if I can make some of the other fonts work, but I’ve got what I wanted. :D

  2. Gerro Says:

    where heck do you get simsun.ttf font at anyway? Someone said its included with microsoft word…

  3. ламинат Says:

    5eThank’s for greate post.6k I compleatly disagree with last post . knn
    ламинат купить 5d

Leave a Reply