Thanks for another question on StackOverflow and the answer of user dada67, told us that Jasper added Khmer Unicode supports since version 6.2.
I tested now on JasperReport 6.3 library with its existing sample in folder:
jasperreports-6.3.0\demo\samples\unicode
And now I could see it’s working good enough for Khmer rendering, just still one issue:
When we mix between Khmer text and English text together but the issue is only when it displays on Pdf, with other formats are fine now.
But I believe we still have a workaround to solve that kind of issue that we need to go deep into detail later.
Here is my tested result:
How to setup the testing demo
After you finished building the jasperreport library, you need to make sure that your Apache Ant has already the library of Apache Ivy, if you don’t, just download, extract it and place the ivy jar (e.g. ivy-2.4.0.jar) into Apache Ant “lib” folder.
Type: ant command on “samples/unicode” folder
The rest, just waiting…
What’s Interesting here…
Google Noto font that handle all the Unicode rendering here.
2 replies on “Jasper Report is now Supported Khmer Unicode to Pdf”
Hi @osify, I am now facing a problem with jasper report 6.3.0. using the default lowaige dependency
When I try to convert the report into pdf via the JRViewer, the result pdf cannot fully display the correct khmer text. For example, “ក្ក” results into “ក្ ក” where the coeng sign is shown, instead of combining two letters into one khmer consonant letter with subscript.
Also, using the JRPdfExporter did not work too.
Do you have any idea on this issue? It sounds weird as I can actually get the khmer text by converting the jasper report into pdf but not how I want it to be.
Directly export from the viewer to PDF is not working, Jasper need to replace to the new itext but I don’t think they will do it as it’s related to new license of the itext that cannot be mixed.
We need some work around solution to achieve the output to pdf, example: produce result as HTML and convert that html into PDF, if anyone can provide some handy code to help, it would be great.