How to use FREEIMAGE.dll for Backgrounds in Wind./Dialogs

Post Reply
User avatar
ukoenig
Posts: 3981
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany
Contact:

How to use FREEIMAGE.dll for Backgrounds in Wind./Dialogs

Post by ukoenig »

Hello,

I wanted to change my dialog-backgrounds
from BMP to another format with FREEIMAGE.dll.

That was impossible.
I did a little change on the sample testimg.
The button-controls are overlappt with the image.
This is normal, when the image is a background.

The controls don't work anymore as soon they
are inside of the image area.
I think, for backgrounds not useful ?

Image

Regards
uwe :o [/img]
Last edited by ukoenig on Sun Mar 16, 2008 12:02 am, edited 1 time in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Uwe,

Here you have a working sample:

Code: Select all

#include "FiveWin.ch"

function Main()

   local oDlg, oImg 
   
   DEFINE IMAGE oImg FILENAME "..\bitmaps\FiveTech.gif"

   DEFINE DIALOG oDlg TITLE "Image background"

   @ 0.5, 1 BUTTON "OK" ACTION MsgInfo( "click" )

   ACTIVATE DIALOG oDlg CENTERED ;
      ON PAINT PalBmpDraw( hDC, 0, 0, oImg:hBitmap )
      
   oImg:End()   

return nil
Image
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
ukoenig
Posts: 3981
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany
Contact:

Backgrounds with freeimage.dll

Post by ukoenig »

Antonio,

thank you very much.
It works great.
Now the user can choose different Graphic-Types.

Greetings from Germany
Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
Post Reply