PDA

View Full Version : simple mdiArea example wanted ..



AbuYusuf
11th February 2010, 17:04
i want simple mdiArea example, as i want to create an application using mdiArea as a frontend, and i'm using Qt-Creator

i saw the example that came with Qt, but it is completely written by hand.

i want an example that have .ui file ( Qt-Designer ) and .cpp files normally

Can i find something like that ?

ChrisW67
11th February 2010, 22:54
It's not difficult. Create your main window in Designer and place the MDI area widget as its central widget and apply a layout. Right-click on the empty MDI area and select Add Subwindow; you can then add widgets to the sub-window. All the code should be generated for you.

Alternatively, you can create your sub-window contents independently as QWidget derivatives and put a small amount of code in your main window to add them to the MDI area as required.