On Thu, 25 Sep 2008 10:44:01 -0400 "bruce westfall" <brucewestfall@...400...> wrote:
I would like to create a menu item in Inkscape, but haven't figured that out yet.
I've attached two files, cutvinyl.inx and cutvinyl.py, which when placed in the ~/.inkscape/extensions directory at an Output menu to the Effects menu, which has one item, Cut Vinyl.
I ran into what I believe to be a bug:
https://bugs.launchpad.net/inkscape/+bug/276382
inkscape --without-gui --export-ps=del.ps del.svg
as a script command does not create postscript output, so the new menu item doesn't actually work for me, although it might work for you as I'm sure --export-ps has worked in the past.
Anyway, all the script does at present is save the document to a temporary .svg file, attempt (this is the bit that fails) to invoke a second instance of inkscape to convert it to PS, and then views it with the PS viewer 'gv'.
I suspect that you'll be able to follow the pattern to add the behavior you want, but if not let me know and I'll flesh it out a bit more.
Cheers -Terry