Centering Checkbox Bitmaps in txbrowse columns

Centering Checkbox Bitmaps in txbrowse columns

Postby PatrickWeisser » Sun Mar 08, 2009 12:44 am

Hello Everyone,

I see that the nDataBmpAlign variable of the TXBrwColumn class allows for only left or right justification, but not centering. And yet the Testxbr3.prg sample shows a checkbox bitmap being centered in the, "Married" column (this dialog is reached by selecting Window, RDD, Selected Cols). I looked at the code for the RddBrwSelColsWin() function of the sample which supports the browse, and I saw where the checkbox bitmap was being set via the code:

Code: Select all  Expand view  RUN

   if ! Empty( oCol := oBrw:oCol( "Married" ) )
      oCol:SetCheck( { "ON", "OFF" } )
      oCol:cSortOrder  := nil
      // oCol:lBmpStretch = .T.
   endif
 


But I don't see how the centering of the checkbox bitmap is being done. Can anyone tell me what variable is being set to center the checkbox bitmap?

Thanks!

-Patrick
User avatar
PatrickWeisser
 
Posts: 53
Joined: Fri Mar 23, 2007 4:10 am
Location: Seattle, WA, USA

Re: Centering Checkbox Bitmaps in txbrowse columns

Postby Daniel Garcia-Gil » Sun Mar 08, 2009 1:08 am

Hello patrick

what FWH version do you use?
User avatar
Daniel Garcia-Gil
 
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita

Re: Centering Checkbox Bitmaps in txbrowse columns

Postby PatrickWeisser » Sun Mar 08, 2009 2:11 am

Hello Daniel,

I'm still on the October 2008 version. I have customized some of the TGet code for my needs so it always takes me time to re-apply my changes when I download a new FiveWin version. But I think it's time for me to upgrade again so I won't fall too far behind everyone else.

The October 2008 version does appear to have the ability to center a check box in a browse column in the TestXbr3.prg sample, so I'm probably just missing something simple in the TextXbr3.prg source code.

Thanks,

-Patrick
User avatar
PatrickWeisser
 
Posts: 53
Joined: Fri Mar 23, 2007 4:10 am
Location: Seattle, WA, USA

Re: Centering Checkbox Bitmaps in txbrowse columns

Postby Daniel Garcia-Gil » Sun Mar 08, 2009 2:21 am

Patrick...

do you use array ?
because the octuber version no work this feature....

it was added in december

viewtopic.php?p=72507#p72507
* Enhancement: Class TXBrowe, the checkbox image can be centered when an array is browsed.

pelase update your actual version or i can tell you how change the xbrowse class
User avatar
Daniel Garcia-Gil
 
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita

Re: Centering Checkbox Bitmaps in txbrowse columns

Postby PatrickWeisser » Sun Mar 08, 2009 7:40 am

Dear Daniel,

Yes I'm browsing an array, so that's the problem exactly. I will update my FiveWin version. It's past time I did that anyway.

Thank you!

-Patrick
User avatar
PatrickWeisser
 
Posts: 53
Joined: Fri Mar 23, 2007 4:10 am
Location: Seattle, WA, USA


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 103 guests