Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » Get Edge Start and End Absolute Coordinates
Get Edge Start and End Absolute Coordinates [message #1790610] Wed, 13 June 2018 14:42 Go to next message
Parsa Pourali is currently offline Parsa PouraliFriend
Messages: 192
Registered: February 2014
Senior Member
Hello,

Is there anyway to get the start point and the end point of an edge?

* getBendPoints returns the relative points which is not useful.
* I don't want to get the coordinates of the source and target nodes of the edge for some reasons.

Any hint would be appreciated.

Bests,
Parsa
Re: Get Edge Start and End Absolute Coordinates [message #1791176 is a reply to message #1790610] Mon, 25 June 2018 13:25 Go to previous message
Laurent Fasani is currently offline Laurent FasaniFriend
Messages: 133
Registered: October 2014
Senior Member
Hello

If you want the displayed point:
Connection connFigure = conn.getConnectionFigure();
Point sourcePoint = connFigure.getSourceAnchor().getReferencePoint();


If you want the GMF points or globally more examples about manipulating edge coordinates, you can read the code of the Sirius Debuging view [1] in getTextForConnection(ConnectionEditPart) method.

regards
Laurent

[1] https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/tree/plugins/org.eclipse.sirius.ui.debug/src/org/eclipse/sirius/ui/debug/SiriusDebugView.java


Laurent Fasani - Obeo
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
Previous Topic:[Virtual Meetup] Modeling tools go up to the cloud...
Next Topic:Bug with displaying edges when the edge should go through a path expression
Goto Forum:
  


Current Time: Wed Sep 19 10:40:41 GMT 2018

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

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

Back to the top