Saturday, 9 September 2017

Method of Components

1) public void paint(Graphics)
            To paint on the screen graphics context of Current object is passed as argument.
2) public void repaint()
            Repaints the screen.
3) public void update(Graphics)
                  Updates the paint on the screen.
4) public Graphics getGraphics()
            To get graphics context of specified component.
5) public Image createImage(int w,int h)
ex :
            Image im = createImage(100,200);
            drawImage(im,100,200,100,200,this);
6) public void setForeground(Color)
7) public void setBackground(Color)

8) public void setFont(Font)

No comments:

Post a Comment

Featured post

Development Of JAVA Program