On 25 Aug 2012, at 20:40, Marc Cunning wrote: > Hi, > I need to create dynamically (at run-time with callbacks) widget groups, > but when adding buttons and sub-windows in the same group, > the buttons are shown ok, but the window not. What's wrong here..? > Below, Using the program example provided by greg, with an little variant, > to sample this question. > Any idea..?
A few things to think about: - Why are you even using nested windows? In fltk that is seldom necessary - most of the same functionality can be got from nested groups more simply. (Also, nesting windows does not always work as well as I'd like across platforms anyway, they don't necessarily all do quite the same things... so nested groups are more reliable.) I'd suggest you look closely at what you are trying to achieve on the display; the apparent need for sub-windows may be illusory, and the code would be simpler without them. - You need to be very careful with the coordinates to make sure the sub-windows will be correctly positioned within their parent to be visible. - You probably need to explicitly call show() on the sub-windows to ensure they get mapped onto the screen. OK, I didn't *actually* try running your code, so this is all speculation - but give these ideas a whirl, see if that helps at all. Cheers, -- Ian _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

