Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Graphiti » Architecture of Graphiti Diagram Editor
Architecture of Graphiti Diagram Editor [message #1059736] Tue, 21 May 2013 13:04 Go to next message
Matthias N is currently offline Matthias NFriend
Messages: 66
Registered: June 2012
Member
Hi,
I want to create a Graphiti Editor (Diagram A) where the user can create several elements.
Now when I doubleclick on an element, another Graphiti Editor (Diagram B) shall be opened, to model the internals.

1) I created a plug-in along with a DiagramTypeProvider and a DiagramType. This one is for Diagram A


My question now is how shall the architecture of the editor look like?

Should I create another plug-in with DiagramTypeProvider and DiagramType for Diagram B. Or can I just add another DiagramTypeProvider and DiagramType to my existing plug-in?


For the sake of diagram navigation, I saw the "AbstractDrillDownFeature", which pretty much looks like what I want to achive. Would it be the right direction to go? Are there any tutorials / examples for similar projects?

Thanks,
Matthias
Re: Architecture of Graphiti Diagram Editor [message #1059804 is a reply to message #1059736] Tue, 21 May 2013 16:20 Go to previous messageGo to next message
Hallvard Traetteberg is currently offline Hallvard TraettebergFriend
Messages: 673
Registered: July 2009
Location: Trondheim, Norway
Senior Member
Matthias,

While it certainly is possible to have separate editors and open one
from the other, it may be easier for the user to work within one
multi-page editor, with one undo-stack, easier navigation etc. In
addition, having separate editors also means splitting the diagrams in
separate files.

Hallvard

On 21.05.13 06.04, Matthias N wrote:
> Hi,
> I want to create a Graphiti Editor (Diagram A) where the user can create
> several elements.
> Now when I doubleclick on an element, another Graphiti Editor (Diagram
> B) shall be opened, to model the internals.
>
> 1) I created a plug-in along with a DiagramTypeProvider and a
> DiagramType. This one is for Diagram A
>
>
> My question now is how shall the architecture of the editor look like?
>
> Should I create another plug-in with DiagramTypeProvider and DiagramType
> for Diagram B. Or can I just add another DiagramTypeProvider and
> DiagramType to my existing plug-in?
>
>
> For the sake of diagram navigation, I saw the
> "AbstractDrillDownFeature", which pretty much looks like what I want to
> achive. Would it be the right direction to go? Are there any tutorials /
> examples for similar projects?
>
> Thanks,
> Matthias
Re: Architecture of Graphiti Diagram Editor [message #1059921 is a reply to message #1059736] Wed, 22 May 2013 07:58 Go to previous messageGo to next message
Michael Wenz is currently offline Michael WenzFriend
Messages: 1931
Registered: July 2009
Location: Walldorf, Germany
Senior Member
Matthias,

I cannot provide a clear answer to that, but it depends on what you want to
achieve. Usually splitting up different parts into separate plugins is a
good idea and you will end up with cleaner coding and architecture because
you are forced to think about APIs and reuse...

The AbstractDrillDownFeature would be a way to go, I could also imagine
using a CustomFeature registered as DoubleClickFetaure to start a new
diagram editor.

Michael
Re: Architecture of Graphiti Diagram Editor [message #1060010 is a reply to message #1059921] Wed, 22 May 2013 14:17 Go to previous message
Matthias N is currently offline Matthias NFriend
Messages: 66
Registered: June 2012
Member
Michael,

thanks for your answer. I will go with your solution.

Thanks
Previous Topic:CustomFeature's create & get all Elements
Next Topic:Question about Link Model
Goto Forum:
  


Current Time: Thu Apr 25 23:48:40 GMT 2024

Powered by FUDForum. Page generated in 0.03335 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top