• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

I have placed a Rectangle object in an Applet container.

 
yuvaraj KumarAmudhan
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have placed a Rectangle object in an Applet container. Is there any pre-defined method to get that object when i give (x,y) point?

thanks
 
Ulf Dittmer
Rancher
Posts: 42969
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not directly. But if you still have the Rectangle object around (or can create a new one using its corner points), then you can use the java.awt.Rectangle#contains(int, int) method to find out.

Moving to the AWT/Swing/GUI forum, since the question has nothing to do with applets.
 
yuvaraj KumarAmudhan
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic