Re: sanity check: deriving from Gtk::Range



On Wed, 2008-07-09 at 21:05 -0500, Joaquim Schmidlap wrote:
> I need to create a Dial type widget, the standard speedometer sort of  
> thing. I looked around for something open source that would work but  
> came up dry, so I'm resigned to building my own.
> 
> It seems like the right thing to do would be to derive from Range. 

control/view components of an MVC system typically use a HAVE-A
relationship with the model part. 

in this case, your "dial" would HAVE-A Range, not use IS-A Range. in
real life that typically means a Gtk::Range* or Gtk::Range&

--p




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]