I have compared the btnbmp source between 11.08 & 10.06 and thankfully there wasnt many changes - I have found the cause of my problem:
Line 1281 in 11.08 is
Code: Select all | Expand
IF !Empty( hBmp )
if SetAlpha() .and. ::aAlpha[ nBtn ]
ABPaint( ::hDC, if( ::lAdjust, nAdjust, nBmpLeft+nAdjust), if( ::lAdjust, nAdjust, nBmpTop+nAdjust ), hBmp, ::nAlphaLevel() )
elseif IsAppThemed()
if !::lTransparent
PalBtnPaint( ::hWnd, if( ::lMOver .and. !Empty( ::hBitmap4 ), ::hBitmap4, ::hBitmap1 ),;
if( ::lMOver .and. !Empty( ::hBitmap4 ), ::hPalette4, ::hPalette1 ),;
if ( ::lAdjust .and. empty( ::hBitmap2 ), ::hBitmap1,::hBitmap2 ),;
if ( ::lAdjust .and. empty( ::hBitmap2 ), ::hPalette1,::hPalette2),;
::hBitmap3, ::hPalette3, ::lPressed, ::lAdjust, ::lBorder,;
::oPopup != nil,;
::nClrPane, if ( ::cCaption == "...", ::cCaption,) , ::nLayout,;
If( ::oFont != nil, ::oFont:hFont, 0 ),;
If( ValType( ::nClrText ) == "B", Eval( ::nClrText, ::lMOver ), ::nClrText ), ::hDC,;
Upper( ::oWnd:ClassName() ) != "TBAR" )
else
hBmpOld = SelectObject( ::hDC, hBmp )
nZeroZeroClr = GetPixel( ::hDC, 0, 0 )
SelectObject( ::hDC, hBmpOld )
nOldClr = SetBkColor( ::hDC, nRGB( 255, 255, 255 ) )
TransBmp( hBmp, nBmpWidth, nBmpHeight, nZeroZeroClr, ::hDC,;
if( ::lAdjust, nAdjust, nBmpLeft + nAdjust ), ;
if( ::lAdjust, nAdjust, nBmpTop + nAdjust ),;
if (::lAdjust, ::nWidth, nBmpWidth ) ,;
if( ::lAdjust, ::nHeight, nBmpHeight ) )
SetBkColor( ::hDC, nOldClr )
endif
else
hBmpOld = SelectObject( ::hDC, hBmp )
nZeroZeroClr = GetPixel( ::hDC, 0, 0 )
SelectObject( ::hDC, hBmpOld )
nOldClr = SetBkColor( ::hDC, nRGB( 255, 255, 255 ) )
TransBmp( hBmp, nBmpWidth, nBmpHeight, nZeroZeroClr, ::hDC,;
if( ::lAdjust, nAdjust, nBmpLeft + nAdjust ), ;
if( ::lAdjust, nAdjust, nBmpTop + nAdjust ),;
if (::lAdjust, ::nWidth, nBmpWidth ) ,;
if( ::lAdjust, ::nHeight, nBmpHeight ) )
SetBkColor( ::hDC, nOldClr )
endif
else
Line 1273 in 10.06
Code: Select all | Expand
IF !Empty( hBmp )
if SetAlpha() .and. ::aAlpha[ nBtn ]
ABPaint( ::hDC, if( ::lAdjust, nAdjust, nBmpLeft+nAdjust), if( ::lAdjust, nAdjust, nBmpTop+nAdjust ), hBmp, ::nAlphaLevel() )
elseif IsAppThemed() .or. !::lTransparent
PalBtnPaint( ::hWnd, if( ::lMOver .and. !Empty( ::hBitmap4 ), ::hBitmap4, ::hBitmap1 ),;
if( ::lMOver .and. !Empty( ::hBitmap4 ), ::hPalette4, ::hPalette1 ),;
if ( ::lAdjust .and. empty( ::hBitmap2 ), ::hBitmap1,::hBitmap2 ),;
if ( ::lAdjust .and. empty( ::hBitmap2 ), ::hPalette1,::hPalette2),;
::hBitmap3, ::hPalette3, ::lPressed, ::lAdjust, ::lBorder,;
::oPopup != nil,;
::nClrPane, if ( ::cCaption == "...", ::cCaption,) , ::nLayout,;
If( ::oFont != nil, ::oFont:hFont, 0 ),;
If( ValType( ::nClrText ) == "B", Eval( ::nClrText, ::lMOver ), ::nClrText ), ::hDC,;
Upper( ::oWnd:ClassName() ) != "TBAR" )
else
hBmpOld = SelectObject( ::hDC, hBmp )
nZeroZeroClr = GetPixel( ::hDC, 0, 0 )
SelectObject( ::hDC, hBmpOld )
nOldClr = SetBkColor( ::hDC, nRGB( 255, 255, 255 ) )
TransBmp( hBmp, nBmpWidth, nBmpHeight, nZeroZeroClr, ::hDC,;
if( ::lAdjust, nAdjust, nBmpLeft + nAdjust ), ;
if( ::lAdjust, nAdjust, nBmpTop + nAdjust ),;
if (::lAdjust, ::nWidth, nBmpWidth ) ,;
if( ::lAdjust, ::nHeight, nBmpHeight ) )
SetBkColor( ::hDC, nOldClr )
endif
If I change the following in 11.08 all works ok:
Code: Select all | Expand
IF !Empty( hBmp )
if SetAlpha() .and. ::aAlpha[ nBtn ]
ABPaint( ::hDC, if( ::lAdjust, nAdjust, nBmpLeft+nAdjust), if( ::lAdjust, nAdjust, nBmpTop+nAdjust ), hBmp, ::nAlphaLevel() )
elseif IsAppThemed() .or. !::lTransparent
if !::lTransparent
Is there a reason for this and could this be put back in future releases?
Regards,
Pete