Results 1 to 2 of 2
  1. #1
    dharav is offline Member
    Join Date
    Dec 2011
    Rep Power

    Question ...---::Graphics HELP! ::---...

    Here is my code and it dosent seem to print a rectangle on the screen, why is that! Can anyone please take a took for me!
    Java Code:
    package dharavsGraphics;
    import java.awt.Color;
    import java.awt.Graphics2D;
    import java.awt.Image;
    import java.awt.geom.Rectangle2D;
    import javax.swing.ImageIcon;
    import javax.swing.JFrame;
    import dharavGraphics.Graphics;
    public class Main extends JFrame{
    	public void paint (Graphics2D g)
    		Graphics2D ga = (Graphics2D)g;
    		int x=900, y=900;
    		Rectangle2D.Double square = new Rectangle2D.Double(10,10,880,880);
    	public static void main(String[] args) 
    		JFrame frame = new Graphics();

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Madgaon, Goa, India
    Rep Power

    Default Re: ...---::Graphics HELP! ::---...

    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. SVG graphics
    By Lacrim in forum Advanced Java
    Replies: 2
    Last Post: 06-09-2012, 01:54 AM
  2. Graphics 2D
    By scopene in forum Java 2D
    Replies: 0
    Last Post: 03-26-2012, 02:21 AM
  3. Graphics g
    By fatabass in forum New To Java
    Replies: 9
    Last Post: 12-25-2011, 01:22 AM
  4. Drawing a graphics onto another Graphics ?
    By Ziden in forum Java Applets
    Replies: 0
    Last Post: 01-08-2011, 08:30 PM
  5. Help with 2d graphics please
    By xbox_nutter in forum New To Java
    Replies: 0
    Last Post: 04-02-2009, 12:48 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts