wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes Problem with Coordinates Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Problem with Coordinates" Watch "Problem with Coordinates" New topic
Author

Problem with Coordinates

Sunil Kumar Gupta
Ranch Hand

Joined: Aug 26, 2005
Posts: 824
Hi all

In my graphics application , i rotated my polygon by angle -45 .

Now when i notice the mouse event over polygon , the method contains

always return false because of rotation , the x and y of polygon has been changed.

Plz suggest me how to apply polygon.contains method which will return true when i click over polygon

Thanks


Lack of will power has caused more failure than lack of intelligence or ability.
My Blog | Red5 Resources | Technology Update | Daily Technology Tips
Sunil Kumar Gupta
Ranch Hand

Joined: Aug 26, 2005
Posts: 824
 
jQuery in Action, 2nd edition
 
subject: Problem with Coordinates
 
Similar Threads
J2SE 1.5.0 fillPolygon method
Background image
Disappearing Graphics on panel
Adding a custom component to a layout?
J2SE 1.5.0 Graphics.fillPolygon method