button(btnbmp) of buttonbar disable caption color fixed

button(btnbmp) of buttonbar disable caption color fixed

Postby ShumingWang » Mon Dec 03, 2007 7:35 am

METHOD Paint() CLASS TBtnBmp

...

if ! Empty( ::cCaption )
nClr = If( IsWindowEnabled( ::hWnd ), ::nClrText, CLR_HGRAY )
SetTextColor( ::hDC, nClr ) // add the line ,show disable button ccaption/text color
nTop = 2 * ( ::nHeight / 3 ) + If( ::lPressed, 1, 0 ) + If( At( CRLF, ::cCaption ) == 0, 5, 0 )
SetBkMode( ::hDC, 1 )

...

Enjoy this.

Shuming Wang
ShumingWang
 
Posts: 465
Joined: Sun Oct 30, 2005 6:37 am
Location: Guangzhou(Canton),China

Postby Antonio Linares » Mon Dec 03, 2007 9:43 am

Shuming,

Thanks! :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42105
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot], Maurizio and 56 guests