new Annotation()
Annotation构造函数。
Methods
-
clear()
-
注释清除
-
clearCurrHlightPoint()
-
清除激光笔
-
download(value)
-
下载
Parameters:
Name Type Description valuearrowTypeEnum 箭头类别,枚举型
Example
annotation.setArrowType(arrowTypeEnum.double);
-
hlightPointInit()
-
设置激光笔
-
init(annoDiv)
-
初始化annotation对象
Parameters:
Name Type Description annoDivObject 注释所在的应用层DOM Div
-
redo()
-
注释重做下一步
-
setArrowLength(value)
-
注释设置箭头宽度
Parameters:
Name Type Description valueint 箭头宽度
Example
annotation.setArrowLength(10);
-
setArrowType(value)
-
注释设置箭头类别
Parameters:
Name Type Description valuearrowTypeEnum 箭头类别,枚举型
Example
annotation.setArrowType(arrowTypeEnum.double);
-
setColor(value)
-
注释设置颜色
Parameters:
Name Type Description valueString 颜色,采用rgb和rgba格式
Example
annotation.setColor('rgba(255,0,0,1'); -
setColorOpacity(value)
-
注释设置颜色透明度
Parameters:
Name Type Description valueString 颜色,采用rgb和rgba格式
Example
annotation.setColor('rgba(255,0,0,1'); -
setFillColor(value)
-
注释设置颜色填充类别
Parameters:
Name Type Description valuefillTypeEnum 颜色填充类别,枚举型
Example
annotation.setFillColor(fillTypeEnum.full);
-
setLineWidth(value)
-
注释设置线条宽度
Parameters:
Name Type Description valueint 线条宽度
Example
annotation.setLineWidth(1);
-
setShapeType(type)
-
注释设置几何形状,如矩形,随机线等 注释类型,如鼠标、注释、橡皮擦
Parameters:
Name Type Description typecanvasTypeEnum 几何形 和 注释状态 枚举型
Example
annotation.setShapeType(shapeTypeEnum.polyline);
-
startHlightPoint()
-
设置激光笔
-
undo()
-
注释撤销上一步