AFAIK it's impossible in Windows (but I can mistake
, as GUI applications do not have stdout opend by default, so to make thing like you described one at least need to write library and link it to all GUI application, while not touching non-GUI ones.
Moreover even if such library became written it might do tricky and non-portable think to init itself...
PS. I didn't want to say that it's impossible at all
, but that's very hard to implement in portable (as C::B is portable) way
May be you are looking for wxLog (er, not shure about name) and friends?