FileDocCategorySizeDatePackage
ImageComponent.javaAPI DocExample593Sat Feb 22 16:54:36 GMT 1997None

ImageComponent

public class ImageComponent extends Component

Fields Summary
Image
image
Dimension
size
Constructors Summary
ImageComponent(Image image)

		this.image = image;
		MediaTracker mt = new MediaTracker(this);
		mt.addImage( image, 0 );
		try { mt.waitForAll(); } catch (InterruptedException e) { /* error */ };
		size = new Dimension ( image.getWidth(null), image.getHeight(null) );
		setSize( size );
	
Methods Summary
public java.awt.DimensiongetPreferredSize()

		return size;
	
public voidpaint(java.awt.Graphics g)

        g.drawImage( image, 0, 0, this );
    
public voidupdate(java.awt.Graphics g)

		paint(g);