I am working on svg editor, specifically the Method draw implementantion.
I want on loading the editor to load an image instead of a background rectangle. Currently the javascript file includes this command to create a background rectangle within the editor.
var createBackground = function(fill) {
svgCanvas.createLayer("background")
cur_shape = svgCanvas.addSvgElementFromJson({
"element": "rect",
"attr": {
"x": -1,
"y": -1,
"width": res.w+2,
"height": res.h+2,
"stroke": "none",
"id": "canvas_background",
"opacity": 1,
"fill": '#ffffff',
"style": "pointer-events:none"
I want to create an image instead of a rectangle.
Is this possible?