Re: [HIGH] STR #3238: Fl_Group::clear method should be virtual
Albrecht Schlosser
Dec 05, 2021
DO NOT REPLY TO THIS MESSAGE. INSTEAD, POST ANY RESPONSES TO THE LINK BELOW.
[STR New]
Link: https://www.fltk.org/str.php?L3238
Version: 1.4-feature
Unfortunately this issue can't be resolved easily (or maybe not at all) by
making some of the methods of Fl_Group virtual. These methods can't be made
virtual because:
(a) many overloaded methods with the same names but different semantics
exist in derived classes in the FLTK core
(b) we can't change these methods because user code may have used and
overridden them in their own derived classes.
I've been thinking about adding some new methods with other names to
achieve some of the desirable goals but this is not a trivial design
change. :-(
Methods that can't be made virtual include [Fl_Group::] clear, remove, add,
insert, ...
Link: https://www.fltk.org/str.php?L3238
Version: 1.4-feature
Comments are owned by the poster. All other content is copyright 1998-2025 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.