Instance-based Programming

Steve Wart thecows at
Fri Jun 29 07:16:33 UTC 2001

I would like to create a simple UI in Squeak. Say (for example) a nice
little dialog for filtering messages in Celeste.

It seems like I should be able to paint a window with fields and
buttons, etc., and script it up using the Viewer.

When I do this, do I need to create a class to hang onto these methods?
What are the issues with just keeping the instance around and giving it
a global name? It seems easier to create an E-toy, give it a name, and
then activate that E-toy from within a regular button. I don't really
like the idea of a large number of globally scoped instances, but it's
probably not practically any different than having a large number of
globally scoped classes.

Will this cause problems, for example, with change sets? Can I browse
versions on scripts they way I can with methods on classes? Adding this
would be nice. I found that I have a tendency to obliterate big chunks
of methods using the SyntaxMorph, and versioning is like a rich person's
undo :-)


More information about the Squeak-dev mailing list