Re: [fpc-devel] Dynamic GUI/Console apptype

2009-12-26 Thread Henry Vermaak
2009/12/27 Mimu Bunnylin m...@mooncore.eu: Currently, programs for Windows have to be specified as either $APPTYPE Console or GUI. If the user runs a console-mode program from a console, the existing console is kept; run outside a console, a new console is created. If the user runs a

Re: [fpc-devel] Dynamic GUI/Console apptype

2009-12-26 Thread Henry Vermaak
So, basically, make a GUI-mode application, let FPC release the console during its normal startup initialisations, then detect that the parent process was a console, and recapture the console... This could work, You will also have to pause the execution of the terminal, since otherwise it will

Re: [fpc-devel] Dynamic GUI/Console apptype

2009-12-26 Thread Michalis Kamburelis
Mimu Bunnylin wrote: But suppose I want a program that will continue running in a console if run from a console, but will not automatically create a new one if run from outside a console. You can declare a program as $apptype GUI, and then try using standard file handles. If this succeeds,