报错:tr was not declared in this scope

报错代码如下:

label->setText(tr("您好,Qt5.5.0!"));

修改为:

 label->setText(QObject::tr("您好,Qt5.5.0!"));

原文地址:https://www.cnblogs.com/yshyee/p/4749663.html