Jonathan wrote:

> I want to have all of my menu windows "inside" of the main window. I don't 
> want to have each menu window appearing in the taskbar and I don't really 
> need the whole window decoration (max./min./close buttons).

As Ian wrote already: don't use a window class then, use Fl_Group to derive 
your 
specific menu class, and add these to your main window.

>>> The first time I show a subwindow I have to use show twice...=20
>>> (if it works, don't touch it!). Could that be causing the trouble?
>> Yes.
>> That should not happen.
>> As a general tip, if something odd happens, try and figure out why.
>> Working round it probably masks all manner of nasty little bugs...
> 
> When I leave the subwindows as top level windows, I only need to call show() 
> once for them to pop-up. Why do I need to do it twice when they are added to 
> MainWin???

Without looking at the FLTK code, I can't tell exactly, but I think that 
subwindows are not really instantiated if their parent is not shown yet. Maybe 
you don't need to show() them twice, but can call redraw() instead on your main 
window to achieve the same (or resize the main window), but that's wild 
guessing 
now.

I really assume that you won't have any problems if you use Fl_Group to derive 
your menus. Using windows to embed in other windows is overkill (and may not 
perform as well, since subwindows are *real* windows for the system). Is it 
because of their coordinates (starting with 0) why you want to use windows 
instead of groups?

Albrecht
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to