|Select a concrete part in a figure [message #517300]
||Fri, 26 February 2010 20:53
| Jan Krakora
Registered: December 2009
I've a question about the draw2d Figure. Consider the PolylineConnection for instance. You have a source ConnectionAnchor with coordinates [0,0] and a target ConnectionAnchor with coordinates [5,5] so it means, the PolylineConnection must have a rectangle bounds with size 5x5.
My question is, how is it made that you can click only exactly the line and not a point next to the line but still inside the bounds, eg. [4,4]?
Because, I made my own Figure with overriden method paintFigure() where I simply draw a line and a oval (like a lollipop). I set the bounds with size 10x5 (it's the minimal size to cover all my lollipop). But now I can click anywhere in the bounds and the lollipop is selected. I would like to select it only when I click exactly the lollipop like the PolylineConnection example above.
Can anybody explain it to me? Thanks
Powered by FUDForum
. Page generated in 0.01505 seconds