首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 操作系统 > UNIXLINUX >

ireport部署到linux系统字体有关问题

2012-11-25 
ireport部署到linux系统字体问题net.sf.jasperreports.engine.util.JRFontNotFoundException: Font 宋体

ireport部署到linux系统字体问题
net.sf.jasperreports.engine.util.JRFontNotFoundException: Font '宋体' is not available to the JVM. See the Javadoc for more details.



解决方法:

1、把需要用到的字体(可以直接拷贝windows系统的C:\WINDOWS\Fonts 下的相关字体)拷贝当前项目的classpath下,一般为classes目录下

2、在classpath里添加 jasperreports.properties 属性文件

文件内容为:

net.sf.jasperreports.awt.ignore.missing.font=true



即可解决

热点排行