spakin / SimpInkScr

Simple Inkscape Scripting
https://inkscape.org/~pakin/%E2%98%85simple-inkscape-scripting
GNU General Public License v3.0
320 stars 31 forks source link

type error #79

Closed Yellow-Subroutine closed 1 year ago

Yellow-Subroutine commented 1 year ago

I get this error when I try to draw a circle:

Traceback (most recent call last): File "/home/mh/.config/inkscape/extensions/SimpInkScr/simpinkscr/simple_inkscape_scripting.py", line 2149, in main() File "/home/mh/.config/inkscape/extensions/SimpInkScr/simpinkscr/simple_inkscape_scripting.py", line 2145, in main SimpleInkscapeScripting().run() File "/usr/share/inkscape/extensions/inkex/base.py", line 231, in run self.save_raw(self.effect()) File "/home/mh/.config/inkscape/extensions/SimpInkScr/simpinkscr/simple_inkscape_scripting.py", line 2138, in effect exec(code, sis_globals) File "", line 6, in File "/home/mh/.config/inkscape/extensions/SimpInkScr/simpinkscr/simple_inkscape_scripting.py", line 1560, in circle obj = inkex.Circle(cx=_python_to_svg_str(center[0]), TypeError: 'float' object is not subscriptable

spakin commented 1 year ago

I'd have to see your script to know for sure, but from the error message it sounds like you didn't pass circle an (x, y) tuple as its first argument.