Inkscape can be fully customized through the configuration files,
usually located in the share/inkscape
directory (/usr/share/inkscape
in Linux).
The user file .inkscape/preferences.xml
contains all the preferences that are accessible from the
Inkscape Preferences dialog, as well as quite a few that are
not. This section gives information on a few of the latter.
New in v0.46.
Some window managers
use Alt+Left Mouse
Drag and
Alt+Left Mouse
Click for their own purposes thereby preventing
Inkscape from receiving the mouse input. In the group
id="mapalt" section you can select an
alternative “Alt” key. A numerical value of 1
selects the default “Alt” key. The numbers 2
through 5 select alternative keys. You can see which keys they
correspond to by running the xkeycaps
program available from
www.jwz.org.
Alternatively, you can switch the window manager to use another key (such as the “Windows” or “Command” key instead of the Alt key. See the FAQ.
Updated in v0.45
You can specify the colors used in the Outline Mode in the group id="wireframecolors" section. Colors are specified in decimal form (converted from a rgba hexadecimal value to base ten).
Default: 255 (#000000ff or black). Color used when stroke crosses a light background.
Default: 4294967295 (#ffffffff or white). Color used when stroke crosses a dark background.
Default: 4278190335 (#ff0000ff or red). Color used to outline images.
Default: 16711935 (#00ff00ff or green). Color used for clip paths.
Default: 65535 (#0000ffff or blue). Color used for masks.
You can force Inkscape to start up in Outline Mode by changing the value of outline in the group id="startmode" to 1.
Updated in v0.45.
A number of preferences control the way content is written to the SVG files. They can be found in the group id="svgoutput" section.
Default: 0. If '0', colors are written as three-digit hexadecimal numbers where possible or as six-digit hexadecimal numbers if not. If non-zero, colors are written when possible with SVG color keyword names such as blue or black. Use of keyword names can cause problems with some Effects.
Default: 8. This is the number of significant digits written out for a number. Lowering the number will save a small amount of space at a cost of precision.
Default: -8. Any number smaller than 10 raised to this value (10-8) is written out as 0.
Default: 2. Number of spaces used for indenting between nested levels of SVG tags. A value of '0' disables indentation.
Default: 0. If '0', attributes are separated by newlines; otherwise, attributes are placed on the same line as their tags.
New drawing templates can be added by adding new files to the
directory share/inkscape/templates
(for
system-wide use) or to the templates
subdirectory in your Inkscape preferences directory. As of
v0.46, the templates
directory is listed
under the Places part of the Save As
dialog. You can directly save any SVG file to this
directory. Saving the file as default.svg
will replace your current default template.
Tip | |
---|---|
Objects, gradients, patterns, etc. can be added to an empty Inkscape SVG file and then saved and placed in the templates directory. When that file is selected in the list of templates, you will have access to all the objects, gradients, and patterns you previously defined. |
You can add custom Swatches
(Palettes) to Inkscape by adding the
appropriate files under the
share/inkscape/palettes
directory. The file
format follows the Gimp palettes file format so palettes can be
shared between the two programs.
The file format is very simple, as the following example 5 color palette file shows.
GIMP Palette Name: MyPalette # 0 0 0 Black 255 0 0 Red 0 255 0 Green 0 0 255 Blue 255 255 255 White
Declaration of the type of file. | |
Name of palette. Shown in list of palettes. | |
Comment. | |
List of colors. There is one color per line. Each color is defined as three numbers representing the values of red, green, and blue followed by a name (shown when the cursor hovers over the swatch). The range of values is 0-255, where 255 means that the corresponding color is fully turned on. The above palette consists of the colors black, red, green, blue, and white. |
It is possible to add custom markers to Inkscape by editing the
file containing the marker definitions
share/inkscape/markers/markers.svg
.
Here is the definition needed to add a “diamond node” marker. It
differs from the diamond markers included with Inkscape in that
the center of the diamond is gray and the orientation doesn't
depend on the slope of the lines.
<marker style="overflow:visible;" id="DiamondNode" refX="0.0" refY="0.0" orient="0.0" inkscape:stockid="DiamondNode"> <path transform="scale(0.8) rotate(180)" style="fill-rule:evenodd;stroke:#000000;fill:#BFBFBF; stroke-width:0.5pt;marker-start:none;" d="M 0.0,2.5 L 2.5,0.0 L 0.0,-2.5 L -2.5,0.0 L 0.0,2.5 z " id="path1234" sodipodi:nodetypes="ccccc" /> <marker>
Start of marker definition. (The “overflow:visible” declaration indicates that the marker should not be clipped if it extends outside a clipping box.) | |
Name of marker. | |
Offset of marker origin from node position. | |
Orientation of marker. If a numerical value, the orientation of the marker with respect to the screen coordinates. If “auto”, then it is aligned with the direction of the path at the node (or the average of the directions of the path in and path out if a corner node). | |
Inkscape id of marker. | |
The definition of the path of the marker. See the file format for Paths in the appendix for more details. | |
End of marker definition. |
For more details, see the Markers section of the SVG specification.
You can change the keyboard shortcuts used by Inkscape by
editing or replacing the file
share/keys/defaults.xml
.
There are a number of alternative shortcuts available. To use
them, simply rename the file to
defaults.xml
.
New in v0.46
ACD Systems Canvas: acd-canvas.xml
.
New in v0.46
Corel Draw: corel-draw-x4.xml
.
Freehand: macromedia-freehand-mx.xml
.
Illustrator: adobe-illustrator-cs2.xml
.
Xara: xara.xml
.
New in v0.46
Zoner Draw: zoner-draw.xml
.
Right-handed illustration (for use in drawing on a tablet with a
stylus held by the right hand; most commonly keyboard shortcuts
are accessible with the left hand):
right-handed-illustration.xml
.
You can also add shortcuts to a
keys/defaults.xml
in your Inkscape
preferences directory. These will override any shortcuts
defined in the system-wide defaults.xml
file.
See the comments in the default file for more details.
One particularly handy shortcut customization is to bind often-used Effects to keys. Here is an example of binding the / key to the Add Nodes effect:
<?xml version="1.0"?> <keys name="My Customization"> <bind key="slash" action="org.ekips.filter.addnodes" display="true"/> </keys>
© 2005-2008 Tavmjong Bah. | Get the book. |