Class: FMPolygonMarker

FMPolygonMarker

FMPolygonMarker 自定义多边形标注对象,为自定义图层。属于fengmap.map.min.js

new fengmap.FMPolygonMarker(options)

Name Type Description
options json

参数

Name Type Description
height number

离地高度, 默认 1

opacity number

多边形的透明度。0.0 - 1.0 之间取值, 默认为 1.0

color String

多边形的颜色

borderWidth number

多边形边框线宽,默认为2

borderColor string

多边形边框线颜色,默认 #FF0000

points array
points[].x number

x坐标

points[].y number

y坐标

Members

borderColor

Properties:
Name Type Description
color string

如:'#ff0000'

borderWidth

Properties:
Name Type Description
val number

线宽

readonlybound

Properties:
Name Type Description
bound fengmap.FMBound

边界

color

修改颜色

Properties:
Name Type Description
color String

如:'#ff0000'

height

离地高度

Properties:
Name Type Description
height number

离地高度

readonlylevel

Properties:
Name Type Description
level number

楼层等级,初始化完成后可以获取当前值

opacity

Properties:
Name Type Description
opacity number

透明度

points

Properties:
Name Type Description
points Array

点集合

readonlytype

Properties:
Name Type Description
type fengmap.FMType

节点类型

visible

Properties:
Name Type Description
visible Boolean

true 显示 false 隐藏

Methods

inherited addTo(floor)

添加到楼层

Name Type Description
floor Object

楼层等级

getBound()

获取Bound

getInsideCenter(){Object}

获取多边形内部点

Returns:
Type Description
Object

inherited remove()

从楼层中移除

inherited traverse(callback)

遍历返回子节点

Name Type Description
callback