Hi CMDBuild Team,
I installed the font “IPAexGothic” on the machine running CMDBuild to display Japanese in reports .
When I run “fc-cache” command on the machine, “IPAexGothic” is displayed at the top (=set as highest priority).
And I restarted tomcat but when I run the report in CMDBuild, Japanese is not displayed .
So I decided to try to update the configuration file.
I understood that I should edit tomcat/webapps/ROOT/WEB-INF/classes/org/cmdbuild/config/default_config.properties.
When I set config file as you have shown in your example, it worked. (Report was successfully printed.)
org.cmdbuild.report.fonts=[{ "name": "Arial", "normal": "org/cmdbuild/report/fonts/arial.ttf", "bold": "org/cmdbuild/report/ fonts/arial.ttf", "italic": "org/cmdbuild/report/fonts/arial.ttf", "boldItalic": "org/cmdbuild/report/fonts/arial.ttf", "pdfEmbedded":"" false"}]
But when I specify IPAexGothic as below, it didn’t work.
org.cmdbuild.report.fonts=[{ "name": "IPAexGothic", "normal": "fonts/ipaexg.ttf", "bold": "fonts/ ipaexg.ttf", "italic": "fonts/ipaexg.ttf", "boldItalic": "fonts/ipaexg.ttf", "pdfEmbedded": "false"}]
Running a report with this configuration resulted in the following error
{
"success": false,
"messages": [
{
"level": "
ERROR",
"show_user": false,
"message": "org.cmdbuild.report.ReportException:
Error processing report = ReportData{id=24925, code=FX_contact}, caused by: org.cmdbuild.report:
ReportException: error processing report = ReportData{id=24925, code=FX_contact}, caused by: com.google.common.util.concurrent.UncheckedExecutionException: org.cmdbuild.report.ReportException:
ReportException: error loading jasper report context, caused by: org.cmdbuild.report:
ReportException: error loading jasper report context, caused by: org.cmdbuild.report:
Error setting font family property key =< normal > value =< fonts/ipaexg.ttf >, caused by: java.lang.reflect.InvocationTargetException, caused by: net.sf.jasperreports.engine.fonts.InvalidFontException:
Error loading font \"fonts/ipaexg.ttf\"., caused by: net.sf.jasperreports.engine.JRException: Input stream not found at: fonts/ipaexg.ttf."
}
]
}
Where should I place the .ttf file?
Thanks.