[Solved]Automatic resize to fit the elements in a Dialog
I have a dialog that has some elements/controls that depending on some options gets some controls inside it to be visible or not. The problem is, when many items are invisible, the dialog looks empty, and one has to resize it (make it smaller), to make it look normal with no empty spaces in it.
I want to restore the Window size to what Qt would choose automatically to fit the elements inside the dialog. Is there such a call?
Thanks for any efforts :)
Are you using layouts?
I'd love to hear it if it's impossible!!! please, any clue?
Did you try to call something like this in the slot that shows/hides the optional parts:
Thanks a lot!!! @resize(minimumSizeHint());@ did it :)