Skip to content
Snippets Groups Projects
Commit e34125b1 authored by Neil Gershenfeld's avatar Neil Gershenfeld
Browse files

fixed names

parent 3b3e42e1
No related branches found
No related tags found
No related merge requests found
...@@ -182,7 +182,6 @@ function save_mask(path) { ...@@ -182,7 +182,6 @@ function save_mask(path) {
circle.setAttribute('stroke-width','0.01') circle.setAttribute('stroke-width','0.01')
circle.setAttribute('fill','none') circle.setAttribute('fill','none')
g.appendChild(circle) g.appendChild(circle)
var name = mod.imageInfo.name+'.'+mod.palette[mod.index][0] var name = mod.imageInfo.name+'.'+mod.palette[mod.index][0]
name += '.'+mod.palette[mod.index][1] name += '.'+mod.palette[mod.index][1]
name += '.'+mod.palette[mod.index][2] name += '.'+mod.palette[mod.index][2]
...@@ -198,20 +197,17 @@ function save_mask(path) { ...@@ -198,20 +197,17 @@ function save_mask(path) {
text.setAttribute('dy','.2') text.setAttribute('dy','.2')
text.textContent = name text.textContent = name
svg.appendChild(text) svg.appendChild(text)
var obj = {} var obj = {}
obj.type = 'file' obj.type = 'file'
obj.name = 'my.svg' obj.name = name+'.svg'
var xml = new XMLSerializer().serializeToString(svg) var xml = new XMLSerializer().serializeToString(svg)
obj.contents = xml obj.contents = xml
outputs.SVG.event(obj) outputs.SVG.event(obj)
/* /*
var html = svg.outerHTML var html = svg.outerHTML
var blob = new Blob([html],{type:"image/svg+xml;charset=utf-8"}) var blob = new Blob([html],{type:"image/svg+xml;charset=utf-8"})
var url = URL.createObjectURL(blob) var url = URL.createObjectURL(blob)
*/ */
} }
// //
// return values // return values
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment