Re: State, Attributes and Some basic widgets

Glynn Clements <[email protected]>
Newsgroups gmane.comp.lang.haskell.gui
Message-ID <[email protected]>
Axel Simon wrote:

> I see three strands of modelling widget hierarchies in Haskell:
> 
> 1.) Don't. Each widget has an individual type, unconnected to the other 
> widgets. (Glynn's ponit of view, if I am not mistaken)

No; my view is *not* to have distinct Haskell types for each widget
class. I should be able to replace any widget by a "compatible" widget
(e.g. a subclass) without having to change all of the code which uses
that widget.

Either have a single generic Widget type (with type checks deferred to
run time), or use type classes.

-- 
Glynn Clements <[email protected]>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.