Connect the Dots
|
ASSIGNMENT:
Make the following alterations to the sample program:
- Create a canvas space 200x200
- Create two fixed points to represent the lower two vertices of a
triangle. One should be at 20,180 and the other at 180,180.
- When the mouse is clicked a third point will move to the location of the
click and lines will be drawn between the three points, forming a
triangle.
- Near each vertex will be a number with a degree sign after it
representing the angle of the vertex.
- The third point must be at least 20 units from the edge of the
canvas area.
|