Home > Back-end >  Qt's own translation files qt_zh_CN. Qm failure
Qt's own translation files qt_zh_CN. Qm failure

Time:03-14

Why load qt's own translation files qt_zh_CN. Qm failure: clearly file is right

QTranslator the translator;
Bool ok=the translator. The load (" :/qm/0 ");
QFileInfo file (" :/qm/0 ");
QDebug () & lt; if (! Ok)
{
QDebug () & lt; & lt;" File not loaded ";
}
The output is
True
File not load
Among them ":/qm/0" is the byname of resource file

CodePudding user response:

 QTranslator the translator; 
The translator. The load (" :/res/language/WMagicMediaPlus_zh_CN qm ");
Anderson nstallTranslator (& amp; The translator);
  • Related