MCPcopy Create free account
hub / github.com/SuperMap/iClient-JavaScript / createCanvas

Method createCanvas

src/openlayers/core/StyleUtils.js:785–792  ·  view source on GitHub ↗

* 创建当前feature对应的canvas * @param {Object} style * @returns {HTMLElement}

(style)

Source from the content-addressed store, hash-verified

783 * @returns {HTMLElement}
784 */
785 static createCanvas(style) {
786 let div = document.createElement('div');
787 document.body.appendChild(div);
788 let canvas = document.createElement('canvas');
789 canvas.id = style.canvas ? style.canvas : 'textCanvas' + Util.newGuid(8);
790 div.appendChild(canvas);
791 return canvas;
792 }
793 /**
794 * 绘制矩形边框背景
795 * @param ctx

Callers 12

getCanvasMethod · 0.95
StyleUtils2Spec.jsFile · 0.45
mapv.min.jsFile · 0.45
mapv.jsFile · 0.45
vFunction · 0.45
yFunction · 0.45
vFunction · 0.45
createCanvasFunction · 0.45
yFunction · 0.45
yFunction · 0.45
yFunction · 0.45
createCanvasFunction · 0.45

Calls 1

createElementMethod · 0.80

Tested by

no test coverage detected