41int main(
int argc,
char* argv[]) {
49 auto gui = gopts->getSwitch(
"gui");
50 auto timeout = gopts->getScalarDouble(
"tt");
52 int ret = EXIT_SUCCESS;
54 log->info(0,
"Starting gsplash example...");
57 QApplication* app =
nullptr;
58 QMainWindow* window =
nullptr;
61 log->info(0,
"g4dialog",
"Running in GUI mode...");
64 app =
new QApplication(argc, argv);
65 window =
new QMainWindow();
66 window->setWindowTitle(QString::fromUtf8(
"displayUI example"));
72 gsplash->message(
"Some text I want to show");
73 gsplash->messageAfter(500,
"Some other text I want to show");
79 QTimer::singleShot(timeout + 500, [] {
80 QCoreApplication::quit();
83 ret = QApplication::exec();
92 log->info(0,
"Running gsplash in command line mode...");
static std::unique_ptr< GSplash > create(const std::shared_ptr< GOptions > &gopts, const std::string &imageName="gemcArchitecture")
Factory method for creating a GSplash instance.