Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » GEF/ZEST more complex examples/projects
GEF/ZEST more complex examples/projects [message #1792909] Wed, 25 July 2018 15:39 Go to next message
João Pedro is currently offline João PedroFriend
Messages: 52
Registered: December 2014
Member
I'm trying to learn how to use GEF/ZEST but the examples from the github page don't seem to be enough.

I want to do something like this:
https://i.stack.imgur.com/JPP8h.png

Basically I need the following requirements:
- Have several inputs/outputs for each block/node. These multiple inputs/outputs need to be distinguishable between them
-Paint one block with different colors to show that the execution of said block is at 50%, 70%, etc.
-Overall I'm trying to replicate the Simulink capabilities to some extent.

I think GEF can give me everything that I need, however from the examples I miss some of the requirements and I have no idea on how to start implementing them (even by looking at the GEF/ZEST documentation).
Thus, can anyone give me some pointers and/or share more complex projects using GEF?

[Updated on: Wed, 25 July 2018 15:42]

Report message to a moderator

Re: GEF/ZEST more complex examples/projects [message #1793507 is a reply to message #1792909] Thu, 09 August 2018 10:29 Go to previous messageGo to next message
João Pedro is currently offline João PedroFriend
Messages: 52
Registered: December 2014
Member
Anyone can give me a hand? Just some example with "several distinguishable inputs/outputs for each block/node" please.

Thank you
Re: GEF/ZEST more complex examples/projects [message #1793537 is a reply to message #1793507] Thu, 09 August 2018 17:27 Go to previous messageGo to next message
Matthias Wienand is currently offline Matthias WienandFriend
Messages: 230
Registered: March 2015
Senior Member
Hi Joao,

I will take some time to answer forum questions tomorrow. In doing so, I will take a closer look and provide you with an appraisal at least.

In order to get an impression of the possibilities of GEF w.r.t. your requirements, you can take a look at the YAKINDU Model Viewer, a tool for navigating Simulink diagrams, which is available for download on the itemis website (a demo application is available for free): https://www.itemis.com/en/yakindu/model-viewer/

Best regards,
Matthias
Re: GEF/ZEST more complex examples/projects [message #1793568 is a reply to message #1793537] Fri, 10 August 2018 09:45 Go to previous messageGo to next message
João Pedro is currently offline João PedroFriend
Messages: 52
Registered: December 2014
Member
Dear Matthias,

Thank you very much for answering! That model Viewer seems awesome as is exactly the kind of thing I want to implement in my app.

With the confirmation that GEF can implement my requirements, now I just need some code examples on similar apps/plugins, so that I can understand how to begin coding this.

I will be waiting for your answer to my OP, whenever possible.

Best regards,

João Malés

[Updated on: Fri, 10 August 2018 09:56]

Report message to a moderator

Re: GEF/ZEST more complex examples/projects [message #1793652 is a reply to message #1793568] Mon, 13 August 2018 10:03 Go to previous messageGo to next message
Matthias Wienand is currently offline Matthias WienandFriend
Messages: 230
Registered: March 2015
Senior Member
Hi Joao,

here you are some insights w.r.t. what we learned during development of model viewer:

- favour JavaFX Shapes over GEF FX Connection and GeometryNode
- really try to avoid Connection and related concepts (too computationally intensive: routing, interpolation, dependent calculations, ...)
- still use GeometryNode for complex shapes and the geometry API for calculations
- stick to the handler > policy > operation architecture for interactions with the main visual elements
- provide extended functionality (search box, bread crumb, etc.) without GEF handler interaction (overwrite HandlerResolver to exclude their visuals from processing within GEF)

There are a few code examples available for GEF:

- GEF Logo Example (part of GEF repository at GitHub)
- GEF Zest Example (part of GEF repository at GitHub)
- GEF Mind Map Tutorial (tutorial provided by itemis AG for free): https://info.itemis.com/en/gef/tutorials/

Unfortunately, something as sophisticated as the Model Viewer is not available as an example. However, multiple distinguishable edges between nodes is supported by default. However, the port locations are not provided by GEF. However, you can, for example, integrate ELK and use it for laying out nodes, edges, labels, and ports.

If you have more questions w.r.t. port positioning, we can discuss them here.

Best regards,
Matthias
Re: GEF/ZEST more complex examples/projects [message #1793653 is a reply to message #1793652] Mon, 13 August 2018 10:22 Go to previous messageGo to next message
João Pedro is currently offline João PedroFriend
Messages: 52
Registered: December 2014
Member
Thank you for the answer Matthias!

I decided and will use GEF! I will probably have a lot of doubts during the development phase and I will post them in this forum. Hope you guys can help me with them :D

With regards to your comment, is ELK the Elastic Stack library? I'm asking since it's the only library appearing in my Google searches and yet it doesn't seem to fit the "layout our nodes, edges, labels and ports" description.
Re: GEF/ZEST more complex examples/projects [message #1793771 is a reply to message #1793653] Wed, 15 August 2018 13:20 Go to previous messageGo to next message
Matthias Wienand is currently offline Matthias WienandFriend
Messages: 230
Registered: March 2015
Senior Member
Hi Joao,

it is a pleasure for me to hear that you have chosen GEF :-)

I was referring to the Eclipse Layout Kernel: https://www.eclipse.org/elk/

Best regards,
Matthias
Re: GEF/ZEST more complex examples/projects [message #1794430 is a reply to message #1793771] Thu, 30 August 2018 14:13 Go to previous messageGo to next message
João Pedro is currently offline João PedroFriend
Messages: 52
Registered: December 2014
Member
Dear Matthias. Do you know of any valid alternative to ELK?

I lost already 3 days trying to integrate ELK within GEF without success.
The support is horrible and there are 0 projects using GEF5 (all of the existing GEF+ELK use org.eclipse.gef.request, org.eclipse.gef.EditPart, org.eclipse.gef.GraphicalEditPart which GEF5 doesn't have anymore).

I'm generating a correct "LayoutMapping mapping" where I can see my nodes and connections, but then I'm not able to apply the Layout correctly. I mean, my GEF graph doesn't suffer any change. Can you provide me with a simple example of a GEF5+ELK project?

Thank you,

João
Re: GEF/ZEST more complex examples/projects [message #1794543 is a reply to message #1794430] Sat, 01 September 2018 18:47 Go to previous messageGo to next message
Tamas Miklossy is currently offline Tamas MiklossyFriend
Messages: 157
Registered: February 2016
Senior Member
Hello Joao,

have you already taken a look at the layouting documentation/examples on the Eclipse GEF Wiki?

https://github.com/eclipse/gef/wiki/Layout
https://github.com/eclipse/gef/wiki/DOT-Examples

They may guide you to the right direction.
Re: GEF/ZEST more complex examples/projects [message #1794580 is a reply to message #1794543] Mon, 03 September 2018 10:01 Go to previous messageGo to next message
João Pedro is currently offline João PedroFriend
Messages: 52
Registered: December 2014
Member
@Tamas Thank you for the answer.

Yes, I did. I'm trying to use ELK because of ports, not the layout. I need each model to have distinguishable (with different selectable labels) ports and Matthias told me before that with GEF alone this is not possible.
Re: GEF/ZEST more complex examples/projects [message #1794591 is a reply to message #1794580] Mon, 03 September 2018 12:03 Go to previous messageGo to next message
Tamas Miklossy is currently offline Tamas MiklossyFriend
Messages: 157
Registered: February 2016
Senior Member
How about to use Graphviz for the layouting (based on the DotLayoutExample)?

The DOT language https://graphviz.gitlab.io/_pages/doc/info/lang.html already support ports via the headport and tailport edge attributes.

However, I do not now if they are powerful enough to cover your usecase. But I think it is a good starting point and worth looking at it.
Re: GEF/ZEST more complex examples/projects [message #1794592 is a reply to message #1794591] Mon, 03 September 2018 12:10 Go to previous messageGo to next message
João Pedro is currently offline João PedroFriend
Messages: 52
Registered: December 2014
Member
Yes, I will definitely give it a try. However I would like to first at least get ELK to work.

The reason why I'm insisting in ELK is: 1-is the one Matthias (one of GEF's developers) recommended; 2-it seems to cover everything that I need.
Re: GEF/ZEST more complex examples/projects [message #1794594 is a reply to message #1794592] Mon, 03 September 2018 12:19 Go to previous message
Tamas Miklossy is currently offline Tamas MiklossyFriend
Messages: 157
Registered: February 2016
Senior Member
I am glad to hear that!

Your experience about the GEF + ELK integration is highly appreciated either in this thread or on one of the following issues:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=440098
https://github.com/eclipse/elk/issues/86
Previous Topic:NullPointerException at ITransformableContentPart
Next Topic:How to access contentChild of AddContentChildOperation
Goto Forum:
  


Current Time: Sat Apr 20 04:05:45 GMT 2024

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

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

Back to the top