I need to know how I can make two btnbmp obtn on two obmp bitmaps that are on a dialog. ODLG
The bitmaps are one white and one black.
I set magenta as the background color in the image that uses the btnbmp (255, 0, 255).
The problem is that the btnbmp button is not transparent and always takes the color of the dialog whether I put it on the oBmp1 image or on the ODLG.
Both the bitmaps and the image that uses the btnbmp are 24 bits.
#include "FiveWin.ch"
STATIC cThemePath := ".\bitmaps\themes\default\"
Function test()
local oDlg
local oBmp1,oBmp2
DEFINE DIALOG oDlg TITLE "test btnbmp su bmp" ;
SIZE 340, 360 PIXEL
@ 10,0 BITMAP oBmp1 FILENAME cThemePath + "square1.bmp" OF oDlg;
size 50,50 adjust noborder PIXEL
oBmp1:nAlphaLevel := 100
@ 10,100 BITMAP oBmp2 FILENAME cThemePath + "square2.bmp" OF oDlg;
size 50,50 adjust noborder PIXEL
oBmp2:nAlphaLevel := 100
activate dialog oDlg ;
on init Put_btn(oBmp1,oBmp2)
return nil
//------------------------------------------------------//
Function Put_btn(oBmp1,oBmp2)
local oBtn1,oBtn2
@ 10, 10 BTNBMP oBtn1 ;
FILENAME cThemePath + "rook0.bmp" ;
SIZE 80,80 PIXEL OF oBmp1 FLAT NOBORDER TRANSPARENT GDIP
@ 10, 10 BTNBMP oBtn1 ;
FILENAME cThemePath + "rook1.bmp" ;
SIZE 80,80 PIXEL OF oBmp2 FLAT NOBORDER TRANSPARENT GDIP
return nilI also tried to use png files in the btnbmp but the btnbmp is not transparent and the background is always gray because it takes the color of the dialog, so I also tried with two pngs and two btnbmps with pngs on the pngs
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com