How to change the width of QDialogbox with the click of a button
Unsolved
General and Desktop
-
This is my QDialog
as of now the width of the QDialog is 1000, on right side the QListwidget covers 500 width, when i click the button "Show/Hide" , i should be able to change the width of QDialog frm 1000 to 500 (such that i am able to hide the QListwidget) and vice versa,i guess i would have to use setFixedWidth(int w) function, but kinda confused how would i do it to change the QDialog size
-
First of all, it seems that you don't use any layouts.
Secondly, don't hide your widget by just resizing your dialog (if you are trying to do that). Better hide the widget itself.To set a width anyway, you can use
QWidget::resize(int w, int h)