XBL
Encyclopedia
XBL is an XML
XML
Extensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....

-based markup language
Markup language
A markup language is a modern system for annotating a text in a way that is syntactically distinguishable from that text. The idea and terminology evolved from the "marking up" of manuscripts, i.e. the revision instructions by editors, traditionally written with a blue pencil on authors' manuscripts...

 used to declare
Declaration (computer science)
In programming languages, a declaration specifies the identifier, type, and other aspects of language elements such as variables and functions. It is used to announce the existence of the element to the compiler; this is important in many strongly-typed languages that require variables and their...

 the behavior and look of XUL
XUL
In computer programming, XUL , the XML User Interface Language, is an XML user interface markup language developed by the Mozilla project. XUL operates in Mozilla cross-platform applications such as Firefox...

-widgets
Widget (computing)
In computer programming, a widget is an element of a graphical user interface that displays an information arrangement changeable by the user, such as a window or a text box. The defining characteristic of a widget is to provide a single interaction point for the direct manipulation of a given...

 and XML elements.

XBL was developed by the Mozilla
Mozilla
Mozilla is a term used in a number of ways in relation to the Mozilla.org project and the Mozilla Foundation, their defunct commercial predecessor Netscape Communications Corporation, and their related application software....

 project for use in the Mozilla Application Suite
Mozilla Application Suite
The Mozilla Application Suite is a cross-platform integrated Internet suite. Its development was initiated by Netscape Communications Corporation, before their acquisition by AOL. It is based on the source code of Netscape Communicator...

; the language is not currently described by any formal standard and is thus proprietary to Mozilla, with the only implementation being the Gecko
Gecko (layout engine)
Gecko is a free and open source layout engine used in many applications developed by Mozilla Foundation and the Mozilla Corporation , as well as in many other open source software projects....

 layout engine
Layout engine
A web browser engine, , is a software component that takes marked up content and formatting information and displays the formatted content on the screen. It "paints" on the content area of a window, which is displayed on a monitor or a printer...

. XBL 2.0 is the new version of XBL, which is in process of being standardized by the World Wide Web Consortium
World Wide Web Consortium
The World Wide Web Consortium is the main international standards organization for the World Wide Web .Founded and headed by Tim Berners-Lee, the consortium is made up of member organizations which maintain full-time staff for the purpose of working together in the development of standards for the...

.

XBL basics

In XUL
XUL
In computer programming, XUL , the XML User Interface Language, is an XML user interface markup language developed by the Mozilla project. XUL operates in Mozilla cross-platform applications such as Firefox...

 one defines the user interface
User interface
The user interface, in the industrial design field of human–machine interaction, is the space where interaction between humans and machines occurs. The goal of interaction between a human and a machine at the user interface is effective operation and control of the machine, and feedback from the...

 layout of an application, and then by applying "styles" one can customize the look of various elements. The drawback is that XUL provides no means to change an element's function. For example, one might want to change how the pieces of a scroll bar work. This is where XBL comes in.

An XBL file contains "bindings
Data binding
Data binding is a general technique that binds two data/information sources together and maintains synchronization of data. This is usually done with two data/information sources with different types as in XML data binding. However, in UI data binding, data and information objects of the same type...

", each of which describes the behavior of a XUL-widget or XML element. For example, a binding might be attached to a scroll bar. The behavior describes the properties and methods
Method (computer science)
In object-oriented programming, a method is a subroutine associated with a class. Methods define the behavior to be exhibited by instances of the associated class at program run time...

 of the scroll bar and also describes the XUL elements defining the scroll bar.

The root element of an XBL file is the element, which contain one or more elements. Each element declares one binding, which can be attached to any XUL element. It may also possess an id attribute. A binding is assigned to an element by setting the CSS
Cascading Style Sheets
Cascading Style Sheets is a style sheet language used to describe the presentation semantics of a document written in a markup language...

 property -moz-binding to the URL
Uniform Resource Locator
In computing, a uniform resource locator or universal resource locator is a specific character string that constitutes a reference to an Internet resource....

 of the binding's file. For example:

scrollbar {
-moz-binding: url('somefile.xml#binding1');
}

wherein binding1 is the id of the binding.

History and future

XBL was initially developed and implemented as part of the Mozilla platform
Mozilla application framework
The Mozilla application framework is a collection of cross-platform software components that make up the Mozilla applications. It was originally known as XPFE, an abbreviation of cross-platform front end. It was also known as XPToolkit...

, alongside the XUL language, so XBL is available in most Mozilla-based products: Firefox
Mozilla Firefox
Mozilla Firefox is a free and open source web browser descended from the Mozilla Application Suite and managed by Mozilla Corporation. , Firefox is the second most widely used browser, with approximately 25% of worldwide usage share of web browsers...

, Thunderbird
Mozilla Thunderbird
Mozilla Thunderbird is a free, open source, cross-platform e-mail and news client developed by the Mozilla Foundation. The project strategy is modeled after Mozilla Firefox, a project aimed at creating a web browser...

, SeaMonkey
SeaMonkey
SeaMonkey is a free and open source cross-platform Internet suite. It is the continuation of the former Mozilla Application Suite, based on the same source code...

etc. There used to be an XBL 1.0 specification document on Mozilla.org, which was submitted to W3C as a Technical Note, but the actual implementation never did match the specification.

The new version of the specification, called XBL 2.0, is under development to address the problems of XBL 1.0 and to allow for implementation with a broader range of Web browser
Web browser
A web browser is a software application for retrieving, presenting, and traversing information resources on the World Wide Web. An information resource is identified by a Uniform Resource Identifier and may be a web page, image, video, or other piece of content...

s.

While the body of this version of the specification was created by the Mozilla project, outside the World Wide Web Consortium, as was the case for the XBL 1.0 version, the W3C Web Application Formats Working Group is now guiding this specification along the W3C Recommendation
W3C recommendation
A W3C Recommendation is the final stage of a ratification process of the World Wide Web Consortium working group concerning a technical standard. This designation signifies that a document has been subjected to a public and W3C-member organization's review. It aims to standardise the Web technology...

 track.

The Candidate Recommendation of the specification was released by W3C in March, 2007. It is stated in the document that it will remain at the Candidate stage until two complete and interoperable implementations exist.

Relationship with other specifications

The sXBL
SXBL
sXBL is a mechanism for defining the presentation and interactive behavior of elements described in a namespace other than SVG's . sXBL is very similar to XBL, as it does for SVG documents what XBL does for XUL documents...

 specification aims to do for SVG
Scalable Vector Graphics
Scalable Vector Graphics is a family of specifications of an XML-based file format for describing two-dimensional vector graphics, both static and dynamic . The SVG specification is an open standard that has been under development by the World Wide Web Consortium since 1999.SVG images and their...

 documents what XBL has done for XUL
XUL
In computer programming, XUL , the XML User Interface Language, is an XML user interface markup language developed by the Mozilla project. XUL operates in Mozilla cross-platform applications such as Firefox...

 documents. SVG is an XML language proposed by the W3C supporting graphics, animations, embedded media, events
Event-driven programming
In computer programming, event-driven programming or event-based programming is a programming paradigm in which the flow of the program is determined by events—i.e., sensor outputs or user actions or messages from other programs or threads.Event-driven programming can also be defined as an...

 and scripted
Scripting language
A scripting language, script language, or extension language is a programming language that allows control of one or more applications. "Scripts" are distinct from the core code of the application, as they are usually written in a different language and are often created or at least modified by the...

 behavior.

XBL 2.0 will supersede the sXBL draft http://lists.w3.org/Archives/Public/public-appformats/2006Sep/0093.html, as stated in the W3C Web Application Format Working Group site. Also the chapters of the
sXBL specification are a subset
Subset
In mathematics, especially in set theory, a set A is a subset of a set B if A is "contained" inside B. A and B may coincide. The relationship of one set being a subset of another is called inclusion or sometimes containment...

 of those of XBL 2.0.

See also

  • XForms
    XForms
    XForms is an XML format for the specification of a data processing model for XML data and user interface for the XML data, such as web forms...

     is also designed to be extended using XBL
  • Wikibook XForm example of XBL
  • XUL
    XUL
    In computer programming, XUL , the XML User Interface Language, is an XML user interface markup language developed by the Mozilla project. XUL operates in Mozilla cross-platform applications such as Firefox...

  • sXBL
    SXBL
    sXBL is a mechanism for defining the presentation and interactive behavior of elements described in a namespace other than SVG's . sXBL is very similar to XBL, as it does for SVG documents what XBL does for XUL documents...


Documentation/Browser implementations


Cross-Browser implementations

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK