Inkscape Extensions in Any Language Tutorial

Discussion about writing code for Inkscape.
User avatar
LiquidAsh
Posts: 71
Joined: Fri Apr 22, 2011 11:35 pm
Contact:

Inkscape Extensions in Any Language Tutorial

Postby LiquidAsh » Mon Nov 07, 2011 7:38 am

I think I've mentioned this was coming in a few threads, so I figured I consolidate updates to a single post here.
Inkscape Extensions in Any Language Tutorial: http://sugarpillstudios.com/wp/?p=142
Please let me know what you think, either by commenting on the blog or replying here. Enjoy!

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Inkscape Extensions in Any Language Tutorial

Postby brynn » Mon Nov 07, 2011 10:12 am

OMG, that is awesome!
I probably am not qualified to comment, since I know very little about coding. But I suspect I can learn a lot from this, and look forward to studying it!

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Inkscape Extensions in Any Language Tutorial

Postby ~suv » Mon Nov 07, 2011 3:42 pm

LiquidAsh wrote:I think I've mentioned this was coming in a few threads, so I figured I consolidate updates to a single post here.
Inkscape Extensions in Any Language Tutorial: http://sugarpillstudios.com/wp/?p=142
Please let me know what you think, either by commenting on the blog or replying here. Enjoy!

One thing to keep in mind IMHO when advertising extension development based on custom binaries: potential loss of cross-platform support.

Inkscape is (and hopefully stays) a cross-platform application, and most of the script extensions - usually python-based, some examples are using Perl, or even Ruby - work out-of-the-box on all platforms (including Windows) [1]. Distributing a new extension written in C# as Windows *.exe binary will limit its use cases. Purely python-based extensions written with care work on Linux, OS X and Windows equally well without additional requirements.

[1] Yes, I'm aware that Inkscape still ships with a couple of (input & output) extensions that depend on a shell script interpreter to run an external command - those don't work in the Windows port of Inkscape (no Bourne shell or bash on Windows). Some of them have already been migrated to a python-based execution (based on run_command.py, used e.g. in fig2dev-ext.py, ps2pdf-ext.py, uniconv-ext.py as extension helper module, or uniconv_output.py)

User avatar
LiquidAsh
Posts: 71
Joined: Fri Apr 22, 2011 11:35 pm
Contact:

Re: Inkscape Extensions in Any Language Tutorial

Postby LiquidAsh » Mon Nov 07, 2011 11:07 pm

@brynn: thanks for the enthusiasm and be sure to let me know if there's anything I can help clarify.

@~suv: great point. I've been developing in-house tools so this hasn't been an issue for me. If anyone is interested in writing cross platform C# extensions, maybe they can write a follow-up to this tutorial (or maybe I will some day). Mono-project.com has cross platform C# and .Net compilers/libraries so I believe it shouldn't be too difficult to modify the python script that I used to select and run a binary appropriate for each environment(?). Not as elegant as having a single script, but I think it should be possible.

Thanks for the feedback.


Return to “Programming”