PyQt5 – Set fixed length for width/height of Status Bar
When window is resized status bar also get resized although we can set a fix size of status bar by using
setFixedSize method with object of status bar. In this article we will see how we can only fix the length of wither width or height i.e other side would be variable.
In order to fix length of width we use
setFixedWidth with object of status bar and to fix length of height we use
setFixedHeight with object of status bar.
Syntax :self.statusBar().setFixedHeight(height) self.statusBar().setFixedWidth(width)
Argument : Both methods take integer as argument.
Action performed :
setFixedHeightfix the height of status bar.
setFixedWidthfix the width of status bar.