Book a Demo

Author Topic: Connector subshapes must rotate  (Read 3072 times)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Connector subshapes must rotate
« on: January 30, 2010, 06:55:27 pm »
When you create subshapes in a connector shapescript, they don't maintain their relationship with the line.  The shapes are drawn on an absolute canvas and the line is drawn on a rotating canvas.  As an example see Simon's provided script to draw an assembly connector (see: lineto behaves differently for main than endshapes).

It looks OK when the target is to the right of the source, but as you "swing" the target around the source, the bug manifests itself, till when the target is to the left of the source, the shape is at it most distorted.

When applied to a connector, the shapescript methods must consistently (some do, some don't) maintain their reference to the angle of the line segment in which they are being drawn.

The temporary solution I've provided further down the topic, suffers from the same fate as Simon's original, it's just that by the judicious juxtaposition of the two circles, I get away with it.

Reported,
Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!