manolo gouy wrote: > In our case (printing), aren't we interested only in shown() > windows?
I wouldn't say so. At least this is an unecessary restriction. You can have all sorts of windows just created in memory, e.g. tool windows etc., and maybe you want to print them for some reason. OTOH, the "shown()" problem only applies to subwindows, so this could be a minor issue... [ my proposal of ...] >> >> virtual int Fl_Widget::is_group() ... > It's because traversing the widget tree is impossible that I had > to find this other trick. So this is_group() method would be quite > useful. Alternatively, setting a type FL_GROUP = FL_WINDOW-1 > in the Fl_Group constructor might suffice, may be. > Fl_Widget::is_group() would become this->type() >= FL_GROUP Well, I have to say: sorry, but NO. That opens a can of worms, because type() is used in Fl_Group (derived) widgets for other reasons, e.g. the scrollbar visibility in Fl_Scroll, the type of browser in Fl_Browser, and many more. Not to talk about the compatibility troubles if someone used type() in his own widgets and we change it now... "They" ;-) tried it in FLTK 2, but there are problems, for instance: http://www.fltk.org/str.php?L1915 Although there is a possible solution, I wouldn't like to go that route. The proposed virtual method, however, is trivial. Albrecht _______________________________________________ fltk-dev mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk-dev
