XUL is an XML variant that can be used to create application user interfaces. It can also be used as an element in creating entire applications. This article, the first in a series, introduces you to the idea and helps you get your system ready to start creating.
Back to XUL: Introduction and Preparation - Creating applications with XUL (Page 2 of 4 )
XUL is just an XML variant used to describe interfaces, you may be thinking, so how can you create entire applications with it? Well, the truth is, you canít. You need something else to glue the various elements together and turn them into functioning entities that work together to actually do things.
The chrome architecture provides a method for granting special permissions to XUL files, such as permission to open or write to files, among other things. XUL files that have these permissions are accessed using a chrome URL, much in the same way as a web page is accessed via an HTTP URL. Chrome includes all interface, presentation and locale files present and registered for you with Mozilla; it is a kind of catch-all term for these so when you add, say, a new toolbar to Mozilla, you are adding chrome.
Like a browser that interprets HTML elements and displays them on-screen, XUL elements are rendered according to the Gecko layout engine, which controls, in part, how the components of the Mozilla browser and the files it displays appear.
All of these things and more combine with XUL to form fully functional applications that can run either within Mozilla or as separate applications in their own right (although components of Mozilla will be used when doing this). During the course of these articles we will look at these in more detail.