那种格式的不需要专门去connect,
用的是另外一个函数,在ui_mainwindow.h这个文件中,
名字叫connectSlotsByName
详细说明:
void QMetaObject::connectSlotsByName ( QObject * object ) [static]
Searches recursively for all child objects of the given object, and connects matching signals from them to slots of object that follow the following form:
void on_<object name>_<signal name>(<signal parameters>);
Let's assume our object has a child object of type QPushButton with the object name button1. The slot to catch the button's clicked() signal would be: