File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes Drawing a Rectangle, Oval, and Square Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Drawing a Rectangle, Oval, and Square" Watch "Drawing a Rectangle, Oval, and Square" New topic
Author

Drawing a Rectangle, Oval, and Square

Michael Taylor
Greenhorn

Joined: Jun 19, 2002
Posts: 15
I am trying to write a program where the user clicks on a button labeled "Rectangle", "Oval", or "Square" and when that action is performed the appropriate shape is display. Can someone look at the partial code below and give me some pointers?


Any help would be appreciated.
Thanks,
Michael
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
Michael,
How have you considered organizing your project? What objects might the project need and what heirarchy might they create? Are you trying to work polymorphism into your project?
If you'd like to learn a bit about what polymorphism is, take a look at The "How My Dog Learned Polymorphism" Story in The Campfire Stories.


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Drawing a Rectangle, Oval, and Square