【问题标题】:gojs: howto increase distance between links or links labels?gojs:如何增加链接或链接标签之间的距离?
【发布时间】:2014-07-10 12:43:25
【问题描述】:

如何增加链接之间的距离(双链接)?

myDiagram.linkTemplate=
    $(go.Link,  // the whole link panel
        $(go.Shape,  // the link shape
            { isPanelMain: true,
                stroke: "black" }),
        $(go.Shape,  // the arrowhead
            { toArrow: "standard",
                stroke: null }),
        $(go.Panel, "Auto",
            $(go.Shape,  // the link shape
                { fill: radgrad, stroke: null }),
            $(go.TextBlock,  // the label
                { textAlign: "center",
                    font: "10pt helvetica, arial, sans-serif",
                    stroke: "#919191",
                    margin: 4 },
                new go.Binding("text", "text"))
         )
     );

http://jsfiddle.net/66ENu/

【问题讨论】:

    标签: javascript gojs


    【解决方案1】:

    切换link.curviness的值:

    myDiagram.linkTemplate=
        $(go.Link,  // the whole link panel
          { curviness: 20 },
          // ... rest of link template
    

    Link.curviness in the API

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-10-11
      • 2021-01-04
      • 2013-06-11
      • 1970-01-01
      • 1970-01-01
      • 2017-04-13
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多