Overview | Methods | This Package | All Packages
Renders the bitmap image to a Graphics object, stretching the image to fill the specified dimensions.
Syntax
protected void drawStretchTo( Graphics g, Rectangle imageRect, Rectangle targetRect, int rop )
Parameters
g
The Graphics object to which to draw the image.
imageRect
A Rectangle object that specifies the bitmap region to draw.
targetRect
A Rectangle object that specifies the area to which to draw the image.
rop
A numerical raster operation (ROP) code that describes how to draw the source image to the target.
Remarks
The drawStretchTo and drawTo methods are used by the Graphics object for all image rendering. For more information on how the Graphics object uses these methods, see the Graphics object's drawImage method.
If the area specified in imageRect is smaller than the area specified in targetRect, the source image is stretched to fill the specified area. If the area specified in imageRect is larger than that specified in targetRect, the image is shrunk.