I created a pdf.
But I found out that the fonts were broken.
The cause was missing temp folder in tomcat was.
If the font is not loaded, we would like to process an exception to prevent pdf generation.
To sum up
Read the font to generate a pdf.
I wnat to check if there is no temp folder for reading font
or if I don’t have the right to read temp folder.
You can determine the actual temp dir location by an inspecting of the system property System.getProperty("java.io.tmpdir");. Also you may override the property with JVM command-line parameter.
However in your particular case the problem reason seems to be other: try to explicitly define the document encoding. Now your on screenshots it looks like a two-bytes encoding is treated as a default single byte encoding (ISO-8859-1) – that causes the garbage texts in the output.
I tested it when there was and when there was no temp folder.
If there is no temp folder, pd4ml cannot read font. If there is a temp folder, read font normally.
Can you confirm the failure to read the font with api?
The temp dir is needed not by PD4ML itself, but by the font subsystem of JVM.
java.awt.Font.createFont() creates java.awt.Font instance from a given byte array, but as a rule (obviously it is platform-dependent) it needs to create a corresponding font file in the temp dir. We cannot control the internal java.awt.Font.createFont() logic, it is only possible to re-define temp dir location with java.io.tmpdir system property.