forked from Neon22/inkscape_extension_template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtemplate.inx
96 lines (84 loc) · 4.02 KB
/
template.inx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<!-- _name must have same name as .py file but capitalise it. Shows on Menu this way-->
<_name>Template</_name>
<!-- id should be unique. Associates entered values with this menu -->
<id>githubacct.uniqueid.Name_of_your_extension</id>
<!-- mention a dependency here and will check for existence (optional)-->
<dependency type="executable" location="extensions">template.py</dependency>
<dependency type="executable" location="extensions">simplestyle.py</dependency>
<!-- start notebook -->
<param name='active-tab' type="notebook">
<!-- one per page(tab) - unique names. Can discover which page in program-->
<page name="title" _gui-text="Your Title">
<param name="param1" type="int" min="3" max="1200" _gui-text="A numeric integer value(3..1200)">12</param>
<param name="param2" type="float" min="0.1" max="1000.0" precision="5" _gui-text="A floating value">1.0</param>
<param name="param3" _gui-text="A Choice" type="optiongroup">
<!-- underscores indicate translatability -->
<_option value="choice1">Label for Choice 1</_option>
<_option value="choice2">Label for Choice 2</_option>
<_option value="choice3">Label for Choice 3</_option>
</param>
<_param name="help" type="description" xml:space="preserve">------------------------------</_param>
<param name="achoice" type="boolean" _gui-text="A boolean value">false</param>
</page>
<!-- next tab -->
<page name='advanced' _gui-text='Advanced options'>
<!-- enum with "minimal" appearance is similar to optiongroup -->
<param name="units" type="optiongroup" appearance="minimal" _gui-text="Units (minimal optiongroup)">
<option value="mm">mm</option>
<option value="cm">cm</option>
<option value="in">in</option>
<option value="pt">pt</option>
<option value="px">px</option></param>
<!-- without "minimal" = radio style -->
<param name="units2" type="optiongroup" _gui-text="Units2 (optiongroup)">
<option value="mm">mm</option>
<option value="cm">cm</option>
<option value="in">in</option>
<option value="pt">pt</option>
<option value="px">px</option></param>
<!-- an unused parameter
<param name="not_implemented" type="float" min="0" max="1000" precision="5" _gui-text="missing feature">0.5</param>
-->
<!-- enum style stretches across page to left -->
<param name="accuracy" type="enum" _gui-text="An enum">
<item value="0">automatic</item>
<item value="20">second choice</item>
<item value="12">third choice</item>
<item value="6">fourth choice</item>
</param>
<_param name="help" type="description">Some inline help.</_param>
</page>
<page name="colorex" _gui-text="More">
<param name="desc_unit" type="description">Any number of description items on page</param>
<param name="desc_unit" type="description">Only one color type on a page but can have many other params.</param>
<!-- color is just like an int. BUT only single use on a page-->
<param name="strokeColour" type="color" gui-text="Line colour: ">0</param>
</page>
<page name="Usage1" _gui-text="Usage">
<!-- space:preserve reqd for neat layout -->
<_param name="use1" type="description" xml:space="preserve">Mylabel:
A pile of useful help and usage info.
</_param>
</page>
<page name="Usage2" _gui-text="Help">
<_param name="use2" type="description" xml:space="preserve">Your help
Put your help in here.
Remember that if this is very long you will need to pad the other tabs so they space out properly.
Pad them with empty lines at the bottom to squeeze parameters up to the top.
</_param>
</page>
</param>
<!-- classify which menu it appears under - can be new name -->
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu _name="Render"/> <!-- which menu under Extensions -->
</effects-menu>
</effect>
<!-- py file again -->
<script>
<command reldir="extensions" interpreter="python">template.py</command>
</script>
</inkscape-extension>