Edje is a complex graphical design & layout library based on Evas that provides an abstraction layer between the application code and the interface, while allowing extremely flexible dynamic layouts and animations.
In more popular terms, Edje makes every application that uses it "skinable" .
"Edje is an attempt to find a middleground between theming and programming without turning the theme itself into just yet another program." -- Carsten Haitzler (The Rasterman)
Edje supports the the creation of visual elements (borders of windows, scrollbars, etc.) allowing the designer to control the layout, look and feel and gui animation of any program using Edje as its basic GUI constructor. This library allows for multiple collections of Layouts in one file, sharing the same image database and thus allowing a whole theme to be conveniently packaged into one file for ease of distribution.
Edje separates the layout and behavior logic. Edje files ship with an image database, used by all the parts in all the collections to source graphical data. It has a directory of logical part names pointing to the part collection entry ID in the file (thus allowing for multiple logical names to point to the same part collection, allowing for the sharing of data between display elements). Each part collection consists of a list of visual parts, as well as a list of programs. A program is a conditionally run program that if a particular event occurs (a button is pressed, a mouse enters or leaves a part) will trigger an action that may affect other parts. In this way a part collection can be "programmed" via its file as to hilight buttons when the mouse passes over them or show hidden parts when a button is clicked somewhere etc. The actions performed in changing from one state to another are also allowed to transition over a period of time, allowing animation.
This separation and simplistic event driven style of programming can produce almost any look and feel one could want for basic visual elements. Anything more complex is likely the domain of an application or widget set that may use Edje as a convenient way of being able to configure parts of the display.
History
Edje is a replacement for "Ebits" which to date has serviced the needs of Enlightenment development for version 0.17. The original design parameters under which Ebits came about were a lot more restricted than the resulting use of them, thus Edje was born. Edje is a more complex layout engine compared to Ebits. It doesn't pretend to do containing and regular layout like a widget set. It still inherits the more simplistic layout ideas behind Ebits, but it now does them a lot more cleanly, allowing for easy expansion, and the ability to cover much more ground than Ebits ever could. Edje separates layout and behavior logic unlike Ebits.
How does Edje work?
Edje internally holds a geometry state machine and state graph of what is visible, where it is, its size, colors, etc. This information is stored on a .eet file. These files are produced by the edje_cc tool, which takes a text file (.edc) as input and "compiles" it onto the .eet (information, images, fonts and any other data needed).
Library Dependency Notes
- Evas - Edje needs Evas to be built with at least PNG and EET image loaders. Edje uses X for the test program, so you will need the SOFTWARE_X11 engine built into Evas as well.
- Ecore - Edje also needs Ecore to be built with at least ECORE_EVAS and ECORE_X modules.
Depends on: Evas Ecore Eet Embryo Eina lua-5.1
Software
Documentation
- Edje Basics
- Edje Data Collection
- Edje Group
- Edje Part
- Edje Part Positioning
- Edje Color Notation
- Edje Image Part
- Edje Text Part
- Edje Textblock Part
- Edje Style
- Edje Program
- EdjeEditor?
- ApplicationDevelopmentWithEdjeWorkflow
- Building Interfaces with Edge (PDF) - may be out of date
ROADMAP
Features for future versions.
1.1:
- Much more expansive LUA API for script-only objects
- Object cache (keep some objects around speculatively)
- Audio support (tracks, patterns, samples, ogg encoded lossy audio)
