-1

I have a Composite called Workspace. In this composite I want to add some graphics object. Each object can be selected, dragged, moved and can have complicated shape (circle, ellipse, polygon,...). I can click at each object to see its properties. What is the best way to implement?

Hieu Nguyen
  • 382
  • 2
  • 15
  • 1
    Have you tried anything yet? – Vincent Ramdhanie Dec 20 '12 at 16:18
  • 1
    You can look at GEF : http://www.eclipse.org/gef/gef_mvc/index.php – Baldrick Dec 20 '12 at 16:22
  • @VincentRamdhanie am considering two ways of implementation: The first way is drawing everything in the workspace, and then handle events all in the workspace. The second way is creating event handlers for each graphics object. The second way seems much more better, but I still don't figure out how to create a flexible object like that – Hieu Nguyen Dec 20 '12 at 16:34

1 Answers1

1

Have a look at Zest. Here is a very good tutorial for using Zest.

As an alternative, there is Draw2d. And again, here is a nice simple example:

enter image description here

Baz
  • 36,440
  • 11
  • 68
  • 94