I try to write a program to draw a custom shapes and then execute all mouse events like dragging,clicking,moving etc.I want to know that in other editor when any shape is select or mouse is near to there boundary then its boundary point start to display.I just want the logic not code how corner points displayed like in image? I've done checking that my mouse clicking is inside of shape or not.This is a rounded-rectangle.When I clicked on its rectangle boundary is start displaying and connection points are also start displaying.How do I do that?
Asked
Active
Viewed 157 times
0

iostream007
- 107
- 1
- 10
-
1You might look at the example cited [here](http://stackoverflow.com/a/11944233/230513). – trashgod May 30 '13 at 23:35
1 Answers
1
Shape
interface has getBounds()
and contains()
methods. Use contains()
to determine whether point belongs to the Shape
and then use getBounds()
to get rectable and use the rectangle's corners to draw the dragging points.

StanislavL
- 56,971
- 9
- 68
- 98