| View previous topic :: View next topic |
| Author |
Message |
Johnny_Bit Moderator
Joined: 15 Jun 2003 Posts: 170
|
Posted: 22/06/04 09:04 Post subject: SysImageList problem |
|
|
| 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: |
|
| Back to top |
|
 |
Kambiz Administrator
Joined: 07 Mar 2003 Posts: 506 Location: Tehran, Iran
|
Posted: 22/06/04 10:11 Post subject: |
|
|
| Probably you set the DrawingStyle property of TSysImageList to dsNormal. It should be dsTransparent. |
|
| Back to top |
|
 |
Johnny_Bit Moderator
Joined: 15 Jun 2003 Posts: 170
|
Posted: 22/06/04 13:58 Post subject: |
|
|
| it is dsTransparent by Default.. i tried to change blend and bk color to cl none but that doesn't help... |
|
| Back to top |
|
 |
Kambiz Administrator
Joined: 07 Mar 2003 Posts: 506 Location: Tehran, Iran
|
Posted: 22/06/04 19:45 Post subject: |
|
|
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? |
|
| Back to top |
|
 |
Johnny_Bit Moderator
Joined: 15 Jun 2003 Posts: 170
|
Posted: 23/06/04 09:40 Post subject: |
|
|
| 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... |
|
| Back to top |
|
 |
Kambiz Administrator
Joined: 07 Mar 2003 Posts: 506 Location: Tehran, Iran
|
Posted: 27/06/04 21:05 Post subject: |
|
|
| Is the drawing okay when you use TImageList instead of TSysImageList? |
|
| Back to top |
|
 |
Johnny_Bit Moderator
Joined: 15 Jun 2003 Posts: 170
|
Posted: 29/06/04 16:31 Post subject: |
|
|
| 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... |
|
| Back to top |
|
 |
Kambiz Administrator
Joined: 07 Mar 2003 Posts: 506 Location: Tehran, Iran
|
Posted: 30/06/04 16:30 Post subject: |
|
|
Hi,
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 |
|
| Back to top |
|
 |
Johnny_Bit Moderator
Joined: 15 Jun 2003 Posts: 170
|
Posted: 04/07/04 10:29 Post subject: |
|
|
| 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 |
|
| Back to top |
|
 |
|