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:
authorCampbell Barton <ideasman42@gmail.com>2020-01-29 05:51:36 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-01-29 05:51:36 +0300
commit6598f0a25cb0485c6e6fa66964c2d74bf80ff705 (patch)
treea15f2b63048bffbfc4e26a1db0800e2b005d4a29 /io_curve_svg
parent9dde6b34b254a3882a1366023eca9792033f9b6c (diff)
Cleanup: trailing space
Diffstat (limited to 'io_curve_svg')
-rw-r--r--io_curve_svg/import_svg.py24
1 files changed, 12 insertions, 12 deletions
diff --git a/io_curve_svg/import_svg.py b/io_curve_svg/import_svg.py
index 013b5bc5..ceb24420 100644
--- a/io_curve_svg/import_svg.py
+++ b/io_curve_svg/import_svg.py
@@ -1741,30 +1741,30 @@ class SVGGeometrySVG(SVGGeometryContainer):
matrix = self.getNodeMatrix()
# Better SVG compatibility: match svg-document units
- # with blender units
-
+ # with blender units
+
viewbox = []
unit = ''
-
+
if self._node.getAttribute('height'):
raw_height = self._node.getAttribute('height')
token, last_char = read_float(raw_height)
document_height = float(token)
- unit = raw_height[last_char:].strip()
-
+ unit = raw_height[last_char:].strip()
+
if self._node.getAttribute('viewBox'):
viewbox = parse_array_of_floats(self._node.getAttribute('viewBox'))
-
+
if len(viewbox) == 4 and unit in ('cm', 'mm', 'in', 'pt', 'pc'):
- #convert units to BU:
- unitscale = units[unit] / 90 * 1000 / 39.3701
-
- #apply blender unit scale:
+ #convert units to BU:
+ unitscale = units[unit] / 90 * 1000 / 39.3701
+
+ #apply blender unit scale:
unitscale = unitscale / bpy.context.scene.unit_settings.scale_length
-
+
matrix = matrix @ Matrix.Scale(unitscale, 4, Vector((1.0, 0.0, 0.0)))
- matrix = matrix @ Matrix.Scale(unitscale, 4, Vector((0.0, 1.0, 0.0)))
+ matrix = matrix @ Matrix.Scale(unitscale, 4, Vector((0.0, 1.0, 0.0)))
# match document origin with 3D space origin.
if self._node.getAttribute('viewBox'):