V
oh das mit dem automatischen Verbindung wusste ich bisher nicht - in dem Fall ist es natürlich Unsinn in einer Namenskonvention on_ für nicht automatisch Verbundene Slots festzulegen
Für alle, die nicht wissen wovon wir reden:
setupUi calls connectSlotsByName. connectSlotsByName parses the moc_ file in order to connect slots and signals. The moc_ file contains a list of all the slots for the class. The parser iterates over the list of slot names looking for the following pattern: on_objectName_signal, where on_objectName_signal is the name of the slot, objectName is the object name and signal is the signal. For example, if you have a slot named, on_doneButton_clicked(), the parser looks for an object named doneButton, a signal named clicked and then connects the on_doneButton_clicked() slot to QButton’s signal clicked().
If you follow this naming convention, you do not need to call the connect() method, nor do you need to connect the signal via the Qt UI editor in VisualStudio. connectSlotsByName will automatically make the connection for you.