Creating the Extension for Custom Interface Operations

The file EmptyGUI.xml follows.

<extension version="1" name="EmptyGUI">
    <guid shortid="EmptyGUI">69d0095b-e138-4841-a13a-de12238c83f6</guid>
    <script src="empty_gui.py" />
    <interface context="Project">
        <images>images</images>
    </interface>
      <workflow name="wf3" context="Project" version="1">
        <tasks>
            <task name="Empty" caption="Empty" icon="Generic_cell" version="1">
                <callbacks>
                    <onupdate>update</onupdate>
                </callbacks>
                <inputs>
                    <input/>
                </inputs>
                <outputs/>
                <contextmenus>
                    <entry name="Empty Gui Op" type="ContextMenuEntry" priority="1.0" icon="default_op">
                        <callbacks>
                            <onclick>click</onclick>
                        </callbacks>
                    </entry>
                </contextmenus>
            </task>
        </tasks>
        <taskgroups>
            <taskgroup name="Empty" caption="Empty" icon="Generic" category="ACT Custom Workflows" abbreviation="MT" version="1">
                <includeTask name="Empty" caption="Empty"/>
            </taskgroup>
        </taskgroups>
      </workflow>
</extension>

This XML file performs the following actions:

  • References the IronPython script empty_gui.py.

  • Defines a single task in the element <tasks>. Within this element, a single context menu is defined in the element <contextmenus>. The callback <onclick> is defined, as required.

  • Defines the inputs and outputs in the elements <inputs> and <outputs>. Note that an empty input and an output are defined.

  • Defines a single task group with a single task in the element <taskgroups>.