类 BigMap.Polygon
Constructor Attributes | Constructor Name and Description |
---|---|
BigMap.Polygon(pointArray, options)
|
Polygon构造函数
|
方法属性 | 方法名称和描述 |
---|---|
禁用编辑
|
|
开启编辑
|
|
[getFillColor 获取填充颜色]
|
|
[getFillOpacity 获取填充透明度]
|
|
返回所画的点集合
|
|
[getStrokeColor 获取边颜色]
|
|
[getStrokeDasharray 获取虚线比例]
|
|
[getStrokeOpacity 获取边透明度]
|
|
[getStrokeStyle 获取边框样式]
|
|
[getStrokeWeight 获取边宽]
|
|
setFillColor(color)
|
[setFillColor 设置填充颜色]
|
setFillOpacity(opacity)
|
[setFillOpacity 设置填充透明度]
|
setLabel(label)
|
给Polygon设置Label
|
setStrokeColor(color)
|
[setStrokeColor 设置边颜色]
|
setStrokeDasharray(dashArray)
|
[setStrokeDasharray 设置虚线比例]
|
setStrokeOpacity(opacity)
|
[setStrokeOpacity 设置边透明度]
|
setStrokeStyle(lineDash)
|
[setStrokeStyle 设置边框样式]
|
setStrokeWeight(weight)
|
[setStrokeWeight 设置边宽]
|
setZIndex(zIndex)
|
[setZIndex 设置zIndex]
|
show()
|
设置显示
|
[getZIndex 获取zIndex]
|
|
hide()
|
设置隐藏
|
on(options, callback, obj)
|
[on 绑订事件]
|
un(options, callback, opt_this)
|
[un 解绑事件]
|
addEventListener(options, callback)
|
给Polygon添加点击事件
|
removeEventListener(options, callback)
|
取消监听
|
类 详情
BigMap.Polygon(pointArray, options)
Polygon构造函数
- Parameters:
- {list[BigMap.Point]} pointArray
- 点的数组
- {json} options
- 多边形样式
{
fillColor:"string 填充颜色",
fillWeight:"number 填充宽度",
fillOpacity:"number 填充透明度",
strokeColor:"string 边框颜色",
strokeWeight:"number 边框宽度",
strokeOpacity:"number 边框透明度",
dash:"boolean 是否为虚线",
lineDash:"array 比例",
zIndex:"number 层级"
}
方法详情
addEventListener(options, callback)
给Polygon添加点击事件
- Parameters:
- {string} options
- 传入参数(click mouseover mouseout)
- {Function} callback
- 自定义事件
disableEditing()
禁用编辑
enableEditing()
开启编辑
{string}
getFillColor()
[getFillColor 获取填充颜色]
- Returns:
- {string} [填充颜色]
{number}
getFillOpacity()
[getFillOpacity 获取填充透明度]
- Returns:
- {number} [填充透明度]
{[BigMap.Point]}
getGeometry()
返回所画的点集合
- Returns:
- {[BigMap.Point]}
{string}
getStrokeColor()
[getStrokeColor 获取边颜色]
- Returns:
- {string} [zIndex指数]
{array}
getStrokeDasharray()
[getStrokeDasharray 获取虚线比例]
- Returns:
- {array} [虚线比例]
{number}
getStrokeOpacity()
[getStrokeOpacity 获取边透明度]
- Returns:
- {number} [边框颜色]
{string}
getStrokeStyle()
[getStrokeStyle 获取边框样式]
- Returns:
- {string} [边框样式]
{string}
getStrokeWeight()
[getStrokeWeight 获取边宽]
- Returns:
- {string} [边框宽度]
{number}
getZIndex()
[getZIndex 获取zIndex]
- Returns:
- {number} [zIndex指数]
hide()
设置隐藏
on(options, callback, obj)
[on 绑订事件]
- Parameters:
- {string} options
- 传入参数(click mouseover mouseout等)
- {Function} callback
- 自定义事件
- obj
removeEventListener(options, callback)
取消监听
- Parameters:
- {string} options
- 传入参数(click mouseover mouseout)
- {Function} callback
- 自定义事件
setFillColor(color)
[setFillColor 设置填充颜色]
- Parameters:
- {string} color
- [填充颜色]
setFillOpacity(opacity)
[setFillOpacity 设置填充透明度]
- Parameters:
- {number} opacity
- [填充透明度]
setLabel(label)
给Polygon设置Label
- Parameters:
- {[BigMap.Label]} label
- [标签]
setStrokeColor(color)
[setStrokeColor 设置边颜色]
- Parameters:
- {string} color
- [边框颜色]
setStrokeDasharray(dashArray)
[setStrokeDasharray 设置虚线比例]
- Parameters:
- {array} dashArray
- [虚线比例]
setStrokeOpacity(opacity)
[setStrokeOpacity 设置边透明度]
- Parameters:
- {number} opacity
- [边框透明度]
setStrokeStyle(lineDash)
[setStrokeStyle 设置边框样式]
- Parameters:
- {string} lineDash
- [边框样式 dashed/solid]
setStrokeWeight(weight)
[setStrokeWeight 设置边宽]
- Parameters:
- {string} weight
- [边框宽度]
setZIndex(zIndex)
[setZIndex 设置zIndex]
- Parameters:
- {number} zIndex
- [zIndex指数]
show()
设置显示
un(options, callback, opt_this)
[un 解绑事件]
- Parameters:
- {string} options
- 传入参数(click mouseover mouseout等)
- {Function} callback
- 自定义事件
- opt_this