Self-Review Exercises

12.1Fill in the blanks in each of the following statements:
  1. In Java 2D, method________of class________sets the characteristics of a line used to draw a shape.

  2. Class________helps specify the fill for a shape such that the fill gradually changes from one color to another.

  3. The________method of class Graphics draws a line between two points.

  4. RGB is short for________,________ and________.

  5. Font sizes are measured in units called_________.

  6. Class_________helps specify the fill for a shape using a pattern drawn in a BufferedImage.

12.2State whether each of the following is true or false. If false, explain why.
  1. The first two arguments of Graphics method drawOval specify the center coordinate of the oval.

  2. In the Java coordinate system, ...

Get Java™ How to Program, Seventh Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.