From: Tom Sawyer Date: 2002-08-08T17:03:38+09:00 Subject: Re: [OT] GUI's and the Rouge, Part IV On Thu, 2002-08-08 at 01:26, Hal E. Fulton wrote: > If you're wanting to delay instantiating the widgets, I would > say you *might* replace the widget itself with (say) an array > that contained enough information to create that widget -- the > class and any parameters to new. > > abutton = [GUtopIa::Button, any, params, we, might, need] > awindow = GUtopIa::Window.new > awindow.body = [ [ abutton ] ] > > Code could easily tell that abutton was an array rather than a > widget, and later could do > > abutton = abutton[0].new(*abutton[1..-1]) # Now I'm a real button > > Just a crazy thought. Past my bedtime here. not a bad notion. could do all of them that way and only bring them in existence later. but i'd want to name the parameters ie.: abutton = { GUtopIa::Button, :any => any, :params => params, ... } awindow = { GUtopIa::Window, :body => [ [ abutton ] ] } i'll think on it. -- ~transami