JDK-8015739 : Background of JInternalFrame is located out of JInternalFrame
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 8,11,17,19,20
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2013-05-31
  • Updated: 2024-09-18
  • Resolved: 2022-11-04
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11 JDK 17 JDK 20
11.0.24-oracleFixed 17.0.12-oracleFixed 20 b23Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Description
JDK/JRE tested: 1.8.0_b92
OS/architecture: Windows 7
Reproducible: Always
Reproducible on machine: aeremeev-ru
Is it a Regression: No
Is it a platform specific issue: I do not tried other platforms, but i think this problem is reproducible with every LAF with rounded corners.

To reproduce use default LAF of Windows 7, compile and run attached file.
In the corners of Internal Frame you can see red points.
Comments
Fix request [11u] I think we should fix this in 11, too. Low risk, affects java.desktop only, clear repro case. Backport from 17, simple resolves and the test had to be adapted to Java 11. Test passes and fails without the fix. SAP nightly testing passed.
19-03-2024

A pull request was submitted for review. URL: https://git.openjdk.org/jdk11u-dev/pull/2607 Date: 2024-03-18 08:20:35 +0000
19-03-2024

Fix request [17u] I backport this for parity with 17.0.12-oracle. Low risk, affects java.desktop only, clear repro case Clean backport except for Copyright. Test passes and fails without the fix. SAP nightly testing passed.
19-03-2024

A pull request was submitted for review. URL: https://git.openjdk.org/jdk17u-dev/pull/2301 Date: 2024-03-18 07:40:51 +0000
18-03-2024

Follow-up fix: JDK-8297449
01-12-2022

Changeset: f857f795 Author: Harshitha Onkar <honkar@openjdk.org> Committer: Alexey Ivanov <aivanov@openjdk.org> Date: 2022-11-04 19:48:31 +0000 URL: https://git.openjdk.org/jdk/commit/f857f795a9fc8b116bfc6b039114051061950e28
04-11-2022

The scaled thick frame drawn around JIF is being painted over by background and JIF titlebar thus causing the border to look uneven on fractional scales.
18-10-2022

On few scales (fractional - 1.25, 1.75) the highlight and shadow lines are not positioned correctly.
07-10-2022

Two edge cases issues were identified while testing with different frame sizes and on different platforms- - One was due to the inherent issue of robot.getPixelColor() which sometimes returns a different pixel color returned at the edge of border. This is a test issue and is fixed by adding a offset of 1 pixel to the border and corner checks. - The other issue occurs only in specific scenario - when the internal frame size is set to 125, 150, 225, 250...etc on uiScale of 1.25 (on Windows). A thin red line is seen at the bottom of the border. This is might be due the loopCount value and being investigated further.
07-10-2022

A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/10274 Date: 2022-09-14 18:33:47 +0000
14-09-2022

The thickness of border set by a scaled value of stroke width on G2D object is not rendering the border as expected for partial scales - 1.25, 1.5, 1.75.
02-09-2022

There are 3 issues related to JinternalFrame border found while testing on Windows & Mac (see attachments) 1. Red dot at each corner - Both on Windows & Mac 2. Background color seems to overflow into border area when scaled especially at 150% - Windows only 3. Border structure looks different on Mac & Window (Metal LAF) when Scaled - maybe due to fractional scaling issue on Windows similar to JDK-8279614. The issue is only on Windows
16-08-2022

setOpaque(false) is commented out in MetalInternalFrameUI which might be the cause for the background of InternalFrame to be seen partially in the border region.
13-08-2022

Possible fix location: JInternalFrame borders (for Metal LAF) are painted in MetalBorders - InternalFrameBorder sub class.
01-08-2022

Reproducible on windows 10 and JDK 20. Background color overflows into the border. Images attached - Internal frame with and without background color for comparison.
19-07-2022

It seems that such JIF(non-rectangular) were incorrectly marked as Opaque.
03-05-2015