on the button click:
if shape button is pressed, set the shape to be drawn
if clear button is pressed, remove objects from vector and repaint
if undo button is pressed, remove last odject from vector and repaint
Drawing Board with controls allows to draw oval, rectangle, line and triangle
extends Applet
implements ActionListener for button controls,
implements ItemListener for choice boxes,
implements MouseMotionListener for rubber band drawing
implements MouseListener for finishing the drawing
when mouse is dragged:
if drawing a triangle and mouse has been released before,
call mouseMove event logic;
set the coordinates and call drawRubberBand
draw the rubberband shape for the triangle, by first erasing
the previous, as mouse moves, then save the previous points
for the redraw on the next pass