Qt 标准对话框
Qt提供了一些可以复用的对话框类型,这些对话框类型全部继承与QDialo类。 Qt中标准对话框遵循相同的使用方法: //定义对话框对象 DialogType dlg(this); //设置对话框属性 dlg.setPrpertyXXX(value); if(dlg.exec() == DialogType::value) { //获取对话框数据 Type V = dlg.getDialogValue(); //处理对话框数据 //.... } Qt消息对话框:QMessageBox QMessageBox 中的实用函数。 void about ( QWidget * parent, const QString & title, const QString & text ) void aboutQt ( QWidget * parent, const QString & title = QString() ) StandardButton critical ( QWidget * parent, const QString & title, const QString & text, StandardButtons buttons = Ok, StandardButton defaultButton = NoButton )