aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes hi please help with conversion from awt to swing Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "hi please help with conversion from awt to swing" Watch "hi please help with conversion from awt to swing" New topic
Author

hi please help with conversion from awt to swing

sakshi saw
Greenhorn

Joined: Jun 06, 2009
Posts: 6
hi
i have an application in awt
which i need to convert to swing

i have a Canvas on which lines are to be drawn so which swing component do you guide

is it JPanel and what should i use for drawing lines which graphics class

please reply soon

Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19759
    
  20

sakshi saw wrote:hi
i have an application in awt
which i need to convert to swing

i have a Canvas on which lines are to be drawn so which swing component do you guide

is it JPanel and what should i use for drawing lines which graphics class

You should override the paintComponent method:


please reply soon

http://faq.javaranch.com/java/EaseUp


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
use a JPanel, and do your graphics in an overridden paintComponent()
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: hi please help with conversion from awt to swing