页面树结构
转至元数据结尾
转至元数据起始

示例说明:
可以通过扩展属性调整地图分析图例调整位置和文字间距,如下图:


属性代码:

{
    legend: {
        align: "right",
        verticalAlign: "bottom",
        x: -50,
        y: 10,
 
        floating: true,
        width: 50,
  
        itemMarginTop: 2,
        itemMarginBottom: 4,
        itemMainMarginTop: 10,
        itemMainMarginBottom: 0
    }
}

 


属性说明:

属性名称

属性描述

属性语法

align

水平居中方式。设置值分别有:left(向左)、center(居中)、right(向右)

{
legend: {
align: "right" //图例水平居右
}
}

verticalAlign

垂直对齐方式,设置值分别有:bottom(底部)和top(顶部)

{
legend: {
verticalAlign: "bottom" //图例垂直居下
}
}

X,Y

XY坐标值,设置值为数字。坐标轴设置和水平垂直设置方式相关

{
legend: {
x: -50,
y: 10
}
}

floating

是否浮动,设置值为:true,false

{
legend: {
floating: true
}
}

width

图例设置宽度,设置值为数字

{
legend: {
width: 50
}
}

itemMarginTop

图例中【指标区间】对应文字上边距设置,设置值为数字

{
legend: {
itemMarginTop: 2
}
}

itemMarginBottom

图例中【指标区间】对应文字下边距设置,设置值为数字

{
legend: {
itemMarginBottom: 4
}
}

itemMainMarginTop

图例中【指标值】对应文字上边距设置,设置值为数字

{
legend: {
itemMainMarginTop: 10
}
}

itemMainMarginBottom

图例中【指标值】对应文字指下边距设置,设置值为数字

{
legend: {
itemMainMarginBottom: 0
}
}

  • 无标签