Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Skin Framework
  New Posts New Posts RSS Feed - Skin + Ribbonbar + Vista: problem and solution
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Skin + Ribbonbar + Vista: problem and solution

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


Joined: 11 May 2007
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote Joe19 Quote  Post ReplyReply Direct Link To This Post Topic: Skin + Ribbonbar + Vista: problem and solution
    Posted: 26 October 2007 at 12:42pm

My app uses both the ribbon bar and skins.  Everything worked fine under XP but with Vista there was strange behavior with the frame and status bar.

The key was to not use EnableFrameTheme on the ribbonbar.  Everything now works under both XP & Vista.  However the applications title bar and open/close buttons are now located above the ribbonbar quick access controls.
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: 29 October 2007 at 2:21am
Hi,
 
Try call XTPSkinFramework()->Remove(m_hWnd) for CMainFrame window.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Joe19 View Drop Down
Newbie
Newbie


Joined: 11 May 2007
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote Joe19 Quote  Post ReplyReply Direct Link To This Post Posted: 05 November 2007 at 12:45pm
I assume you mean XTPSkinManager()->Remove(m_hWnd).  Using this and then pRibbonBar->EnableFrameTheme() in my CMainFrame::OnCreate method helps buts doesn't fully solve the problem.
 
This image shows the application under vista.  You see that there is still a title bar instead of having the controls inserted into the ribbon bar.  However, there are no problems using the application.
 
This next image is the same code running under XP.  It is a little hard to see, but there is now a gray border around the application, however the Frames title bar is no longer visiable and the frames controls are in the ribbon bar.
 
 
This last image is without using the XTPSkinManager()->Remove(m_hWnd) under XP.  You see the gray border is no longer present.  This code causes lots of problems under Vista.
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: 05 November 2007 at 1:28pm
Hello,
 
Try reporoduce same problem with our sample and attach it here.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Joe19 View Drop Down
Newbie
Newbie


Joined: 11 May 2007
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote Joe19 Quote  Post ReplyReply Direct Link To This Post Posted: 05 November 2007 at 7:43pm
Oleg,
 
Attached is the modified project based on your RibbonSample.  I only changed 2 files, MainFrm.cpp and RibbonSample.rc2.  If you do a search with "// skin modified" you will find the changes I made.  This project duplicates all the issues I raised in previous posts.
 
I did change the project configuration to statically link to the MFC libraries because I got a side by side error when trying to run under Vista.
 
-Joe
 
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: 06 November 2007 at 4:30am
Hi,
 
just move XTPSkinManager()->Remove(m_hWnd) in the beginning of OnCreate and better LoadSkin move to constructor.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Joe19 View Drop Down
Newbie
Newbie


Joined: 11 May 2007
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote Joe19 Quote  Post ReplyReply Direct Link To This Post Posted: 06 November 2007 at 11:48am
That solved the problem.  Works the same under Vista and XP now.  Many thanks,
 
-Joe
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.141 seconds.