Creating an extension - object guides
In this recipe we will go through the creation of a new extension that split an object into sections of equal width using guides. The number of sections will be chosen by the user in a pop up panel.
How to do it...
The following steps will demonstrate how to create a new extension:
1. Open your favorite file browser and navigate to the
inkscape/extensions
folder inside your personal configuration folder.2. Create two new text files named
object_guides.inx
andobject_guides.py
.3. Open the
object_guides.inx
file. Add the usual XML header, the<_name>
tag with the title of the extension, and the<id>
tag with the definitionorg.ekips.filter.object_guides:
<?xml version="1.0" encoding="UTF-8"?> <inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension"> <_name>Object Guides</_name> <id>org.ekips.filter.object_guides</id>
4. Add two dependencies:
object_guides.py
andinkex.py:
<dependency...