Re: [AD] mac port of allegro

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


In message <20001210013133.A10556@xxxxxxxxxx>, George Foot writes:
>On Sat, Dec 09, 2000 at 08:44:36PM +0000, ronaldo hideki yamada wrote:
>> The stdclib in a mac redirect all printf() out to an file called stdout I
>> must to solve this?
>
>That doesn't matter.  printf output is discarded in graphics
>modes in DOS and Linux, and under X if you didn't run the
>program from the command line, and in Windows if the program
>doesn't have a console window.  Portable Allegro programs will
>use allegro_message before setting a graphics mode (which calls
>printf on most platforms, but brings up a message box on
>Windows), and their own graphics calls after setting a graphics
>mode.

Thinking about the win32 port than the Mac port:

I have a program which supports a few command line switches.  Ideally if
it's run from a "dos" window, I'd like the output of --help to go to that
window, but if it's passed a filename it should load and display that in a
directx window (or fullscreen).  I could put the whole --help output in a
message box, but it would look very odd.

Actually, it seems to me a better behaviour for allegro_message() would be
for it to output to the window the program was run from (if it was),
otherwise to use a message box.

I'm not a windows programmer, but I've been having a play with
AllocConsole() and related functions, but with no success so far.  My main
obstacle is that I don't have a windows box, and testing under wine doesn't
help.  So I need to keep sending programs to a friend with a windows box...

Is it actually possible to achieve what I want, and does anyone know how?

Cheers,
Olly



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/