Program #2 DishPan Jan 2008 - William T Krieger DishPan is my name for Program #2. It has a lot of letters in common with DrawableShapes, which I have yet to type correctly on the first try in over a week. There are 20 classes defined in DishPan: 1) There are 5 shape classes that all implement the ShapeInt interface. They encapsulate the the basics of each shape and statistics like area and perimeter: Circle, Rectangle, Square, RtTriangle, and RTree 2) There are 5 drawable shape classes that extend DrawableShape, one for each shape above: DrawableCircle, DrawableRectangle, DrawableSquare, DrawableTriangle, and DrawableRTree. 3) There are 3 basic classes from Chapter 3 for doing general-purpose shape stuff are the interface ShapeInt, and abstract classes Drawable and DrawableShape. I added methods to these to support my random stuff and also the factory() method allows me to support any number of DrawableShape sub-classes without modifying the DishPan panel or menu code. 4) There are 4 menu classes, all extending JMenu, that implement the GUI part of DishPan: FileMenu, AddMenu, RandomMenu, and RemoveMenu. 5) A lot of heavy lifting is done in DrawableShapesPanel. Most of the code to add random drawable shapes to the panel and remove them, etc is done there. 6) There is the main() in DishPan. 7) The applet version is in DishPanApplet. The program works pretty well, but it's not perfect. + It seems that sometimes removing objects isn't quite right. I haven't pinned it down yet though. + There is a lot of weak Javadoc documentation... some from the code that I snarfed from the textbook. + I should add the ability to add shapes of your designated size and location, rather than just random. + I'm sure the inheritance mechanisms to allow general shapes in Dishpan can be made cleaner. It works and that's cool. I think I could make it leaner and meaner with another shot at it. DishPan! thanks... yow, bill