Quantcast
Channel: GoJS - Northwoods Software
Viewing all articles
Browse latest Browse all 7069

Avoiding nodes when linking the ports on nodes

$
0
0

@Ank wrote:

Hi everyone,
I am linking some ports that i have on the nodes and the links are not avoiding the nodes and i have already set routing: go.Link.AvoidsNodes .So what am i doing wrong ?

Here is my linkTemplate

 // Defining template for links
 myDiagram.linkTemplate =
 GO(go.Link,  // the whole link panel
      {
        selectable: true,
        relinkableFrom: true,
        relinkableTo: true,
        reshapable: true,
        routing: go.Link.AvoidsNodes,
        curve: go.Link.JumpOver,
        corner: 5,
        toShortLength: 4
      },
      new go.Binding("points").makeTwoWay(),

      GO(go.Shape,  // the link path shape
        { isPanelMain: true, strokeWidth: 1 }
      ),

      GO(go.Shape,  // the arrowhead
        { toArrow: "Standard", stroke: null }
      ),

      GO(go.Panel, "Auto",
        new go.Binding("visible", "isSelected").ofObject(),
        GO(go.Shape, "RoundedRectangle",  // the link shape
          { fill: null, stroke: null }
        )
      )
  );

As you can see links are not avoiding the nodes..

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 7069

Trending Articles