Widgets disabled from startup: disabling in Qt Designer or in code?



  • Greetings.

    I have made several applications which use QtDesigner to create the corresponding Graphical User Interface.

    My question on this matter is simple, however that may not have a unique and precise answer, I wonder what is most recommended.

    When some GUI widgets should be disabled at startup: Is it better to establish disabling directly on the QtDesigner form or is best done in code (as in a class constructor, for example)?

    This question could be generalized to cover the initial settings of the widgets (not only the state enabled/disabled).

    Thanks in advance for any help and / or suggestions.



  • HI,

    using QT Designer is easier but less flexible; if you want reuse the same UI for different widgets I suggest to create a method/slot that applies your settings according your rules.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.