Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2011-03-20 16:08:27 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2011-03-20 16:08:27 +0300
commit59bd26a246eca2eaa1016a0d2ce16badfc262117 (patch)
tree9a9a8ce74c06445bb8a94e851623bc4788ac4cb0
parent97b21507bd4288c6566fca3f533c8040e523b203 (diff)
Fix #26556: SVG Import fails to parse Inkscape file.
Suppose zero frictional part for case there's space or comma after dot in float value. Inkscape sometimes uses such weird format.
-rw-r--r--io_curve_svg/import_svg.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/io_curve_svg/import_svg.py b/io_curve_svg/import_svg.py
index 3122df91..565db959 100644
--- a/io_curve_svg/import_svg.py
+++ b/io_curve_svg/import_svg.py
@@ -86,6 +86,11 @@ def SVGParseFloat(s, i=0):
while i < n and s[i].isdigit():
token += s[i]
i += 1
+ elif s[i].isspace() or s[i] == ',':
+ # Inkscape sometimes uses qeird float format with missed
+ # fractional part after dot. Suppose zero fractional part
+ # for this case
+ pass
else:
raise Exception('Invalid float value near ' + s[start:start + 10])