bug in Ribbon 2010 style

bug in Ribbon 2010 style

Postby ukservice » Fri Jul 15, 2011 12:46 pm

Hello,

I compile ribbon sample with 2010 style but does not work fine. Please, see picture.

Image

Uploaded with ImageShack.us

Thank you.
FWH 11.11, Harbour 3.1 and Borland C++ 5.82
User avatar
ukservice
 
Posts: 417
Joined: Tue Feb 23, 2010 3:09 pm
Location: John

Re: bug in Ribbon 2010 style

Postby Daniel Garcia-Gil » Fri Jul 15, 2011 11:24 pm

Hello

please change this method in tribbon.prg

Code: Select all  Expand view
METHOD AddGroup( nWidth, cCaption, nDialogs, bAction, cBitmap, aGrad )

   local oGroup, nCol := 1, n
   local hBmp

   DEFAULT nWidth:= 150, cCaption := "", nDialogs := 150

   if nDialogs > Len( ::aDialogs ) .or. nDialogs < 1
      MsgStop( "Non defined dialogs", "Fivewin: Ribbonbar Support" )
      return nil
   endif

   if !empty( ::aDialogs[ nDialogs ]:aControls )
      for n= 1 to Len( ::aDialogs[ nDialogs ]:aControls )
         if ::aDialogs[ nDialogs ]:aControls[ n ]:ClassName() == "TRBGROUP"
            nCol += ::aDialogs[ nDialogs ]:aControls[ n ]:nWidth + ::nGroupSeparation
         endif
      next
   endif
   
   if aGrad != NIL
      hBmp = GradientBmp( Self, ::nRight - ::nRightMargin - 3, ::nBottom - ::nTopMargin + 1, aGrad )
   else
      hBmp = ::hBmpBrushEx
   endif  

   oGroup := TRBGroup():New( ::aDialogs[ nDialogs ], 1, nCol,;
                             ::aDialogs[ nDialogs ]:nHeight - 3, nWidth, ;
                             Len( ::aControls )+1, cCaption, bAction , ::nClrBoxIn, ::nClrBoxOut,,;
                             CreatePatternBrush(  hBmp  ), , , , Self, ,cBitmap )
   if aGrad != NIL
      DeleteObject( hBmp )
   endif

return oGroup
User avatar
Daniel Garcia-Gil
 
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita

Re: bug in Ribbon 2010 style

Postby ukservice » Sat Jul 16, 2011 1:37 pm

Thank you, I will test.

And what about Menu blue colour not the same as msgbar?.

Thanks
FWH 11.11, Harbour 3.1 and Borland C++ 5.82
User avatar
ukservice
 
Posts: 417
Joined: Tue Feb 23, 2010 3:09 pm
Location: John

Re: bug in Ribbon 2010 style

Postby Daniel Garcia-Gil » Sat Jul 16, 2011 1:53 pm

Hello

i saw some programs with 2010 style (including windows explorer) and the menu only change in internal color
look this post http://forums.fivetechsupport.com/viewtopic.php?p=115469#p115469
User avatar
Daniel Garcia-Gil
 
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita

Re: bug in Ribbon 2010 style

Postby ukservice » Sat Jul 16, 2011 2:05 pm

Hello

Blue colour is for 2007. For 2010 colour should be the same as msgbar.

Anyway, I need to change menu that its colour is the same as msgbar. Otherwise I can´t use 2010 style.

Please, how can I do?.

Thank you.
FWH 11.11, Harbour 3.1 and Borland C++ 5.82
User avatar
ukservice
 
Posts: 417
Joined: Tue Feb 23, 2010 3:09 pm
Location: John

Re: bug in Ribbon 2010 style

Postby Daniel Garcia-Gil » Sat Jul 16, 2011 2:10 pm

Hello

to next fivewin release i will try build a custom skin menu (but i dont promise), for now is not possible, sorry
User avatar
Daniel Garcia-Gil
 
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita

Re: bug in Ribbon 2010 style

Postby ukservice » Sun Jul 17, 2011 8:50 am

Hello,

Thank you very much. It would be a great idea.

If not, you can provide full source code of menu, so I can make those changes. I don´t understand why is not included.

Thank you again.
FWH 11.11, Harbour 3.1 and Borland C++ 5.82
User avatar
ukservice
 
Posts: 417
Joined: Tue Feb 23, 2010 3:09 pm
Location: John

Re: bug in Ribbon 2010 style

Postby Antonio Linares » Sun Jul 17, 2011 3:46 pm

Ukservice,

We will try to modify FWH Class TMenu so it admits custom defined colors :-)
regards, saludos

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

Re: bug in Ribbon 2010 style

Postby ukservice » Sun Jul 17, 2011 4:55 pm

Thank you Master.
FWH 11.11, Harbour 3.1 and Borland C++ 5.82
User avatar
ukservice
 
Posts: 417
Joined: Tue Feb 23, 2010 3:09 pm
Location: John


Return to FiveWin for Harbour/xHarbour

Who is online

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