【问题标题】:how to do even spaces between grid lines in both x and y axis using amcharts如何使用 amcharts 在 x 轴和 y 轴上的网格线之间做均匀的空间
【发布时间】:2020-03-23 13:56:50
【问题描述】:

如何使用 amcharts 在 x 和 y 轴上的网格线之间设置均匀的空格?

我需要在网格线之间做相等的空间你可以看到图片。 我需要改变什么

这是我的图表设置:

我正在使用 amcharts 3

{
    valueAxes: [
        {
            gridAlpha: 0,
            includeAllValues: false
        }
    ],
    graphs: [],
    listeners: [],
    chartCursor: {
        onePanelOnly: true,
        leaveCursor: true,
        valueLineAxis :false,
        valueLineEnabled: false,
        valueLineBalloonEnabled: false,
        cursorPosition: 'mouse'
    },
    chartScrollbar: {
        oppositeAxis: false,
        offset: 30,
        updateOnReleaseOnly: true,
        selectedBackgroundColor: "#c1e6ee"
    },
    categoryAxis: {
        gridThickness: 1,
        minPeriod: 'fff',
        parseDates: true,
        minorGridEnabled: true
    }
}

1

【问题讨论】:

    标签: javascript html angular amcharts amcharts4


    【解决方案1】:

    对我来说,设置

    "synchronizeGrid": true,
    

    作为图表配置的主要属性。 (https://www.amcharts.com/docs/v3/reference/amserialchart/#synchronizeGrid_property)

    也许您还需要检查 minHorizo​​ntalGap? (https://www.amcharts.com/docs/v3/reference/axisbase/#minHorizontalGap_property)

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2019-06-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多