February 2014
Beginner
1248 pages
62h 25m
English
12.17 (Interactive Drawing Application) In this exercise, you’ll implement a GUI application that uses the MyShape hierarchy from GUI and Graphics Case Study Exercise 10.2 to create an interactive drawing application. You’ll create two classes for the GUI and provide a test class that launches the application. The classes of the MyShape hierarchy require no additional changes.
The first class to create is a subclass of JPanel called DrawPanel, which represents the area on which the user draws the shapes. Class DrawPanel should have the following instance variables:
a) An array shapes of type MyShape that will store all the shapes the user draws.
b) An integer shapeCount ...
Read now
Unlock full access