Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » DirectGraphLayout
DirectGraphLayout [message #164876] Thu, 20 January 2005 23:03 Go to next message
Eclipse UserFriend
Originally posted by: brett.bock.embarcadero.com

Using the DirectedGraphLayout object, I have a fairly simple test case that
fails, see figure. Basically if a node is not connected by an edge to
another node the layout will throw.

Am I missing something fundamental here? What is the standard way to
correct this situation.

Thank you,
Brett


Re: DirectGraphLayout [message #164954 is a reply to message #164876] Fri, 21 January 2005 13:13 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: mmacfadden.redoaksw.com

The DirectiedGraph layout expects the graph to be completely connected,
meaning no disconnected components. You should take a look at the
schema editor example. URL:

http://www.eclipse.org/articles/Article-GEF-editor/gef-schem a-editor.html

When the auto layout is gone, temporary edges are added to the graph
that connects all disconnected components. The edges only exist in the
graph and not the model. Take a look at the
NodeJoiningDirectedGraphLayout class. This makes use of the
ClusterEdgeCreator and DummyEdgeCreater classes to accomplish this.
After the layout is done the dummy edges (and possibly nodes) are just
discarded because they don't correspond to any real entity in the model.

Hope this helps.

~Mike MacFadden

Brett Bock wrote:
> Using the DirectedGraphLayout object, I have a fairly simple test case that
> fails, see figure. Basically if a node is not connected by an edge to
> another node the layout will throw.
>
> Am I missing something fundamental here? What is the standard way to
> correct this situation.
>
> Thank you,
> Brett
>
>
Re: DirectGraphLayout [message #164969 is a reply to message #164954] Fri, 21 January 2005 15:25 Go to previous message
Eclipse UserFriend
Originally posted by: brett.bock.embarcadero.com

Great! That works very well.

"Michael MacFadden" <mmacfadden@redoaksw.com> wrote in message
news:csqv6d$rge$1@www.eclipse.org...
> The DirectiedGraph layout expects the graph to be completely connected,
> meaning no disconnected components. You should take a look at the schema
> editor example. URL:
>
> http://www.eclipse.org/articles/Article-GEF-editor/gef-schem a-editor.html
>
> When the auto layout is gone, temporary edges are added to the graph that
> connects all disconnected components. The edges only exist in the graph
> and not the model. Take a look at the NodeJoiningDirectedGraphLayout
> class. This makes use of the ClusterEdgeCreator and DummyEdgeCreater
> classes to accomplish this. After the layout is done the dummy edges (and
> possibly nodes) are just discarded because they don't correspond to any
> real entity in the model.
>
> Hope this helps.
>
> ~Mike MacFadden
>
> Brett Bock wrote:
>> Using the DirectedGraphLayout object, I have a fairly simple test case
>> that fails, see figure. Basically if a node is not connected by an edge
>> to another node the layout will throw.
>>
>> Am I missing something fundamental here? What is the standard way to
>> correct this situation.
>>
>> Thank you,
>> Brett
Previous Topic:Connections as container for EditParts?
Next Topic:Mouse Handling in GEF
Goto Forum:
  


Current Time: Fri Apr 19 08:14:13 GMT 2024

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

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

Back to the top