-
Bug
-
Resolution: Cannot Reproduce
-
P3
-
None
-
1.4.0_01, 1.4.1_02, 1.4.2
-
x86
-
windows_2000, windows_xp
Name: jk109818 Date: 05/07/2003
FULL PRODUCT VERSION :
java version "1.4.2-beta"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-beta-b19)
Java HotSpot(TM) Client VM (build 1.4.2-beta-b19, mixed mode)
FULL OS VERSION :
Microsoft Windows XP [Version 5.1.2600]
A DESCRIPTION OF THE PROBLEM :
If you use a 32x32 icon for JInternalFrames in Windows LAF, the icon is not resized correctly (as it is in the case of JFrames), and only the bottom half of the icon is shown. This has been working before, if I remember correctly it broke in 1.4 FCS so this is a regression.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Set the LAF to Windows. Create a JFrame with a JDesktopPane inside. Add a JInternalFrame instance and set the internal frame's icon to a 32x32 image.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
The icon should be resized to 16x16.
ACTUAL -
The icon is not resized, instead, it is cut in half, and the lower half is displayed.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import java.awt.*;
import javax.swing.*;
public class Test extends JFrame {
public Test () {
JDesktopPane pane = new JDesktopPane ();
getContentPane ().add (pane);
JInternalFrame jif = new JInternalFrame ("test",true);
jif.setFrameIcon (new ImageIcon ("some32x32.gif"));
pane.add (jif);
jif.setSize (100,100);
jif.setVisible (true);
setVisible (true);
}
public void run () {
}
public static void main (String[] args) {
try {
UIManager.setLookAndFeel (UIManager.getSystemLookAndFeelClassName ());
} catch (Exception e) {}
new Test ();
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
Convert the image to 16x16. But this is an ugly, non-portable solution.
Release Regression From : 1.3.1_06
The above release value was the last known release where this
bug was known to work. Since then there has been a regression.
(Review ID: 185380)
======================================================================