submorphs overlapping

Lex Spoon lex at
Thu May 26 01:52:33 UTC 2005

=?iso-8859-1?b?RnJhbudvaXM=?= THIMON <thimof at> wrote:
> Hi,
> I'd like to now how it was possible to draw the submorphs UNDER their owner
> instead of drawing them ABOVE it.

Todd pointed in the direction of doing this, but it sounds like doing
this literally might cause some oddities.  For example, mouse events
might get routed to strange places -- a user could *think* they were
clicking on morph M but the event gets sent to one of M's submorphs.  M
is drawn with the submorphs behind it, but the event-routing logic will
treat them as if they are in front.  Likewise for drag-and-drop and

If you are doing some kind of experiment then that kind of things don't
matter.  If you are trying to make a really robust program, though, I
would be tempted to play it safe and use an extra submorph to achieve
the same visual effect.  Simply have the in-front stuff be another
submorph that is in front of all the other submorphs.  This way puts
less stress on the Morphic machinery, and increases the chances that you
will not have to fix up multiple pieces of morphic in order to keep your
morph acting sane.  Leave the beast asleep, and let someone else go
monkey with it.  :>

All this said, if it really is some research project, e.g. you are
experimenting with alternative graphics frameworks, then ignore me and
enjoy the exploration!


More information about the Squeak-dev mailing list