
-----------------------------------
sk8boarder1414
Thu Apr 19, 2007 11:24 pm

Drawing Java
-----------------------------------
Hey, wanted to print some shapes in java, came up with this.. what else do I need to make some shapes appear?
Doesn't work in my java.

class Helicopter
{
	   public void paint( Graphics g ) 
	   {
      	 	g.setColor(Color.blue);
      		g.fillOval(20, 20, 10, 10);   
       }
 	
}

-----------------------------------
wtd
Thu Apr 19, 2007 11:59 pm

RE:Drawing Java
-----------------------------------
Nowhere have you given any indication that your class has any kind of Applet functionality.  How would you do so?

-----------------------------------
sk8boarder1414
Sun May 06, 2007 8:27 pm

Re: Drawing Java
-----------------------------------
well ok, if i included the package java.awt

and said 

import java.awt.*;

How else would i get the shapes to appear, thats the pacakge for graphics.

-----------------------------------
Reality Check
Mon May 07, 2007 9:58 pm

Re: Drawing Java
-----------------------------------
Read some tutorials...your problem is obviously going to require a whole explanation on Java and how it works since you obviously don't know.  I could just tell you the code but there's no sense in that.  You won't learn anything.  Go read some tutorials.
