Results 1 to 7 of 7
Thread: Smiley Face
- 11-29-2011, 09:17 AM #1
Member
- Join Date
- Nov 2010
- Location
- Virginia
- Posts
- 14
- Rep Power
- 0
Smiley Face
Hello There,
I am trying to create a smiley face using Japplet, but nothing comes up when I run the program
here are my codes
import java.awt.*;
import java.applet.*;
public class NewJApplet2 extends Applet {
public void paint(Graphics g)
{
g.setColor(Color.yellow);
g.fillOval(50, 50, 75, 75);
g.setColor(Color.black);
g.fillOval(65, 70, 15, 15);
g.fillOval(95, 70, 15, 15);
g.drawArc(70, 90, 40,15, 180, 180);
}
}
Please advise what should i modify
- 11-29-2011, 02:59 PM #2
Re: Smiley Face
How are you running your applet? How big is it? What do you see?
How to Ask Questions the Smart Way
Static Void Games - GameDev tutorials, free Java and JavaScript hosting!
Static Void Games forum - Come say hello!
- 11-29-2011, 07:28 PM #3
Member
- Join Date
- Nov 2010
- Location
- Virginia
- Posts
- 14
- Rep Power
- 0
Re: Smiley Face
Thank you for your interest to help me:
1. I am trying to run the applet through my IDE ( Netbeans and Jcreator )
2 .the applet is not big: it should occupy a quarter of the screen max.
3. I will attach a screenshot for the dislay
- 11-29-2011, 08:21 PM #4
Re: Smiley Face
I'd recommend putting a print statement in your paint method to figure out whether it's ever actually being called.
How to Ask Questions the Smart Way
Static Void Games - GameDev tutorials, free Java and JavaScript hosting!
Static Void Games forum - Come say hello!
- 11-30-2011, 09:39 AM #5
Similar Threads
-
next book after john smiley's
By johnpipes in forum New To JavaReplies: 1Last Post: 11-18-2011, 09:27 PM -
Face Dections CTS
By rockos in forum Advanced JavaReplies: 2Last Post: 09-17-2011, 10:40 AM -
Java Smiley App
By hawken89 in forum Java AppletsReplies: 0Last Post: 03-01-2011, 12:47 PM -
Solr- New face of Search
By petermatilda in forum Java SoftwareReplies: 1Last Post: 08-30-2010, 07:05 PM
Bookmarks