Page 1 of 1
Annoying borders on TSbuttons
Posted: Sat Nov 18, 2006 4:20 am
by reinaldocrespo
Hi everyone;
Take a look at the image below.
I'd like to get rid of the border around the images.
Can someone help?
Reinaldo.
Posted: Sat Nov 18, 2006 9:43 am
by Antonio Linares
Reinaldo,
Use the clause TRANSPARENT
Posted: Sat Nov 18, 2006 11:18 am
by Antonio Linares
ops, I just realized you were talking about TSButtons.
TSButton should be changed to use FWH TransBmp() function. There is a sample of use in source\classes\bitmap.prg
Posted: Sat Nov 18, 2006 12:49 pm
by reinaldocrespo
Anotnio;
thank you.
source\classes\bitmap.prg is the source for the actual class tbitmap. It does not show a sample on how to use it.
Please try again,
Reinaldo.
Posted: Sat Nov 18, 2006 12:55 pm
by Antonio Linares
Reinaldo,
From source\classes\bitmap.prg:
Code: Select all
hBmpOld = SelectObject( ::hDC, ::hBitmap )
nZeroZeroClr = GetPixel( ::hDC, 0, 0 )
SelectObject( ::hDC, hBmpOld )
nOldClr = SetBkColor( ::hDC, nRGB( 255, 255, 255 ) )
TransBmp( ::hBitmap, ::nWidth(), ::nHeight(), nZeroZeroClr, ::hDC,;
::nX, ::nY, Super:nWidth(), Super:nHeight() )
SetBkColor( ::hDC, nOldClr )
Posted: Sat Nov 18, 2006 2:30 pm
by reinaldocrespo
ohh, I see.
Perhaps someone has already patch Tsbutton to work with TRANSPARENT clause?
Reinaldo.