Graphics.clearRect
Class Overview | Class Members |
This Package |
All Packages
public abstract void clearRect( int x,
int y,
int width,
int height )
Parameters
- x
- the x coordinate of the rectangle to clear.
- y
- the y coordinate of the rectangle to clear.
- width
- the width of the rectangle to clear.
- height
- the height of the rectangle to clear.
Description
Clears the specified rectangle by filling it with the background
color of the current drawing surface. This operation does not
use the current paint mode.
Beginning with Java 1.1, the background color
of offscreen images may be system dependent. Applications should
use setColor followed by fillRect to
ensure that an offscreen image is cleared to a specific color.
See Also
fillRect, drawRect, setColor, setPaintMode, setXORMode