I have had several requests to remove the title bar when using the RibbonBar.
Chris Andries helped with this and found the enableFrameTheme() method of the RibbonBar object.
This, and some other code changes provides nearly the desired affect, but the RibbonBar then occupies too much of the drawing area.
See the following video:
http://bb.donnay-software.com:8080/supp ... lbar2.html
Any ideas are welcome.
Code is attached.
Ribbonbar Title problem
Ribbonbar Title problem
- Attachments
-
- tabbedtoolbar.zip
- Tabbed Toolbar title problem
- (33.53 KiB) Downloaded 1234 times
The eXpress train is coming - and it has more cars.
Re: Ribbonbar Title problem
search in Sample for iTunes ... that is that Stylerdonnay wrote:I have had several requests to remove the title bar when using the RibbonBar.
Chris Andries helped with this and found the enableFrameTheme() method of the RibbonBar object.

i say your Video and that Browse Position/Size is wrong ... we did had that Problem before ... hm ...
here my Code
Code: Select all
* aSize := AppDesktop():currentsize()
aSize[1] := aSize[1]/10*9
aSize[2] := aSize[2]/10*9
aPos := CenterPos( aSize ,AppDesktop():currentsize())
oDlg:minButton := .T.
oDlg:maxButton := .T.
oDlg:setDisplayFocus := {| uNIL1, uNIL2, oSelf | XSet2Browse(oDlg) }
oDlg:setinputfocus := {| uNIL1, uNIL2, oSelf | YSet2Browse(oDlg) }
oDlg:configure()
oDlg:setposandsize(aPos,aSize)
* oDlg:setFrameState( XBPDLG_FRAMESTAT_MAXIMIZED )
//
// CJ Menu Ribbonbar and Statusbar
//
#IFDEF CJBARS
oDlg:PathIco := ZPATH+"ICON"
oDlg:InitImgList()
oDlg:InitMenuBar()
oDlg:oCbarS:ActiveMenuBar:Visible := .T.
#ENDIF
#IFDEF CJBARS
//
// Event from Ribbonbar
//
RibbonBlock(oDlg)
#ENDIF
//
// Static on :drawingArea using Threads
//
oDlg:InitTabArea()
oControl := oDlg:InitTabShort()
#IFDEF CJSKIN
oDlg:oSkin:callMethod("ApplyWindow", oDlg:oCbarS:getHWND() )
oDlg:oSkin:callMethod("ApplyWindow", oDlg:oRibbonbar:hWnd )
#ENDIF
You can use RibbonTabgroup to get that "Effect" btw using ::oRibbonBar:AllowMinimize := .T. and ::oRibbonBar:Minimized := .T. you can get "more" Space and use Ribbenbar as "dropdown Menue"
greetings by OHR
Jimmy
Jimmy
Re: Ribbonbar Title problem
Hi Jimmy,
I think the trick is in the following functions?
I suppose your initTabArea method is defining the height of the workarea.
I think the trick is in the following functions?
Code: Select all
oDlg:InitTabArea()
oControl := oDlg:InitTabShort()
Re: Ribbonbar Title problem
as i say i "attach" a Static to RibbonTabGroup.skiman wrote: I think the trick is in the following functions?I suppose your initTabArea method is defining the height of the workarea.Code: Select all
oDlg:InitTabArea() oControl := oDlg:InitTabShort()
Code: Select all
METHOD VOBWORK:InitTabArea()
LOCAL oDraw := ::drawingArea
LOCAL aSize := ::drawingArea:currentsize()
LOCAL aPos := {SC_LEFT,0}
aSize[1] := aSize[1]-SC_LEFT+SC_ADD // PbStack Leiste
aSize[2] := aSize[2]+SC_ADD
::aTabPage[ID_CALENDAR ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_ERFASSUNG,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_ARBEIT ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_FAKTURA ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_KUNDEN ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_IMOBILIE ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_ARTIKEL ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_UMSATZ ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_TOOLS ,IS_RIBSTAT] := XbpStatic():new( oDraw,, aPos,aSize,,.F. ):create()
::aTabPage[ID_CALENDAR ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 229, 242, 255 } ))
::aTabPage[ID_ERFASSUNG,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 204, 229, 254 } ))
::aTabPage[ID_ARBEIT ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 153, 203, 255 } ))
::aTabPage[ID_FAKTURA ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 101, 177, 255 } ))
::aTabPage[ID_KUNDEN ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 050, 151, 255 } ))
::aTabPage[ID_IMOBILIE ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 050, 151, 255 } ))
::aTabPage[ID_ARTIKEL ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 000, 125, 255 } ))
::aTabPage[ID_UMSATZ ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 000, 100, 204 } ))
::aTabPage[ID_TOOLS ,IS_RIBSTAT]:setColorBG(GraMakeRGBColor( { 255, 242, 229 } ))
::aTabPage[ID_CALENDAR ,IS_RIBSTAT]:setCaption("CALENDAR ")
::aTabPage[ID_ERFASSUNG,IS_RIBSTAT]:setCaption("ERFASSUNG")
::aTabPage[ID_ARBEIT ,IS_RIBSTAT]:setCaption("ARBEIT ")
::aTabPage[ID_FAKTURA ,IS_RIBSTAT]:setCaption("FAKTURA ")
::aTabPage[ID_KUNDEN ,IS_RIBSTAT]:setCaption("KUNDEN ")
::aTabPage[ID_IMOBILIE ,IS_RIBSTAT]:setCaption("IMOBILIE ")
::aTabPage[ID_ARTIKEL ,IS_RIBSTAT]:setCaption("ARTIKEL ")
::aTabPage[ID_UMSATZ ,IS_RIBSTAT]:setCaption("UMSATZ ")
::aTabPage[ID_TOOLS ,IS_RIBSTAT]:setCaption("TOOLS ")
::aTabPage[ID_CALENDAR ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_CALENDAR )}
::aTabPage[ID_ERFASSUNG,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_ERFASSUNG)}
::aTabPage[ID_ARBEIT ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_ARBEIT )}
::aTabPage[ID_FAKTURA ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_FAKTURA )}
::aTabPage[ID_KUNDEN ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_KUNDEN )}
::aTabPage[ID_IMOBILIE ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_IMOBILIE )}
::aTabPage[ID_ARTIKEL ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_ARTIKEL )}
::aTabPage[ID_UMSATZ ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_UMSATZ )}
::aTabPage[ID_TOOLS ,IS_RIBSTAT]:resize := {|mp1,mp2,oSelf| ::TabResize(mp1,mp2,oSelf,ID_TOOLS )}
RETURN self
Code: Select all
METHOD VOBWORK:TabResize(aOldSize,aNewSize,oSelf,nIDNr)
LOCAL iMax, aChild
LOCAL aSize := aNewSize
IF aOldSize[1] == 0 .AND. aOldSize[2] == 0
aOldSize := aNewSize
RETURN self
ELSEIF aNewSize[1] == 0 .OR. aNewSize[2] == 0
RETURN self
// add "same Size", nothing had happend
ELSEIF aNewSize[1] == aOldSize[1] .AND. aNewSize[2] == aOldSize[2]
RETURN self
ENDIF
* oSelf:hide()
* oSelf:LockUpdate(.T.)
oSelf:setPosAndSize({SC_LEFT,0},aNewSize)
aChild := oSelf:childList()
iMax := LEN(aChild)
IF iMax > 0
DO CASE
CASE nIDNr == ID_CALENDAR ; ::Tab_CALENDAR (aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_ERFASSUNG ; ::Tab_ERFASSUNG(aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_ARBEIT ; ::Tab_ARBEIT (aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_FAKTURA ; ::Tab_FAKTURA (aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_KUNDEN ; ::Tab_KUNDEN (aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_IMOBILIE ; ::Tab_IMOBILIE (aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_ARTIKEL ; ::Tab_ARTIKEL (aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_UMSATZ ; ::Tab_UMSATZ (aOldSize,aNewSize,oSelf)
CASE nIDNr == ID_TOOLS ; ::Tab_TOOLS (aOldSize,aNewSize,oSelf)
ENDCASE
ENDIF
* oSelf:LockUpdate(.F.)
* oSelf:show()
RETURN self
greetings by OHR
Jimmy
Jimmy
Re: Ribbonbar Title problem
eXpress++ and XCodeJock are products for Xbase++, not harbour.i "think" the "Problem" is that only Xbase++ have a :DrawingArea. In harbour you have to use a Static to "simulate" it.
I am trying to get a simple answer.
All of the code you posted is impossible to understand because it isn't something that can be compiled and run.
It is a lot of pieces that don't connect together in any kind of understandable form.
The eXpress train is coming - and it has more cars.
Re: Ribbonbar Title problem
i knew this and it was only to show Difference from Xbase++ to "other" Windows Compiler.rdonnay wrote:eXpress++ and XCodeJock are products for Xbase++, not harbour.i "think" the "Problem" is that only Xbase++ have a :DrawingArea. In harbour you have to use a Static to "simulate" it.
as you can use Codejock for other Compiler/System i "testdrive" WinDev. Like harbour it does not have a :drawingArea and so it have no Problem with Position / Titelbar
the Answer is :DrawingArea ! Codejock does not know it !rdonnay wrote:I am trying to get a simple answer.
as you know i do not have Express++ so i can not make a Demo for it.rdonnay wrote:All of the code you posted is impossible to understand because it isn't something that can be compiled and run.
It is a lot of pieces that don't connect together in any kind of understandable form.
I have no Problem with Ribbonbar any more and i just want to show some "pure" Xbase++ Source Code where i use CJ Methode and Property which might miss in XCodejock.
i do not remember (now) which Methode/Property was the "missing", but when you read my Source you will find them and you can read in Codejock Help File about it.
greetings by OHR
Jimmy
Jimmy