Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Dynamic layouts in Qt
chihwah last edited by
I have been working on creating dynamic layouts (responds to user selections) for user inputs and writing the output of that to MySql.
The problem is that every time I change something about my code (i.e. add a new widget to contain my input widgets or change something about the layout), I have to rewrite my functionality to incorporate that change, as it is quite custom. For example, I have undo and redo buttons that function differently for different types of widget types that I've subclassed, and different inputs write to different columns in SQL.
I've been managing it based on finding specific object names within my layout so far. It's hard because a specific widget can be nested within multiple widgets.
If anyone else has worked on projects with dynamic layouts before, I would appreciate some tips or advice on what I could be doing better and what has worked for you.