[Qt-interest] my QMdiArea subwindows are not working properly

River Tarnell river at loreley.flyingparchment.org.uk
Wed Dec 10 23:32:18 CET 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

hi,

so i have the following curious problem when i run my program on Windows XP,
using Qt 4.4.3 (open source version).  i don't see this behaviour on Linux,
also using 4.4.3.

the problem is this: when i create several subwindows, it's impossible to
switch between them.  in windowed mode, clicking on a subwindow gives it focus,
but doesn't bring it to the front (the previously selected window stays at the
front).  in tabbed mode, clicking on each tab header selects that tab, but
doesn't change the subwindow being displayed (again, the previously displayed
subwindow remains).

i assume there's something i'm doing wrong to cause this - but what could it
be?

my main window was created in Designer.  other than adding actions to the
toolbar and menu, i don't change anything.  i add new subwindows like this:

	QTermWidget *term = new QTermWidget(s);
	QMdiSubWindow *win = ui.mdiArea->addSubWindow(term);
	win->setWindowTitle(name);
	win->showMaximized();
	term->show();
	term->run();

(QTermWidget is a custom widget derived from QWidget).

thanks,
river.
-----BEGIN PGP SIGNATURE-----

iD8DBQFJQENyIXd7fCuc5vIRAn6AAJ9C8yhzbFHkGEbdF1wSsmGLvhfguQCgmvsr
+3gO82MFQXomhjnRtIrb7Og=
=v38s
-----END PGP SIGNATURE-----



More information about the Qt-interest-old mailing list