Article Source: http://www.linuxidc.com/Linux/2010-01/23990.htm
Installation environment
Ubuntu 9.10, Java 1.6.0.15
First, find the font you need.
C:/Windows/fonts. I copied only simhei. TTF and simsun. TTC.
After installing Java, you can see many fonts in the installation directory/usr/lib/JVM/Java-6-sun/JRE/lib/fonts/of Java. Create a directory here, the name is fallback (use this name. It is said that Ubuntu cannot find the set font.
Find the font in the directory) and copy the font you need to the directory.
$ Mkdir fallback
$ Sudo CP./your font DIR/simhei. TTF fallback/
$ Sudo CP./your font DIR/simsun. TTC fallback/
Next, we should note that many documents do not describe this point, that is, the permission of the font file must be readable! I did not pay attention here.
After several days, I finally found out.
$ CD fallback/
$ Sudo chmod 644 simhei. TTF
$ Sudo chmod 644 simsun. TTC
Then, run the following command in the fallback directory:
$ Mkfontscale & mkfontdir
In this case, the fonts. dir and fonts. Scale files are generated under the fallback directory, and the fonts. Scale contents are appended to the fonts. dir in the parent directory,
$ Su
$ Cat fonts. scale>.../fonts. dir
This should be done. If not, the FC-Cache refresh the font cache.