Print Page | Close Window

Using ribbon color schemes with docking panes etc

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=6315
Printed Date: 12 November 2025 at 5:10am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Using ribbon color schemes with docking panes etc
Posted By: robin_l
Subject: Using ribbon color schemes with docking panes etc
Date Posted: 04 February 2007 at 11:20am
When using a ribbon, following the RibbonSample example it is easy to have the general appearance use one of the blue/black/silver/aqua color schemes. In addition, any toolbars/menu bars/status bars that are present automatically take on the required colors.
 
However, neither CXTPDockingPaneManager nor CXTPTabClientWnd items seem to adjust color. How is it possible to do this?
 
Also, how can I determine the colors being used from within the application so that I can change app-specific elements to match? The GetXtremeColor(xxx) function does not seem to return different values even when the different color schemes are in operation.



Replies:
Posted By: Oleg
Date Posted: 05 February 2007 at 1:36am
Hi,
 
Set xtpPaneThemeOffice2007 theme for dockingpanes.
 
Check Samples\DockingPane\PaneSample.


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: robin_l
Date Posted: 05 February 2007 at 6:02am
Hi Oleg,
 
The xtpPaneThemeOffice2007 theme is fine for the blue ribbon color, but does not update when the black/aqua/silver color schemes are used. I tested by inserting the following into a version of the RibbonMDISample that I'd incorporated the ribbon colour style code from RibbonSample:
 
    m_paneManager.InstallDockingPanes(this);
    m_paneManager.SetTheme(xtpPaneThemeOffice2007);
    m_paneManager.UseSplitterTracker(FALSE);
    m_paneManager.CreatePane(  IDS_PANEWINDOW,
                  CRect(0, 0,150, 120), xtpPaneDockLeft );
 
In the blue color, all is fine, but in black neither the docking panes nor the tab client use the same color scheme as the ribbon.
  


Posted By: Oleg
Date Posted: 05 February 2007 at 11:25am
Call
 
m_paneManager.GetPaintManager()->RefreshMetrics()
after you change color.


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: robin_l
Date Posted: 05 February 2007 at 6:51pm
Excellent! This sets the docking pane color correctly. To set the tab client wnd I also needed to add the line:

m_wndClient.GetPaintManager()->RefreshMetrics();

This sets the color of the tab background correctly, but as the default is to use the OneNote color scheme it still looks odd. However, ensuring that the following is set:

m_wndClient.GetPaintManager()->SetOneNoteColors(FALSE);

gives exactly what I need. Many thanks for your help!




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net