Birtchart Linux in the Chinese garbled problem is that the Java Virtual machine can not find the Chinese font file caused by fonts.
Steps:
1. Export lang=zh_cn in. Bash_profile. GB2312 modified to:
Export lang=zh_cn.gb18030. Because GB2312 does not support some special characters.
2. Modify the font in the generated chart's XML Source: Change the Sansserif to SimSun.
3. Find a Chinese font that can be used under Linux, which can be C:\WINDOWS\FONTS\SIMSUN.TTC under Windows 7.
4, in this to use the root user "root/rootgnnt" login, put the above fonts in the Linux Server installation JDK directory under the/opt/jdk1.8.0_91/jre/lib/fonts directory.
5, modify the/opt/jdk1.8.0_91/jre/lib/fonts/fonts.dir
5.1, the first line of the number plus one (if 48 is changed to 49).
5.2. Add in the last line:
Simsun.ttc-sungtil gb-medium-r-normal--0-0-0-0-c-0-gb2312.1988-0
6. Modify the/opt/jdk1.8.0_91/jre/lib/fontconfig.properties.src file
Change the line containing iso8859-1 from the equal sign to the following:
-sungtil gb-medium-r-normal--0-0-0-0-c-0-gb2312.1988-0
Contains "Chartobyteiso8859_1" can not change).
7. Start the Web server
Before the modification, garbled as:
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M02/84/1C/wKiom1eF4JGRauraAAAlR91wYuI171.png-wh_500x0-wm_3 -wmp_4-s_3312468920.png "title=" 20160713143255.png "alt=" Wkiom1ef4jgrauraaaalr91wyui171.png-wh_50 "/>
After modification, as normal as:
650) this.width=650; "Src=" Http://s5.51cto.com/wyfs02/M00/84/1D/wKiom1eF4N-QxzuQAAB_akXzgS8149.png-wh_500x0-wm_3 -wmp_4-s_1314129827.png "title=" 20160713143419.png "alt=" Wkiom1ef4n-qxzuqaab_akxzgs8149.png-wh_50 "/>
The problem of garbled characters of Birt chart in Linux