Repository navigation
Replies: 2 comments 3 replies
|
You don't specify which Ubuntu, or whether it's the distro OpenJDK. If it's distro, it's usually a font configuration issue. You should be able to find some possible solutions online. Or try with an OpenJDK distribution like Temurin. |
|
I solved the problem. It seems to be a bug in OpenJDK 27. The cause was duplicate fonts: both fonts-liberation and fonts-liberation2 were installed, and they contain files with identical names. On JDK 27, new Font("Liberation Sans", Font.PLAIN, 16) resolves to Liberation Sans Bold Italic, whereas JDK 21, 24, and 25 correctly return the regular face. According to the font debug log, the JDK initially registers the Bold Italic file with a higher rank during font lookup. When the duplicate Regular file is subsequently encountered, it is rejected because it has a lower rank. As a result, the font family is left without a plain face, and the lookup falls back to Bold Italic. Workaround - sudo apt remove fonts-liberation2 I will submit a bug report. |

Uh oh!
There was an error while loading. Please reload this page.
I upgraded to Java 27, and now all the text in NetBeans 31 appears in bold.
For example:

I tried reducing the font size by adding --font-size 13 to the configuration file. The font size decreased, but the text still appears bold. I didn't have this issue with Java 25.
I use OpenJDK and Ubuntu 20.
Could anyone help me?
All reactions