Q1. What is the paintComponent method? How is it used in Java graphics? How does a program intentionally cause the paintComponent method to execute?
Q2. What does invoking the base class paintComponent method accomplish?
Q3. What window events can a program handle? Explain the difference between the WindowListener interface and the WindowAdapter.
Q4. What interface does an application need to use if it wants to get updates on the current position of the mouse cursor? How does the program get the x,y coordinates of the mouse cursor?
Q5. Write a few lines of code to create a timer in Java which fires an ActionEvent every 250 msec. Assume the existence of a TimerHdlr class which needs to respond to timer events.
Q6. Describe the types of information available to a program when using the KeyListener interface.