FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Transparent bitmap on folder
Posts: 858
Joined: Fri Oct 07, 2005 12:00 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 08:19 AM

Hello,
I still have problem to display a transparent bitmap on folder with xp theme. See www.softwarexp.co.uk/beta/bitmap_on_folder.gif

I'm working with xHarbor 0.99.5+FWH26

Is there a solution available ?

Thanks in advance

Marco Turco

Best Regards,



Marco Turco

SOFTWARE XP LLP
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 08:23 AM

Marco,

Have you tried oBmp:lTransparent := .t. after creating it ?

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 858
Joined: Fri Oct 07, 2005 12:00 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 09:21 AM

Yes I used the transparent clause in the sample you saw.

This problem appairs only on folder with xp theme,
without xp theme the transparent clause runs fine.

We had a similar problem with the say on folder
but you alredy solved this some time ago.

Marco

Best Regards,



Marco Turco

SOFTWARE XP LLP
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 11:29 AM
Marco,

The problems comes from the gradient background where the bitmap is painted on.

FWH already provides a special function to paint transparent on gradient background:

void TransBmp( HBITMAP hBitmap, int iXsize, int iYsize,
               COLORREF rgbTransparent, HDC hDC,
               int iXOffset, int iYOffset, int iWidth, int iHeight )


source is located at source\function\fwbmp.c. The problem is that we don't know why yet, this function looses GDI resources. We have been trying several times to find whats going wrong with it, but with no luck up to now.

If we could fix it, then we could easily paint transparent over a gradient background.
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 01:04 PM

I can't see anything wrong in the TransBmp() source code...

EMG

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 01:07 PM

Enrico,

Yes, I think the same but the fact is that if we use it, and you start resizing the main window, then you can see how it gets slower, as it were consuming more and more resources.

The code is there, so it may be used, but with caution until we know for sure if it is working ok.

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 01:13 PM

Might it be that it keeps called by the paint event when it haven't already terminated the previous execution?

Only a stub in the dark.

EMG

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Transparent bitmap on folder
Posted: Wed Dec 14, 2005 01:50 PM

Enrico,

Its a good idea, thank you :)

Lets check it...

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Transparent bitmap on folder
Posted: Thu Dec 15, 2005 11:55 AM
We already have transparent bitmaps on folders with XP look :-)

regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion