报错:tr was not declared in this scope 报错代码如下: label->setText(tr("您好,Qt5.5.0!")); 修改为: label->setText(QObject::tr("您好,Qt5.5.0!"));