View this PageEdit this PageAttachments to this PageHistory of this PageHomeRecent ChangesSearch the SwikiHelp Guide
Hotspots: Admin Pages | Turn-in Site |
Current Links: Case Final Project Summer 2007

Sum02 Final Exam Review: drawingEditor

Edit Sum02 Final Exam Review: drawingEditor here.

You want to extend your drawing editor so that it can be used by radiologist to mark-up a chest x-ray. The radiologist wants to load
in a chest-xray and then add a shape (like a circle, polygon, etc) on an interesting spot in the x-ray. Then they want to annotate the
shape with a sound file that describes what is interesting about the shape. They might also want to annotate the shape with the
location and finding. Locations and findings can both have parents and children. For example a location is "Lungs". It has the parent
"Chest". It has the children "Left Lung" and "Right Lung".

well, the obvious is to add data fields to the shape object, so that all shapes drawn can store the sound file, the location, and the finding. a location can be an object, with the heirarchy as described above, with any attached information that goes with a location in the location object.

the next step is to create a new event, and the messages in the event handler that set up a recorder when an annotation is desired. something like pressing 'a' when a shape is selected, starts the recorder. alan fay

1. One tool that you are missing is a pen-like tool that will create a shape starting with the first mouse down and following the mouse until a mouse release. The shape will be a series of connected lines. How would your design change to add this tool?

well, that wasn't my interpretation of what was asked. however, i don't see why the design would have to change to add in the tool. wasn't the point to follow good OO to not have to change the design when new functionality is desired? the way our drawing editor was set up, all that is required to do this is to add a new button, a new shape, and a couple of event-handling messages to the program. alan fay

2. Redraw the UML diagram to add the new classes you will need.

not an ascii master, so i'll just say again a new command must be added: DrawingEditorPenCommand; a new shape: DrawingEditorFreeFormShape; and a couple of messages in the event-handler, something like penStillDown: evt and the like. alan fay

Link to this Page