Re: stk::rectangle
Marc Strämke <[email protected]> Mon, 20 Oct 2003 12:01:04 +0200
| Newsgroups | gmane.comp.embedded.stk.gui.devel |
|---|---|
| Message-ID | <[email protected]> |
Dunno, my solution would be to make two rectangle classes, one for objects which provide a rectangle like interface (and this class should have an absolute minimum of virtual functions) And a second class which is non-virtual (POD!) for usage in rendering etc, this is basicly where the vfuncs slow us extremely down atm! Darren Vincent Hart wrote: > I am beginning to feel the same way. I had to wrap most of the rect > functions to add the on_resize signal anyway. Perhaps we should revert > to the "has a" model and remove all the virtual crap from rectangle. > Let's discuss this thoroughly before we make any changes to the source > though, this needs to be the last time we change how rects and widgets > relate. > > Darren > > On Sun, 2003-10-19 at 05:29, Marc Strämke wrote: > >>Hi team, >>I have just looked at the changes darren commited today, and have found >>out that rectangle contains virtual functions, do you guys really think >>thats good? Imo we should create rectangle_interface class or something >>to derive from, and not use the regular rectangle. These changes make >>rectangle easyli a few 100 bytes(!!!) Big, this is really not the right >>thing to do for an object which the user expects to be lightweight is >>it? Imo we only got two options, either we stop deriving from rectangle, >>or we create two rectangle classes, one which serves as an interface and >>from which you can derive, so it behaves like a rectangle but isnt one, >>but we really shouldnt continue with using a struct full of virtual >>functions everywhere in the code, this is a major source of bloat! >> >> >> >>_______________________________________________ >>Libstk mailing list >>Libstk@Óq«LD" >>http://www.dvhart.com/cgi-bin/mailman/listinfo/libstk > >