<?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 : Tabbed MDI</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Toolkit Pro : Tabbed MDI]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 13 May 2026 15:58:33 +0000</pubDate>
  <lastBuildDate>Mon, 08 Dec 2003 12:01:29 +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=226</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[Tabbed MDI : A fix for the above problem is...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=630&amp;title=tabbed-mdi#630</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=245">ddyer</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 08 December 2003 at 12:01pm<br /><br /><P>A fix for the above problem is to place the OnSize code above into ShowWindow.&nbsp; You still get that annoying redraw flash whenver you click on a tab, but it works:</P><P>Any thoughts on how to prevent the redraw flashing?</P><FONT color=#0000ff size=2><P><FONT face="Courier New, Courier, mono" size=1>void</FONT></FONT><FONT face="Courier New, Courier, mono" size=1> CChildFrame::OnShowWindow(BOOL bShow, UINT nStatus)<BR></FONT><FONT face="Courier New, Courier, mono" size=1>{<BR></FONT><FONT face="Courier New, Courier, mono" size=1>CMDIChildWnd::OnShowWindow(bShow, nStatus);</FONT></P><P><FONT face="Courier New, Courier, mono" size=1></FONT></P><P><FONT size=1><FONT face="Courier New, Courier, mono" color=#0000ff>if</FONT><FONT face="Courier New, Courier, mono"> (bShow) {<BR></FONT></FONT><FONT face="Courier New, Courier, mono" size=1>WINDOWPLACEMENT sWndPos;<BR></FONT><FONT size=1><FONT face="Courier New, Courier, mono">sWndPos.length = </FONT><FONT face="Courier New, Courier, mono" color=#0000ff>sizeof</FONT><FONT face="Courier New, Courier, mono">(WINDOWPLACEMENT);<BR></FONT></FONT><FONT face="Courier New, Courier, mono" size=1>sWndPos.flags = 0;<BR></FONT><FONT face="Courier New, Courier, mono" size=1>sWndPos.showCmd = SW_SHOWMAXIMIZED;<BR></FONT><FONT face="Courier New, Courier, mono" size=1>SetWindowPlacement(&amp;sWndPos);<BR></FONT><FONT face="Courier New, Courier, mono" size=1>}<BR></FONT><FONT face="Courier New, Courier, mono" size=1>}</FONT></P>]]>
   </description>
   <pubDate>Mon, 08 Dec 2003 12:01:29 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=630&amp;title=tabbed-mdi#630</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : Iused theOnSizetip and and it...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=584&amp;title=tabbed-mdi#584</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=245">ddyer</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 01 December 2003 at 12:02pm<br /><br /><P>I&nbsp;used the&nbsp;OnSize&nbsp;tip and and it worked great.&nbsp; It even removed that annoying "flash" when tabbing between the&nbsp;&nbsp;windows caused by rendering the "normal size" window frame then erasing it and rendering the maximized frame.</P><P>BUT... create three frames, then click on the middle tab (frame #2 on forefront).&nbsp;&nbsp; Now resize the window.&nbsp; As you resize, the XTP MDI manager goes nuts making frames #2 and #3 alternately the forefront window.</P><P>&nbsp;</P><P>You can easily replicate this by adding the OnSize bit to the GUI_VisualStudio7 demo, then when running it select File-&gt;New-&gt;File three times and resize the application:</P><P><FONT color=#0033cc>void CChildFrame::OnSize(UINT nType, int cx, int cy) <BR>{<BR>&nbsp;&nbsp;&nbsp;&nbsp; CMDIChildWnd::OnSize(nType, cx, cy);<BR><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // ADD -&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(nType == SIZE_MINIMIZED || nType == SIZE_RESTORED) {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; WINDOWPLACEMENT sWndPos;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;sWndPos.length = sizeof(WINDOWPLACEMENT);<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;sWndPos.flags = 0;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;sWndPos.showCmd = SW_SHOWMAXIMIZED;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;SetWindowPlacement(&amp;sWndPos);<BR>&nbsp;&nbsp;&nbsp;&nbsp; }<BR>&nbsp;&nbsp;&nbsp;&nbsp; //&lt;-&nbsp;ADD<BR>}</FONT></P><P>&nbsp;</P><P>&nbsp;</P><P>Is this an XTP bug?</P><span style="font-size:10px"><br /><br />Edited by ddyer</span>]]>
   </description>
   <pubDate>Mon, 01 Dec 2003 12:02:11 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=584&amp;title=tabbed-mdi#584</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : Thanks oleg that worked ok only...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=540&amp;title=tabbed-mdi#540</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=234">kelvincannon</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 13 November 2003 at 7:44am<br /><br /><P>Thanks oleg that worked ok only you must place it after "LoadCommandBars(_T("Bar State"));"</P><P><FONT color=#808080 size=2>&nbsp;</P></FONT>]]>
   </description>
   <pubDate>Thu, 13 Nov 2003 07:44:24 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=540&amp;title=tabbed-mdi#540</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : If you use ToolkitPro you can...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=531&amp;title=tabbed-mdi#531</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 13 November 2003 at 12:58am<br /><br /><P>If you use ToolkitPro you can add &nbsp;</P><P>CXTPCommandBar* pMenuBar = pCommandBars-&gt;SetMenu("Menu Bar", IDR_MAINFRAME);<BR>pMenuBar-&gt;SetFlags(xtpFlagHideMinimizeBox | xtpFlagHideMaximizeBox);</P><P>this hide minimize and maximize buttons in the menu bar.</P>]]>
   </description>
   <pubDate>Thu, 13 Nov 2003 00:58:33 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=531&amp;title=tabbed-mdi#531</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : Kelvin,Try using this code in...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=524&amp;title=tabbed-mdi#524</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=226">Matt1</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 12 November 2003 at 1:01pm<br /><br /><P>Kelvin,<BR><BR>Try using this code in your child frame's OnSize() function:</P><BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px"><P dir=ltr style="MARGIN-RIGHT: 0px"><FONT color=#0033cc>void CChildFrame::OnSize(UINT nType, int cx, int cy) <BR>{<BR>&nbsp;&nbsp;&nbsp;&nbsp; CMDIChildWnd::OnSize(nType, cx, cy);<BR><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // ADD -&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(nType == SIZE_MINIMIZED || nType == SIZE_RESTORED) {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; WINDOWPLACEMENT sWndPos;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;sWndPos.length = sizeof(WINDOWPLACEMENT);<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;sWndPos.flags = 0;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;sWndPos.showCmd = SW_SHOWMAXIMIZED;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;SetWindowPlacement(&amp;sWndPos);<BR>&nbsp;&nbsp;&nbsp;&nbsp; }<BR>&nbsp;&nbsp;&nbsp;&nbsp; //&lt;-&nbsp;ADD<BR>}</FONT></P></BLOCKQUOTE><P dir=ltr style="MARGIN-RIGHT: 0px">This actually seems to work well with ToolkitPro when combined with a child window&nbsp;that doesn't have&nbsp;Min/Max box styles like yours.&nbsp; For straight MFC this does not work so well because the Min/Max boxes sometimes show up for some reason.<BR><BR>Also, you might want to remove the FWS_ADDTOTITLE style too because the above code interferes with that process.<BR><BR>If you end up finding a better solution, please post it here.</P>]]>
   </description>
   <pubDate>Wed, 12 Nov 2003 13:01:01 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=524&amp;title=tabbed-mdi#524</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : Thisis anMFC issue.I also would...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=523&amp;title=tabbed-mdi#523</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=226">Matt1</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 12 November 2003 at 12:28pm<br /><br /><P>This&nbsp;is an&nbsp;MFC issue.<BR><BR>I also would benefit from MDI windows that are force to stay maximized.&nbsp; I've tried forcing this in OnSize() but it's hackish and makes the Min/Max/Close buttons do <EM>strange</EM> things.<BR><BR>Does anybody know how to solve this problem gracefully?</P>]]>
   </description>
   <pubDate>Wed, 12 Nov 2003 12:28:54 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=523&amp;title=tabbed-mdi#523</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : I can not do that because I need...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=522&amp;title=tabbed-mdi#522</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=234">kelvincannon</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 12 November 2003 at 9:08am<br /><br /><P>I can not do that because I need the windows to remain maximized and not let the user changed them.</P><P>Thanks</P><P>Kelvin</P><P>&nbsp;</P>]]>
   </description>
   <pubDate>Wed, 12 Nov 2003 09:08:47 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=522&amp;title=tabbed-mdi#522</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : You remove WS_MAXIMIZEBOX flagand...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=519&amp;title=tabbed-mdi#519</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 12 November 2003 at 8:31am<br /><br /><P>You remove WS_MAXIMIZEBOX flag&nbsp;and it cant be&nbsp;maximized.</P><P>Try to remove &nbsp;this line</P><P>&nbsp;cs.style &amp;= ~(WS_MINIMIZEBOX|WS_MAXIMIZEBOX); </P>]]>
   </description>
   <pubDate>Wed, 12 Nov 2003 08:31:49 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=519&amp;title=tabbed-mdi#519</guid>
  </item> 
  <item>
   <title><![CDATA[Tabbed MDI : I have written a Tabbed MDI program...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=518&amp;title=tabbed-mdi#518</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=234">kelvincannon</a><br /><strong>Subject:</strong> 226<br /><strong>Posted:</strong> 12 November 2003 at 8:16am<br /><br /><P>I have written a Tabbed MDI program with a PreCreateWindow function as follows:</P><P>BOOL CDigitizeFrame::PreCreateWindow(CREATESTRUCT&amp; cs) <BR>{<BR>&nbsp; cs.x=cs.y=0;<BR>&nbsp; cs.cx=cs.cy=32767;<BR>&nbsp; cs.style |= WS_BORDER;<BR>&nbsp; cs.style &amp;= ~WS_THICKFRAME;<BR>&nbsp; cs.style &amp;= ~(WS_MINIMIZEBOX|WS_MAXIMIZEBOX); <BR>&nbsp; return CMDIChildWnd::PreCreateWindow(cs); <BR>}</P><P>The problem is that when I tab to the next window it is drawn as a restored window and not a maximized windows. Does anyone know how to prevent this from happening.</P><P>Thanks</P><P>Kelvin</P><P>&nbsp;</P>]]>
   </description>
   <pubDate>Wed, 12 Nov 2003 08:16:19 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=226&amp;PID=518&amp;title=tabbed-mdi#518</guid>
  </item> 
 </channel>
</rss>