I would like to write a program that enable user to draw geometric shapes like circles, triangles, rectangles and so on.
I would like also to be able to drag and drop or resize/move a shape that was previously drawn.
- I thought to draw the shapes inside a Panel. Does it seems reasonable ?
- After I draw a circle, it becomes a part of a Bitmap. Of course, I do save circle's details in some other object.
But what I don't understand is how to implement the following:
When the mouse is over the circle, the circle is chosen, and then using some key enables the user to resize/move it.
How can I know that the mouse is over the circle ?
Do I need to check the mouse coordinates vs all circle pixel coordinates ?
I'm looking for simpler solution.