[Newbies] Manipulation of existing objects

Marcus Strehlow marcus.strehlow at gmail.com
Sun Jan 6 20:53:03 UTC 2008


Hi all,

I am fairly new to Squeak, and so far I have figured out the syntax  
and everything, I do understand the basics. However, I am stuck on one  
particular thing - manipulation of objects that have been created, and  
are now in a World. I think the easiest example of what I mean is by  
the following. Assume for a moment I have created a simple  
RectangleMorph in the World, in this case with a specific parameter,  
the color. The code for this would work out as:

| 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?


Thanks for your help,

Marcus





More information about the Beginners mailing list