home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 1997 May / Pcwk0597.iso / sybase / starbuck / java.z / ComponentPeer.java < prev    next >
Text File  |  1996-05-03  |  2KB  |  55 lines

  1. /*
  2.  * @(#)ComponentPeer.java    1.12 95/10/07 Sami Shaio
  3.  *
  4.  * Copyright (c) 1995 Sun Microsystems, Inc. All Rights Reserved.
  5.  *
  6.  * Permission to use, copy, modify, and distribute this software
  7.  * and its documentation for NON-COMMERCIAL purposes and without
  8.  * fee is hereby granted provided that this copyright notice
  9.  * appears in all copies. Please refer to the file "copyright.html"
  10.  * for further important copyright and licensing information.
  11.  *
  12.  * SUN MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF
  13.  * THE SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
  14.  * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
  15.  * PARTICULAR PURPOSE, OR NON-INFRINGEMENT. SUN SHALL NOT BE LIABLE FOR
  16.  * ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR
  17.  * DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES.
  18.  */
  19.  
  20. package java.awt.peer;
  21.  
  22. import java.awt.*;
  23. import java.awt.image.ImageProducer;
  24. import java.awt.image.ImageObserver;
  25. import java.awt.image.ColorModel;
  26.  
  27. public interface ComponentPeer {
  28.     void        show();
  29.     void        hide();
  30.     void        enable();
  31.     void        disable();
  32.     void        paint(Graphics g);
  33.     void        repaint(long tm, int x, int y, int width, int height);
  34.     void        print(Graphics g);
  35.     void        reshape(int x, int y, int width, int height);
  36.     boolean        handleEvent(Event e);
  37.     Dimension        minimumSize();
  38.     Dimension        preferredSize();
  39.     ColorModel        getColorModel();
  40.     java.awt.Toolkit    getToolkit();
  41.     Graphics        getGraphics();
  42.     FontMetrics        getFontMetrics(Font font);
  43.     void        dispose();
  44.     void        setForeground(Color c);
  45.     void        setBackground(Color c);
  46.     void        setFont(Font f);
  47.     void        requestFocus();
  48.     void        nextFocus();
  49.  
  50.     Image         createImage(ImageProducer producer);
  51.     Image         createImage(int width, int height);
  52.     boolean        prepareImage(Image img, int w, int h, ImageObserver o);
  53.     int            checkImage(Image img, int w, int h, ImageObserver o);
  54. }
  55.