1. Tooltip

提示框

1.1. new Tooltip([options])

Param Type Default Description
[options] Object {}

提示框配置参数

[options.fontSize] Number 13

字体大小

[options.fontColor] String 'rgba(255, 255, 255, 1)'

字体颜色

[options.fontOffset] Cartesian2 new BOSGeo.Cartesian2(8, 8)

字体以左上角为原点的偏移量,横向为x,竖向为y,单位为像素

[options.backgroundColor] String 'rgba(0, 0, 0, 0.7)'

背景色

[options.offset] Cartesian2 new BOSGeo.Cartesian2(10, 0)

位置以左上角为原点的偏移量,横向为x,竖向为y,单位为像素

[options.show] Boolean true

是否显示提示框

Example

var tooltip = new BOSGeo.Tooltip();

1.2. 属性

属性名 Type Default Description
fontSize Number 13

字体大小

fontColor String 'rgba(255, 255, 255, 1)'

字体颜色

fontOffset Cartesian2 'new BOSGeo.Cartesian2(8, 8)'

提示框中的字体以左上角为原点的偏移量,横向为x,竖向为y,单位为像素

backgroundColor String 'rgba(0, 0, 0, 0.7)'

提示框的背景色

offset Cartesian2 'new BOSGeo.Cartesian2(10, 0)'

位置以左上角为原点的偏移量,横向为x,竖向为y,单位为像素

message String

提示框的显示文本

show Boolean true

提示框的显隐

id String Globe_TOOLTIP_ID

提示框id,只读属性

isActivated Boolean

是否已激活,只读属性

1.3. 方法

1.3.1. tooltip.active()

激活提示框

1.3.2. tooltip.destroy()

销毁提示框类

版权所有@盈嘉互联(北京)科技有限公司 京ICP备15051988号-9 Copyright © 2022 all right reserved,powered by Gitbook该文件修订时间: 2022-02-22 17:53:54

results matching ""

    No results matching ""