Hi,
why all standard connection routers do that? Let's say the NullConnectionRouter:
public void route(Connection conn) {
PointList points = conn.getPoints();
points.removeAllPoints();
Point p;
conn.translateToRelative(p = getStartPoint(conn));
points.addPoint(p);
conn.translateToRelative(p = getEndPoint(conn));
points.addPoint(p);
conn.setPoints(points);
}
I have a PolyLineConnection with XYAnchors on my graph. Those anchors are absolute points.
When I zoom in my ScalableFreeformRootEditPart and also scroll it little bit, the connection is translated and zoomed out.
It is because of conn.translateToRelative(p = getStartPoint(conn));
and conn.translateToRelative(p = getEndPoint(conn));
where startPoint and endPoint are those mine absolute XYAnchor points.
Why the connection router does this traslation anyway? How does it work when connections are used appropriately in the connection layer?