The contents of a package can be divided into five primary components. They are the building blocks from which user interfaces are constructed. A radio-button is a widget, as is a menu, or a scrollbar. XPToolkit provides a cross-platform implementation for all of the XUL tags. It is the intent that one day these implementations will be pluggable, so that a third party will be able to drop in a completely different implementation of a given widget, but for now that is not the case.
Widgets can be simple or complex.
They can even be composed of other widgets. A toolbar-widget, for example, can contain several button widgets. Appearance - The appearance of the content can be customized using Cascading Style Sheets . Just as style can be applied to HTML content, it can also be applied to XUL content. Behavior - The behavior of the package is defined using JavaScript, services, and the application object model.