Ok, in the meantime I've been trying and investigating some more. The situation is as follows: We have a lot of older custom commands, written in Delphi. To have these commands visually fit the polished ArcGIS 10 look, we would like to support the new possibility of using fully transparency-enabled PNG icons to appear on the ArcMap toolbars. This works very well from C#/.Net, but seems to be a bit more tricky to support from other development environments.
According to some documentation found on arcigs.com, ArcObjects expects the bitmap handle that is supplied in the get-bitmap method to be a handle to a GDI bitmap. To my knowledge, GDI bitmaps do not support transparency (whereas GDI+ would do that). It seems that the command base classes to some magic with the bitmaps (premultipying? based on what colors?).
ESRI people, would it be possible to give a few hints on what you do in the baseclasses? Any other tips or tricks for this? Honestly, I'm not too much into GDI and everything, so maybe I'm just not seeing the obvious solution. And just for clarification: I do not want the key-transparency with one color being transparent or anything. Instead, I would like to support the alpha channel of PNG images (as with all the new ESRI commands).
Thanks for any help. Would be nice if we can discuss and maybe, in the end, have a nice snippet of code that would possibily help other developers, too.
Best regards,
Andry