View this PageEdit this PageUploads to this PageVersions of this PageHomeRecent ChangesSearchHelp Guide

notes-4-13

Prof. Pitt reported on the UIUC First Annual Celebration of Women in Computing, and in particular the Squeak workshop for mostly middle-school aged girls. He demonstrated a couple of projects that had been done. Most of the girls spent time getting comfortable with the drawing and scripting environments, and implement a simple script involving motion.

Students demonstrated Squeak-educational projects most aimed at getting squeaklearners familiar with basic ideas of properties, variables, and simple scripting, including tests.

Themes that arose from student and professor feedback:

  • Projects need to proceed slowly, step-by-step.
  • Screen shots and intermediate checkpoints help a lot.
  • Projects should clearly articulate (1) what the prerequisites are (in terms of squeak knowledge, and/or other background knowledge) for the project.
  • Projects should describe what the main skills to be learned are, both in terms of squeak constructs, as well as general principles.

Prompted by a question about keeping a log of x,y values as a car is driven, for later analysis, some time was spent determining whether there is a simple method to record information as text during pogram execution. The solution was neither complex nor pretty (nor easy to find):

  • The "text" object (not scrolling text) has a "cursor" variable, and a script primitive to allow insertion before the cursor. (To insert at the end, you need to pad the text with a blank.)
  • Thus, inserting text is easily done via setting the text's cursor to text's "count" or "numberof characters" (or whatever variable tracks the size of the string), and then doing a textinsertchars command (anothre method that comes with the text object
  • To insert a number however, is trickier, since you can't drop a number or variable representing one onto the tile representing the characters to be added to the test... the data type is incorrect. To fix this, you need to trick Squeak into doing the data coercion for you by using another text variable (say textnum), and telling it change its numeric value to the variable of interest. This has the effect of inserting the text version of the variable into the text object textnum. Then, you can insert textnum into the larger textbox created (at the end).
  • This underscores the need for a simple object that acts as a read/write text window, and does automatic data coercion (or has mehtods availabile for it).