OS/2, eCS & ArcaOS - Technical > Programming

Writing on console with WINDOWAPI

(1/2) > >>

Jochen Schäfer:
Hi.

Does someone know a way to write on the console if the application is of type WINDOWAPI?
For my Featherpad port, I have the problem, that the help text emitted with -h on console doesn't show up, but seems to be captured with the console redirection.
Any ideas?

Andi B.:
Compiling as console app which morphs itself to a winowing one at startup? There a a lot of apps which do that. Most probably an edm2 article too. Do you know about that or should I try to search for examples?

Edit: http://www.edm2.com/index.php/Dangers_with_morphing
http://www.edm2.com/index.php/Porting_SDL_applications_to_OS/2

Jochen Schäfer:
Yes, I know the trick and it seems that Qt5 itself does this, but if you start the application from WPS, you get a flashing shell. I want to avoid that.

Rich Walsh:
"featherpad 2>&1 | tee"  (using GNU tee)
or
"featherpad!s" (using Run!)

Dave Yeo:
Firefox does it by creating a console window, try doing x:\programs\firefox\firefox -help.
Probably not worth tracing down where the code to do that is as you just end up with a finished console window.

Navigation

[0] Message Index

[#] Next page

Go to full version