[Qt-interest] stdout of MSWin GUI application run from console
Graeme Gill
graeme2 at argyllcms.com
Wed Apr 13 17:44:10 CEST 2011
Paul Miller wrote:
> Graeme - I must apologize I thought you were asking how to do it. I've
> seen code like what you've posted there but never got it to work
> reliably. How do you know when your program is launched from a console
> versus the UI/Explorer?
The idea is not to have to care - it's the same application
whether run as a pure GUI or from a console. It erases the
MSWin distinction between GUI and console application (just
as in Linux/X11 etc.)
It's compiled as a "GUI" application, but if it's launched from a
console, then the parent process will have a console, so the stdio
etc. can be re-attached. This wasn't possible on Win2k, but
is on XP and latter.
Graeme Gill.
More information about the Qt-interest-old
mailing list