When I make plugins.jasperPluginRMI.runReport() with OUTPUT_FORMAT.PDF the text formatted as “bold” is displayed as normal/standard.
The reports are correct on output format PRINT and/or HTML.
I have tried the JasperReports Basic Plugin version 6.0.0 up to 6.4.1, but always the same.
I need a correct output of the reports as PDF. Any suggestions what I can do?
Servoy 7.4.11
Java 1.8.0_231
macOS Mojave
Jaspersoft Studio 6.4.0
mboegem:
Look like as if the PDF doesn’t use the correct font.
Hi Marc,
I have read this topic before, but there are some differences like:
Reports are displayed correct in JasperViewer
iReport → Jaspersoft Studio
[attachment=0]jr_fonts.png[/attachment]
I get only this fonts from the menu for PDF Font Name.
Edit
PDF Font Name menu is only for replacement the set font.
Hi Thomas
yes I think I just had to export them (Fritz Maurhofer:do you remember?)
I deployed them to user direktory
C:\Users\ralfa\JaspersoftWorkspace\MyReports
Putting the font.jar into the JasperoftWorkspace/Reports directory doesn’t work.
If I have set the created (and exported as .jar) font family for pdf (i.e. Arial_pdf.jar) in Jaspersoft Studio to text fields on my report, but I always get this error:
<< java.lang.Exception: net.sf.jasperreports.engine.util.JRFontNotFoundException: Font “Arial_pdf” is not available to the JVM. See the Javadoc for more details. >>
I think the font.jar must be stored in Servoy server directory (or Tomcat for NGClient), but where? I don’t remember and server > webapps > ROOT is also not working.
In the Jasperreports Wiki is only discribed the how to for the Jasper Server.
I was in hope to find anything on servoyforge, but the webserver is currently down…
Edit
Currently works only in Debug Client on Servoy Developer.
With Smart Client on production server I get an empty report with errors I have to investigate.
Ok, I have copied my Arial_pdf.jar extension font to <servoy_install_path>/application_server/plugins/servoy_jasperreports folder on the production server and signed it.
But I still get the error:
ERROR - JRViewerPanel - Page paint error.
net.sf.jasperreports.engine.util.JRFontNotFoundException: Font “Arial_pdf” is not available to the JVM. See the Javadoc for more details.
I got this error message also in the Debug Client of Servoy Developer, but as soon as I have copied the Arial_pdf.jar into the …/servoy_jasperreports direction, all is working as expected.
Of course, I have restarted the server before trying to create a report.
There is some documentation in servoy-forge website https://www.servoyforge.net/projects/se … ease_notes
but I agree that it is not easily available. It should be added to servoy-jasperreports wiki page not in release note.
One more question:
While creating the font extension in jaspersoft studio you have to select the fonts(family) by source.
But the fonts direction is different on different OS. Does this matter if I choose the fonts from the OS source for the font extension?
I have putted the fonts to a folder in …/application_server/server/ROOT/reports/fonts and created the font extension from this source.
I have also copied this fonts folder to this direction on the production app server.
No, it doesn’t mater, jar file doesn’t have any reference to your local fonts.
After you add fonts to jasperreport studio and export them as a jar file, font_extension.jar (or any other name you give it ) file is created, this font_extension.jar is the only file you need to copy in <servoy_install_path>/application_server/plugins/servoy_jasperreports folder in your application server. Therefore you don’t need to copy fonts folder.
Hope that helps. Let me know if you have any other questions.
I have a new project with Servoy TI. On my PC out of Servoy-Developer the Font Arial with Bold=true works (or better it worked last week, today not anymore lol)
But on the client-server it just doesnt work.
I had the Problem years ago with smart-client but it was a easy fix with the font.jar and JNLP edit. But how do we do it in the TI version on Tomcat?
In the Servoy-Exporter the, for example arial.jar wont show for export.
After the .war gets started on the server, it doesnt create a plugins/servoy-jasperreport folder etc.
I tried every solution i found online or had in mind. SansSerif and Arial both dont get to bold in the final PDF.
Anyone have a idea? I just cant get to work with TI (servoy 23.6, jasper-report 6.20.1).
Either you have to make sure that the font is installed on the server (also installed/accessible to the account that is running tomcat)
OR
Like you mentioned export the font jar files so JasperReports are using them.
Developer is always a bit tricky, because the Jasper process is executed locally, being able to use the fonts which are installed on your machine, where in a deployed situation, all the Java code is able to use, is whatever is installed on the server it’s running on.
Hope this helps.
BTW it doesn’t make sense that Jasper plugin is not exported, unless you told the exporter not to.