[Qt-interest] Maximize one MDI Window
Constantin Makshin
cmakshin at gmail.com
Mon Mar 28 22:32:58 CEST 2011
Edit MDI-related part of Qt or implement MDI yourself. Since state sharing is there "by design", you don't have much choice.
On Tuesday 29 March 2011 00:18:41 Yuriy Rusinov wrote:
> > You can't maximize one MDI subwindow and keep others in "normal" state. That's the way MDI works — all subwindows use the same "not-minimized" state.
>
> Ok, what I have to do for use maximized state for active window only ?
> >
> > On Monday 28 March 2011 23:51:17 Yuriy Rusinov wrote:
> >> Hello, colleagues !
> >>
> >> I have to maximize one subwindow in mdi area. I do
> >> QMdiSubWindow * m_objEditorW = m_mdiArea->addSubWindow (objEditor);
> >> m_objEditorW->setAttribute (Qt::WA_DeleteOnClose);
> >> connect (objEditor, SIGNAL (closeEditor()), m_objEditorW, SLOT (close()) );
> >> int id = <something>
> >> if (id == 7)
> >> {
> >> objEditor->setWindowState (objEditor->windowState() |
> >> Qt::WindowMaximized | Qt::WindowActive);
> >> m_objEditorW->setWindowState (m_objEditorW->windowState() |
> >> Qt::WindowMaximized | Qt::WindowActive);
> >> }
> >> objEditor->show();
> >> required window is showed maximized, but other subwindows are shown
> >> maximized too. Where is my error ? What I have to do for correction
> >> this ?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 490 bytes
Desc: This is a digitally signed message part.
Url : http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110329/bde83126/attachment.bin
More information about the Qt-interest-old
mailing list