Skip to main content



      Home
Home » Eclipse Projects » GEF » Label parallel to Connection
Label parallel to Connection [message #249593] Mon, 13 July 2009 11:13 Go to next message
Eclipse UserFriend
Hi,

I use GMF to create a graphical editor, I have Label with icon in the
middle of my connections, my connections don't have bendpoints.
Then I want my label be parallel to my connection. I can probably use
Transform draw2d class to keep my label rotation angle identical to my
connection rotation angle, but I don't see how to use Transform draw2d
class.

There is a example of his use?

Thanks.
Re: Label parallel to Connection [message #249602 is a reply to message #249593] Mon, 13 July 2009 11:56 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

There is a method on ConnectionEditPart: installBendpointEditPolicy() that
I'd suggest to override, but it's private. Please raise a bug and we'll
change it's visibility.

Cheers,
Alex
Re: Label parallel to Connection [message #249642 is a reply to message #249602] Wed, 15 July 2009 02:34 Go to previous messageGo to next message
Eclipse UserFriend
Alex Boyko a écrit :
> Hi,
>
> There is a method on ConnectionEditPart: installBendpointEditPolicy()
> that I'd suggest to override, but it's private. Please raise a bug and
> we'll change it's visibility.
>
> Cheers,
> Alex
>
>

Hi Alex,

I don't know how I can do what I want by overriding
ConnectionEditPart.installBendpointEditPolicy().
Otherwise I should be able to override previously installed
EditPolicy.CONNECTION_BENDPOINTS_ROLE EditPolicy with following code :

installEditPolicy(EditPolicy.CONNECTION_BENDPOINTS_ROLE, new
NullConnectionBendPointEditPolicy());

but this code don't have effect.

Thanks Alex.
Re: Label parallel to Connection [message #249652 is a reply to message #249642] Wed, 15 July 2009 06:07 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

Have a look at https://bugs.eclipse.org/bugs/show_bug.cgi?id=281246
Regards,

Mariot


Esteban DUGUEPEROUX a écrit :
> Alex Boyko a écrit :
>> Hi,
>>
>> There is a method on ConnectionEditPart: installBendpointEditPolicy()
>> that I'd suggest to override, but it's private. Please raise a bug and
>> we'll change it's visibility.
>>
>> Cheers,
>> Alex
>>
>>
>
> Hi Alex,
>
> I don't know how I can do what I want by overriding
> ConnectionEditPart.installBendpointEditPolicy().
> Otherwise I should be able to override previously installed
> EditPolicy.CONNECTION_BENDPOINTS_ROLE EditPolicy with following code :
>
> installEditPolicy(EditPolicy.CONNECTION_BENDPOINTS_ROLE, new
> NullConnectionBendPointEditPolicy());
>
> but this code don't have effect.
>
> Thanks Alex.
Re: Label parallel to Connection [message #249695 is a reply to message #249652] Wed, 22 July 2009 14:08 Go to previous message
Eclipse UserFriend
Hi Mariot,

Thanks for your tip, now I can do it with GEF but I can't do it with GMF
(see news://news.eclipse.org:119/h3q0kl$p43$1@build.eclipse.org).

Thanks.
Previous Topic:Object creation with DnD from the palette prevent direct edit
Next Topic:How to run a project
Goto Forum:
  


Current Time: Sat May 31 01:23:22 EDT 2025

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

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

Back to the top