Edje Data Collection reference

An Edje Data Collection, it's a plain text file (normally identified with the .edc extension),consisting of instructions for the Edje Compiler.

The syntax for the edje data collection files follows a simple structure of "blocks { .. }" that can contain "properties: ..", more blocks, or both.

Quick access to block descriptions:

Author:
Andres Blanc (dresb) andresblanc@gmail.com

Top-Level blocks

externals
        externals {
           external: "name";
        }
 

The "externals" block is used to list each external module file that will be used in others programs.

 
external [external filename]
 Used to add a file to the externals list.

images

        images {
            image: "filename1.ext" COMP;
            image: "filename2.ext" LOSSY 99;
        set {
           name: "image_name_used";
               image {
                  image: "filename3.ext" LOSSY 90;
                  size: 201 201 500 500;
               }
               image {
                  image: "filename4.ext" COMP;
                  size: 51 51 200 200;
               }
               image {
                  image: "filename5.ext" COMP;
                  size: 11 11 50 50;
               }
               image {
                  image: "filename6.ext" RAW;
                  size: 0 0 10 10;
               }
            }
            ..
        }
 

The "images" block is used to list each image file that will be used in the theme along with its compression method (if any). Besides the document's root, additional "images" blocks can be included inside other blocks, normally "collections", "group" and "part", easing maintenance of the file list when the theme is split among multiple files.

 
image [image file] [compression method] (compression level)
 Used to include each image file. The full path to the directory holding the images can be defined later with edje_cc's "-id" option. Compression methods:
  • RAW: Uncompressed.
  • COMP: Lossless compression.
  • LOSSY [0-100]: Lossy comression with quality from 0 to 100.
  • USER: Do not embed the file, refer to the external file instead.

set

    set {
       name: "image_name_used";
       image {
          image: "filename3.ext" LOSSY 90;
          size: 201 201 500 500;
       }
       image {
          image: "filename4.ext" COMP;
          size: 51 51 200 200;
       }
       image {
          image: "filename5.ext" COMP;
          size: 11 11 50 50;
       }
       image {
          image: "filename6.ext" RAW;
          size: 0 0 10 10;
       }
    }
 

The "set" block is used to define an image with different content depending on their size. Besides the document's root, additional "set" blocks can be included inside other blocks, normally "collections", "group" and "part", easing maintenance of the file list when the theme is split among multiple files.

 

name [image name]
 Define the name that refer to this image description.

 

size [minw minh maxw mawh]
 Define the minimal and maximal size that will select the specified image.

fonts

        fonts {
            font: "filename1.ext" "fontname";
            font: "filename2.ext" "otherfontname";
            ..
        }
 

The "fonts" block is used to list each font file with an alias used later in the theme. As with the "images" block, additional "fonts" blocks can be included inside other blocks.

 
font [font filename] [font alias]
 Defines each font "file" and "alias", the full path to the directory holding the font files can be defined with edje_cc's "-fd" option.

data

        data {
            item: "key" "value";
            file: "otherkey" "filename.ext";
            ..
        }
 

The "data" block is used to pass arbitrary parameters from the theme to the application. Unlike the "images" and "fonts" blocks, additional "data" blocks can only be included inside the "group" block.

 
item [parameter name] [parameter value]
 Defines a new parameter, the value will be the string specified next to it.

 

file [parameter name] [parameter filename]
 Defines a new parameter , the value will be the contents of the specified file formated as a single string of text. This property only works with plain text files.

color_classes

        color_classes {
            color_class {
                name:  "colorclassname";
                color:  [0-255] [0-255] [0-255] [0-255];
                color2: [0-255] [0-255] [0-255] [0-255];
                color3: [0-255] [0-255] [0-255] [0-255]
            }
            ..
        }
 

The "color_classes" block contains a list of one or more "color_class" blocks. Each "color_class" allows the designer to name an arbitrary group of colors to be used in the theme, the application can use that name to alter the color values at runtime.

 

name [color class name]
 Sets the name for the color class, used as reference by both the theme and the application.

 

color [red] [green] [blue] [alpha]
 The main color.

 

color2 [red] [green] [blue] [alpha]
 Used as shadow in text and textblock parts.

 

color3 [red] [green] [blue] [alpha]
 Used as outline in text and textblock parts.

styles

        styles {
            style {
                name: "stylename";
                base: "..default style properties..";

                tag:  "tagname" "..style properties..";
                ..
            }
            ..
        }
 

The "styles" block contains a list of one or more "style" blocks. A "style" block is used to create style <tags> for advanced TEXTBLOCK formatting.

 

name [style name]
 The name of the style to be used as reference later in the theme.

 

base [style properties string]
 The default style properties that will be applied to the complete text.

 

tag [tag name] [style properties string]
 Style to be applied only to text between style <tags>..</tags>.

collections

        collections {
            ..
            group { }
            group { }
            ..
        }
 

The "collections" block is used to list the groups that compose the theme. Additional "collections" blocks do not prevent overriding group names.

Group sub blocks

group
        collections {
            ..
            group {
                name: "nameusedbytheapplication";
                alias: "anothername";
                min: width height;
                max: width height;

                data { }
                script { }
                parts { }
                programs { }
            }
            ..
        }
 

A "group" block contains the list of parts and programs that compose a given Edje Object.

 

name [group name]
 The name that will be used by the application to load the resulting Edje object and to identify the group to swallow in a GROUP part. If a group with the same name exists already it will be completely overriden by the new group.

 

script_only [on/off]
 The flag (on/off) as to if this group is defined ONLY by script callbacks such as init(), resize() and shutdown()

 

alias [aditional group name]
 Additional name to serve as identifier. Defining multiple aliases is supported.

 

min [width] [height]
 The minimum size for the container defined by the composition of the parts. It is not enforced.

 

max [width] [height]
 The maximum size for the container defined by the totality of the parts. It is not enforced.

script

        ..
        group {
            script {
                //embryo script
            }
            ..
            program {
                script {
                    //embryo script
                }
            }
            ..
        }
        ..
 

This block is used to "inject" embryo scripts to a given Edje theme and it functions in two modalities. When it's included inside a "program" block, the script will be executed every time the program is run, on the other hand, when included directly into a "group", "part" or "description" block, it will be executed once at load time, in the load order.

parts

        group {
            parts {
                alias: "theme_part_path" "real_part_path";
                ..
            }
        }
 

Alias of part give a chance to let the designer put the real one in a box or reuse one from a GROUP or inside a BOX.

part

        group {
            parts {
                ..
                part {
                    name: "partname";
                    type: IMAGE;
                    mouse_events:  1;
                    repeat_events: 0;
                    ignore_flags: NONE;
                    clip_to: "anotherpart";
                    source:  "groupname";
                    pointer_mode: AUTOGRAB;
                    use_alternate_font_metrics: 0;

                    description { }
                    dragable { }
                    items { }
                }
                ..
            }
        }
 

Parts are used to represent the most basic design elements of the theme, for example, a part can represent a line in a border or a label on a button.

 

name [part name]
 The part's name will be used as reference in the theme's relative positioning system, by programs and in some cases by the application. It must be unique within the group.

 

type [TYPE]
 Set the type (all caps) from among the available types, it's set to IMAGE by default. Valid types:
  • RECT
  • TEXT
  • IMAGE
  • SWALLOW
  • TEXTBLOCK
  • GROUP
  • BOX
  • TABLE
  • EXTERNAL

 

mouse_events [1 or 0]
 Specifies whether the part will emit signals, altought is named "mouse_events", disabling it (0) will prevent the part from emitting any type of signal at all. Its set to 1 by default.

 

repeat_events [1 or 0]
 Specifies whether a part echoes a mouse event to other parts below the pointer (1), or not (0). Its set to 0 by default.

 

ignore_flags [FLAG] ...
 Specifies whether events with the given flags should be ignored, i.e., will not have the signals emitted to the parts. Multiple flags must be separated by spaces, the effect will be ignoring all events with one of the flags specified. Possible flags:
  • NONE (default value, no event will be ignored)
  • ON_HOLD

 

scale [1 or 0]
 Specifies whether the part will scale its size with an edje scaling factor. By default scale is off (0) and the default scale factor is 1.0 - that means no scaling. This would be used to scale properties such as font size, min/max size of the part, and possibly can be used to scale based on DPI of the target device. The reason to be selective is that some things work well being scaled, others do not, so the designer gets to choose what works best.

 

pointer_mode [MODE]
 Sets the mouse pointer behavior for a given part. The default value is AUTOGRAB. Aviable modes:
  • AUTOGRAB, when the part is clicked and the button remains pressed, the part will be the source of all future mouse signals emitted, even outside the object, until the button is released.
  • NOGRAB, the effect will be limited to the part's container.

 

precise_is_inside [1 or 0]
 Enables precise point collision detection for the part, which is more resource intensive. Disabled by default.

 

use_alternate_font_metrics [1 or 0]
 Only affects text and textblock parts, when enabled Edje will use different size measurement functions. Disabled by default. (note from the author: I don't know what this is exactlu useful for?)

 

clip_to [another part's name]
 Only renders the area of part that coincides with another part's container. Overflowing content will not be displayed.

 

source [another group's name]
 Only available to GROUP or TEXTBLOCK parts. Swallows the specified group into the part's container if a GROUP. If TEXTBLOCK it is used for the group to be loaded and used for selection display UNDER the selected text. source2 is used for on top of the selected text, if source2 is specified.

 

source2 [another group's name]
 Only available to TEXTBLOCK parts. It is used for the group to be loaded and used for selection display OVER the selected text. source is used for under of the selected text, if source is specified.

 

source3 [another group's name]
 Only available to TEXTBLOCK parts. It is used for the group to be loaded and used for cursor display UNDER the cursor position. source4 is used for over the cursor text, if source4 is specified.

 

source4 [another group's name]
 Only available to TEXTBLOCK parts. It is used for the group to be loaded and used for cursor display OVER the cursor position. source3 is used for under the cursor text, if source4 is specified.

 

source5 [another group's name]
 Only available to TEXTBLOCK parts. It is used for the group to be loaded and used for anchors display UNDER the anchor position. source6 is used for over the anchors text, if source6 is specified.

 

source6 [another group's name]
 Only available to TEXTBLOCK parts. It is used for the group to be loaded and used for anchor display OVER the anchor position. source5 is used for under the anchor text, if source6 is specified.

 

effect [EFFECT]
 Causes Edje to draw the selected effect among:
  • PLAIN
  • OUTLINE
  • SOFT_OUTLINE
  • SHADOW
  • SOFT_SHADOW
  • OUTLINE_SHADOW
  • OUTLINE_SOFT_SHADOW
  • FAR_SHADOW
  • FAR_SOFT_SHADOW
  • GLOW

 

entry_mode [MODE]
 Sets the edit mode for a textblock part to one of:
  • NONE
  • PLAIN
  • EDITABLE
  • PASSWORD It causes the part be editable if the edje object has the keyboard focus AND the part has the edje focus (or selectable always regardless of focus) and in the event of password mode, not selectable and all text chars replaced with *'s but editable and pastable.

 

select_mode [MODE]
 Sets the selection mode for a textblock part to one of:
  • DEFAULT
  • EXPLICIT DEFAULT selection mode is what you would expect on any desktop. Press mouse, drag and release to end. EXPLICIT mode requires the application controlling the edje object has to explicitly begin and end selection modes, and the selection itself is dragable at both ends.

 

multiline [1 or 0]
 It causes a textblock that is editable to allow multiple lines for editing.

dragable

        part {
            ..
            dragable {
                confine: "another part";
                events:  "another dragable part";
                x: 0 0 0;
                y: 0 0 0;
            }
            ..
        }
 

When this block is used the resulting part can be dragged around the interface, do not confuse with external drag & drop. By default Edje (and most applications) will attempt to use the minimal size possible for a dragable part. If the min property is not set in the description the part will be (most likely) set to 0px width and 0px height, thus invisible.

 
x [enable/disable] [step] [count]
 Used to setup dragging events for the X axis. The first parameter is used to enable (1 or -1) and disable (0) dragging along the axis. When enabled, 1 will set the starting point at 0.0 and -1 at 1.0. The second parameter takes any integer and will limit movement to values divisible by it, causing the part to jump from position to position. The third parameter, (question from the author: What is count for?).

 

y [enable/disable] [step] [count]
 Used to setup dragging events for the Y axis. The first parameter is used to enable (1 or -1) and disable (0) dragging along the axis. When enabled, 1 will set the starting point at 0.0 and -1 at 1.0. The second parameter takes any integer and will limit movement to values divisibles by it, causing the part to jump from position to position. The third parameter, (question from the author: What is count for?).

 

confine [another part's name]
 When set, limits the movement of the dragged part to another part's container. When you use confine don't forget to set a min size for the part, or the draggie will not show up.

 

events [another dragable part's name]
 It causes the part to forward the drag events to another part, thus ignoring them for itself.

items

        part {
            ..
        box {
                items {
                    item {
                        type: TYPE;
                        source: "some source";
                        min: 1 1;
                        max: 100 100;
                        padding: 1 1 2 2;
                    }
                    item {
                        type: TYPE;
                        source: "some other source";
                        name: "some name";
                        align: 1.0 0.5;
                    }
                    ..
                }
        }
            ..
        }
 

On a part of type BOX, this block can be used to set other groups as elements of the box. These can be mixed with external objects set by the application through the edje_object_part_box_* API.

 

type Only GROUP for now (defaults to it)
 Sets the type of the object this item will hold.

 

name [name for the object]
 Sets the name of the object via evas_object_name_set().

 

source [another group's name]
 Sets the group this object will be made from.

 

min [width] [height]
 Sets the minimum size hints for this object.

 

prefer [width] [height]
 Sets the preferred size hints for this object.

 

max [width] [height]
 Sets the maximum size hints for this object.

 

padding [left] [right] [top] [bottom]
 Sets the padding hints for this object.

 

align [x] [y]
 Sets the alignment hints for this object.

 

weight [x] [y]
 Sets the weight hints for this object.

 

aspect [w] [h]
 Sets the aspect width and height hints for this object.

 

aspect_mode NONE, NEITHER, HORIZONTAL, VERTICAL, BOTH
 Sets the aspect control hints for this object.

 

options [extra options]
 Sets extra options for the object. Unused for now.

 

position [col] [row]
 Sets the position this item will have in the table. This is required for parts of type TABLE.

 

span [col] [row]
 Sets how many columns/rows this item will use. Defaults to 1 1.

State description sub blocks

description
        description {
            inherit: "another_description" INDEX;
            state: "description_name" INDEX;
            visible: 1;
            min: 0 0;
            max: -1 -1;
            align: 0.5 0.5;
            fixed: 0 0;
            step: 0 0;
            aspect: 1 1;

            rel1 {
                ..
            }

            rel2 {
                ..
            }
        }
 

Every part can have one or more description blocks. Each description is used to define style and layout properties of a part in a given "state".

 

inherit [another description's name] [another description's index]
 When set, the description will inherit all the properties from the named description. The properties defined in this part will override the inherited properties, reducing the amount of necessary code for simple state changes. Note: inheritance in Edje is single level only.

 

state [a name for the description] [an index]
 Sets a name used to identify a description inside a given part. Multiple descriptions are used to declare different states of the same part, like "clicked" or "invisible". All states declarations are also coupled with an index number between 0.0 and 1.0. All parts must have at least one description named "default 0.0".

 

visible [0 or 1]
 Takes a boolean value specifying whether part is visible (1) or not (0). Non-visible parts do not emit signals. The default value is 1.

 

align [X axis] [Y axis]
 When the displayed object's size is smaller than its container, this property moves it relatively along both axis inside its container. The default value is "0.5 0.5".

 

fixed [width, 0 or 1] [height, 0 or 1]
 This affects the minimum size calculation. See edje_object_size_min_calc() and edje_object_size_min_restricted_calc(). This tells the min size calculation routine that this part does not change size in width or height (1 for it doesn't, 0 for it does), so the routine should not try and expand or contract the part.

 

min [width] [height]
 The minimum size of the state.

 

max [width] [height]
 The maximum size of the state.

 

step [width] [height]
 Restricts resizing of each dimension to values divisibles by its value. This causes the part to jump from value to value while resizing. The default value is "0 0" disabling stepping.

 

aspect [min] [max]
 Normally width and height can be resized to any values independently. The aspect property forces the width to height ratio to be kept between the minimum and maximum set. For example, "1.0 1.0" will increase the width a pixel for every pixel added to heigh. The default value is "0.0 0.0" disabling aspect.

 

aspect_preference [DIMENSION]
 Sets the scope of the "aspect" property to a given dimension. Available options are BOTH, VERTICAL, HORIZONTAL and NONE

 

color_class [color class name]
 The part will use the color values of the named color_class, these values can be overrided by the "color", "color2" and "color3" properties set below.

 

color [red] [green] [blue] [alpha]
 Sets the main color to the specified values (between 0 and 255).

 

color2 [red] [green] [blue] [alpha]
 Sets the text shadow color to the specified values (0 to 255).

 

color3 [red] [green] [blue] [alpha]
 Sets the text outline color to the specified values (0 to 255).

rel1/rel2

        description {
            ..
            rel1 {
                relative: 0.0 0.0;
                offset:     0   0;
            }
            ..
            rel2 {
                relative: 1.0 1.0;
                offset:    -1  -1;
            }
            ..
        }
 

The rel1 and rel2 blocks are used to define the position of each corner of the part's container. With rel1 being the left-up corner and rel2 being the right-down corner.

 
relative [X axis] [Y axis]
 Moves a corner to a relative position inside the container of the relative "to" part. Values from 0.0 (0%, beginning) to 1.0 (100%, end) of each axis.

 

offset [X axis] [Y axis]
 Affects the corner position a fixed number of pixels along each axis.

 

to [another part's name]
 Causes a corner to be positioned relatively to another part's container.

 

to_x [another part's name]
 Causes a corner to be positioned relatively to the X axis of another part's container. Simply put affects the first parameter of "relative".

 

to_y [another part's name]
 Causes a corner to be positioned relatively to the Y axis of another part's container. Simply put, affects the second parameter of "relative".

Image state description sub blocks

image
        description {
            ..
            image {
                normal: "filename.ext";
                tween:  "filename2.ext";
                ..
                tween:  "filenameN.ext";
                border:  left right top bottom;
                middle:  0/1/NONE/DEFAULT/SOLID;
            }
            ..
        }
 

 
normal [image's filename]
 Name of image to be used as previously declared in the images block. In an animation, this is the first and last image displayed. It's required in any image part

 

tween [image's filename]
 Name of an image to be used in an animation loop, an image block can have none, one or multiple tween declarations. Images are displayed in the order they are listed.

 

border [left] [right] [top] [bottom]
 If set, the area (in pixels) of each side of the image will be displayed as a fixed size border, from the side -> inwards, preventing the corners from being changed on a resize.

 

middle 0, 1, NONE, DEFAULT, SOLID
 If border is set, this value tells Edje if the rest of the image (not covered by the defined border) will be displayed or not or be assumed to be solid (without alpha). The default is 1/DEFAULT.

 

border_scale 0, 1
 If border is set, this value tells Edje if the border should be scaled by the object/global edje scale factors

 

scale_hint 0, NONE, DYNAMIC, STATIC
 Sets the evas image scale hint letting the engine more effectively save cached copies of the scaled image if it makes sense

fill

        description {
            ..
            fill {
                smooth: 0-1;
                origin {
                    relative: X-axis Y-axis;
                    offset:   X-axis Y-axis;
                }
                size {
                    relative: width  height;
                    offset:   width  height;
                }
            }
            ..
        }
 

The fill method is an optional block that defines the way an IMAGE part is going to be displayed inside its container.

 
smooth [0 or 1]
 The smooth property takes a boolean value to decide if the image will be smoothed on scaling (1) or not (0). The default value is 1.

 

spread TODO
 TODO

 

type TODO
 TODO

origin

        description {
            ..
            fill {
                ..
                origin {
                    relative: 0.0 0.0;
                    offset:   0   0;
                }
                ..
            }
            ..
        }
 

The origin block is used to place the starting point, inside the displayed element, that will be used to render the tile. By default, the origin is set at the element's left-up corner.

 
relative [X axis] [Y axis]
 Sets the starting point relatively to displayed element's content.

 

offset [X axis] [Y axis]
 Affects the starting point a fixed number of pixels along each axis.

size

        description {
            ..
            fill {
                ..
                size {
                    relative: 1.0 1.0;
                    offset:  -1  -1;
                }
                ..
            }
            ..
        }
 

The size block defines the tile size of the content that will be displayed.

 
relative [width] [height]
 Takes a pair of decimal values that represent the a percentual value of the original size of the element. For example, "0.5 0.5" represents half the size, while "2.0 2.0" represents the double. The default value is "1.0 1.0".

 

offset [X axis] [Y axis]
 Affects the size of the tile a fixed number of pixels along each axis.

Text state description sub blocks

text
        part {
            description {
                ..
                text {
                    text:        "some string of text to display";
                    font:        "font_name";
                    size:         SIZE;
                    text_class:  "class_name";
                    fit:          horizontal vertical;
                    min:          horizontal vertical;
                    max:          horizontal vertical;
                    align:        X-axis     Y-axis;
                    source:      "part_name";
                    text_source: "text_part_name";
                    elipsis:      0.0-1.0;
                    style:       "stylename";
                }
                ..
            }
        }
 

 
text [a string of text, or nothing]
 Sets the default content of a text part, normally the application is the one changing its value.

 

text_class [text class name]
 Similar to color_class, this is the name used by the application to alter the font family and size at runtime.

 

font [font alias]
 This sets the font family to one of the aliases set up in the "fonts" block. Can be overrided by the application.

 

style [the style name]
 Causes the part to use the default style and tags defined in the "style" block with the specified name.

 

repch [the replacement character string]
 If this is a textblock and is in PASSWORD mode this string is used to replace every character to hide the details of the entry. Normally you would use a "*", but you can use anything you like.

 

size [font size in points (pt)]
 Sets the default font size for the text part. Can be overrided by the application.

 

fit [horizontal] [vertical]
 When any of the parameters is set to 1 edje will resize the text for it to fit in it's container. Both are disabled by default.

 

min [horizontal] [vertical]
 When any of the parameters is enabled (1) it forces the minimum size of the container to be equal to the minimum size of the text. The default value is "0 0".

 

max [horizontal] [vertical]
 When any of the parameters is enabled (1) it forces the maximum size of the container to be equal to the maximum size of the text. The default value is "0 0".

 

align [horizontal] [vertical]
 Change the position of the point of balance inside the container. The default value is 0.5 0.5.

 

source [another TEXT part's name]
 Causes the part to use the text properties (like font and size) of another part and update them as they change.

 

text_source [another TEXT part's name]
 Causes the part to display the text content of another part and update them as they change.

 

elipsis [point of balance]
 Used to balance the text in a relative point from 0.0 to 1.0, this point is the last section of the string to be cut out in case of a resize that is smaller than the text itself. The default value is 0.0.

Box state description sub blocks

box
        part {
            description {
                ..
                box {
                    layout: "vertical";
                    padding: 0 2;
                    align: 0.5 0.5;
            min: 0 0;
                }
                ..
            }
        }
 

A box block can contain other objects and display them in different layouts, any of the predefined set, or a custom one, set by the application.

 
layout [primary layout] [fallback layout]
 Sets the layout for the box:
  • horizontal (default)
  • vertical
  • horizontal_homogeneous
  • vertical_homogeneous
  • horizontal_max (homogeneous to the max sized child)
  • vertical_max
  • horizontal_flow
  • vertical_flow
  • stack
  • some_other_custom_layout_set_by_the_application You could set a custom layout as fallback, it makes very very little sense though, and if that one fails, it will default to horizontal.

 
align [horizontal] [vertical]
 Change the position of the point of balance inside the container. The default value is 0.5 0.5.

 
padding [horizontal] [vertical]
 Sets the space between cells in pixels. Defaults to 0 0.

 
min [horizontal] [vertical]
 When any of the parameters is enabled (1) it forces the minimum size of the box to be equal to the minimum size of the items. The default value is "0 0".

Table state description sub blocks

table
        part {
            description {
                ..
                table {
                    homogeneous: TABLE;
                    padding: 0 2;
                    align: 0.5 0.5;
                }
                ..
            }
        }
 

A table block can contain other objects packed in multiple columns and rows, and each item can span across more than one column and/or row.

 
homogeneous [homogeneous mode]
 Sets the homogeneous mode for the table:
  • NONE (default)
  • TABLE
  • ITEM

 
align [horizontal] [vertical]
 Change the position of the point of balance inside the container. The default value is 0.5 0.5.

 
padding [horizontal] [vertical]
 Sets the space between cells in pixels. Defaults to 0 0.

Map state description sub blocks

map
    description {
        ..
        map {
            perspective: "name";
            light: "name";
            on: 1;
            smooth: 1;
            perspective_on: 1;
            backface_cull: 1;
            alpha: 1;
            
            rotation {
                ..
            }
        }
        ..
    }
 

 
perspective [another part's name]
 This sets the part that is used as the "perspective point" for giving a part a "3d look". The perspective point should have a perspective section that provides zplane and focal properties. The center of this part will be used as the focal point, so size, color and visibility etc. are not relevant just center point, zplane and focal are used. This also implicitly enables perspective transforms (see the on parameter for the map section).

 

light [another part's name]
 This sets the part that is used as the "light" for calculating the brightness (based on how directly the part's surface is facing the light source point). Like the perspective point part, the center point is used and zplane is used for the z position (0 being the zero-plane where all 2D objects normally live) and positive values being further away into the distance. The light part color is used as the light color (alpha not used for light color). The color2 color is used for the ambient lighting when calculating brightness (alpha also not used).

 

on [1 or 0]
 This enables mapping for the part. Default is 0.

 

smooth [1 or 0]
 This enable smooth map rendering. This may be linear interpolation, anisotropic filtering or anything the engine decides is "smooth". This is a best-effort hint and may not produce precisely the same results in all engines and situations. Default is 1

 

alpha [1 or 0]
 This enable alpha channel when map rendering. Default is 1.

 

backface_cull [1 or 0]
 This enables backface culling (when the rotated part that normally faces the camera is facing away after being rotated etc.). This means that the object will be hidden when "backface culled".

 

perspective_on [1 or 0]
 Enable perspective when rotating even without a perspective point object. This would use perspective set for the object itself or for the canvas as a whole as the global perspective with edje_perspective_set() and edje_perspective_global_set().

rotation

    map {
        ..
        rotation {
            center: "name";
            x: 45.0;
            y: 45.0;
            z: 45.0;
        }
        ..
    }
 

Rotates the part, optionally with the center on another part.

 
center [another part's name]
 This sets the part that is used as the center of rotation when rotating the part with this description. The part's center point is used as the rotation center when applying rotation around the x, y and z axes. If no center is given, the parts original center itself is used for the rotation center.

 

x [X degrees]
 This sets the rotation around the x axis of the part considering the center set. In degrees.

 

y [Y degrees]
 This sets the rotation around the u axis of the part considering the center set. In degrees.

 

z [Z degrees]
 This sets the rotation around the z axis of the part considering the center set. In degrees.

perspective

    description {
        ..
        perspective {
            zplane: 0;
            focal: 1000;
        }
        ..
    }
 

Adds focal and plane perspective to the part. Active if perspective_on is true. Must be provided if the part is being used by other part as it's perspective target.

 
zplane [unscaled Z value]
 This sets the z value that will not be scaled. Normally this is 0 as that is the z distance that all objects are at normally.

 

focal [distance]
 This sets the distance from the focal z plane (zplane) and the camera - i.e. very much equating to focal length of the camera

Params state description sub blocks

params
    description {
        ..
        params {
            int: "name" 0;
            double: "other_name" 0.0;
            string: "another_name" "some text";
        bool: "name" 1;
        choice: "some_name" "value";
        }
        ..
    }
 

Set parameters for EXTERNAL parts. The value overwrites previous definitions with the same name.

 

int [param_name] [int_value]
 Adds an integer parameter for an external object

 

double [param_name] [double_value]
 Adds a double parameter for an external object

 

string [param_name] [string_value]
 Adds a string parameter for an external object

 

bool [param_name] [bool_value]
 Adds an boolean parameter for an external object. Value must be 0 or 1.

 

choice [param_name] [choice_string]
 Adds a choice parameter for an external object. The possible choice values are defined by external type at their register time and will be validated at runtime.

Program block

program
        group {
            programs {
               ..
                  program {
                     name: "programname";
                     signal: "signalname";
                     source: "partname";
                     filter: "partname" "statename";
                     in: 0.3 0.0;
                     action: STATE_SET "statename" state_value;
                     transition: LINEAR 0.5;
                     target: "partname";
                     target: "anotherpart";
                     after: "programname";
                     after: "anotherprogram";
                  }
               ..
            }
        }
 

Programs define how your interface reacts to events. Programs can change the state of parts, react to events or trigger other events.

 

name [program name]
 Symbolic name of program as a unique identifier.

 

signal [signal name]
 Specifies signal(s) that should cause the program to run. The signal received must match the specified source to run. Signals may be globbed, but only one signal keyword per program may be used. ex: signal: "mouse,clicked,*"; (clicking any mouse button that matches source starts program).

 

source [source name]
 Source of accepted signal. Sources may be globbed, but only one source keyword per program may be used. ex:source: "button-*"; (Signals from any part or program named "button-*" are accepted).

 

filter [part] [state]
 Filter signals to be only accepted if the part [part] is in state named [state]. Only one filter per program can be used. If [state] is not given, the source of the event will be used instead.

 

in [from] [range]
 Wait 'from' seconds before executing the program. And add a random number of seconds (from 0 to 'range') to the total waiting time.

 

action [type] [param1] [param2]
 Action to be performed by the program. Valid actions are: STATE_SET, ACTION_STOP, SIGNAL_EMIT, DRAG_VAL_SET, DRAG_VAL_STEP, DRAG_VAL_PAGE, FOCUS_SET, PARAM_COPY, PARAM_SET Only one action can be specified per program. Examples:
action: STATE_SET "statename" 0.5;
action: ACTION_STOP;
action: SIGNAL_EMIT "signalname" "emitter";
action: DRAG_VAL_SET 0.5 0.0;
action: DRAG_VAL_STEP 1.0 0.0;
action: DRAG_VAL_PAGE 0.0 0.0;
action: FOCUS_SET;
action: FOCUS_OBJECT;
action: PARAM_COPY "src_part" "src_param" "dst_part" "dst_param";
action: PARAM_SET "part" "param" "value";

 

transition [type] [length]
 Defines how transitions occur using STATE_SET action.
Where 'type' is the style of the transition and 'length' is a double specifying the number of seconds in which to preform the transition.
Valid types are: LINEAR, SINUSOIDAL, ACCELERATE, and DECELERATE.

 

target [target]
 Program or part on which the specified action acts. Multiple target keywords may be specified, one per target. SIGNAL_EMITs do not have targets.

 

after [after]
 Specifies a program to run after the current program completes. The source and signal parameters of a program run as an "after" are ignored. Multiple "after" statements can be specified per program.

 

api [name] [description]
 Specifies a hint to let applications (or IDE's) know how to bind things. The parameter name should contain the name of the function that the application should use, and description describes how it should be used.