diff options
| author | Nicolas Dufour <nicoduf@yahoo.fr> | 2010-09-06 18:55:37 +0000 |
|---|---|---|
| committer | JazzyNico <nicoduf@yahoo.fr> | 2010-09-06 18:55:37 +0000 |
| commit | 0e3050d2a6ca650c3baee54d07bbaa96a42ce9e9 (patch) | |
| tree | 6411d34b2fdf30bacc4574332786ab3aac254159 | |
| parent | Automatically add shortcuts to tooltips (diff) | |
| download | inkscape-0e3050d2a6ca650c3baee54d07bbaa96a42ce9e9.tar.gz inkscape-0e3050d2a6ca650c3baee54d07bbaa96a42ce9e9.zip | |
Extensions. Consistency fix and UI improvements (Modify path submenu).
(bzr r9746)
| -rw-r--r-- | share/extensions/addnodes.inx | 10 | ||||
| -rw-r--r-- | share/extensions/edge3d.inx | 45 | ||||
| -rw-r--r-- | share/extensions/flatten.inx | 2 | ||||
| -rwxr-xr-x | share/extensions/fractalize.inx | 8 | ||||
| -rw-r--r-- | share/extensions/interp_att_g.inx | 102 | ||||
| -rwxr-xr-x | share/extensions/interp_att_g.py | 4 | ||||
| -rw-r--r-- | share/extensions/radiusrand.inx | 44 | ||||
| -rwxr-xr-x | share/extensions/radiusrand.py | 5 | ||||
| -rw-r--r-- | share/extensions/straightseg.inx | 12 | ||||
| -rw-r--r-- | share/extensions/whirl.inx | 8 |
10 files changed, 127 insertions, 113 deletions
diff --git a/share/extensions/addnodes.inx b/share/extensions/addnodes.inx index f260f3df4..b61d0a92d 100644 --- a/share/extensions/addnodes.inx +++ b/share/extensions/addnodes.inx @@ -4,12 +4,12 @@ <id>org.ekips.filter.addnodes</id> <dependency type="executable" location="extensions">addnodes.py</dependency> <dependency type="executable" location="extensions">inkex.py</dependency> - <param name="method" type="optiongroup" _gui-text="Division method"> - <_option value="bymax">By max. segment length</_option> - <_option value="bynum">By number of segments</_option> + <param name="method" type="enum" _gui-text="Division method:"> + <_item value="bymax">By max. segment length</_item> + <_item value="bynum">By number of segments</_item> </param> - <param name="max" type="float" min="0.1" max="10000.0" _gui-text="Maximum segment length (px)">10.0</param> - <param name="segments" type="int" min="1" max="1000" _gui-text="Number of segments">2</param> + <param name="max" type="float" min="0.1" max="10000.0" _gui-text="Maximum segment length (px):">10.0</param> + <param name="segments" type="int" min="1" max="1000" _gui-text="Number of segments:">2</param> <effect needs-live-preview="false"> <object-type>path</object-type> <effects-menu> diff --git a/share/extensions/edge3d.inx b/share/extensions/edge3d.inx index 9b287359f..bc5f073ed 100644 --- a/share/extensions/edge3d.inx +++ b/share/extensions/edge3d.inx @@ -1,30 +1,23 @@ <?xml version="1.0" encoding="UTF-8"?> <inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension"> - <_name>Edge 3D</_name> - <id>org.greygreen.inkscape.effects.edge3d</id> - <dependency type="executable" location="extensions">edge3d.py</dependency> - <dependency type="executable" location="extensions">inkex.py</dependency> - <param name="angle" type="float" min="0.0" max="360.0" - _gui-text="Illumination Angle">45</param> - <param name="shades" type="int" min="2" max="360" - _gui-text="Shades">2</param> - <param name="bw" type="boolean" - _gui-text="Only black and white">0</param> - <param name="thick" type="float" min="1.0" max="50.0" - _gui-text="Stroke width">10</param> - <param name="stddev" type="float" min="1.0" max="100.0" - _gui-text="Blur stdDeviation">5</param> - <param name="blurwidth" type="float" min="1.0" max="10.0" - _gui-text="Blur width">2</param> - <param name="blurheight" type="float" min="1.0" max="10.0" - _gui-text="Blur height">2</param> - <effect> + <_name>Edge 3D</_name> + <id>org.greygreen.inkscape.effects.edge3d</id> + <dependency type="executable" location="extensions">edge3d.py</dependency> + <dependency type="executable" location="extensions">inkex.py</dependency> + <param name="angle" type="float" min="0.0" max="360.0" _gui-text="Illumination Angle:">45</param> + <param name="shades" type="int" min="2" max="360" _gui-text="Shades:">2</param> + <param name="bw" type="boolean" _gui-text="Only black and white:">0</param> + <param name="thick" type="float" min="1.0" max="50.0" _gui-text="Stroke width:">10</param> + <param name="stddev" type="float" min="1.0" max="100.0" _gui-text="Blur stdDeviation:">5</param> + <param name="blurwidth" type="float" min="1.0" max="10.0" _gui-text="Blur width:">2</param> + <param name="blurheight" type="float" min="1.0" max="10.0" _gui-text="Blur height:">2</param> + <effect> <object-type>path</object-type> - <effects-menu> - <submenu _name="Modify Path"/> - </effects-menu> - </effect> - <script> - <command reldir="extensions" interpreter="python">edge3d.py</command> - </script> + <effects-menu> + <submenu _name="Modify Path"/> + </effects-menu> + </effect> + <script> + <command reldir="extensions" interpreter="python">edge3d.py</command> + </script> </inkscape-extension> diff --git a/share/extensions/flatten.inx b/share/extensions/flatten.inx index 8167175d8..4c8298623 100644 --- a/share/extensions/flatten.inx +++ b/share/extensions/flatten.inx @@ -4,7 +4,7 @@ <id>org.ekips.filter.flatten</id> <dependency type="executable" location="extensions">flatten.py</dependency> <dependency type="executable" location="extensions">inkex.py</dependency> - <param name="flatness" type="float" min="0.0" max="1000.0" _gui-text="Flatness">10.0</param> + <param name="flatness" type="float" min="0.0" max="1000.0" _gui-text="Flatness:">10.0</param> <effect> <object-type>path</object-type> <effects-menu> diff --git a/share/extensions/fractalize.inx b/share/extensions/fractalize.inx index 189bb2afa..4893189e8 100755 --- a/share/extensions/fractalize.inx +++ b/share/extensions/fractalize.inx @@ -4,13 +4,13 @@ <id>org.ekips.filter.fractalize</id> <dependency type="executable" location="extensions">fractalize.py</dependency> <dependency type="executable" location="extensions">inkex.py</dependency> - <param name="subdivs" type="int" _gui-text="Subdivisions">6</param> - <param name="smooth" type="float" _gui-text="Smoothness">4.0</param> + <param name="subdivs" type="int" _gui-text="Subdivisions:">6</param> + <param name="smooth" type="float" _gui-text="Smoothness:">4.0</param> <effect> <object-type>path</object-type> <effects-menu> - <submenu _name="Modify Path"/> - </effects-menu> + <submenu _name="Modify Path"/> + </effects-menu> </effect> <script> <command reldir="extensions" interpreter="python">fractalize.py</command> diff --git a/share/extensions/interp_att_g.inx b/share/extensions/interp_att_g.inx index cd78abccf..39c043519 100644 --- a/share/extensions/interp_att_g.inx +++ b/share/extensions/interp_att_g.inx @@ -1,51 +1,57 @@ <?xml version="1.0" encoding="UTF-8"?> <inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension"> - <_name>Interpolate Attribute in a group</_name> - <id>org.inkscape.filter.interp-att-g</id> - <dependency type="executable" location="extensions">interp_att_g.py</dependency> - <dependency type="executable" location="extensions">inkex.py</dependency> - <_param name="intro" type="description">This effect applies a value for any interpolatable attribute for all elements inside the selected group or for all elements in a multiple selection</_param> - <param name="att" type="enum" _gui-text="Attribute to Interpolate"> - <_item value="width">Width</_item> - <_item value="height">Height</_item> - <_item value="scale">Scale</_item> - <_item value="trans-x">Translate X</_item> - <_item value="trans-y">Translate Y</_item> - <_item value="fill">Fill</_item> - <_item value="opacity">Opacity</_item> - <_item value="other">Other</_item> - </param> - <_param name="other-info" type="description">If you select "Other", you must know the SVG attributes to identify here this "other":</_param> - <param name="att-other" type="string" _gui-text="Other Attribute"></param> - <param name="att-other-type" type="enum" _gui-text="Other Attribute type"> - <_item value="color">Color</_item> - <_item value="int">Integer Number</_item> - <_item value="float">Float Number</_item> - </param> - <param name="att-other-where" type="enum" _gui-text="Where to apply?"> - <_item value="tag">Tag</_item> - <_item value="style">Style</_item> - <_item value="transform">Transformation</_item> - </param> - <_param name="sep" type="description">••••••••••••••••••••••••••••••••••••••••••••••••</_param> - <param name="start-val" type="string" _gui-text="Start Value"></param> - <param name="end-val" type="string" _gui-text="End Value"></param> - <param name="unit" type="enum" _gui-text="Unit"> - <_item value="none">No Unit</_item> - <_item value="color">Color</_item> - <item>px</item> - <item>pt</item> - <item>in</item> - <item>cm</item> - <item>mm</item> - </param> - <effect> - <object-type>all</object-type> - <effects-menu> - <submenu _name="Modify Path"/> - </effects-menu> - </effect> - <script> - <command reldir="extensions" interpreter="python">interp_att_g.py</command> - </script> + <_name>Interpolate Attribute in a group</_name> + <id>org.inkscape.filter.interp-att-g</id> + <dependency type="executable" location="extensions">interp_att_g.py</dependency> + <dependency type="executable" location="extensions">inkex.py</dependency> + <param name="tab" type="notebook"> + <page name="Options" _gui-text="Options"> + <param name="att" type="enum" _gui-text="Attribute to Interpolate:"> + <_item value="width">Width</_item> + <_item value="height">Height</_item> + <_item value="scale">Scale</_item> + <_item value="trans-x">Translate X</_item> + <_item value="trans-y">Translate Y</_item> + <_item value="fill">Fill</_item> + <_item value="opacity">Opacity</_item> + <_item value="other">Other</_item> + </param> + <_param name="other-info" type="description">If you select "Other", you must know the SVG attributes to identify here this "other".</_param> + <param name="att-other" type="string" _gui-text="Other Attribute:"></param> + <param name="att-other-type" type="enum" _gui-text="Other Attribute type:"> + <_item value="color">Color</_item> + <_item value="int">Integer Number</_item> + <_item value="float">Float Number</_item> + </param> + <param name="att-other-where" type="enum" _gui-text="Apply to:"> + <_item value="tag">Tag</_item> + <_item value="style">Style</_item> + <_item value="transform">Transformation</_item> + </param> + <_param name="sep" type="description">••••••••••••••••••••••••••••••••••••••••••••••••</_param> + <param name="start-val" type="string" _gui-text="Start Value:"></param> + <param name="end-val" type="string" _gui-text="End Value:"></param> + <param name="unit" type="enum" _gui-text="Unit:"> + <_item value="none">No Unit</_item> + <_item value="color">Color</_item> + <item>px</item> + <item>pt</item> + <item>in</item> + <item>cm</item> + <item>mm</item> + </param> + </page> + <page name="Help" _gui-text="Help"> + <_param name="intro" type="description">This effect applies a value for any interpolatable attribute for all elements inside the selected group or for all elements in a multiple selection.</_param> + </page> + </param> + <effect> + <object-type>all</object-type> + <effects-menu> + <submenu _name="Modify Path"/> + </effects-menu> + </effect> + <script> + <command reldir="extensions" interpreter="python">interp_att_g.py</command> + </script> </inkscape-extension> diff --git a/share/extensions/interp_att_g.py b/share/extensions/interp_att_g.py index f23edaf36..9829de3e8 100755 --- a/share/extensions/interp_att_g.py +++ b/share/extensions/interp_att_g.py @@ -50,6 +50,10 @@ class InterpAttG(inkex.Effect): action="store", type="string", dest="unit", default="color", help="Values unit.") + self.OptionParser.add_option("--tab", + action="store", type="string", + dest="tab", + help="The selected UI-tab when OK was pressed") def getColorValues(self): sv = string.replace( self.options.start_val, '#', '' ) diff --git a/share/extensions/radiusrand.inx b/share/extensions/radiusrand.inx index 3349f4549..38e7d6c4c 100644 --- a/share/extensions/radiusrand.inx +++ b/share/extensions/radiusrand.inx @@ -1,22 +1,28 @@ <?xml version="1.0" encoding="UTF-8"?> <inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension"> - <_name>Jitter nodes</_name> - <id>org.ekips.filter.radiusrand</id> - <dependency type="executable" location="extensions">radiusrand.py</dependency> - <dependency type="executable" location="extensions">inkex.py</dependency> - <_param name="title" type="description">This effect randomly shifts the nodes (and optionally node handles) of the selected path.</_param> - <param name="radiusx" type="float" min="0.0" max="1000.0" _gui-text="Maximum displacement in X, px">10.0</param> - <param name="radiusy" type="float" min="0.0" max="1000.0" _gui-text="Maximum displacement in Y, px">10.0</param> - <param name="end" type="boolean" _gui-text="Shift nodes">true</param> - <param name="ctrl" type="boolean" _gui-text="Shift node handles">false</param> - <param name="norm" type="boolean" _gui-text="Use normal distribution">true</param> - <effect> - <object-type>path</object-type> - <effects-menu> - <submenu _name="Modify Path"/> - </effects-menu> - </effect> - <script> - <command reldir="extensions" interpreter="python">radiusrand.py</command> - </script> + <_name>Jitter nodes</_name> + <id>org.ekips.filter.radiusrand</id> + <dependency type="executable" location="extensions">radiusrand.py</dependency> + <dependency type="executable" location="extensions">inkex.py</dependency> + <param name="tab" type="notebook"> + <page name="Options" _gui-text="Options"> + <param name="radiusx" type="float" min="0.0" max="1000.0" _gui-text="Maximum displacement in X (px):">10.0</param> + <param name="radiusy" type="float" min="0.0" max="1000.0" _gui-text="Maximum displacement in Y (px):">10.0</param> + <param name="end" type="boolean" _gui-text="Shift nodes">true</param> + <param name="ctrl" type="boolean" _gui-text="Shift node handles">false</param> + <param name="norm" type="boolean" _gui-text="Use normal distribution">true</param> + </page> + <page name="Help" _gui-text="Help"> + <_param name="title" type="description">This effect randomly shifts the nodes (and optionally node handles) of the selected path.</_param> + </page> + </param> + <effect> + <object-type>path</object-type> + <effects-menu> + <submenu _name="Modify Path"/> + </effects-menu> + </effect> + <script> + <command reldir="extensions" interpreter="python">radiusrand.py</command> + </script> </inkscape-extension> diff --git a/share/extensions/radiusrand.py b/share/extensions/radiusrand.py index 15b816853..1a36d5cba 100755 --- a/share/extensions/radiusrand.py +++ b/share/extensions/radiusrand.py @@ -52,6 +52,11 @@ class RadiusRandomize(inkex.Effect): action="store", type="inkbool", dest="norm", default=True, help="Use normal distribution") + self.OptionParser.add_option("--tab", + action="store", type="string", + dest="tab", + help="The selected UI-tab when OK was pressed") + def effect(self): for id, node in self.selected.iteritems(): if node.tag == inkex.addNS('path','svg'): diff --git a/share/extensions/straightseg.inx b/share/extensions/straightseg.inx index 965b33086..45014c879 100644 --- a/share/extensions/straightseg.inx +++ b/share/extensions/straightseg.inx @@ -4,13 +4,13 @@ <id>org.ekips.filter.straightseg</id> <dependency type="executable" location="extensions">straightseg.py</dependency> <dependency type="executable" location="extensions">inkex.py</dependency> - <param name="percent" type="float" min="0.0" max="100.0" _gui-text="Percent">50.0</param> - <param name="behavior" type="int" min="1" max="2" _gui-text="Behavior">1</param> + <param name="percent" type="float" min="0.0" max="100.0" _gui-text="Percent:">50.0</param> + <param name="behavior" type="int" min="1" max="2" _gui-text="Behavior:">1</param> <effect> - <object-type>path</object-type> - <effects-menu> - <submenu _name="Modify Path"/> - </effects-menu> + <object-type>path</object-type> + <effects-menu> + <submenu _name="Modify Path"/> + </effects-menu> </effect> <script> <command reldir="extensions" interpreter="python">straightseg.py</command> diff --git a/share/extensions/whirl.inx b/share/extensions/whirl.inx index f68d99d35..a7de60f2b 100644 --- a/share/extensions/whirl.inx +++ b/share/extensions/whirl.inx @@ -4,13 +4,13 @@ <id>org.ekips.filter.whirl</id> <dependency type="executable" location="extensions">whirl.py</dependency> <dependency type="executable" location="extensions">inkex.py</dependency> - <param name="whirl" type="float" min="0.00" max="1000.00" _gui-text="Amount of whirl">5.0</param> + <param name="whirl" type="float" min="0.00" max="1000.00" _gui-text="Amount of whirl:">5.0</param> <param name="rotation" type="boolean" _gui-text="Rotation is clockwise">true</param> <effect> <object-type>path</object-type> - <effects-menu> - <submenu _name="Modify Path"/> - </effects-menu> + <effects-menu> + <submenu _name="Modify Path"/> + </effects-menu> </effect> <script> <command reldir="extensions" interpreter="python">whirl.py</command> |
