Nov-02-2018, 03:05 PM
(Nov-02-2018, 02:57 PM)Gribouillis Wrote: From the point of view of OOP design, I'd say that there is a design problem if a class has too many attributes. It means that some of these attributes could be grouped together and form subojects aggregated to the initial object.
OOP is not one of my strong suits yet, and your response reminded me that I would like to address that as well. Is there a Python structure that is well suited to grouping attributes together? In my current code, I have a bunch of wx.StaticText, wx.TextCtrl, and sizers, among a few other widgets. I have yet to identify a design pattern (MVC, MVP, etc.) to follow which I realize is pretty important as the application grows larger. That said, can I group these widgets outside of a to-be-selected design pattern, or would the pattern itself achieve that in a more cohesive manner?