Jump to content
  • Advertisement
Sign in to follow this  
d000hg

Floating (dockable?) menus

This topic is 4863 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I need to re-write my level editor at some point, it's currently in pure Win32API and very ugly! I plan to use MFC but while I've done a lot of work in this area I'm used only to dialog-based applications, wheras a heightmap editor should probably be window-based... One thing I definitely need is floating menus - how are these achieved in MFC? Is this a MDI thing or is it better to have some modal dialogs floating about? Dockable menus are I suppose advantageous but hardly a requirement! Basically I want D3D running in some window, with menus and toolbars etc - it's just getting the main infrastructure set up to get the different windows working so I can re-implement existing functionality!

Share this post


Link to post
Share on other sites
Advertisement
Floating windows can be implemented using just a dialog or window but dockable windows are a bit difficult. Win32 does not have them natively. Catch-22 has two tutorials on creating dockable windows in Win32. They are here and here. MFC, however, has them natively. Their functionality is implemented in CControlBar.

Share this post


Link to post
Share on other sites
When I implemented a flaoting toolbar dialog in Win32, I had problems in that whenever you used it, the focus was lost from the main application window, meaning you had to get it back somehow which seemed un-professional! Is there a standard way round this other than me just hacking in some SetFocus() calls?

As for MDI, what is an example of a standard program which uses this? I don't know if I need it or not...

Share this post


Link to post
Share on other sites
Photoshop uses MDI. Office 97 uses MDI (later versions do not). AOL and Opera use MDI (unless Opera has changed its interface since I last used it).

As for the focus problems, were you using WS_EX_TOOLWINDOW to create your floating windows? The tutorial in the link I gave you before does and his tutorials generally give programs that look and act professionally.

Share this post


Link to post
Share on other sites
Ah, probably not. I'm definitely going to use MFC when I redo the application; you'd recommend using CControlBar instead of basing by own classes on CDialog then I presume?

Thanks for the advice by the way.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!