When we create a window, by default, it is resizable but with the help of
setFixedSize() method we can fix the size of window. But what if we want to resize the window up-to some extent; in order to do this, we have to set the maximum size of the window. We will use
Syntax : self.setMaximumSize(width, height)
Argument : It takes two argument both integer i.e width and height.
Action performed : It set the maximum size of window.
- PyQt5 – Set maximum size for width or height of window
- PyQt5 – How to set minimum size of window | setMinimumSize method
- PyQt5 – Set fix window size for height or width
- PyQt5 – Set minimum window size | setMinimumWidth and setMinimumHeight method
- PyQt5 - How to adjust size of ComboBox according to the items size
- PyQt5 - Set maximum size of status bar
- Set title of window in PyQt5 - setWindowTitle
- How to set icon to a window in PyQt5 ?
- Set Window Icon Text in PyQt5 | setWindowIconText() method
- PyQt5 – Set status bar message in window
- Python | Window size Adjustment in Kivy
- wxPython - Get size of Radio Button Window
- PyQt5 QCalendarWidget - Setting Maximum Size
- PyQt5 QCalendarWidget - Getting Maximum Size
- PyQt5 QLabel - Checking if the opacity effect is window type
- PyQt5 - How to add image in window ?
- PyQt5 – How to change background color of Main window ?
- PyQt5 – How to hide the title bar of window ?
- PyQt5 - How to create semi transparent window ?
- PyQt5 - Get opacity level of the main window | windowOpacity() method
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.