Yes, that's basically correct. You have one MainWindow instance and one CTester instance, so this combination is a "single document interface" with a tiny "document".does it mean that I "invented" the "SDI" concept there, so my CTester class is a "document", correct? ... In that case, what I did there was a "tiny" minimal SDI application?
So in an MDI app, there are "multiple documents" which are often independent of each other. So, each QMdiSubWindow (a typical GUI element for an MDI app) would have its own "document" instance, in your case, its own CTester member variable. Each of these CTester instances are independent, so setting the parameter on one of them has no effect on any other instance.And another question is, what about the MDI then? Same thing?
Depending on the nature of your app, the MainWindow class might have its own "document" which keeps track of all of the other "documents" in the MDI windows. Think of a C++ project - each MDI window contains a source code file that is edited independently of the files in the other windows, but the MainWindow owns the C++ project to which all of the source files belong. An MDI window needs to be able to tell the main window that the document has changed, and the main window needs to tell the MDI windows to save their documents when the user clicks the "build" button.
Bookmarks