mdc Posted May 9, 2009 Share Posted May 9, 2009 Is it possible to use a .ttf file not installed on the system as a font in a report displayed on screen?From this thread it didn't seem to be possible back in 2006...http://jasperforge.org/plugins/espforum/view.php?group_id=102&forumid=103&topicid=1150So - why would I like to do this? Well, because our reports consist of a bunch of different files; mainreport, headerandfooter report, images, subreport and fonts. I would like to store all of these in a zip file with some form of meta file to automaticlly compile a complete report. I think everything except the font thing is doable. Or is it?TIA,Marcus Link to comment Share on other sites More sharing options...
andfedotov Posted May 11, 2009 Share Posted May 11, 2009 Can't answer your question, but it seems like it has something to do with a recent patch of JasperRepots.It might help you to find an answer...JasperReports 3.1.3 Change Log===================================- font extensions support to allow using TTF files without the need to install them into the system; this also allows using different TTF files for the same logical font name, depending on the locale; Link to comment Share on other sites More sharing options...
mdc Posted May 11, 2009 Author Share Posted May 11, 2009 Thanks, it surly looks like what I want. Anyone got an example of how to use it? Is it the class JRFontUtil I should look at? Link to comment Share on other sites More sharing options...
lucianc Posted May 20, 2009 Share Posted May 20, 2009 mdcWrote: Thanks, it surly looks like what I want. Anyone got an example of how to use it? Is it the class JRFontUtil I should look at? Take a look at the demo/samples/fonts sample report shipped with JR to see a working example of font extensions.Regards,Lucian Link to comment Share on other sites More sharing options...
mdc Posted June 4, 2009 Author Share Posted June 4, 2009 What I understand thats only when exporting PDF files - right? I solved that by creating a custom JRPdfExporter. The problem still remains when viewing a report onscreen. Or have I missed something? Link to comment Share on other sites More sharing options...
lucianc Posted June 5, 2009 Share Posted June 5, 2009 Font extensions apply to the on-screen/Java report viewer as well. See the above mentioned sample report.Regards,Lucian Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now