<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : CXTPRibbonBar display issues</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Command Bars : CXTPRibbonBar display issues]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Thu, 11 Jun 2026 10:27:20 +0000</pubDate>
  <lastBuildDate>Tue, 24 Jun 2008 11:58:37 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=11141</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[CXTPRibbonBar display issues : There are a lot of changes. Can...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=11141&amp;PID=37354&amp;title=cxtpribbonbar-display-issues#37354</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3213">rdhd</a><br /><strong>Subject:</strong> 11141<br /><strong>Posted:</strong> 24 June 2008 at 11:58am<br /><br /><P>There are a lot of changes. Can you narrow it down a bit?</P>]]>
   </description>
   <pubDate>Tue, 24 Jun 2008 11:58:37 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=11141&amp;PID=37354&amp;title=cxtpribbonbar-display-issues#37354</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPRibbonBar display issues : Hi,  you can download 11.2.2,...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=11141&amp;PID=37169&amp;title=cxtpribbonbar-display-issues#37169</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 11141<br /><strong>Posted:</strong> 22 June 2008 at 2:34am<br /><br />Hi,<DIV>&nbsp;</DIV><DIV>you can download 11.2.2, check what lines was changed and include it to your 11.2 release.</DIV>]]>
   </description>
   <pubDate>Sun, 22 Jun 2008 02:34:34 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=11141&amp;PID=37169&amp;title=cxtpribbonbar-display-issues#37169</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPRibbonBar display issues : I posted a question before about...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=11141&amp;PID=37164&amp;title=cxtpribbonbar-display-issues#37164</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3213">rdhd</a><br /><strong>Subject:</strong> 11141<br /><strong>Posted:</strong> 21 June 2008 at 3:29pm<br /><br />I posted a question before about having more than one ribbon causing problems. I have modified the RibbonMDISample sample to show these problems.<DIV>&nbsp;</DIV><DIV>The issue I have is the old "MFC" caption and/or window icons displaying on top of the CodeJock ribbon.</DIV><DIV>&nbsp;</DIV><DIV>To show the ribbon problems, I modified the sample to create and then delete a second ribbon. Make the same modifications (I will upload the modified mainfrm.cpp file) and build the sample.</DIV><DIV>&nbsp;</DIV><DIV>Then again I can't upload since I am not a "registered forum member". I'll insert the code changes below.</DIV><DIV>&nbsp;</DIV><DIV>Then start the sample. Neither the frame nor the mdi child created will be maximized. Move the cursor from the mdi client area and over the status bar crossing over the "NUM" section and onto the resize gripper at the lower right of the frame. When the mouse moves over the gripper, the MFC minimize, maximize and close icons will display over the top of the CJ frame's corresponding icons. That is the first problem.</DIV><DIV>&nbsp;</DIV><DIV>Now set up your desktop with the sample frame and another window like the dos prompt such that the two windows don't intersect. With the sample being the active app, move the cursor to the dos prompt window and click it to activate it. Now move the cursor back to the sample app and click it. At this time, the entire MFC caption displays over the top of the CJ frame.</DIV><DIV>&nbsp;</DIV><DIV>Performing other operations also can cause the MFC display overlay to occur. Sometimes it remains and sometimes it just flashes and the CJ ribbon overdisplays it. For instance, maximize and restore the mdi child window a few times. Notice the MFC overdisplay on the child window as it dynamically sizes up or down.</DIV><DIV>&nbsp;</DIV><DIV>Or maximize the mdi child and grab the frame's resize gripper and dynamically resize the frame. Notice the light show at the top of the frame window as the MFC caption and icons and the CJ ribbon fight it out for display supremacy.</DIV><DIV>&nbsp;</DIV><DIV>I really need to be able to allow the creation of more than one ribbon and would like to find a fix to this. I am not asking CJ to provide a fix in 11.2, which is our current version. If there is anything I can do to avoid the problem in our code I will gladly make changes.</DIV><DIV>&nbsp;</DIV><DIV>Just in case the upload fails:</DIV><DIV>&nbsp;</DIV><DIV>In MainFrm.h, find the definition of CreateRibbonbar and modify it to be:</DIV><DIV><FONT size=2></FONT>&nbsp;</DIV><DIV><FONT size=2>BOOL CreateRibbonBar</FONT><FONT color=#0000ff size=2>(bool</FONT><FONT size=2> bSecond</FONT><FONT color=#0000ff size=2>);</FONT></DIV><DIV><FONT color=#0000ff size=2>&nbsp;</DIV></FONT><DIV>In CMainFrame::OnCreate, add this right before the return statement:</DIV><DIV>&nbsp;</DIV><DIV><FONT size=2><P></FONT><FONT color=#0000ff size=2>if</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(!</FONT><FONT size=2>CreateRibbonBar</FONT><FONT color=#0000ff size=2>(true))</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>{</P></FONT><FONT size=2><P>TRACE0</FONT><FONT color=#0000ff size=2>(</FONT><FONT color=#a31515 size=2>"Failed to create ribbon\n"</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>return</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>-</FONT><FONT color=#ff0000 size=2>1</FONT><FONT color=#0000ff size=2>;</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>}</P></FONT></DIV><DIV>Then replace the CreateRibbonBar function with this modified code:</DIV><DIV>&nbsp;</DIV><DIV><FONT size=2><P>BOOL CMainFrame</FONT><FONT color=#0000ff size=2>::</FONT><FONT size=2>CreateRibbonBar</FONT><FONT color=#0000ff size=2>(bool</FONT><FONT size=2> bSecond</FONT><FONT color=#0000ff size=2>)</P><P>{</P></FONT><FONT size=2><P>CMenu menu</FONT><FONT color=#0000ff size=2>;</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>if(</FONT><FONT size=2> bSecond </FONT><FONT color=#0000ff size=2>)</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>{</P></FONT><FONT size=2><P>CRuntimeClass</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pCommandBarsClass </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> RUNTIME_CLASS</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPCommandBars</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>m_pCommandBars </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPCommandBars</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2> pCommandBarsClass</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>CreateObject</FONT><FONT color=#0000ff size=2>();</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// fail to set the site and we crash.</P></FONT><FONT size=2><P>m_pCommandBars</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetSite</FONT><FONT color=#0000ff size=2>(this);</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// set the ribbon theme</P></FONT><FONT size=2><P>m_pCommandBars</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetTheme</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpThemeRibbon</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>}</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>else</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>{</P></FONT><FONT size=2><P>menu</FONT><FONT color=#0000ff size=2>.</FONT><FONT size=2>Attach</FONT><FONT color=#0000ff size=2>(::</FONT><FONT size=2>GetMenu</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>m_hWnd</FONT><FONT color=#0000ff size=2>));</P></FONT><FONT size=2><P>SetMenu</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>NULL</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>}</P></FONT><FONT size=2><P>CXTPCommandBars</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pCommandBars </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> bSecond </FONT><FONT color=#0000ff size=2>?</FONT><FONT size=2> m_pCommandBars </FONT><FONT color=#0000ff size=2>:</FONT><FONT size=2> GetCommandBars</FONT><FONT color=#0000ff size=2>();</P><P>&nbsp;</P><P>#ifndef</FONT><FONT size=2> CREATE_FROM_XML</P><P>CXTPRibbonBar</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pRibbonBar</FONT><FONT color=#0000ff size=2>;</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>if(</FONT><FONT size=2> bSecond </FONT><FONT color=#0000ff size=2>)</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>{</P></FONT><FONT size=2><P>pRibbonBar </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPRibbonBar</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pCommandBars</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>_T</FONT><FONT color=#0000ff size=2>(</FONT><FONT color=#a31515 size=2>"The Ribbon"</FONT><FONT color=#0000ff size=2>),</FONT><FONT size=2> xtpBarFloating</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> RUNTIME_CLASS</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPRibbonBar</FONT><FONT color=#0000ff size=2>));</P></FONT><FONT size=2><P>m_pRibbonBar </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pRibbonBar</FONT><FONT color=#0000ff size=2>;</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// If I don't set visible to false, and for some reason the m_pCommandBars is not destroyed when I release it below,</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// the ribbon will display! So failsafe by setting visibility to false.</P></FONT><FONT size=2><P></P><P></FONT><FONT color=#008000 size=2>// Skip this call and the ribbon displays at the top left of the desktop.</P></FONT><FONT size=2><P>m_pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetVisible</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>FALSE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>m_pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>EnableFrameTheme</FONT><FONT color=#0000ff size=2>();</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>}</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>else</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>{</P></FONT><FONT size=2><P>pRibbonBar </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPRibbonBar</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pCommandBars</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>_T</FONT><FONT color=#0000ff size=2>(</FONT><FONT color=#a31515 size=2>"The Ribbon"</FONT><FONT color=#0000ff size=2>),</FONT><FONT size=2> xtpBarTop</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> RUNTIME_CLASS</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPRibbonBar</FONT><FONT color=#0000ff size=2>));</P></FONT><FONT size=2><P>pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>EnableDocking</FONT><FONT color=#0000ff size=2>(</FONT><FONT color=#ff0000 size=2>0</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P></P><P>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pControlFile </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddSystemButton</FONT><FONT color=#0000ff size=2>(</FONT><FONT color=#ff0000 size=2>0</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlFile</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetCommandBar</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>menu</FONT><FONT color=#0000ff size=2>.</FONT><FONT size=2>GetSubMenu</FONT><FONT color=#0000ff size=2>(</FONT><FONT color=#ff0000 size=2>0</FONT><FONT color=#0000ff size=2>));</P></FONT><FONT size=2><P></P><P>pControlFile</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetIconId</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>IDB_GEAR</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>}</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>if</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(!</FONT><FONT size=2>pRibbonBar</FONT><FONT color=#0000ff size=2>)</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>{</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>return</FONT><FONT size=2> FALSE</FONT><FONT color=#0000ff size=2>;</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>}</P></FONT><FONT size=2><P>CXTPRibbonTab</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pTabHome </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddTab</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_TAB_HOME</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPRibbonGroup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pGroupFile </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pTabHome</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddGroup</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_GROUP_FILE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupFile</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_NEW</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupFile</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_OPEN</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupFile</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_CLOSE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pControlSave </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pGroupFile</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlSplitButtonPopup</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_SAVE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlSave</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_SAVE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlSave</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_SAVE_AS</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pControlPrint </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pGroupFile</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlSplitButtonPopup</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_PRINT</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlPrint</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_PRINT</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlPrint</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_PRINT_SETUP</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlPrint</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetBeginGroup</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>TRUE</FONT><FONT color=#0000ff size=2>);</P><P>&nbsp;</P></FONT><FONT size=2><P>CXTPRibbonTab</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pTabEdit </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddTab</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_TAB_EDIT</FONT><FONT color=#0000ff size=2>);</P><P>&nbsp;</P></FONT><FONT size=2><P>CXTPRibbonGroup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pGroupClipborad </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pTabEdit</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddGroup</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_GROUP_CLIPBOARD</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupClipborad</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>ShowOptionButton</FONT><FONT color=#0000ff size=2>();</P></FONT><FONT size=2><P></P><P>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pControlPaste </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pGroupClipborad</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlSplitButtonPopup</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_PASTE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlPaste</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_PASTE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlPaste</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_PASTE_SPECIAL</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupClipborad</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_CUT</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupClipborad</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_COPY</FONT><FONT color=#0000ff size=2>);</FONT><FONT size=2> </P><P>pGroupClipborad</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FORMAT_PAINTER</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPRibbonGroup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pGroupEditing </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pTabEdit</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddGroup</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_GROUP_EDITING</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupEditing</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_FIND</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupEditing</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_REPLACE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupEditing</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_GOTO</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pControlSelect </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pGroupEditing</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlPopup</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_SELECT</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlSelect</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_SELECT_ALL</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlSelect</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetFlags</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpFlagManualUpdate</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P></P><P></P><P></P><P>CXTPRibbonTab</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pTabView </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddTab</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_TAB_VIEW</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPRibbonGroup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pGroupDocumentView </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pTabView</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddGroup</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_GROUP_DOCUMENTVIEWS</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupDocumentView</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_VIEW_NORMAL</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupDocumentView</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_PRINT_PREVIEW</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupDocumentView</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_VIEW_FULLSCREEN</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPRibbonGroup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pGroupShowHide </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pTabView</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddGroup</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_GROUP_SHOWHIDE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupShowHide</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlCheckBox</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_VIEW_STATUS_BAR</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupShowHide</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlCheckBox</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_VIEW_WORKSPACE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPRibbonGroup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pGroupWindow </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pTabView</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>AddGroup</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>ID_GROUP_WINDOW</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupWindow</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_WINDOW_NEW</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pGroupWindow</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_WINDOW_ARRANGE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pControlSwitchWindows </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>CXTPControlPopup</FONT><FONT color=#0000ff size=2>*)</FONT><FONT size=2>pGroupWindow</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlPopup</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_WINDOW_SWITCH</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlSwitchWindows</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetCommandBar</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> XTP_ID_WINDOWLIST</FONT><FONT color=#0000ff size=2>);</P><P>&nbsp;</P></FONT><FONT size=2><P>CXTPControl</FONT><FONT color=#0000ff size=2>*</FONT><FONT size=2> pControlAbout </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_APP_ABOUT</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pControlAbout</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>SetFlags</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpFlagRightAlign</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetQuickAccessControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_SAVE</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetQuickAccessControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_EDIT_UNDO</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetQuickAccessControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>Add</FONT><FONT color=#0000ff size=2>(</FONT><FONT size=2>xtpControlButton</FONT><FONT color=#0000ff size=2>,</FONT><FONT size=2> ID_FILE_PRINT</FONT><FONT color=#0000ff size=2>);</P></FONT><FONT size=2><P>pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>GetQuickAccessControls</FONT><FONT color=#0000ff size=2>()-&gt;</FONT><FONT size=2>CreateOriginalControls</FONT><FONT color=#0000ff size=2>();</P><P>#else</P></FONT><FONT color=#808080 size=2><P>CXTPPropExchangeXMLNode px(TRUE, 0, _T("Settings"));</P><P>if (px.LoadFromResource(AfxGetInstanceHandle(), MAKEINTRESOURCE(IDR_LAYOUT), RT_HTML))</P><P>{</P><P>CXTPPropExchangeSection pxCommandBars(px.GetSection(_T("CommandBars")));</P><P>XTP_COMMANDBARS_PROPEXCHANGE_PARAM param; </P><P>param.bSerializeControls = TRUE;</P><P>GetCommandBars()-&gt;DoPropExchange(&amp;pxCommandBars, &amp;param);</P><P>}</P><P>else</P><P>{</P><P>AfxMessageBox(_T("Can't load Layout"));</P><P>return FALSE;</P><P>}</P><P>CXTPRibbonBar* pRibbonBar = (CXTPRibbonBar*)GetCommandBars()-&gt;GetMenuBar();</P><P>pRibbonBar-&gt;EnableCustomization(FALSE);</P><P>pRibbonBar-&gt;GetQuickAccessControls()-&gt;SetOriginalControls(new CXTPOriginalControls());</P><P>pRibbonBar-&gt;GetQuickAccessControls()-&gt;GetOriginalControls()-&gt;Add(xtpControlButton, ID_FILE_SAVE);</P><P>pRibbonBar-&gt;GetQuickAccessControls()-&gt;GetOriginalControls()-&gt;Add(xtpControlButton, ID_EDIT_UNDO);</P><P>pRibbonBar-&gt;GetQuickAccessControls()-&gt;GetOriginalControls()-&gt;Add(xtpControlButton, ID_FILE_PRINT);</P></FONT><FONT color=#0000ff size=2><P>#endif</P><P>&nbsp;</P></FONT><FONT size=2><P>pRibbonBar</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>EnableFrameTheme</FONT><FONT color=#0000ff size=2>();</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// After the frame displays it should be that you have the sample frame window up with one mdi child. Neither</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// the frame nor the child is maximized. Move the cursor down towards the status bar to use the gripper in the</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// lower right to resize the frame and cross over the "NUM" area and onto the gripper. At this point, the old</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// caption bar's minmize, maximize and close icons display over the CJ icons.</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// Keep a dos window on the desktop and make sure the sample frame and dos window do not intersect. Now move</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// the cursor onto the dos window and click to activate. Then move the cursor back to the sample and click</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// it to activate it. At this point, the entire CJ title and icon area is completly overdrawn by the old mfc</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// caption and icon stuff. You don't have to use a dos window, any window that doesn't intersect the sample</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// app that is activated followed by activating the sample will show the problem.</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// I tried not setting the frame to be the site but CJ will crash if I don't. I found code in CJ that called</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// GetSite() and tested the result before using it. But a few lines later there was a GetSite()-&gt;SomeCall().</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// Perhaps I can set another site but what would I use?</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>if(</FONT><FONT size=2> bSecond </FONT><FONT color=#0000ff size=2>)</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>{</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// Set a break here and skip the following code. Then examine the frame window. It has two title and icon</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// rows. But the old style caption and icons don't display.</P></FONT><FONT size=2><P></P><P>pCommandBars</FONT><FONT color=#0000ff size=2>-&gt;</FONT><FONT size=2>InternalRelease</FONT><FONT color=#0000ff size=2>();</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>// should have been the only ref on the object.</P></FONT><FONT size=2><P>pCommandBars </FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2> NULL</FONT><FONT color=#0000ff size=2>;</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>}</P></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2>return</FONT><FONT size=2> TRUE</FONT><FONT color=#0000ff size=2>;</P><P>}</P></FONT></DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Sat, 21 Jun 2008 15:29:25 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=11141&amp;PID=37164&amp;title=cxtpribbonbar-display-issues#37164</guid>
  </item> 
 </channel>
</rss>