new fengmap.FMCompositeMarker(options)
| Name | Type | Description | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
json |
参数
|
Members
-
height
-
离地高度
Properties:
Name Type Description heightnumber 离地高度
-
readonlylevel
-
Properties:
Name Type Description levelnumber 楼层等级,初始化完成后可以获取当前值
-
opacity
-
标注透明度
Properties:
Name Type Description opacitynumber 标注透明度 修改需要调用update方法更新
-
plateColor
-
Properties:
Name Type Description plateColorString 文字背景色 修改需要调用update方法更新
-
plateOpacity
-
Properties:
Name Type Description plateOpacitynumber 背景透明度 修改需要调用update方法更新
-
plateStrokeColor
-
Properties:
Name Type Description plateStrokeColorString 文字背景色边框 修改需要调用update方法更新
-
plateStrokeRadius
-
Properties:
Name Type Description plateStrokeRadiusnumber 背景圆角半径 修改需要调用update方法更新
-
readonlytype
-
Properties:
Name Type Description typefengmap.FMType 节点类型, 值为 fengmap.FMType.TEXT_MARKER
-
visible
-
Properties:
Name Type Description visibleBoolean true 显示 false 隐藏
-
readonlyx
-
Properties:
Name Type Description xnumber 坐标
-
readonlyy
-
Properties:
Name Type Description ynumber 坐标
-
zoomRange
-
标注比例尺缩放级别属性
Properties:
Name Type Description zoomRangearray 标注比例尺缩放级别(可调范围为1-29),默认值:[16,23]
Methods
-
addTo(floor)
-
添加到楼层
Name Type Description floorObject 楼层等级
-
getBelongedBuildingID(){string|null}
-
获取当前对象所属的 buildingID
Returns:
Type Description string | null null 表示归属为当前地图或室内外一体化中的室外主地图 -
getImage(){string}
-
获取图片或视频信息
- Deprecated
- 3.2.4 版本及以后版本将不可用, 使用getMedia方法代替
Returns:
Type Description string 获取图片信息 -
getMedia(){string}
-
获取图片或视频信息
Returns:
Type Description string 获取图片信息 -
getText(){string|array}
-
获取文字信息
Returns:
Type Description string | array 地图覆盖物组 -
jump(options)
-
图标标注跳动动画。
Name Type Description optionsObject Name Type Description heightnumber 图标跳动的高度。
timesnumber 图标跳动次数。不设置该参数或设置为0时, 一直跳动。
durationnumber 单次跳动动画的持续时长(秒)。
delaynumber 一次跳动完成到下次跳动开始的等待时长(秒)。
-
moveTo(options){fengmap.FMAnimation}
-
动画移动marker到指定位置
Name Type Description optionsjson Name Type Description xnumber 图片地图位置x值,默认对应楼层中心点坐标
ynumber 图片地图位置y值,默认对应楼层中心点坐标
animateboolean 是否需要动画,默认false
durationnumber 移动到指定位置所用的时间(秒),默认0.5
finishfunction 移动到指定位置后的回调函数
Returns:
Type Description fengmap.FMAnimation animation 动画类 -
remove()
-
从楼层中移除
-
rotateTo(options)
-
水平旋转至特定角度,带动画,只对render为flat(平铺)和FIX_FLAT(矩形平铺)时有效
Name Type Description optionsjson Name Type Description headingnumber {number} 角度
animateBoolean 是否启动动画 默认 false
durationnumber 动画持续时间
finishfunction 移动到指定位置后的回调函数
-
setImage(url, size)
-
设置图片,设置后需要执行update()方法更新
Name Type Description urlstring 图片的url地址
sizearray 图片大小,数组第一个元素是宽,第二个元素为高
- Deprecated
- 3.2.4 版本及以后版本将不可用, 使用setMedia方法代替
-
setMedia(url, size)
-
设置图片或视频,设置后需要执行update()方法更新
Name Type Description urlstring 图片或视频的url地址
sizearray 图片大小,数组第一个元素是宽,第二个元素为高
-
setText(text)
-
设置文字信息,设置后需要执行update()方法更新, 换行符为“%rn%”
Name Type Description textstring | array 文字信息
-
stopJump()
-
停止图标标注跳动动画。
-
tiltTo(options)
-
倾斜旋转至特定角度,带动画,只对render为flat(平铺)和FIX_FLAT(矩形平铺)时有效
Name Type Description optionsjson Name Type Description tiltnumber {number} 角度
animateBoolean 是否启动动画 默认 false
durationnumber 动画持续时间
finishfunction 移动到指定位置后的回调函数
-
update()
-
更新marker