diff --git a/src/octoprint/plugins/svgtogcode/static/js/render_fills.js b/src/octoprint/plugins/svgtogcode/static/js/render_fills.js index b21da1b3..0a1ce9dc 100644 --- a/src/octoprint/plugins/svgtogcode/static/js/render_fills.js +++ b/src/octoprint/plugins/svgtogcode/static/js/render_fills.js @@ -124,7 +124,7 @@ Snap.plugin(function (Snap, Element, Paper, global) { // get svg as dataUrl var svgStr = elem.outerSVG(); - var svgDataUri = 'data:image/svg+xml;base64,' + window.btoa(svgStr); + var svgDataUri = 'data:image/svg+xml;base64,' + window.btoa(unescape(encodeURIComponent(svgStr))); //deprecated unescape needed! var source = new Image(); source.src = svgDataUri; diff --git a/src/octoprint/plugins/svgtogcode/static/js/working_area.js b/src/octoprint/plugins/svgtogcode/static/js/working_area.js index c7c2e83a..79cc1685 100644 --- a/src/octoprint/plugins/svgtogcode/static/js/working_area.js +++ b/src/octoprint/plugins/svgtogcode/static/js/working_area.js @@ -276,7 +276,7 @@ $(function(){ f.node.childNodes.forEach(function(entry) { if(entry.nodeType == 8) { // Nodetype 8 = comment if(entry.textContent.indexOf('Illustrator') > -1) { - new PNotify({title: gettext("Illustrator SVG Detected"), text: "Looks like an Illustrator SVG! If the scale is not right, and you want to change the DPI, please go to the \'Settings\' menu and change the \'SVG dpi\' field under \'Plugins/Svg Conversion\' and add the file again.", type: "info", hide: false}); + new PNotify({title: gettext("Illustrator SVG Detected"), text: "Illustrator SVG detected! To preserve coorect scale, please go to the \'Settings\' menu and change the \'SVG dpi\' field under \'Plugins/Svg Conversion\' according to your file. And add it again.", type: "info", hide: false}); } } });