PDA

View Full Version : how to disable the maximize button?



zabeehkhan
23rd October 2008, 16:56
Hi all,

I want to disable the maximize button in my pyqt4 main window.

I have created a main windows using the qt designer and want to disable the maximize button in it.

any example, tutorial, code will highly be appreciated..

zabeehkhan
23rd October 2008, 16:57
and of course I use python then for the functions, etc..

I meant I have created the UI using the qt designer..

spirit
23rd October 2008, 17:01
read more about window flags Qt::WindowFlags (http://doc.trolltech.com/4.4/qt.html#WindowType-enum)

spirit
23rd October 2008, 17:09
example on C++


...
setWindowFlags(windowFlags() ^ Qt::WindowMaximizeButtonHint);
...

netmat
14th April 2010, 08:26
Is it possible to remove any one of the maximize or minimize button(not just disabling) ?

I want to have only a close button and minimize button in my widget.
So far what I hv achieved is only disabling the maximize button. Can I hide/remove that completely?
The minimize and maximize button are comming as a pair always. Is there any way to get only one of them like close button?

Thanks and regards,
~netmat