Project 2: Smalltalk Morphic application

Due:
Thu 4 Mar 2004 (proposal)
Fri 12 Mar 2004 (main submission)
Mon 15 Mar 2004 (wiki page)

Description

This project should be done in groups of two or three. Proportionately more work will be expected of a group of three.

For this project, you must develop an interactive application using Squeak and Morphic. You have considerable latitude in determining what (and how much) to write; this is intended to be an opportunity for you to program something fun. Along the way you should get to know Smalltalk and Morphic (and GUI programming more generally) a little better.

This project has the following steps:

  1. Name your group.
  2. Schedule a presentation meeting.
  3. Write a project proposal.
  4. Implement your project.
  5. Produce a wiki page documenting your project.

We describe these steps in more detail below.

  1. Choose a unique name for your group that fits in the Smalltalk naming convention for class categories (InitialCaps).

    All your classes for this project should be written in the class category Morphic-04Wi-YourGroupName. Choose something that you think nobody else will choose, because you will be creating page on the wiki for your group later.

  2. Schedule a meeting with Keunwoo to present your project, using the web tool at the following links:

    Presentations will be in one of the undergraduate labs in the CSE building. Your entire group must be present. If you cannot make any of the available times, email Keunwoo and schedule a separate meeting time.

  3. Write a project proposal, which must contain the following:

    1. A one- or two-paragraph summary of what you intend to implement for your project. You must describe why your project makes good use of Smalltalk --- i.e., where does your project use inheritance and object-oriented design principles? You could also describe the user interaction, and maybe sketch the visual appearance of your project.
    2. A class hierarchy diagram describing the main classes in your project, and their inheritance relationships.
  4. Implement your project and submit it. Your implementation must satisfy the requirements listed below under "code requirements". Your submission must include the following:

    1. a hard copy of a fileOut of your sources.
    2. A README file containing your group members' names, and instructions for running your project and a description of your project design. The latter of these should be an updated version of what you wrote for your project proposal.
    3. electronic copy of your fileOut.
    4. A zip or tar.gz archive containing any external resources that need to be imported into the Squeak image in order for your project to work.

    As an alternative to items #3-4, you can instead export a "Squeaklet" that contains a complete Morphic project. To do this, enter your Morphic project and use the World menu's Save project on file... menu option. Squeak will gather up the resources used by this project and export them to a .pr file in the Squeaklets subdirectory under the Squeak installation. This projects file can then be opened up in any compatible Squeak image!

    If you choose to go the Squeaklet route for submission, then you should set up your project so that, upon opening the project, the user can immediately dive in and begin playing with your application:

    Use the sample projects inside the "Worlds of Squeak" as examples of how you could set up your Squeaklet.

  5. Produce a page on the course wiki documenting your project. Put a link to your group's page on the project list page. This page must include the following:
    1. At least one screen shot of your project in action. (In order to save space and make the page more readable, please crop your screen shot to show only the portion of the screen containing your application.)
    2. A link to your source code fileOut.
    3. An English description of your project, and how to run it.

    For items 1-2, you should use the wiki's file upload functionality (see the "Upload file" link in the wiki sidebar).

    If you decide to make a Squeaklet, you can also upload the Squeaklet, or put the Squeaklet on your CSE home page with an external link from your project's wiki page. (You will probably have to do the latter, because the wiki has a 2MB maximum limit on the size of an individual uploaded file.)

Code requirements

  1. Some part of your application, at some point, must override handling of user input from the mouse, the keyboard, or both.
  2. At least one of your Morph subclasses must have a customized appearance (i.e., must override the drawOn: method).
  3. Your Morph hierarchy must be at least three levels deep, not counting inheritance from Morph or Object. In other words, there must be at least one class defined by you that has a subclass that in turn has a subclass.
  4. You must use at least one super send somewhere in your project.
  5. Every class must have a class comment describing its purpose.
  6. Your code must run cleanly on a stock, freshly-downloaded Squeak 3.6 image. Test your fileOut or Squeaklet on a fresh image to make sure it works!

Due dates

Optional starter code

Morphic-CSE341-Sim.st is some optional starter code. You may use this code as a base for your application, or you may ignore it completely. Either way, you may find it worthwhile to fileIn this code and browse through the code in the Morphic-CSE341-Sim class category --- it shows you how to do useful things like

I have tried to comment the code extensively. If I have time to play around with this more, then I may add more functionality and comments. ~k