On Fri, 13 Aug 2021 12:29:06 GMT, Maxim Kartashev <github.com+28651297+mkartas...@openjdk.org> wrote:
>> oh you are getting metrics for a JFrame ? That's not going to exercise any >> new font code so is pointless except to make it so the test has to be >> headful. > > But `getFontMetrics()` is the primary "entry point" that generated all the > JNI warnings in the first place. And I'm also not sure that we could've > gotten all the warnings on Windows without `JFrame`. So what's wrong with g2d.setFont(font); FontMetrics metrics = g2d.getFontMetrics(font); ? No frame needed. ------------- PR: https://git.openjdk.java.net/jdk/pull/4572