[Q][Morphic] Accept-drop property and re-layout

Hannes Hirzel hirzel at spw.unizh.ch
Fri Mar 8 17:44:24 UTC 2002


On Fri, 8 Mar 2002, Stéphane Rollandin wrote:

> At 23:03 07/03/02, you wrote:
> >When I drag out a character on the black pickup halo and later want to
> >put it back it will not 'snap into' its place and the other TextMorphs
> >will not reshuffle. I tried RectangleMorph and Morph as well.
> >
> >What am I missing?
> 
> 
> Your code works fine with me, and snapping back/reshuffling works ok.
> 
> 
> Stef
> 
> 
Thanks for verifying. I tried it again and find out what happened. 

- I blue-clicked on the 'o' of 'hello world'
- I grabbed the 'o' at the black pickup halo.
- I dragged it out onto the WorldMorph and released the mouse button.

- I picked it up again to put it back at the original spot.
- I dropped the 'o' when the shape of the 'o' was more or less precisely
  at the spot where it should be and released it.
--> The 'o' was there but did not snap in.

Correct way:
- The point of the mouse cursor (i.e. the black halo) is crucial in 
  deciding where the TextMorph is dropped. I was assuming that it
  is the center of the TextMorph, in this case of the 'o', which counts.
  If I point with the arrow of the mouse cursor at the target spot and
  then release the mouse button the TextMorph snaps in correctly and
  the other morphs reshuffle.


This expericence motivates me to further explore the possibilites of
composite morphs in using Squeak as a presentation system (let's even
call it an 'authoring system' for presentations)


Regards
Hannes Hirzel



P.S. May I ask you not to use the accent aigu in your 'from field'.
Unfortunately your name shows up as something like
    
     iso-8859-1?Q?St=E9phane?= Rollandin.

Within the body text it should not be necessary.




More information about the Squeak-dev mailing list