The Widget Package Descriptor
Below is an example zk.wpd of our SimpleLabel.
<package name="com.foo" language="xul/html"> <widget name="SimpleLabel"/> </package>
The table below describes the elements used within the above XML and their description.
|package||The root element denotes the package name and the language it belongs to|
|widget||The widget class name (without the package name). If the package contains multiple widgets list them one by one|
Having created the configuration the basic implementation of our component is complete. However it will not have any interactive events. Therefore the next logical step is to start adding events to the component.
zul.grid depends on
zul.menu. This can easily be specified by placing them within the
depends attribute as follows.
<package name="zul.grid" language="xul/html" depends="zul.mesh,zul.menu"> <widget name="Column"/> <widget name="Columns"/> <widget name="Grid"/> <widget name="Row"/> <widget name="Rows"/> <widget name="Foot"/> <widget name="Footer"/> </package>
script element. For example, the following is the content of
<package name="zul.db" language="xul/html" depends="zk.fmt,zul.inp"> <script src="datefmt.js"/> <widget name="Calendar"/> <widget name="Datebox"/> </package>
For more information, please refer to ZK Client-side Reference: Widget Package Descriptor.