Help with SketchMorphs...

Joshua 'Schwa' Gargus schwa at cc.gatech.edu
Thu Aug 2 12:53:56 UTC 2001


Hi Kyle,

On Wed, Aug 01, 2001 at 08:56:11PM -0000, Henry.Bygott at Colorado.EDU wrote:
> Is there some way I can set up a sketchMorph so that I can change its
> (or even better yet, parts of it's) color with a simple command from 
> within my code?  A way to run replace color without the prompts, or 
> just a plain color: method?  THanks
>     Kyle


There are several ways to do this.  One is to change the form
displayed by the SketchMorph (aSketchMorph form: Form fromUser).
Another is to manipulate the form directly (aSketchMorph form
replaceColor: Color yellow withColor: Color red).  Look at Form's
instance methods for some of the other manipulations you can do.

> 
> PS- I'm not entirely sure this is the best place to be posting this 
> question - is there a more general forum anybody knows of that would 
> be better suited to this type of inquiry?

This is the correct place to ask these sorts of questions.

Joshua




More information about the Squeak-dev mailing list