int main(int argc, char *argv[]) { QApplication a(argc, argv); GeneratorWindow w; w.show(); // packageInfo info = plugLibInfo("/home/elessar/qutim/plugins/libyandexnarod.so").toInfo(); // info.properties["version"] = "0.1.0"; // QDir dir("/home/elessar/qutim"); // QZipWriter writer("test.zip"); // { // QByteArray data = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"; // data.append(info.toString().toUtf8()); // writer.addFile("Pinfo.xml", data); // } // foreach(const QString filepath, info.files) // { // QFile file(dir.filePath(filepath)); // if(file.open(QIODevice::ReadOnly)) // writer.addFile(filepath, &file); // } // writer.close(); // qDebug() << info.toString(); return a.exec(); }
int main(int argc, char** argv) { try { QApplication app(argc, argv); GeneratorWindow myWindow; QScreen* screen = app.primaryScreen(); QRect rec = screen->geometry(); myWindow.resize(rec.size().width(), rec.size().height() - 100); myWindow.show(); return app.exec(); } catch (std::exception& e) { std::cout << e.what() << std::endl; } return -1; }