Skip to main content



      Home
Home » Eclipse Projects » GEF » Loop Connections
Loop Connections [message #229176] Tue, 16 January 2007 12:34 Go to next message
Eclipse UserFriend
Originally posted by: adfasfasdf.gmx.com

Hello!

I have to connect a figure with itself (in general with more than one
connection). I am using draw2d without GEF.
I looked in this newsgroup in order to find a solution, but i havent
find a good one yet.
What is the best way to do this? Are there now any existing solutions?

Thanks in advance!
Marcus
Re: Loop Connections [message #229221 is a reply to message #229176] Wed, 17 January 2007 03:32 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

I don't know if it is possible to define a connection with source figure =
destination figure ... have you tried ??

May be you can use a polyline ??

Manu
Re: Loop Connections [message #229235 is a reply to message #229221] Wed, 17 January 2007 04:26 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: adfasfasdf.gmx.com

Yes, it is possible.
At the moment I am using a BendpointConnectionRouter if the source and
target figure are the same. Then I add some Bendpoints to the connection.
I am not sure if this is the best solution, because the results are not
very nice, maybe I am doing something wrong.

The problem is that the source and target anchor are the same, so no
connection is painted if I use the ShortestPathConnectionRouter, for
instance.


I think I could use polylines to connect the figure, but I thought using
connections is the natural way.
It is not unusual to connect a figure with itself, so I am sure that I
am not the first with this problem...
Aren´t there any examples or sth. like that?
I had a look at the logic example, but I havent found sth. that could
help me...

Marcus





> Hi,
>
> I don't know if it is possible to define a connection with source figure
> = destination figure ... have you tried ??
>
> May be you can use a polyline ??
>
> Manu
>
Re: Loop Connections [message #229433 is a reply to message #229235] Fri, 19 January 2007 08:29 Go to previous message
Eclipse UserFriend
I think I would just do it like you did. For your figure though, do you
have multiple anchors configured. It will probably not look nice if all
you have is ChopBoxAnchor because the connection will not look
"square/parallel".

Nhu

Marcus wrote:
> Yes, it is possible.
> At the moment I am using a BendpointConnectionRouter if the source and
> target figure are the same. Then I add some Bendpoints to the connection.
> I am not sure if this is the best solution, because the results are not
> very nice, maybe I am doing something wrong.
>
> The problem is that the source and target anchor are the same, so no
> connection is painted if I use the ShortestPathConnectionRouter, for
> instance.
>
>
> I think I could use polylines to connect the figure, but I thought using
> connections is the natural way.
> It is not unusual to connect a figure with itself, so I am sure that I
> am not the first with this problem...
> Aren´t there any examples or sth. like that?
> I had a look at the logic example, but I havent found sth. that could
> help me...
>
> Marcus
>
>
>
>
>
>> Hi,
>>
>> I don't know if it is possible to define a connection with source figure
>> = destination figure ... have you tried ??
>>
>> May be you can use a polyline ??
>>
>> Manu
>>
Previous Topic:resizing when moving
Next Topic:Custom XYLayout re-sizing problem.
Goto Forum:
  


Current Time: Mon May 12 17:33:45 EDT 2025

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

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

Back to the top