[UI] ToolBuilder
Igor Stasenko
siguctua at gmail.com
Wed Sep 12 17:32:26 UTC 2007
On 12/09/2007, Jason Johnson <jason.johnson.081 at gmail.com> wrote:
> Personally I think I would prefer to use a decorator pattern then
> Traits for this. The issue is that Traits can easily be accidentally
> used to implement multiple inheritance which is bad. This is not the
> only thing they can be used for, but I think what ever we build will
> be really important so it's best to not use such features unless we
> really do need it. Anyone reading OO books on building GUI's is going
> to be expecting decoration here, not Traits.
>
Yes, but decorations helps little with exposing interfaces.
Anyways, its a good idea.
Decorations will subtly change morphs hierarchy, but help to avoid
'delegation mess'.
Then, for example, a Workspace morph should be a text morph with
SystemWindow as topmost decoration.
And hierarchy changed from:
world->systemWindow->ScrollPane->workspace
to simply:
world->workspace
(while workspace looking back to its decoration: <- ScrollPane <-
SystemWindow in bottop-top order)
Interesting, what if we put in use decorations then? Do we have a
potential for support such thing in current morphic model?
--
Best regards,
Igor Stasenko AKA sig.
More information about the UI
mailing list