On Wed, 30 Mar 2022 16:59:50 GMT, Phil Race <p...@openjdk.org> wrote:
> Well the test is setting the Windows L&F, and evaluating its rendering. Which > seems to me to make it windows-specific, as written. The test would would > need to run through all the L&Fs if it is actually valid to do so. Right, the bug was reported on Windows. The Windows L&F uses `EtchedBorder` for `TitledBorder` whereas other L&F don't. From this point of view, the bug is Windows-specific. Yet the fix is in the shared code, in the `javax.swing.border.EtchedBorder` class which is not Look-and-Feel specific. I'm sure the problem can be reproduced if `EtchedBorder` is used directly rather than via `TitledBorder`. Yet you wouldn't see the bug on Linux and macOS because these two platforms support only integer scales, but the issue occurs with fractional scales only. If the test uses `EtchedBorder` directly, there'll be no need to iterate L&Fs. The test sets `EtchedBorder` border to a panel, the panel renders the border. * In fact, Windows 10 renders titled border flat: one grey line instead of etched border that was used in previous versions. Shall we update Swing's Windows L&F? ------------- PR: https://git.openjdk.java.net/jdk/pull/7449