package org.CurlyFries.HelloWorld;
import java.awt.Button;
import java.awt.Color;
import java.awt.Graphics;
import javax.swing.JApplet;
public class HelloWorld extends JApplet {
final int radius = 40;
int x = 0;
int y = 65;
public final int width = 100 + (radius / 2);
public final int height = 100 + (radius / 2);
public void paint(Graphics gr) {
setBackground(Color.WHITE);
gr.setColor(Color.red);
while (true) {
gr.fillOval(x, y, radius, radius);
x++;
try {
Thread.sleep(50);
} catch (Exception e) {
}
;
}
}
}
Any help is appreciated!
Thanks in advance

New Topic/Question
Reply



MultiQuote





|