正常状态消息 - 除非显示临时消息,否则这些消息始终由应用程序显示。这就是我对正常状态信息的了解。因此,使用这些代码对我的构造Qt正常状态栏在临时状态后不显示
ui.statusbar->showMessage("Temp message", 3000); // ui is the Ui::AutoGenHeaderForForm
QLabel *label = new QLabel;
ui.statusBar->addWidget(label);
label->setText("hello world");
我得到的是,当我运行项目中,我得到了状态临时消息,持续3秒。然后我没有拿到hello world回来。如果hello world在3秒后自动出现在的位置温度讯息?
其实我想要没有QStatusBar :: addPermanentWidget。 – Dewsworld 2012-03-13 16:30:23