Detect if application is running offscreen
-
Hi, for Qt applications you can pass
-platform offscreen
on the command line and it will start the program without a GUI.
How can I detect in my program, if it was started this way?QCommandLineParser
does not seem to "see" this passed option.@Magnus21
the platform plugin to load can also be set via env variable. in this case you wouldn't be able to catch it anyway using QCommandLineParser.QGuiApplication::platformName() reflects that though