53 lines
2.4 KiB
XML
53 lines
2.4 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<XternalApps:tool xmlns:my="http://github.com/jsmaniac/XternalApps/myTool" xmlns:XternalApps="http://github.com/jsmaniac/XternalApps" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
|
|
<XternalApps:name>MyTool</XternalApps:name>
|
|
<XternalApps:tooltip>This tool is my tool, it is very useful in a toolset.</XternalApps:tooltip>
|
|
<XternalApps:icon>MyTool.svg</XternalApps:icon>
|
|
<XternalApps:extended-description>
|
|
Lots of text,
|
|
blah blha bhal
|
|
</XternalApps:extended-description>
|
|
<!-- Internal model and default values follow: -->
|
|
<xforms:model>
|
|
<xforms:instance>
|
|
<my:tool>
|
|
<my:svgfile/>
|
|
<my:option1/>
|
|
<my:option2>default value</my:option2>
|
|
<my:option3>bar</my:option3>
|
|
</my:tool>
|
|
</xforms:instance>
|
|
<!-- to get a filename on the command-line, use:
|
|
<xforms:bind ref="my:svgfile" type="xsd:anyURI" required="true()"/>
|
|
-->
|
|
<!-- use XternalApps:pipe to have the file piped directly into the command being run -->
|
|
<xforms:bind ref="my:svgfile" type="mime:image/svg+xml" required="true()"/>
|
|
<xforms:bind ref="my:option1" type="xsd:decimal" required="true()"/>
|
|
<xforms:bind ref="my:option2" type="xsd:string" required="true()"/>
|
|
<xforms:bind ref="my:option3" type="xsd:string" required="true()"/>
|
|
<!--<xforms:submission action="myTool.py" method="exec-double-dash" />-->
|
|
<XternalApps:command medhod="exec" style="double-dash">
|
|
<XternalApps:exception ref="my:svgfile" style="pipe" />
|
|
<XternalApps:returns style="pipe" type="image/svg+xml" />
|
|
</XternalApps:command>
|
|
</xforms:model>
|
|
<!-- Description of the user interface follows: -->
|
|
<xforms:group>
|
|
<xforms:label>Page 1</xforms:label>
|
|
<xforms:input ref="my:option1" label="Option One ∀"/>
|
|
<xforms:input ref="my:option2" label="Option Two π"/>
|
|
<xforms:upload ref="my:svgfile" accept="image/svg+xml">
|
|
<xforms:label>Input image</xforms:label>
|
|
<xforms:filename ref="@filename" />
|
|
</xforms:upload>
|
|
</xforms:group>
|
|
<xforms:group>
|
|
<xforms:label>Page 2</xforms:label>
|
|
<xforms:input ref="my:option2" label="Option Two"/>
|
|
<xforms:select1 ref="my:option3" label="Option Three">
|
|
<xforms:item label="Foo label" value="foo"/>
|
|
<xforms:item label="Bar label" value="bar"/>
|
|
</xforms:select1>
|
|
</xforms:group>
|
|
</XternalApps:tool>
|