Hi,
Just hacked together a handy (at least for me) extension which allows to seelctivly create rectangles with 1 - 4 ( yeah I know, 4 is quite pointless) rounded corners This comes in quite handy tryingto create tabs and speech bubbles.
It it more a proof of concept which definitely needs some more work on it, but it basically works.
I made it under Debian/Linux, don't know how/if it works under Windows (havent tried yet).
You need command-line php to make it work.
You can download it here: http://simon.familiekainz.at/projekte/linux/inkscape/rounded.zip
Usage:
* Create rounded rectangle
* Select rectange
* Extensions->Misc->Rounded
* Adjust settings
* Apply
Please give me some feedback/critics.
Regards.
Extension for 1 - 4 rounded corners
Re: Extension for 1 - 4 rounded corners
Welcome to InkscapeForum!
Awesome! Always like to see new stuff for Inkscape
Can you explain with not too technical language, how this differs from the existing Rectangle shape tool?
I remember someone asking about setting a certain radius for the rounded corners. (sometime in the last 6 months to year, it seems to me) This will make them happy, if this new extension will do that. Of course I can't remember who it was. But perhaps they'll see this
PS -- I'm on Win7, 64-bit, and would be glad to test, if I can understand it well enough to use it
Basics - Help menu > Tutorials
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Re: Extension for 1 - 4 rounded corners
I`ve tried it but it crashes inkscape (win7/x64/Ink 48.3.1)
What Win has to say about it...
What Win has to say about it...
Code: Select all
Problem signature:
Problem Event Name: APPCRASH
Application Name: inkscape.exe
Application Version: 0.48.3.1
Application Timestamp: 4fe5ae19
Fault Module Name: libglibmm-2.4-1.dll
Fault Module Version: 0.0.0.0
Fault Module Timestamp: 4dd5ae9a
Exception Code: 40000015
Exception Offset: 00031be1
...
Re: Extension for 1 - 4 rounded corners
OnionJuice wrote:Just hacked together a handy (at least for me) extension which allows to seelctivly create rectangles with 1 - 4 ( yeah I know, 4 is quite pointless) rounded corners This comes in quite handy tryingto create tabs and speech bubbles.
It it more a proof of concept which definitely needs some more work on it, but it basically works.
I made it under Debian/Linux, don't know how/if it works under Windows (havent tried yet).
You need command-line php to make it work.
(…)
Please give me some feedback/critics.
Works ok on OS X 10.7.4 Lion (64bit), but fails on Mac OS X 10.5.8 (32bit, Intel).
On Mac OS X 10.5.8, Inkscape 0.48.x crashes (also with an unhandled exception in glibmm (what: Open failed)) after a warning message on the console about getopt() (among other warnings). Apparently the error messages (from the php script) somehow end up being stored at the top of the tmp SVG file generated by Inkscape (ink_ext_XXXXXX.svgZAYBX):
Code: Select all
Warning: getopt(): No support for long options in this build in /Users/my_name/.config/inkscape/extensions/rounded.php on line 7
Warning: getopt(): No support for long options in this build in /Users/my_name/.config/inkscape/extensions/rounded.php on line 9
PHP version on Mac OS X 10.5.8 Leopard:
Code: Select all
$ php --version
PHP 5.2.15 (cli) (built: May 2011 18:56:00)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
PHP version on OS X 10.7.4 Lion:
Code: Select all
$ php --version
PHP 5.3.10 with Suhosin-Patch (cli) (built: Feb 20 2012 22:55:53)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
If the extension works, it's rather slow (due to spawning a separate Inkscape process with GUI window (verbs only work with GUI)). Maybe - considering that the underlying math for the union can't be incredibly complex - it might be worthwhile to do the math in the script itself and generate the resulting path there (python would be easier, since inkscape ships with several python modules offering some convenience functions for XML parsing and path writing).