United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-4675064 : Black shadow around icons in JFileChooser using Windows XP

Details
Type:
Bug
Submit Date:
2002-04-26
Status:
Resolved
Updated Date:
2003-04-12
Project Name:
JDK
Resolved Date:
2002-08-23
Component:
client-libs
OS:
windows_xp
Sub-Component:
javax.swing
CPU:
x86
Priority:
P4
Resolution:
Fixed
Affected Versions:
1.4.0,1.4.1
Fixed Versions:
1.4.1_02 (02)

Related Reports
Backport:

Sub Tasks

Description

Name: jk109818			Date: 04/25/2002


FULL PRODUCT VERSION :
java version "1.4.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-b92)
Java HotSpot(TM) Client VM (build 1.4.0-b92, mixed mode)

FULL OPERATING SYSTEM VERSION :
Microsoft Windows XP [Version 5.1.2600]


A DESCRIPTION OF THE PROBLEM :
I have seen the following problem on two different Windows
XP systems: Any JFileChooser using the Windows Look and
Feel will display the shadow around icons as pitch black,
instead of the normal light gray color. This black shadow
is very noticeable and ugly. The other colors in the icons
display correctly.

This problem shows up only in Java JFileChooser's in the
Windows Look and Feel and is not specific to any program.
In fact, the black shadows show up in the SwingSet and
FileChooserDemo that ships with Java 1.4. Normal Windows
file choosers (not written in Java) display the icons just
fine.

Again, this occurs every time and is reproducible on at
least two Windows XP machines, which do not have any
similar hardware. I have tried closing all background
programs and processes to no effect. Needless to say, I'm
stumped on this one.

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Find a Windows XP machine.
2. Bring up a JFileChooser in the SwingSet demo using the
   Windows Look and Feel.
3. Look for very apparent black shadows around the icons.
4. If everything looks normal, try another Windows XP
   machine. I've found 2 machines that display the black
   borders. I've only looked at 3 XP machines total.

EXPECTED VERSUS ACTUAL BEHAVIOR :
Expected: Nice looking icons with a light gray shadow.
Actual  : Ugly black shadows around the icons.

This bug can be reproduced always.
(Review ID: 145891) 
======================================================================


###@###.### 2002-08-07

same problem reported by a CAP member:

J2SE Version (please include all output from java -version flag):
  java version "1.4.1-rc"
  Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-rc-b18)
  Java HotSpot(TM) Client VM (build 1.4.1-rc-b18, mixed mode)

Does this problem occur on J2SE 1.3 or 1.4?  Yes / No (pick one)
  Yes 1.4.x
  Not 1.3.x

Operating System Configuration Information (be specific):
  Microsoft Windows XP Pro  (All Windows Updates as at 7Aug2002)
  Video driver - NVidia 2.1.3.2 (10/12/2001)

Java System properties:
C:\dev\JavaEnv>java -cp classes org.palfreyman.util.JavaEnv
-- listing properties --
java.runtime.name=Java(TM) 2 Runtime Environment, Stand...
sun.boot.library.path=c:\java\j2sdk1.4.1_b18\jre\bin
java.vm.version=1.4.1-rc-b18
java.vm.vendor=Sun Microsystems Inc.
java.vendor.url=http://java.sun.com/
path.separator=;
java.vm.name=Java HotSpot(TM) Client VM
file.encoding.pkg=sun.io
user.country=GB
sun.os.patch.level=
java.vm.specification.name=Java Virtual Machine Specification
user.dir=C:\dev\JavaEnv
java.runtime.version=1.4.1-rc-b18
java.awt.graphicsenv=sun.awt.Win32GraphicsEnvironment
java.endorsed.dirs=c:\java\j2sdk1.4.1_b18\jre\lib\endorsed
os.arch=x86
java.io.tmpdir=C:\DOCUME~1\Kev\LOCALS~1\Templine.separator=

java.vm.specification.vendor=Sun Microsystems Inc.
user.variant=
os.name=Windows XP
sun.java2d.fontpath=
java.library.path=c:\java\j2sdk1.4.1_b18\bin;.;C:\WINDO...
java.specification.name=Java Platform API Specification
java.class.version=48.0
java.util.prefs.PreferencesFactory=java.util.prefs.WindowsPreferencesFac...
os.version=5.1
user.home=C:\Documents and Settings\Kev
user.timezone=
java.awt.printerjob=sun.awt.windows.WPrinterJob
file.encoding=Cp1252
java.specification.version=1.4
user.name=Kev
java.class.path=classes
java.vm.specification.version=1.0
sun.arch.data.model=32
java.home=c:\java\j2sdk1.4.1_b18\jre
java.specification.vendor=Sun Microsystems Inc.
user.language=en
awt.toolkit=sun.awt.windows.WToolkit
java.vm.info=mixed mode
java.version=1.4.1-rc
java.ext.dirs=c:\java\j2sdk1.4.1_b18\jre\lib\ext
sun.boot.class.path=c:\java\j2sdk1.4.1_b18\jre\lib\rt.jar...
java.vendor=Sun Microsystems Inc.
file.separator=java.vendor.url.bug=http://java.sun.com/cgi-bin/bugreport...
sun.cpu.endian=little
sun.io.unicode.encoding=UnicodeLittle
sun.cpu.isalist=pentium i486 i386

Hardware Configuration Information (be specific):
  AMD Athlon 1GHz
  512MB PC133 RAM
  Motherboard Abit KT7-RAID
  Video Abit NVIDIA GeForce 2 MX 32MB

Bug Description:
  The filesystem icons are not rendered correctly in the Windows L&F on
  Windows XP.

  Eg. Desktop, My Computer, normal folder icon, special folder icons, etc.
  The Icons have a dirty black shadow - maybe its a transparency issue?

  Please dont release like this - its the same in 1.4.0 - and needs fixing for
  client GUI apps to look anything other than awful on XP.

  This is not an issue for 1.3.x, since it does not attempt to mimic the
  native file chooser, or icons.

Steps to Reproduce (be specific):

C:\java\j2sdk1.4.1_b18\demo\jfc\FileChooserDemo>set
JAVA_HOME=c:\java\j2sdk1.4.1_b18
C:\java\j2sdk1.4.1_b18\demo\jfc\FileChooserDemo>set
PATH=%JAVA_HOME%\bin;%PATH%
C:\java\j2sdk1.4.1_b18\demo\jfc\FileChooserDemo>java -version
java version "1.4.1-rc"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-rc-b18)
Java HotSpot(TM) Client VM (build 1.4.1-rc-b18, mixed mode)

C:\java\j2sdk1.4.1_b18\demo\jfc\FileChooserDemo>java -jar
FileChooserDemo.jar

Then switch to Windows L&F


                                    

Comments
EVALUATION

In some cases the icons on XP have an alpha channel to make
the edges be semi-transparent. In this case the icon mask
should not be applied. Fixed in native AWT code.

###@###.### 2002-08-13
                                     
2002-08-13
CONVERTED DATA

BugTraq+ Release Management Values

COMMIT TO FIX:
1.4.1_02
mantis
mantis-b02

FIXED IN:
1.4.1_02
mantis
mantis-b02

INTEGRATED IN:
1.4.1_02
mantis
mantis-b02


                                     
2004-06-14



Hardware and Software, Engineered to Work Together