PDA

View Full Version : How to create a top-level widget without taskbar entry but with maximize button?



Alex_123
13th January 2009, 14:48
The problem is that QDialog in Qt4 has no maximize button and I don't know how to add one. Thanks in advance.

P.S. Mostly I'm going to use it on x11 and Mac.

jpn
13th January 2009, 15:07
See Window Flags Example.

spirit
13th January 2009, 15:12
an example


...
QProgressDialog pd("sdfsdf", "sdfsdf", 0, 100, this);
pd.setWindowFlags(pd.windowFlags() | Qt::WindowMaximizeButtonHint);
pd.exec();
...

PS. look at QTDIR/examples/widgets/windowflags

Alex_123
13th January 2009, 15:28
It might be caused by x11 but window hints does not work at all in the windowflags example. Simply a dialog has no minimize and maximize buttons; but a window has them.

Alex_123
13th January 2009, 15:32
Seems like there's no window type flag, except Qt::Window, that allows minimize and maximize btns.