Hide/Show a window

There is a way to show within a program a Window iconified with
SDL_WM_IconifyWindow()?

I need to build a window that “popups/disappears” handled by an UDP
message, Win32 has an API to do so:

ShowWindow(hwnd, SW_SHOW / SW_HIDE);

I think that Iconify is the nearest thing I can do with SDL, and it’s
enough for what I need, provided I can display back the window when needed…

In the worst case I can rebuild the window every time, but this is also
tricky since there is no function call to free a window created with
SDL_SetVideoMode, I have to use SDL_Quit!

One idea is to place the window out of the screen I’ve seen that it can be
done but not in a portable way, so I think that if I cannot be portable I
can use the X and Win32 calls to hide/show the window :slight_smile:

Bye,
Gabry (gabrielegreco at tin.it)

There is a way to show within a program a Window iconified with
SDL_WM_IconifyWindow()?

I need to build a window that “popups/disappears” handled by an UDP
message, Win32 has an API to do so:

ShowWindow(hwnd, SW_SHOW / SW_HIDE);
I don’t know of any way to un-iconify the window either.

I think that Iconify is the nearest thing I can do with SDL, and it’s
enough for what I need, provided I can display back the window when needed…

In the worst case I can rebuild the window every time, but this is also
tricky since there is no function call to free a window created with
SDL_SetVideoMode, I have to use SDL_Quit!
I don’t know if it’s supposed to be legal, but you can just call
SDL_SetVideoMode again without quitting to reconstruct the window.

Failing that, you should be able to just stop the video subsystem,
rather than do an SDL_Quit

One idea is to place the window out of the screen I’ve seen that it can be
Please don’t do this. Ever.On Tue, 2002-04-30 at 12:46, Gabriele Greco wrote:

done but not in a portable way, so I think that if I cannot be portable I
can use the X and Win32 calls to hide/show the window :slight_smile:

Bye,
Gabry (gabrielegreco at tin.it)


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

End of Rant.

Jimmy
Jimmy’s World (http://www.jimmysworld.org)
-------------- next part --------------
A non-text attachment was scrubbed…
Name: not available
Type: application/pgp-signature
Size: 232 bytes
Desc: This is a digitally signed message part
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20020430/269f0be9/attachment.pgp

Gabriele Greco wrote:

There is a way to show within a program a Window iconified with
SDL_WM_IconifyWindow()?

I need to build a window that “popups/disappears” handled by an UDP
message, Win32 has an API to do so:

ShowWindow(hwnd, SW_SHOW / SW_HIDE);

I would like to see this too - along with support for creating and
destroying multiple windows with SDL. It has been discussed here
before (long time ago) - but I still haven’t had the time to
code it :slight_smile:

Does anyone know about the plans for multiple (and maybe even nested?)
windows in SDL? SDL 1.3? :slight_smile:

Cheers–
http://www.HardcoreProcessing.com

Gabriele Greco wrote:

There is a way to show within a program a Window iconified with
SDL_WM_IconifyWindow()?

I need to build a window that “popups/disappears” handled by an UDP
message, Win32 has an API to do so:

ShowWindow(hwnd, SW_SHOW / SW_HIDE);

You can do it in a platform dependent manner, by accessing the SDL
system dependent hooks in SDL_syswm.h
Take a look at the scrap demo for an example of using this API:
http://www.libsdl.org/projects/scrap/

Does anyone know about the plans for multiple (and maybe even nested?)
windows in SDL? SDL 1.3? :slight_smile:

The SDL 2.0 API will have multiple windows (but not nested windows), and
the plan is for you to be able to cleanly tell SDL what window you want it
to display to.

See ya,
-Sam Lantinga, Software Engineer, Blizzard Entertainment

Sam Lantinga wrote:

ShowWindow(hwnd, SW_SHOW / SW_HIDE);

You can do it in a platform dependent manner, by accessing the SDL
system dependent hooks in SDL_syswm.h
Take a look at the scrap demo for an example of using this API:
http://www.libsdl.org/projects/scrap/

This is a good example - I think this might even make it possible to
get DirectSound to work on Windows with SDL :slight_smile:

Does anyone know about the plans for multiple (and maybe even nested?)
windows in SDL? SDL 1.3? :slight_smile:

The SDL 2.0 API will have multiple windows (but not nested windows), and
the plan is for you to be able to cleanly tell SDL what window you want it
to display to.

Sounds great - thanks :slight_smile:

Cheers–
http://www.HardcoreProcessing.com