Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Seeking advice on customizing graph layout behavior
Seeking advice on customizing graph layout behavior [message #138312] Tue, 15 June 2004 20:04 Go to next message
Thomas D. Johnson is currently offline Thomas D. JohnsonFriend
Messages: 72
Registered: July 2009
Member
First let me thank the GEF team for the Draw2D and .graph
package, as well as the excellent examples.

I've used the GEF "flow" example as a starting point for a simple
graph editor. I call it 'simple' because my requirements don't
require a fully general purpose directed (possibly cyclic) graph layout
algorithm.

Nonetheless, I started with the "flow" example to learn the proper
relationships between EditPart, Figure, etc. and I think it helped
a lot.

Basically I want to control the layout of the nodes so that
they're positioned from left to right. I have read Randy Hudson's
advice from a while back ...

> There is no support for horizontal orientation. Use the class
> Transposer for this.

and I don't see where that advice should be applied. Since most
of the GraphVisitor classes are in the ..draw2d.internal.graph
package, I assume that I'm supposed to create my own sequence of
visitors. However, it sounds as if I'd likely have to rework my
new code in the future if/when the 'internal' classes change.

Maybe using the (very nice) general purpose graph layout is overkill,
and I should just be using Draw2D myself to draw the one or two
cycles and connections between my (mostly disconnected) subgraphs?

Regards,

Tom Johnson
Re: Seeking advice on customizing graph layout behavior [message #138419 is a reply to message #138312] Wed, 16 June 2004 14:02 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

"Tom Johnson" <tdjohns1@rockwellcollins.com> wrote in message
news:cank7v$5so$1@eclipse.org...
> First let me thank the GEF team for the Draw2D and .graph
> package, as well as the excellent examples.
>
> I've used the GEF "flow" example as a starting point for a simple
> graph editor. I call it 'simple' because my requirements don't
> require a fully general purpose directed (possibly cyclic) graph layout
> algorithm.
>
> Nonetheless, I started with the "flow" example to learn the proper
> relationships between EditPart, Figure, etc. and I think it helped
> a lot.
>
> Basically I want to control the layout of the nodes so that
> they're positioned from left to right. I have read Randy Hudson's
> advice from a while back ...
>
> > There is no support for horizontal orientation. Use the class
> > Transposer for this.
>
> and I don't see where that advice should be applied. Since most
> of the GraphVisitor classes are in the ..draw2d.internal.graph

You would use this before and after invoking the public class,
DirectedGraphLayout.

> package, I assume that I'm supposed to create my own sequence of
> visitors. However, it sounds as if I'd likely have to rework my
> new code in the future if/when the 'internal' classes change.
>
> Maybe using the (very nice) general purpose graph layout is overkill,
> and I should just be using Draw2D myself to draw the one or two
> cycles and connections between my (mostly disconnected) subgraphs?

Post a picture of what you are trying to layout.
>
> Regards,
>
> Tom Johnson
>
Re: Seeking advice on customizing graph layout behavior [message #138547 is a reply to message #138419] Wed, 16 June 2004 18:43 Go to previous message
Thomas D. Johnson is currently offline Thomas D. JohnsonFriend
Messages: 72
Registered: July 2009
Member
Randy Hudson wrote:

(snip)

>>Basically I want to control the layout of the nodes so that
>>they're positioned from left to right. I have read Randy Hudson's
>>advice from a while back ...
>>
>> > There is no support for horizontal orientation. Use the class
>> > Transposer for this.
>>
>>and I don't see where that advice should be applied. Since most
>>of the GraphVisitor classes are in the ..draw2d.internal.graph
>
>
> You would use this before and after invoking the public class,
> DirectedGraphLayout.

Ah. Let me experiment with that first before troubling you further.
Sorry for the silly question.

Tom Johnson
Previous Topic:creating a transparent box
Next Topic:Am I ready for the standalone plunge?
Goto Forum:
  


Current Time: Fri Apr 26 22:47:14 GMT 2024

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

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

Back to the top