2 * \file ConsoleApplicationPrivate.h
3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
8 * Full author contact details are available in file CREDITS.
11 #ifndef CONSOPLEAPPLICATIONPRIVATE_H
12 #define CONSOPLEAPPLICATIONPRIVATE_H
14 #include "support/qstring_helpers.h"
16 #include <QCoreApplication>
27 class ConsoleApplication;
29 class ConsoleApplicationPrivate : public QCoreApplication
33 ConsoleApplicationPrivate(ConsoleApplication * owner,
34 std::string const & app, int & argc, char ** argv)
35 : QCoreApplication(argc, argv), owner_(owner)
37 setOrganizationName("LyX");
38 setOrganizationDomain("lyx.org");
39 setApplicationName(toqstr(app));
41 qsrand(QDateTime::currentDateTime().toTime_t());
45 // set timer to do the work asynchronously after the event
47 QTimer::singleShot(0, this, SLOT(doExec()));
57 ConsoleApplication * owner_;
61 } // namespace support
64 #endif // CONSOPLEAPPLICATIONPRIVATE_H