FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour How can I make this ?
Posts: 858
Joined: Fri Oct 07, 2005 12:00 PM
How can I make this ?
Posted: Wed Aug 12, 2009 09:10 AM
Hi,
is there a FWH build-in class to make this ? See
Best Regards,



Marco Turco

SOFTWARE XP LLP
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: How can I make this ?
Posted: Wed Aug 12, 2009 08:09 PM

Marco,

No, but you could use the new Ribbonbar to do something similar.

An Explorer bar would also work. There was a third-party one, but I think it is dead. It would be nice if Antonio would put it on his To-Do list.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 4043
Joined: Wed Dec 19, 2007 06:40 PM
Re: How can I make this ?
Posted: Thu Aug 13, 2009 04:31 PM

James,

I finished testing Ribbonbar-Values.
I think, using a Ribbonbar is not the Solution, because You will always have Tabs on Top of the Bar.
In case, Marco wants to change to different Menues ( Levels ), it will work.
I tested with just one Group, but the Result looks different to Marco's Screenshot.
I don't know for the Moment, if it is possible to hide the Tabs and work with just one Group.
Using Vtitle with included Buttons, could be a Solution.

Best Regards
Uwe :lol:

Since 1995 ( the first release of FW 1.9 )

i work with FW.

If you have any questions about special functions, maybe i can help.
Posts: 858
Joined: Fri Oct 07, 2005 12:00 PM
Re: How can I make this ?
Posted: Thu Aug 13, 2009 06:18 PM
Hi,
the better solution I have found is using rbbuttons.


However I have the followin problem:
I need to change the windows color background at runtime and the buttons always keep the previous windows color,
do you know if is there a way to update the correct background for the button ?

This is a self contained code that show the problem. PRessing the button the windows background change but the button background remains white.


Code (fw): Select all Collapse
#include "fivewin.ch"
#include "ribbon.ch"

Function main()

    local oWnd
    local oBtn1


    DEFINE WINDOW oWnd TITLE "TTitle Class Test"

   @ 20, 10 RBBTN oBtn1 OF oWnd BITMAP "24exit.bmp";
              SIZE 100, 25   PROMPT "Test " TRANSPARENT MOSTLEFT;
              ACTION ChangeWndColor(oWnd)

    activate window oWnd maximized


return nil

Function ChangeWndColor(oWnd)
    oWnd:Setcolor(nil, nrgb(199,213,239))
    oWnd:Refresh()
    return




Any ideas ?
Best Regards,



Marco Turco

SOFTWARE XP LLP
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 PM
Re: How can I make this ?
Posted: Thu Aug 13, 2009 06:40 PM
Hello Marco

try with this code
Code (fw): Select all Collapse
#include "fivewin.ch"
#include "ribbon.ch"

Function main()

    local oWnd
    local oBtn1


    DEFINE WINDOW oWnd TITLE "TTitle Class Test"

   @ 20, 10 RBBTN oBtn1 OF oWnd BITMAP "24exit.bmp";
              SIZE 100, 25   PROMPT "Test " TRANSPARENT MOSTLEFT;
              ACTION ( ChangeWndColor(oWnd), ChangeBTNColor( oWnd ) )

    activate window oWnd maximized


return nil

Function ChangeWndColor(oWnd)
    oWnd:Setcolor(nil, nrgb(199,213,239))
    oWnd:Refresh()
return

Function ChangeBTNColor( oWnd )
local n, oBtn

    if ! Empty( oWnd:aControls )
      for n = 1 to Len( oWnd:aControls )
         if oWnd:aControls[ n ]:Classname == "TRBTN"
            oBtn = oWnd:aControls[ n ]
            DeleteObject( oBtn:hBack )
            oBtn:hBack := CreateSolidBrush( nrgb(199,213,239) )
            oBtn:ReleaseDC()
         endif
      next
    endif       
         
return nil
Posts: 4043
Joined: Wed Dec 19, 2007 06:40 PM
Re: How can I make this ?
Posted: Fri Aug 14, 2009 09:08 AM
Marco,

You can create Your own Buttonbar and display inside any Control on any Place You like.



Best Regards
Uwe :-)
Since 1995 ( the first release of FW 1.9 )

i work with FW.

If you have any questions about special functions, maybe i can help.
Posts: 858
Joined: Fri Oct 07, 2005 12:00 PM
Re: How can I make this ?
Posted: Fri Aug 14, 2009 09:11 AM

It runs fine.

Thank you.

Best Regards,



Marco Turco

SOFTWARE XP LLP
Posts: 858
Joined: Fri Oct 07, 2005 12:00 PM
Re: How can I make this ?
Posted: Fri Aug 14, 2009 09:13 AM
You are right but with your solution - as I know - I can't display the support image and the text. Isn't it ?

ukoenig wrote:Marco,

You can create Your own Buttonbar and display inside any Control on any Place You like.



Best Regards
Uwe :-)
Best Regards,



Marco Turco

SOFTWARE XP LLP

Continue the discussion