I am generating the report in three formats
I am having trouble with displaying font in pdf, generated pdf shows font as normal font and some other than which I specified. Other two formats are fine. Now I follow the steps on this blog
I tried it for the Jasper Studio 5.5.1. And it didn't work some how my pdf was displayed in the report viewer part but when I tried to export it, and open the exported pdf it showed an error. That can not read pdf.
What I did is :
1. I added font using Preferences-> font -> added Calibri
2. This generates my pdf as per my requirement but then html is blank nothing except logo.
3. This doesn't work in my application too. It generates only blank html with logo and a pdf which doesn't have the desired fonts.
Help needed in displaying fonts I need in my pdf. I tried the approach with jar too, I created a jar and put it in my classpath, but here I wonder how does the jasper engine detects that this is the jar that I need to use while generating the reports. And this effort failed too.
The atricle that you shared in this thread is a good soruce of the information,
however I would like to share with you the additional source regarding your question:
Please pay your attention to the <pdfEmbedded>true</pdfEmbedded> tag
In short: you should create a font extension jar file and then make it available in your application, you can read more about how to do this in the aforementioned guide.
I have attached a sample of the font extension file that I used in JasperReports Server 5.5.0 to this thread.