JDK-6578189 : Regression:TitleBorder insets have changed and it causes bcoz of 6434444.
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 6u3
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2007-07-09
  • Updated: 2011-05-18
  • Resolved: 2011-05-18
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 6 JDK 7
6u4Fixed 7 b20Fixed
Related Reports
Relates :  
Description
Bug Info:
=========
Till 6u2 b05,if you set the TitleBorder to a component,it aligned center with left and right margins inside the TitleBorder.

But from 6u3 b01 onwards,If you set the TitleBorder to a component,its not aligning to center and left and right margins are missing.It touches the edges of the TitleBorder and also looks ugly.

The component default height is also varying for some components.I am suspecting,this issue causes because of the change in xpstyle.java file for the fix 6434444.

Its happening on windows xp flavors only.

JDK Info:
=========
java version "1.6.0_03-ea"
Java(TM) SE Runtime Environment (build 1.6.0_03-ea-b01)
Java HotSpot(TM) Client VM (build 1.6.0_03-ea-b01, mixed mode, sharing)


Please find the attached images for verifying the issue.

In the image the first one captured with 6u2 b05 and second one captured with 6u3 b01.

Comments
EVALUATION Before the fix for 6434444 the value of Prop.SIZINGMARGINS was used to get the content margins which was wrong. After the fix the value of Prop.CONTENTMARGINS is used which is not quite correct either. The right way to get content margins is to use uxtheme's GetThemeBackgroundContentRect ( http://msdn2.microsoft.com/en-us/library/ms649925.aspx ). I suggest to use this method in XPStyle.getContentMargin
11-07-2007