Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - Ribbon Sample
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Ribbon Sample

 Post Reply Post Reply
Author
Message
coldjoke View Drop Down
Newbie
Newbie


Joined: 07 June 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote coldjoke Quote  Post ReplyReply Direct Link To This Post Topic: Ribbon Sample
    Posted: 07 June 2007 at 5:27am
I've tried for so long
and still can't setup RibbonBar in a simple SDI project
is it possible to provide an simple Ribbon sample that can be understood without reading too many codes??
 
by the way, i am using v 11.1.0
 
thanks
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 07 June 2007 at 6:53am
Hi,
 
Attach project you tried. Will point what you forget.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
coldjoke View Drop Down
Newbie
Newbie


Joined: 07 June 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote coldjoke Quote  Post ReplyReply Direct Link To This Post Posted: 07 June 2007 at 11:26pm

somehow it works now @@

but i got another problem.
now i have the RibbonBar but the docking pane has gone
 
 m_paneManager.InstallDockingPanes(this);
 // Set Office 2003 Theme
 m_paneManager.SetTheme(xtpPaneThemeOffice2003);
is it because i am using xtpPaneThemeOffice2003??
 
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 08 June 2007 at 1:14am
Hi,
No, theme can't be problem. Do you create some panes?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
coldjoke View Drop Down
Newbie
Newbie


Joined: 07 June 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote coldjoke Quote  Post ReplyReply Direct Link To This Post Posted: 08 June 2007 at 2:32am

i used the wizard to create the project and it created 2 panes for me

all i did to the project is remove menu and toolbar
and insert Ribbon
 
this is the creation of the panes
 
 // Initialize the docking pane manager and set the
 // initial them for the docking panes.  Do this only after all
 // control bars objects have been created and docked.
 m_paneManager.InstallDockingPanes(this);
 // Set Office 2003 Theme
 m_paneManager.SetTheme(xtpPaneThemeOffice2003);
 // Create docking panes.
 CXTPDockingPane* pwndPane1 = m_paneManager.CreatePane(
  IDR_PANE_OPTIONS, CRect(0, 0,200, 120), xtpPaneDockLeft);
 CXTPDockingPane* pwndPane2 = m_paneManager.CreatePane(
  IDR_PANE_PROPERTIES, CRect(0, 0,200, 120), xtpPaneDockBottom, pwndPane1);
 // Set the icons for the docking pane tabs.
 int nIDIcons[] = {IDR_PANE_OPTIONS, IDR_PANE_PROPERTIES};
  m_paneManager.SetIcons(IDB_BITMAP_ICONS, nIDIcons,
  _countof(nIDIcons), RGB(0, 255, 0));
 // Load the previous state for docking panes.
 CXTPDockingPaneLayout layoutNormal(&m_paneManager);
 if (layoutNormal.Load(_T("NormalLayout")))
 {
  m_paneManager.SetLayout(&layoutNormal);
 }
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 08 June 2007 at 3:42am
Hi,
 
Just tried. Works for me.
 
 
Attach project.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
coldjoke View Drop Down
Newbie
Newbie


Joined: 07 June 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote coldjoke Quote  Post ReplyReply Direct Link To This Post Posted: 08 June 2007 at 3:59am

after adding these two line at the end

 
 m_paneManager.ShowPane(IDR_PANE_OPTIONS);
 m_paneManager.ShowPane(IDR_PANE_PROPERTIES);
it works too, but before using RibbonBar
Back to Top
coldjoke View Drop Down
Newbie
Newbie


Joined: 07 June 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote coldjoke Quote  Post ReplyReply Direct Link To This Post Posted: 08 June 2007 at 4:05am
and i don't have the permission to upload files :(
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 08 June 2007 at 6:05am
Hi,
I modified forum settings.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
coldjoke View Drop Down
Newbie
Newbie


Joined: 07 June 2007
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote coldjoke Quote  Post ReplyReply Direct Link To This Post Posted: 08 June 2007 at 11:18pm
Hi,
I know where the problem is now
I closed the docking panes when testing my sample
and by default, the layout was saved on close
that's why they never came out again.
 
thanks for the help :)
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.109 seconds.