Click to See Complete Forum and Search --> : GUI that is not a Dialog


Shaun
April 3rd, 1999, 12:10 AM
How do you have a program's GUI not be the typical dialog etc. Programs such as Sonique and Winamp use a graphic for interaction. Is this possible with Visual C++

Thanks

April 3rd, 1999, 07:38 AM
I believe the way to create an irregular shaped window is to use CreatePolygonRgn to create a region that is the same shape as your bitmap. Then you would use SetWindowRgn to make the window that size and shape. You would do all this in the window's OnInitDialog. There may be other ways.

Hope this helps,
Gary Kirkham

April 3rd, 1999, 01:44 PM
Yes, I did this once. But you have to be careful how you do this.

The window still considers itself to be a rectangle, the poly region thing really just cuts chunks off the dialog. The cut edge won't have the nice edge that regular windows have.

Also, if you cut off the title bar, you won't have anything to move the window with! You'll have to override some functions to allow dragging.