Hi James,
I've had this exact problem, and it's been driving me mad for months! It's made particularly bad because I have a round icon, and the transparency looks awful when the image is scaled.
I've asked about 3 different questions here on the same issue, and the few answers that I've had have been pretty much of the "can't be done" type. I'm coming to the conclusion that that's the right answer!
The only way of doing this properly that I've found is by using a Shell in SWT, but that can't be (easily) combined with the Swing/AWT stuff that I'm using in the rest of my application. (Shell does it very well though, by taking an array of Images, of different sizes, and using the most appropriate one).
Interestingly, if you don't set the icon, you get the default
Java coffee cup icon, which works properly! I've found one mention of a registry hack to change that icon to any Windows .ico file (which contains several icons of different sizes, for just this reason), but couldn't make it work, and it's far from being an ideal solution anyway.
If you do get anywhere on this, please, please post your solution here!
In the meantime, we're switching to a square icon!
David.
Edit: I forgot to mention,
you should also check your icon with Windows (if you're using Windows) set to 'Large Fonts', it makes the icon on the taskbar about 150% of its original size, and therefore has similar nasty effects!
[ October 13, 2006: Message edited by: David Payne ]