【问题标题】:How to fix the position of LegendBox in the chart?如何固定 LegendBox 在图表中的位置?
【发布时间】:2020-02-25 17:37:09
【问题描述】:

我正在使用 LightningChartJS 创建图表。目前图例框的位置可以通过拖动来改变。如何修复图例框的位置? ​


const legend = chart.addLegendBox()
.setOrigin(UIOrigins.RightTop)
.setPosition({ x: 90, y: 90 })
.setMargin({ left: 10, right: 10, top: 10, bottom: 10 })
legend.add(chart)

【问题讨论】:

    标签: javascript charts legend lineseries lightningchart


    【解决方案1】:

    拖动可以禁用

    legend.setDraggingMode( UIDraggingModes.notDraggable )
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-03-10
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多