#1: SysImageList problem Author: Johnny_Bit, Posted: 22/06/04 09:04 Hi, I have little problem with SysImageList, concretly with drawning icons. The problem is that icon is placed on non-transparent white square and no settings about drawning style, or bk color can change it. maybe screen will show it:
#2: Author: Kambiz, Location: Tehran, IranPosted: 22/06/04 10:11 Probably you set the DrawingStyle property of TSysImageList to dsNormal. It should be dsTransparent.
#3: Author: Johnny_Bit, Posted: 22/06/04 13:58 it is dsTransparent by Default.. i tried to change blend and bk color to cl none but that doesn't help...
#4: Author: Kambiz, Location: Tehran, IranPosted: 22/06/04 19:45 It could not be because of TSysImageList, because the component just set the image list handle, and doesn't override the base class methods.
Are you using a third party XP Theme Manager?
#5: Author: Johnny_Bit, Posted: 23/06/04 09:40 Well i do use ThemeManager from Delphi Germs, but when i removed it (completly, so there are no even single call or unit left knowing 'bout existence of it) and problem still exist...
#6: Author: Kambiz, Location: Tehran, IranPosted: 27/06/04 21:05 Is the drawing okay when you use TImageList instead of TSysImageList?
#7: Author: Johnny_Bit, Posted: 29/06/04 16:31 Icons & bitmaps works fine, but i didn't tried 32 bits icons. i try later, more sets but it seems that this problem is hard to solve...
Suddenly today I encountered to the same problem in my own application.
The controls use either ImageList_Draw or ImageList_DrawEx API function to draw an imagelist image on their device context. The controls that using the second API, have problem with image transparency.
ImageList_DrawEx API as one of its parameters needs the background color, and imagelist provides a value for this parameter by BkColor property. To have a transparent image, the BkColor property must be clNone.
To resolve the problem in SysImageList, I changed the default value of BkColor property to clNone.
The update is available to download.
Cheers,
Kambiz
#9: Author: Johnny_Bit, Posted: 04/07/04 10:29 heh... i didn't thinked that it was it... i've got same problem with api functions when i tried to make nice gray out effect and hotlight efect on images... damn.. if i had just hard line connection to internet on my home computer... it would be great. thanks a lot Kambiz