XLEFF - an XML Layout Engine For Flash

Article
The Present and the Future of XLEFF
Phase I - Genesis
This article should be of interest to anyone who is considering utilizing XLEFF in a project (see the license) and, also, to experienced developers willing to contribute to the evolution of this software (see the contact).

The current version of XLEFF is released under an open source license that makes the number of its applications basically limitless, since the source code allows you to customize it to fit in your projects. The license allows you to use and modify XLEFF in your own projects as long as, in fairness, you give credit to the author of the original work.

In this article I will describe the present of XLEFF and guess about its future that depends on several factors, starting from its technological dependencies.

XLEFF Tech Dependencies

XLEFF is implemented using ActionScript 2 and it generates user interfaces utilizing what was originally called the Macromedia Component Architecture version 2, initially appearing in Flash MX2004 and still present in Flash 8.

Those dependencies imply that, in order to run XLEFF, you must be working with:

  • ActionScript 2
  • Flash MX2004 or Flash 8 (Professional editions)

The advent of ActionScript 3 and of a new version of the component architecture will require a major porting of XLEFF into the new platform.

Both Flash MX2004 and Flash 8 are major versions of the authoring environment, meaning that they will stay around for quite a long time even after the next generation of Flash comes out.

That fact alone gives the current version of XLEFF a status of "lively" piece of software for the next couple of years at least.

It is my intention to port XLEFF into the next generation of Flash. However, XLEFF users should not rely on that since XLEFF is not a commercial product: it is not supported and none of its future developments are granted. Quite simply, you are on your own when using it.

When designing XLEFF I envisioned three phases of its life cycle, each of them identified by different objectives.

Knowing those objectives may well help you in deciding if it's the case to use XLEFF in your projects or not.

Phase I Objectives

The definition of the objectives of the first and current phase (Genesis) has been heavily influenced by the fact that I originally designed XLEFF for internal use only.

Such beginnings account for both strengths and weaknesses of the current version.

The major weakness is the lack of documentation that is arguably the main objective of the next phase (Maturation).

Documenting a software design can be very expensive in terms of time and that somewhat explains the frequent lack of documentation that developers experience even in the case of commercial software.

On the other hand, to produce a robust, highly readable and easily maintainable code was the main objective of XLEFF since its inception. If you know ActionScript 2 pretty well, you may benefit from that without suffering from the lack of documentation.

Another major objective of the first phase was to have a very flexible design to allow for the many extensions that an XML Layout Engine may and should include.

Readability and flexibility have been arguably achieved by pushing the object-orientated paradigm.

The XModel class is the most visible example of this approach since it extends the ActionScript built-in XML parser in order to produce an object model automatically, starting from XML data.

First Conclusion

If your experience with ActionScript is still superficial, you may be interested in XLEFF for the limited purpose to learn from the code and reuse part of it (for instance, the XModel class can be used stand-alone in your XML projects without requiring any other XLEFF class - see my recent book "Mastering the Flash Component Architecture" for a chapter describing the use of this class or, alternatively, wait for the upcoming article on this website).

If instead you are an experienced ActionScript developer, you do not need any suggestion from me about how to use XLEFF. Just download the code and make up your own mind about it.

The next section introduces the objectives currently set for the second phase of XLEFF.

Recommended Book

Published: February 27, 2006

Mastering
the Flash Component Architecture

by Antonio De Donatis
Mastering the Flash Component Architecture

The Flash authoring environment comes with a hidden treasure.

Apart from the powerful components that can enable the development of Rich Internet Applications, it also includes the source code of the whole component architecture that you can use to learn how to customize the existing components and how to reuse its rich functionality, with the help of this essential book from the AdvancED series of friends of ED.

Core Sections

  • XLEFF Sampler
  • XLEFF Source Code
  • XLEFF Genesis


An XML Layout Engine For FlashCopyright © 2005-2006 Antonio De Donatis