Route first point missing

Hi, I found a problem with the first point of the route of a link. As you can see in the picture below when you create a link from Unit one to Unit two, there is no point on the first corner of that route. Is there any option or an easy way to create this point? If no then do you know a way to create this missing point on the route?
Thank you for your help, it’s appreciated.
Martin

By “point” I assume you mean “reshape handle”. The Point is actually there in the Link.Route.Points. And there is another point just before the end of the route at “Unit two”, that does not have a reshape handle.

The reason is that when ports have a FromSpot or a ToSpot, the routing will have the first or last segment come out straight from/to the port. The length of this segment is controlled by the FromEndSegmentLength and ToEndSegmentLength properties on the Route, and defaulting to the attached Node properties on the port FrameworkElement.

Because the length of the end segment is fixed, the user cannot move that point with the LinkReshapingTool, so there is no reshape handle at that point.

Also, it is handy to leave that point open for use by other tools’ handles, just as the very end points are open for use by the RelinkingTool.

If you really want to have a reshape handle at those next-to-end points, you could override Route.AddOrthoPoints to add an extra Point at the same points.

Thank you for the advice, your solution works when the link is created. However we had to create a code to duplicate the point when a node is drag on the layout.

Did you override Route.AddOrthoPoints? That should work to make sure the points are duplicated each time the link is completely re-routed.

No we create our own method AddOrthoPoints because we want to duplicate the points only when the first 3 points are not vertical or horizontal. We call our AddOrthoPoints at 2 places (GoXamDraggingTool.DoStop, GoXamLinkReshapingTool.DoMouseUp). The result of that code is that we only see the “reshape handle” when there an angle at the begining of the link.