[Newbies] Manipulation of existing objects

Enno Schwass onkelenno at mac.com
Sun Jan 6 21:05:45 UTC 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi

> | rectangle |
> rectangle := RectangleMorph new openInWorld.
> rectangle color: Color white.
>
> Now, that the object is created in the World, how do I change its  
> properties while it exists? How would one change the color of the  
> RectangleMorph in this example, while it is on screen? Since  
> everything is an object, and objects can receive messages, I do  
> believe this to be possible, correct?

Just send messages to your reference (rectangle).

You did this in line 2

rectangle color: Color white.

You can send other messages like

rectangle useRoundedCorners.

If you dont have a reference to your morph, open a workspace, select  
in its menu

"create textual references to dropped morphs"

then drag and drop your morph into your workspace. Use the printed  
reference to send messages to.

Hope this helps
Enno
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (Darwin)

iD8DBQFHgUKpRar8+mLBvIcRAiEzAJ0SapyszXWsgQGKJB73igEQHHfrmQCfR2pG
4rb15n30jFTDOAj+BkMLQfM=
=UynF
-----END PGP SIGNATURE-----


More information about the Beginners mailing list