#77 fixed
dataURL needed to be encoded correctly for non latin1 - rephrasing of popup for DPI conversion (Illustrator)
This commit is contained in:
parent
5a696e01fa
commit
0e346add14
2 changed files with 2 additions and 2 deletions
|
|
@ -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;
|
||||
|
||||
|
|
|
|||
|
|
@ -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});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in a new issue