The class changes are exactly the ones that I commented you at the beginning of this thread:
use ABPaint() instead of DrawMasked() in Method Paint(). Thats all

Anser,
The class changes are exactly the ones that I commented you at the beginning of this thread:
use ABPaint() instead of DrawMasked() in Method Paint(). Thats all
Code: Select all | Expand
@04,14 BITMAP oBmp SIZE 43,55 of oFolder:aDialogs[1] RESOURCE "User76x112"
Just modify Class TBitmap Method Paint() to use ABPaint()
Code: Select all | Expand
PalBmpDraw( ::hDC, ::nX, ::nY, ::hBitmap, ::hPalette,;
Super:nWidth(), Super:nHeight(),, ::lTransparent, ::nClrPane )
Code: Select all | Expand
TransBmp( ::hBitmap, ::nWidth(), ::nHeight(), nZeroZeroClr, ::hDC,;
::nX, ::nY, ::nWidth(), ::nHeight() )
Code: Select all | Expand
@04,14 BITMAP oBmp SIZE 43,55 of oFolder:aDialogs[1] RESOURCE "User76x112"
oBmp:bPainted:={ || ABPaint( oBmp:hDC, 0, 0, oBmp:hBitmap, 220 )}
Code: Select all | Expand
IF ! ::lBmpAlpha // New Data .T. or .F.
TransBmp( ::hBitmap, ::nWidth(), ::nHeight(), nZeroZeroClr, ::hDC,;
::nX, ::nY, Super:nWidth(), Super:nHeight() )
Else
ABPaint( ::hDC, ::nX, ::nY, ::hBitmap, 220 )
Endif
Code: Select all | Expand
IF ! ::lBmpAlpha // New Data .T. or .F.
PalBmpDraw( ::hDC, ::nX, ::nY, ::hBitmap, ::hPalette,;
::nWidth(), ::nHeight(),, ::lTransparent, ::nClrPane )
Else
ABPaint( ::hDC, ::nX, ::nY, ::hBitmap, 220 )
Endif
Antonio Linares wrote:Wouldn't it better if we could automatically detect if the bitmap has an alpha channel into it and automatically call the proper painting routine ?
Antonio Linares wrote:Wouldn't it better if we could automatically detect if the bitmap has an alpha channel into it and automatically call the proper painting routine ?