TextField truncation after upgrading to JDK11


Are there any known issues related to font metrics or rendering with jasper reports from JDK8 to JDK11?

We recently upgrade to JDK 11.0.16 from JDK8 and noticing some TextField labels are being truncated. Increasing the width or using the property TextAdjust="ScaleFont" fixes the issue but we can not figure out how many reports will have problems and need fixing.

Is there anyway to override the textField properties globally using Jasper library or any other solution which works JVM wide?


Thank you


girish.sharma's picture
Joined: Feb 27 2023 - 1:51pm
Last seen: 2 months 4 weeks ago

2 Answers:


Could you please give me the environment details, also attached the jasperreport.properties file.
You can also use the StretchHeight as textAdjust it may help you, in case if it now works then you need to use the ScaleFont.

Please go through the below-attached document for more information:

Unfortunately, you can't set the property globally it may cause other issues with the other reports.

Swapnil Pawar's picture
Joined: Apr 22 2021 - 5:44am
Last seen: 2 days 4 hours ago


If you don't want to use the ScaleFont option then for other alternatives you need to use the font extension for the pdf export and need to embed the font into the
pdf. Pdf export not using the system font or OS fonts as the JRS pdf export need to embed the font in the report using font extension as mentioned below wiki
article: https://community.jaspersoft.com/wiki/custom-font-font-extension

Note: "DejaVu Sans" Font is an inbuilt Font Extension provided in the JRS.

I hope this will help you, Please let us know if you have any queries. Thanks!

Swapnil Pawar's picture
Joined: Apr 22 2021 - 5:44am
Last seen: 2 days 4 hours ago