Code

Extensions. Fix live preview crash in custom color extension when invalid values...
[inkscape.git] / share / extensions / straightseg.py
index f6460f2d55af5a1bcc65aa800ab7b6fb0b57bcc2..16db996fc94a81c089550522667aba96122756e6 100755 (executable)
@@ -65,8 +65,9 @@ class SegmentStraightener(inkex.Effect):
                         last = params[-2:]
                 node.set('d',simplepath.formatPath(p))
 
-e = SegmentStraightener()
-e.affect()
+if __name__ == '__main__':
+    e = SegmentStraightener()
+    e.affect()
 
 
 # vim: expandtab shiftwidth=4 tabstop=8 softtabstop=4 encoding=utf-8 textwidth=99