How to create a Docking MultiTab Pane |
Post Reply |
Author | |
elmue
Groupie Joined: 05 June 2010 Location: Germany Status: Offline Points: 24 |
Post Options
Thanks(0)
Posted: 12 July 2010 at 9:11am |
Hello
I invested a lot of time to get it working. Now here it is: A docking pane that contains multiple documents. I modified the sample GUI_VisualStudio that now hosts all Script Editor Childs in a Docking Pane. Neither MFC nor Xtreme Toolkit provide this functionality. There is the CXTPTabControl in the Xtreme Toolkit. But the functionality is rather limited in comparison to the CXTPTabClientWnd which normally hosts the Tabs in a MultiDocument application. But MFC has not been designed to run CMDIChildWnd in a pane. So a part of the functionalty had to be overridden or partially re-impemented. CMultiDocTemplate in MFC can not be used to create the CDocument/CView's. In this download you find my class CPaneMultiTab which does all the work. But also in CMainFrame and in the CGUI_VisualStudioApp some changes where necessary. When Microsoft has developed MFC they never thought that anybody might add panes to their MultiDoc classes and run a TabControl with CMDIChildWnd's in this pane. Microsoft routes all commands like opening a file and the Edit commands to CWinApp which does the default processing. There where some changes necessary. But finally it works like a charme. I find this functionality so etremely usefull that I don't understand why there is no Codejock sample available that shows how to do that. What about adding my class to the toolkit ? Or at least adding my sample to the samples collection ? There is no sample available that shows how to host multiple CDocument/CView pairs in a pane in a Tab Control. There are some samples with Tab controls but they are not usefull for this purpose. I hope my several hours of work are helpfull for some other people. Download the Project GUI_VisualStudio_MultiTab: uploads/20100712_090552_GUI_VisualStudi.zip ATTENTION: This project will not compile if you don't copy it to .....\Xtreme Toolkit\Samples\UserInterface\GUI_VisualStudio_MultiTab\ Elmü |
|
znakeeye
Senior Member Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
|
Thanks for sharing!
|
|
PokerMemento - http://www.pokermemento.com/
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |