#include <QtGui/QApplication>
#include "mainwindow.h"
#include<QFileInfo>
#include<QTextCodec>
#include <QtDebug>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
MainWindow w;
w.show();
QTextCodec::setCodecForTr(QTextCodec::codecForLocale());
QFile file("a.txt");
if(!file.open(QIODevice::WriteOnly|QIODevice::Text|QIODevice::Append))//最后一个是追加写入
qDebug()<<"错误";
file.write("hello qt \nhand some\n");//换行\n
file.write("hehe");
file.close();
return a.exec();
}
TRANSLATIONS = info.ts
lupdate hello.pro