Edje Object

Modules | Typedefs | Enumerations | Functions
Edje Object
Edje

This group discusses functions that deal with Edje layouts and its components. More...

## Modules
| Edje Communication Interface: Message
| Functions that deal with messages.
| Edje Communication Interface: Signal
| Functions that deal with signals.
| Edje Scale
| Functions that deal with scaling objects.
| Edje Class: Color
| Functions that deal with Color Classes.
| Edje Class: Size
| Functions that deal with Size Classes.
| Edje Class: Text
| Functions that deal with Text Classes.
| Edje Object File
| Functions to deals with EDJ files.
| Edje Object Animation
| Functions that deal with animations.
| Edje Object Geometry
| Functions that deal with object's geometry.
| Edje Part
| Functions that deal with layout components.
| Edje Perspective
| Functions that deal with 3D projection of an 2D object.

## Typedefs
typedef enum _Edje_Aspect_Control | Edje_Aspect_Control
| All Edje aspect control values.

## Enumerations
enum | _Edje_Aspect_Control { EDJE_ASPECT_CONTROL_NONE = 0 , EDJE_ASPECT_CONTROL_NEITHER = 1 , EDJE_ASPECT_CONTROL_HORIZONTAL = 2 , EDJE_ASPECT_CONTROL_VERTICAL = 3 , EDJE_ASPECT_CONTROL_BOTH = 4 }

## Functions
const char * | edje_object_part_object_name_get (const Evas_Object *obj)
| Gets the part name of an edje part object. More...
Evas_Object * | edje_object_add (Evas *evas)
| Instantiates a new Edje object. More...
Eina_Bool | edje_object_preload (Evas_Object *obj, Eina_Bool cancel)
| Preloads the images on the Edje Object in the background. More...
void | edje_object_signal_callback_add (Evas_Object *obj, const char *emission, const char *source, Edje_Signal_Cb func, void *data)
| Adds a callback for an arriving Edje signal, emitted by a given Edje object. More...
void | edje_object_signal_emit (Evas_Object *obj, const char *emission, const char *source)
| Sends/emits an Edje signal to a given Edje object. More...
void * | edje_object_signal_callback_del (Evas_Object *obj, const char *emission, const char *source, Edje_Signal_Cb func)
| Removes a signal-triggered callback from an object. More...
void * | edje_object_signal_callback_del_full (Evas_Object *obj, const char *emission, const char *source, Edje_Signal_Cb func, void *data)
| Unregisters/deletes a callback set for an arriving Edje signal, emitted by a given Edje object. More...
Edje_Load_Error | edje_object_load_error_get (const Evas_Object *obj)
| Gets the (last) file loading error for a given Edje object. More...
const char * | edje_load_error_str (Edje_Load_Error error)
| Converts the given Edje file load error code into a string describing it in English. More...
Eina_Bool | edje_object_part_geometry_get (const Evas_Object *obj, const char *part, int *x, int *y, int *w, int *h)
| Retrieves the geometry of a given Edje part, in a given Edje object's group definition, relative to the object's area. More...
const char * | edje_object_part_state_get (const Evas_Object *obj, const char *part, double *val_ret)
| Returns the state of the Edje part. More...
const Efl_Canvas_Object * | edje_object_part_object_get (const Evas_Object *obj, const char *part)
| Gets a handle to the Evas object implementing a given Edje part, in an Edje object. More...
void | edje_object_update_hints_set (Evas_Object *obj, Eina_Bool update)
| Whether this object updates its size hints automatically. More...
Eina_Bool | edje_object_update_hints_get (const Evas_Object *obj)
| Whether this object updates its size hints automatically. More...
void | edje_object_size_min_calc (Evas_Object *obj, int *minw, int *minh)
| Calculates the minimum required size for a given Edje object. More...
void | edje_object_size_min_restricted_calc (Evas_Object *obj, int *minw, int *minh, int restrictedw, int restrictedh)
| Calculates the minimum required size for a given Edje object. More...
Eina_Bool | edje_object_parts_extends_calc (Evas_Object *obj, int *x, int *y, int *w, int *h)
| Calculates the geometry of the region, relative to a given Edje object's area, occupied by all parts in the object. More...
void | edje_object_calc_force (Evas_Object *obj)
| Forces a Size/Geometry calculation. More...
int | edje_object_freeze (Evas_Object *obj)
| Freezes the Edje object. More...
int | edje_object_thaw (Evas_Object *obj)
| Thaws the Edje object. More...
EINA_DEPRECATED void | edje_extern_object_min_size_set (Evas_Object *obj, Evas_Coord minw, Evas_Coord minh)
| Sets the object minimum size. More...
EINA_DEPRECATED void | edje_extern_object_max_size_set (Evas_Object *obj, Evas_Coord maxw, Evas_Coord maxh)
| Sets the object maximum size. More...
EINA_DEPRECATED void | edje_extern_object_aspect_set (Evas_Object *obj, Edje_Aspect_Control aspect, Evas_Coord aw, Evas_Coord ah)
| Sets the object aspect size. More...
Eina_Bool | edje_object_file_set (Evas_Object *obj, const char *file, const char *group)
| Sets the EDJ file (and group within it) to load an Edje object's contents from. More...
void | edje_object_file_get (const Evas_Object *obj, const char **file, const char **group)
| Gets the file and group name that a given Edje object is bound to. More...
Eina_Bool | edje_object_mmap_set (Evas_Object *obj, const Eina_File *file, const char *group)
| Sets the EDJ file (and group within it) to load an Edje object's contents from. More...
void | edje_object_mirrored_set (Evas_Object *obj, Eina_Bool rtl)
| Sets the RTL orientation for this object. More...
Eina_Bool | edje_object_mirrored_get (const Evas_Object *obj)
| Gets the RTL orientation for this object. More...
void | edje_object_language_set (Evas_Object *obj, const char *language)
| Sets the language for this object. More...
const char * | edje_object_language_get (const Evas_Object *obj)
| Gets the language for this object. More...
void | edje_object_text_insert_filter_callback_add (Evas_Object *obj, const char *part, Edje_Text_Filter_Cb func, void *data)
| Adds a filter function for newly inserted text. More...
void * | edje_object_text_insert_filter_callback_del (Evas_Object *obj, const char *part, Edje_Text_Filter_Cb func)
| Deletes a function from the filter list. More...
void * | edje_object_text_insert_filter_callback_del_full (Evas_Object *obj, const char *part, Edje_Text_Filter_Cb func, void *data)
| Deletes a function and matching user data from the filter list. More...
void | edje_object_text_markup_filter_callback_add (Evas_Object *obj, const char *part, Edje_Markup_Filter_Cb func, void *data)
| Adds a markup filter function for newly inserted text. More...
void * | edje_object_text_markup_filter_callback_del (Evas_Object *obj, const char *part, Edje_Markup_Filter_Cb func)
| Deletes a function from the markup filter list. More...
void * | edje_object_text_markup_filter_callback_del_full (Evas_Object *obj, const char *part, Edje_Markup_Filter_Cb func, void *data)
| Deletes a function and matching user data from the markup filter list. More...
void | edje_object_play_set (Evas_Object *obj, Eina_Bool play)
| Whether this object is playing or not. More...
Eina_Bool | edje_object_play_get (const Evas_Object *obj)
| Whether this object is playing or not. More...
void | edje_object_transition_duration_factor_set (Evas_Object *obj, double scale)
| Transition duration factor. More...
double | edje_object_transition_duration_factor_get (const Evas_Object *obj)
| Transition duration factor. More...
void | edje_object_size_min_get (const Evas_Object *obj, int *minw, int *minh)
| Gets the minimum size specified – as an EDC property – for a given Edje object. More...
void | edje_object_size_max_get (const Evas_Object *obj, int *maxw, int *maxh)
| Gets the maximum size specified – as an EDC property – for a given Edje object. More...
void | edje_object_item_provider_set (Edje_Object *obj, Edje_Item_Provider_Cb func, void *data)
| Sets the function that provides item objects for named items in an edje entry text. More...
void | edje_object_animation_set (Efl_Canvas_Layout *obj, Eina_Bool on)
| Whether this object is animating or not. More...
Eina_Bool | edje_object_animation_get (const Efl_Canvas_Layout *obj)
| Whether this object is animating or not. More...
Efl_Input_Device * | edje_object_seat_get (const Efl_Canvas_Layout *obj, Eina_Stringshare *name)
| Returns the seat device given its Edje's name. More...
Eina_Stringshare * | edje_object_seat_name_get (const Efl_Canvas_Layout *obj, Efl_Input_Device *device)
| Gets the name given to a set by Edje. More...
Eina_Error | edje_object_layout_load_error_get (const Efl_Canvas_Layout *obj)
| Gets the (last) file loading error for a given object. More...
Eina_Bool | edje_object_content_remove (Efl_Canvas_Layout *obj, Efl_Gfx_Entity *content)
| Unswallow an object from this Edje. More...

## Detailed Description

This group discusses functions that deal with Edje layouts and its components.

An important thing to know about this group is that there is no Edje_Object in code. What we refer here as object are layouts (or themes) defined by groups, and parts, both declared in EDC files. They are of type Evas_Object as the other native objects of Evas, but they only exist in Edje, so that is why we are calling them "edje objects".

With the Edje Object Group functions we can deal with layouts by managing its aspect, content, message and signal exchange and animation, among others.

## Function Documentation

## ◆ edje_object_part_object_name_get()

const char* edje_object_part_object_name_get | ( | const Evas_Object * | obj | ) |

Gets the part name of an edje part object.

Parameters

  obj | An edje part object

Returns
  The name of the part, if the object is an edje part, or `NULL`

Note
  If this function returns `NULL`, `obj` was not an Edje part object

See also
  edje_object_part_object_get()

Since
  1.10

References evas_object_data_get().

## ◆ edje_object_add()

Evas_Object* edje_object_add | ( | Evas * | evas | ) |

Instantiates a new Edje object.

Parameters

  evas | A valid Evas handle, the canvas to place the new object in

Returns
  A handle to the new object created, or `NULL` on errors.

This function creates a new Edje smart object, returning its `Evas_Object` handle. An Edje object is useless without a (source) file set to it, so you'd most probably call edje_object_file_set() afterwards, like in:

Evas_Object *edje;
edje = edje_object_add(canvas);
if (!edje)
{
fprintf(stderr, "could not create edje object!\n");
return NULL;
}
if (!edje_object_file_set(edje, "theme.edj", "group_name"))
{
int err = edje_object_load_error_get(edje);
const char *errmsg = edje_load_error_str(err);
fprintf(stderr, "could not load 'group_name' from theme.edj: %s",
errmsg);
evas_object_del(edje);
return NULL;
}
edje_load_error_str
const char * edje_load_error_str(Edje_Load_Error error)
Converts the given Edje file load error code into a string describing it in English.
Definition: edje_load.c:108
edje_object_add
Evas_Object * edje_object_add(Evas *evas)
Instantiates a new Edje object.
Definition: edje_smart.c:22
edje_object_load_error_get
Edje_Load_Error edje_object_load_error_get(const Eo *obj)
Gets the (last) file loading error for a given Edje object.
Definition: edje_legacy.c:15
edje_object_file_set
Eina_Bool edje_object_file_set(Evas_Object *obj, const char *file, const char *group)
Sets the EDJ file (and group within it) to load an Edje object's contents from.
Definition: edje_smart.c:467
evas_object_del
EVAS_API void evas_object_del(Evas_Object *obj)
Marks the given Evas object for deletion (when Evas will free its memory).
Definition: evas_object_main.c:928
Evas_Object
Efl_Canvas_Object Evas_Object
An Evas Object handle.
Definition: Evas_Common.h:185

Note
  You can get a callback every time edje re-calculates the object (either due to animation or some kind of signal or input). This is called in-line just after the recalculation has occurred. It is a good idea not to go and delete or alter the object inside this callbacks, simply make a note that the recalculation has taken place and then do something about it outside the callback. To register a callback use code like:

evas_object_smart_callback_add(edje_obj, "recalc", my_cb, my_cb_data);
evas_object_smart_callback_add
EVAS_API void evas_object_smart_callback_add(Evas_Object *eo_obj, const char *event, Evas_Smart_Cb func, const void *data)
Add (register) a callback function to the smart event specified by event on the smart object obj.
Definition: evas_object_smart.c:1040

See also
  evas_object_smart_callback_add()

Note
  Before creating the first Edje object in your code, remember to initialize the library, with edje_init(), or unexpected behavior might occur.

Examples
  bg_example_03.c, edje-basic.c, edje-box.c, edje-box2.c, edje-color-class.c, edje-drag.c, edje-perspective.c, edje-signals-messages.c, edje-swallow.c, edje-table.c, edje-text.c, emotion_test_main.c, and evas-aspect-hints.c.

References EINA_SAFETY_ON_FALSE_RETURN_VAL, and EVAS_CANVAS_CLASS.

Referenced by edje_edit_part_source_set().

## ◆ edje_object_preload()

Eina_Bool edje_object_preload | ( | Evas_Object * | obj,
|  | Eina_Bool | cancel
| ) |  |

Preloads the images on the Edje Object in the background.

This function requests the preload of all data images (on the given object) in the background. The work is queued before being processed (because there might be other pending requests of this type). It emits a signal "preload,done" when finished.

Note
  Use `true` on scenarios where you don't need the image data preloaded anymore.

Parameters

  [in] | obj | The object.
  [in] | cancel | `false` will add it the preloading work queue, `true` will remove it (if it was issued before).

Returns
  `false` if obj was not a valid Edje object otherwise `true`

References alloca(), edje_object_preload(), edje_object_signal_callback_add(), edje_object_signal_callback_del(), EDJE_PART_TYPE_GROUP, EDJE_PART_TYPE_IMAGE, EINA_FALSE, EINA_TRUE, EVAS_CALLBACK_IMAGE_PRELOADED, evas_object_event_callback_add(), evas_object_event_callback_del_full(), evas_object_image_file_get(), and evas_object_image_preload().

Referenced by edje_object_preload().

## ◆ edje_object_signal_callback_add()

void edje_object_signal_callback_add | ( | Evas_Object * | obj,
|  | const char * | emission,
|  | const char * | source,
|  | Edje_Signal_Cb | func,
|  | void * | data
| ) |  |

Adds a callback for an arriving Edje signal, emitted by a given Edje object.

Edje signals are one of the communication interfaces between code and a given Edje object's theme. With signals, one can communicate two string values at a time, which are: - "emission" value: the name of the signal, in general - "source" value: a name for the signal's context, in general

Though there are those common uses for the two strings, one is free to use them however they like.

Signal callback registration is powerful, in the way that blobs may be used to match multiple signals at once. All the "*?[\" set of `fnmatch()` operators can be used, both for emission and source.

Edje has internal signals it will emit, automatically, on various actions taking place on group parts. For example, the mouse cursor being moved, pressed, released, etc., over a given part's area, all generate individual signals.

By using something like edje_object_signal_callback_add(obj, "mouse,down,*", "button.*", signal_cb, NULL); being "button.*" the pattern for the names of parts implementing buttons on an interface, you'd be registering for notifications on events of mouse buttons being pressed down on either of those parts (those events all have the "mouse,down," common prefix on their names, with a suffix giving the button number). The actual emission and source strings of an event will be passed in as the emission and source parameters of the callback function (e.g. "mouse,down,2" and "button.close"), for each of those events.

Note
  See the syntax for EDC files See also edje_object_signal_emit() on how to emits Edje signals from code to a an object edje_object_signal_callback_del_full()

Parameters

  [in] | emission | The signal's "emission" string
  [in] | source | The signal's "source" string
  [in] | func | The callback function to be executed when the signal is emitted.
  [in] | data | A pointer to data to pass in to func.

Referenced by edje_object_preload().

## ◆ edje_object_signal_emit()

void edje_object_signal_emit | ( | Evas_Object * | obj,
|  | const char * | emission,
|  | const char * | source
| ) |  |

Sends/emits an Edje signal to a given Edje object.

This function sends a signal to the object obj. An Edje program, at obj's EDC specification level, can respond to a signal by having declared matching @'signal' and @'source' fields on its block (see the syntax for EDC files).

See also edje_object_signal_callback_add() for more on Edje signals.

Parameters

  [in] | emission | The signal's "emission" string
  [in] | source | The signal's "source" string

Referenced by elm_slider_indicator_show_set(), and elm_thumb_animate_set().

## ◆ edje_object_signal_callback_del()

void* edje_object_signal_callback_del | ( | Evas_Object * | obj,
|  | const char * | emission,
|  | const char * | source,
|  | Edje_Signal_Cb | func
| ) |  |

Removes a signal-triggered callback from an object.

Parameters

  obj | A valid Evas_Object handle.
  emission | The emission string.
  source | The source string.
  func | The callback function.

Returns
  The data pointer

This function removes a callback, previously attached to the emission of a signal, from the object obj. The parameters emission, source and func must match exactly those passed to a previous call to edje_object_signal_callback_add(). The data pointer that was passed to this call will be returned.

See also
  edje_object_signal_callback_add().
  edje_object_signal_callback_del_full().

References edje_object_signal_callback_del_full().

Referenced by edje_object_preload().

## ◆ edje_object_signal_callback_del_full()

void* edje_object_signal_callback_del_full | ( | Evas_Object * | obj,
|  | const char * | emission,
|  | const char * | source,
|  | Edje_Signal_Cb | func,
|  | void * | data
| ) |  |

Unregisters/deletes a callback set for an arriving Edje signal, emitted by a given Edje object.

Parameters

  obj | A handle to an Edje object
  emission | The signal's "emission" string
  source | The signal's "source" string
  func | The callback function passed on the callback's registration
  data | The pointer given to be passed as data to `func`

Returns
  `data` on success, or `NULL` on errors (or if `data` had this value)

This function removes a callback, previously attached to the emission of a signal, from the object obj. The parameters emission, source, func and data must match exactly those passed to a previous call to edje_object_signal_callback_add(). The data pointer that was passed to this call will be returned.

See also
  edje_object_signal_callback_add().
  edje_object_signal_callback_del().

References eina_stringshare_add(), eina_stringshare_del(), and EINA_TRUE.

Referenced by edje_object_signal_callback_del().

## ◆ edje_object_load_error_get()

Edje_Load_Error edje_object_load_error_get | ( | const Evas_Object * | obj | ) |

Gets the (last) file loading error for a given Edje object.

This function is meant to be used after an Edje EDJ file loading, what takes place with the edje_object_file_set() function. If that function does not return `true`, one should check for the reason of failure with this one.

edje_load_error_str()

Returns
  The Edje loading error, one of: - #EDJE_LOAD_ERROR_NONE - #EDJE_LOAD_ERROR_GENERIC - #EDJE_LOAD_ERROR_DOES_NOT_EXIST - #EDJE_LOAD_ERROR_PERMISSION_DENIED - #EDJE_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED - #EDJE_LOAD_ERROR_CORRUPT_FILE
  - #EDJE_LOAD_ERROR_UNKNOWN_FORMAT - #EDJE_LOAD_ERROR_INCOMPATIBLE_FILE - #EDJE_LOAD_ERROR_UNKNOWN_COLLECTION - #EDJE_LOAD_ERROR_RECURSIVE_REFERENCE

## ◆ edje_load_error_str()

const char* edje_load_error_str | ( | Edje_Load_Error | error | ) |

Converts the given Edje file load error code into a string describing it in English.

Parameters

  error | the error code, a value in ::Edje_Load_Error.

Returns
  Always returns a valid string. If the given `error` is not supported, `"Unknown error"` is returned.

edje_object_file_set() is a function which sets an error value, afterwards, which can be fetched with edje_object_load_error_get(). The function in question is meant to be used in conjunction with the latter, for pretty-printing any possible error cause.

Examples
  edje-basic.c, edje-signals-messages.c, and evas-aspect-hints.c.

## ◆ edje_object_part_geometry_get()

Eina_Bool edje_object_part_geometry_get | ( | const Evas_Object * | obj,
|  | const char * | part,
|  | int * | x,
|  | int * | y,
|  | int * | w,
|  | int * | h
| ) |  |

Retrieves the geometry of a given Edje part, in a given Edje object's group definition, relative to the object's area.

This function gets the geometry of an Edje part within its group. The x and y coordinates are relative to the top left corner of the whole obj object's area.

Note
  Use `null` pointers on the geometry components you're not interested in: they'll be ignored by the function.
  On failure, this function will make all non-$null geometry pointers' pointed variables be set to zero.

Parameters

  [in] | part | The Edje part's name
  [out] | x | A pointer to a variable where to store the part's x coordinate
  [out] | y | A pointer to a variable where to store the part's y coordinate
  [out] | w | A pointer to a variable where to store the part's width
  [out] | h | A pointer to a variable where to store the part's height

Returns
  `true` on success, `false` otherwise

References EINA_FALSE, EINA_SAFETY_ON_NULL_RETURN_VAL, and EINA_TRUE.

## ◆ edje_object_part_state_get()

const char* edje_object_part_state_get | ( | const Evas_Object * | obj,
|  | const char * | part,
|  | double * | val_ret
| ) |  |

Returns the state of the Edje part.

Parameters

  [in] | part | The part name
  [out] | val_ret | Part state value

Returns
  The part state: "default" for the default state "" for other states

## ◆ edje_object_part_object_get()

const Efl_Canvas_Object* edje_object_part_object_get | ( | const Evas_Object * | obj,
|  | const char * | part
| ) |  |

Gets a handle to the Evas object implementing a given Edje part, in an Edje object.

This function gets a pointer of the Evas object corresponding to a given part in the obj object's group.

You should never modify the state of the returned object (with evas_object_move() or evas_object_hide() for example), because it's meant to be managed by Edje, solely. You are safe to query information about its current state (with evas_object_visible_get() or evas_object_color_get() for example), though.

Note
  If the type of Edje part is GROUP, SWALLOW or EXTERNAL, returned handle by this function will indicate nothing or transparent rectangle for events. Use $.part_swallow_get() in that case.

Parameters

  [in] | part | The Edje part's name

Returns
  A pointer to the Evas object implementing the given part, `null` on failure (e.g. the given part doesn't exist)

Examples
  edje-basic.c.

## ◆ edje_object_update_hints_set()

void edje_object_update_hints_set | ( | Evas_Object * | obj,
|  | Eina_Bool | update
| ) |  |

Whether this object updates its size hints automatically.

By default edje doesn't set size hints on itself. If this property is set to `true`, size hints will be updated after recalculation. Be careful, as recalculation may happen often, enabling this property may have a considerable performance impact as other widgets will be notified of the size hints changes.

A layout recalculation can be triggered by edje_object_size_min_calc(), edje_object_size_min_restricted_calc(), edje_object_parts_extends_calc() or even any other internal event.

Enable or disable auto-update of size hints.

Parameters

  [in] | update | Whether or not update the size hints.

## ◆ edje_object_update_hints_get()

Eina_Bool edje_object_update_hints_get | ( | const Evas_Object * | obj | ) |

Whether this object updates its size hints automatically.

By default edje doesn't set size hints on itself. If this property is set to `true`, size hints will be updated after recalculation. Be careful, as recalculation may happen often, enabling this property may have a considerable performance impact as other widgets will be notified of the size hints changes.

A layout recalculation can be triggered by edje_object_size_min_calc(), edje_object_size_min_restricted_calc(), edje_object_parts_extends_calc() or even any other internal event.

Whether this object updates its size hints automatically.

Returns
  Whether or not update the size hints.

## ◆ edje_object_size_min_calc()

void edje_object_size_min_calc | ( | Evas_Object * | obj,
|  | int * | minw,
|  | int * | minh
| ) |  |

Calculates the minimum required size for a given Edje object.

This call works exactly as edje_object_size_min_restricted_calc(), with the last two arguments set to 0. Please refer to its documentation, then.

Parameters

  [out] | minw | The minimum required width (return value)
  [out] | minh | The minimum required height (return value)

References edje_object_size_min_restricted_calc().

## ◆ edje_object_size_min_restricted_calc()

void edje_object_size_min_restricted_calc | ( | Evas_Object * | obj,
|  | int * | minw,
|  | int * | minh,
|  | int | restrictedw,
|  | int | restrictedh
| ) |  |

Calculates the minimum required size for a given Edje object.

This call will trigger an internal recalculation of all parts of the object, in order to return its minimum required dimensions for width and height. The user might choose to impose those minimum sizes, making the resulting calculation to get to values equal or larger than `restrictedw` and `restrictedh`, for width and height, respectively.

Note
  At the end of this call, the object won't be automatically resized to the new dimensions, but just return the calculated sizes. The caller is the one up to change its geometry or not.

Warning
  Be advised that invisible parts in the object will be taken into account in this calculation.

Parameters

  [out] | minw | The minimum required width (return value)
  [out] | minh | The minimum required height (return value)
  [in] | restrictedw | The minimum width constraint as input, `minw` can not be lower than this
  [in] | restrictedh | The minimum height constraint as input, `minh` can not be lower than this

References EINA_SIZE2D.

Referenced by edje_object_size_min_calc().

## ◆ edje_object_parts_extends_calc()

Eina_Bool edje_object_parts_extends_calc | ( | Evas_Object * | obj,
|  | int * | x,
|  | int * | y,
|  | int * | w,
|  | int * | h
| ) |  |

Calculates the geometry of the region, relative to a given Edje object's area, occupied by all parts in the object.

This function gets the geometry of the rectangle equal to the area required to group all parts in obj's group/collection. The x and y coordinates are relative to the top left corner of the whole obj object's area. Parts placed out of the group's boundaries will also be taken in account, so that x and y may be negative.

Note
  On failure, this function will make all non-$null geometry pointers' pointed variables be set to zero.

Parameters

  [out] | x | The parts region's X coordinate
  [out] | y | The parts region's Y coordinate
  [out] | w | The parts region's width
  [out] | h | The parts region's height

Returns
  `true` on success, `false` otherwise

References EINA_RECT_ZERO.

## ◆ edje_object_calc_force()

void edje_object_calc_force | ( | Evas_Object * | obj | ) |

Forces a Size/Geometry calculation.

Forces the object to recalculate its layout regardless of freeze/thaw.

See also edje_object_freeze and edje_object_thaw.

Referenced by edje_edit_part_clip_to_set(), edje_edit_part_del(), edje_edit_part_effect_set(), edje_edit_part_scale_set(), edje_edit_part_selected_state_set(), edje_edit_state_aspect_pref_set(), edje_edit_state_color3_set(), edje_edit_state_color_class_set(), edje_edit_state_font_set(), edje_edit_state_image_border_fill_set(), edje_edit_state_image_border_set(), edje_edit_state_image_set(), edje_edit_state_map_light_set(), edje_edit_state_map_on_set(), edje_edit_state_map_perspective_focal_set(), edje_edit_state_map_perspective_set(), edje_edit_state_map_perspective_zplane_set(), edje_edit_state_map_rotation_center_set(), edje_edit_state_map_rotation_set(), edje_edit_state_map_zoom_set(), edje_edit_state_text_repch_set(), edje_edit_state_text_set(), edje_edit_state_text_size_range_min_max_set(), edje_edit_state_text_size_set(), edje_edit_state_text_source_set(), edje_edit_state_text_style_set(), edje_edit_state_text_text_source_set(), edje_edit_state_vector_set(), edje_edit_state_visible_set(), and edje_scale_set().

## ◆ edje_object_freeze()

int edje_object_freeze | ( | Evas_Object * | obj | ) |

Freezes the Edje object.

This function puts all changes on hold. Successive freezes will nest, requiring an equal number of thaws.

See also edje_object_thaw()

Returns
  The frozen state or 0 on error

Referenced by edje_freeze().

## ◆ edje_object_thaw()

int edje_object_thaw | ( | Evas_Object * | obj | ) |

Thaws the Edje object.

This function thaws the given Edje object.

Note
  If successive freezes were done, an equal number of thaws will be required.

See also edje_object_freeze()

Returns
  The frozen state or 0 if the object is not frozen or on error.

Referenced by edje_thaw().

## ◆ edje_extern_object_min_size_set()

EINA_DEPRECATED void edje_extern_object_min_size_set | ( | Evas_Object * | obj,
|  | Evas_Coord | minw,
|  | Evas_Coord | minh
| ) |  |

Sets the object minimum size.

Deprecated:
  use evas_object_size_hint_min_set() instead.

Parameters

  obj | A valid Evas_Object handle
  minw | The minimum width
  minh | The minimum height

This sets the minimum size restriction for the object.

References evas_object_size_hint_min_set().

## ◆ edje_extern_object_max_size_set()

EINA_DEPRECATED void edje_extern_object_max_size_set | ( | Evas_Object * | obj,
|  | Evas_Coord | maxw,
|  | Evas_Coord | maxh
| ) |  |

Sets the object maximum size.

Deprecated:
  use evas_object_size_hint_max_set() instead.

Parameters

  obj | A valid Evas_Object handle
  maxw | The maximum width
  maxh | The maximum height

This sets the maximum size restriction for the object.

References evas_object_size_hint_max_set().

## ◆ edje_extern_object_aspect_set()

EINA_DEPRECATED void edje_extern_object_aspect_set | ( | Evas_Object * | obj,
|  | Edje_Aspect_Control | aspect,
|  | Evas_Coord | aw,
|  | Evas_Coord | ah
| ) |  |

Sets the object aspect size.

Deprecated:
  use evas_object_size_hint_aspect_set() instead.

Parameters

  obj | A valid Evas_Object handle
  aspect | The aspect control axes
  aw | The aspect radio width
  ah | The aspect ratio height

This sets the desired aspect ratio to keep an object that will be swallowed by Edje. The width and height define a preferred size ASPECT and the object may be scaled to be larger or smaller, but retaining the relative scale of both aspect width and height.

References EVAS_ASPECT_CONTROL_NONE.

## ◆ edje_object_file_set()

Eina_Bool edje_object_file_set | ( | Evas_Object * | obj,
|  | const char * | file,
|  | const char * | group
| ) |  |

Sets the EDJ file (and group within it) to load an Edje object's contents from.

Returns
  `EINA_TRUE` on success, or `EINA_FALSE` on errors (check edje_object_load_error_get() after this call to get errors causes)

Edje expects EDJ files, which are theming objects' descriptions and resources packed together in an EET file, to read Edje object definitions from. They usually are created with the ``.edj extension. EDJ files, in turn, are assembled from textual object description files, where one describes Edje objects declaratively – the EDC files (see the syntax for those files).

Those description files were designed so that many Edje object definitions – also called groups (or collections) – could be packed together in the same EDJ file, so that a whole application's theme could be packed in one file only. This is the reason for the `group` argument.

Use this function after you instantiate a new Edje object, so that you can "give him life", telling where to get its contents from.

See also
  edje_object_add()
  edje_object_file_get()
  edje_object_mmap_set()

Parameters

  [in] | file | The path to the EDJ file to load `from`
  [in] | group | The name of the group, in `file`, which implements an Edje object

Examples
  bg_example_03.c, edje-basic.c, edje-box.c, edje-box2.c, edje-color-class.c, edje-drag.c, edje-perspective.c, edje-signals-messages.c, edje-swallow.c, edje-table.c, edje-text.c, emotion_test_main.c, and evas-aspect-hints.c.

Referenced by edje_edit_clean_save_as(), and edje_edit_part_source_set().

## ◆ edje_object_file_get()

void edje_object_file_get | ( | const Evas_Object * | obj,
|  | const char ** | file,
|  | const char ** | group
| ) |  |

Gets the file and group name that a given Edje object is bound to.

This gets the EDJ file's path, with the respective group set for the given Edje object. If obj is either not an Edje file, or has not had its file/group set previously, by edje_object_file_set(), then both `file` and `group` will be set to `NULL`, indicating an error.

See also
  edje_object_file_set()

Note
  Use `NULL` pointers on the file/group components you're not interested in: they'll be ignored by the function.

Parameters

  [out] | file | The path to the EDJ file to load `from`
  [out] | group | The name of the group, in `file`, which implements an Edje object

## ◆ edje_object_mmap_set()

Eina_Bool edje_object_mmap_set | ( | Evas_Object * | obj,
|  | const Eina_File * | file,
|  | const char * | group
| ) |  |

Sets the EDJ file (and group within it) to load an Edje object's contents from.

Returns
  `EINA_TRUE` on success, or `EINA_FALSE` on errors (check edje_object_load_error_get() after this call to get errors causes)

Edje expects EDJ files, which are theming objects' descriptions and resources packed together in an EET file, to read Edje object definitions from. They usually are created with the ``.edj extension. EDJ files, in turn, are assembled from textual object description files, where one describes Edje objects declaratively – the EDC files (see the syntax for those files).

Those description files were designed so that many Edje object definitions – also called groups (or collections) – could be packed together in the same EDJ file, so that a whole application's theme could be packed in one file only. This is the reason for the `group` argument.

Use this function after you instantiate a new Edje object, so that you can "give him life", telling where to get its contents from.

See also
  edje_object_add()
  edje_object_file_get()

Since
  1.8

Parameters

  [in] | file | The Eina.File pointing to the EDJ file to load `from`
  [in] | group | The name of the group, in `file`, which implements an Edje object

## ◆ edje_object_mirrored_set()

void edje_object_mirrored_set | ( | Evas_Object * | obj,
|  | Eina_Bool | rtl
| ) |  |

Sets the RTL orientation for this object.

Parameters

  [in] | rtl | New value of flag `true/$false`

Since
  1.1.0

## ◆ edje_object_mirrored_get()

Eina_Bool edje_object_mirrored_get | ( | const Evas_Object * | obj | ) |

Gets the RTL orientation for this object.

You can RTL orientation explicitly with edje_object_mirrored_set.

Returns
  New value of flag `true/$false`

Since
  1.1.0

## ◆ edje_object_language_set()

void edje_object_language_set | ( | Evas_Object * | obj,
|  | const char * | language
| ) |  |

Sets the language for this object.

Parameters

  [in] | language | The language value

Since
  1.1.0

## ◆ edje_object_language_get()

const char* edje_object_language_get | ( | const Evas_Object * | obj | ) |

Gets the language for this object.

Returns
  The language value

Since
  1.1.0

## ◆ edje_object_text_insert_filter_callback_add()

void edje_object_text_insert_filter_callback_add | ( | Evas_Object * | obj,
|  | const char * | part,
|  | Edje_Text_Filter_Cb | func,
|  | void * | data
| ) |  |

Adds a filter function for newly inserted text.

Whenever text is inserted (not the same as set) into the given part, the list of filter functions will be called to decide if and how the new text will be accepted. There are three types of filters, EDJE_TEXT_FILTER_TEXT, EDJE_TEXT_FILTER_FORMAT and EDJE_TEXT_FILTER_MARKUP. The text parameter in the func filter can be modified by the user and it's up to him to free the one passed if he's to change the pointer. If doing so, the newly set text should be malloc'ed, as once all the filters are called Edje will free it. If the text is to be rejected, freeing it and setting the pointer to `null` will make Edje break out of the filter cycle and reject the inserted text.

Warning
  This function will be deprecated because of difficulty in use. The type(format, text, or markup) of text should be always checked in the filter function for correct filtering. Please use edje_object_text_markup_filter_callback_add() instead. There is no need to check the type of text in the filter function because the text is always markup. Warning: If you use this function with edje_object_text_markup_filter_callback_add() together, all Edje_Text_Filter_Cb functions and Edje_Markup_Filter_Cb functions will be executed, and then filtered text will be inserted.

See also edje_object_text_insert_filter_callback_del, edje_object_text_insert_filter_callback_del_full and edje_object_text_markup_filter_callback_add

Parameters

  [in] | part | The part name
  [in] | func | The callback function that will act as filter
  [in] | data | User provided data to pass to the filter function

References eina_list_append(), EINA_SAFETY_ON_NULL_RETURN, and eina_stringshare_add().

## ◆ edje_object_text_insert_filter_callback_del()

void* edje_object_text_insert_filter_callback_del | ( | Evas_Object * | obj,
|  | const char * | part,
|  | Edje_Text_Filter_Cb | func
| ) |  |

Deletes a function from the filter list.

Delete the given func filter from the list in part. Returns the user data pointer given when added.

See also edje_object_text_insert_filter_callback_add and edje_object_text_insert_filter_callback_del_full

Parameters

  [in] | part | The part name
  [in] | func | The function callback to remove

Returns
  The user data pointer if successful, or `null` otherwise

References EINA_LIST_FOREACH, eina_list_remove_list(), EINA_SAFETY_ON_NULL_RETURN_VAL, and eina_stringshare_del().

## ◆ edje_object_text_insert_filter_callback_del_full()

void* edje_object_text_insert_filter_callback_del_full | ( | Evas_Object * | obj,
|  | const char * | part,
|  | Edje_Text_Filter_Cb | func,
|  | void * | data
| ) |  |

Deletes a function and matching user data from the filter list.

Delete the given func filter and data user data from the list in part. Returns the user data pointer given when added.

See also edje_object_text_insert_filter_callback_add and edje_object_text_insert_filter_callback_del

Parameters

  [in] | part | The part name
  [in] | func | The function callback to remove
  [in] | data | The data passed to the callback function

Returns
  The same data pointer if successful, or `null` otherwise

References EINA_LIST_FOREACH, eina_list_remove_list(), EINA_SAFETY_ON_NULL_RETURN_VAL, and eina_stringshare_del().

## ◆ edje_object_text_markup_filter_callback_add()

void edje_object_text_markup_filter_callback_add | ( | Evas_Object * | obj,
|  | const char * | part,
|  | Edje_Markup_Filter_Cb | func,
|  | void * | data
| ) |  |

Adds a markup filter function for newly inserted text.

Whenever text is inserted (not the same as set) into the given part, the list of markup filter functions will be called to decide if and how the new text will be accepted. The text parameter in the func filter is always markup. It can be modified by the user and it's up to him to free the one passed if he's to change the pointer. If doing so, the newly set text should be malloc'ed, as once all the filters are called Edje will free it. If the text is to be rejected, freeing it and setting the pointer to `null` will make Edje break out of the filter cycle and reject the inserted text. This function is different from edje_object_text_insert_filter_callback_add() in that the text parameter in the func filter is always markup.

Warning
  If you use this function with edje_object_text_insert_filter_callback_add() together, all Edje_Text_Filter_Cb functions and Edje_Markup_Filter_Cb functions will be executed, and then filtered text will be inserted.

See also edje_object_text_markup_filter_callback_del, edje_object_text_markup_filter_callback_del_full and edje_object_text_insert_filter_callback_add

Parameters

  [in] | part | The part name
  [in] | func | The callback function that will act as markup filter
  [in] | data | User provided data to pass to the filter function

Since
  1.2.0

References eina_list_append(), EINA_SAFETY_ON_NULL_RETURN, and eina_stringshare_add().

## ◆ edje_object_text_markup_filter_callback_del()

void* edje_object_text_markup_filter_callback_del | ( | Evas_Object * | obj,
|  | const char * | part,
|  | Edje_Markup_Filter_Cb | func
| ) |  |

Deletes a function from the markup filter list.

Delete the given func filter from the list in part. Returns the user data pointer given when added.

See also edje_object_text_markup_filter_callback_add and edje_object_text_markup_filter_callback_del_full

Parameters

  [in] | part | The part name
  [in] | func | The function callback to remove

Returns
  The user data pointer if successful, or `null` otherwise

Since
  1.2.0

References EINA_LIST_FOREACH, eina_list_remove_list(), EINA_SAFETY_ON_NULL_RETURN_VAL, and eina_stringshare_del().

## ◆ edje_object_text_markup_filter_callback_del_full()

void* edje_object_text_markup_filter_callback_del_full | ( | Evas_Object * | obj,
|  | const char * | part,
|  | Edje_Markup_Filter_Cb | func,
|  | void * | data
| ) |  |

Deletes a function and matching user data from the markup filter list.

Delete the given func filter and data user data from the list in part. Returns the user data pointer given when added.

See also edje_object_text_markup_filter_callback_add and edje_object_text_markup_filter_callback_del

Parameters

  [in] | part | The part name
  [in] | func | The function callback to remove
  [in] | data | The data passed to the callback function

Returns
  The same data pointer if successful, or `null` otherwise

Since
  1.2.0

References EINA_LIST_FOREACH, eina_list_remove_list(), EINA_SAFETY_ON_NULL_RETURN_VAL, and eina_stringshare_del().

## ◆ edje_object_play_set()

void edje_object_play_set | ( | Evas_Object * | obj,
|  | Eina_Bool | play
| ) |  |

Whether this object is playing or not.

This property indicates whether the object is running or not. If stopped (or paused), all transitions are disabled and programs stop running, until resumed.

If play is disabled, the object will remain the same, and its parts will not change state. Note that play can be disabled during a transition between states, effectively freezing the object in flight. When paused, no events will be processed or sent.

Setting to `true` resumes playing from the current state.

Start or stop playing programs in this object.

Parameters

  [in] | play | The play state, `true` by default.

## ◆ edje_object_play_get()

Eina_Bool edje_object_play_get | ( | const Evas_Object * | obj | ) |

Whether this object is playing or not.

This property indicates whether the object is running or not. If stopped (or paused), all transitions are disabled and programs stop running, until resumed.

If play is disabled, the object will remain the same, and its parts will not change state. Note that play can be disabled during a transition between states, effectively freezing the object in flight. When paused, no events will be processed or sent.

Setting to `true` resumes playing from the current state.

Get the current state of play, `true` by default.

Returns
  The play state, `true` by default.

References EINA_FALSE.

## ◆ edje_object_transition_duration_factor_set()

void edje_object_transition_duration_factor_set | ( | Evas_Object * | obj,
|  | double | scale
| ) |  |

Transition duration factor.

This defines a multiplier for the duration of transitions as they are defined in EDC. By default this factor is 1.0, which means animations play at the same speed as described in EDC.

Sets transition duration factor.

Parameters

  [in] | scale | The transition duration factor.

## ◆ edje_object_transition_duration_factor_get()

double edje_object_transition_duration_factor_get | ( | const Evas_Object * | obj | ) |

Transition duration factor.

This defines a multiplier for the duration of transitions as they are defined in EDC. By default this factor is 1.0, which means animations play at the same speed as described in EDC.

Gets transition duration factor.

Returns
  The transition duration factor.

## ◆ edje_object_size_min_get()

void edje_object_size_min_get | ( | const Evas_Object * | obj,
|  | int * | minw,
|  | int * | minh
| ) |  |

Gets the minimum size specified – as an EDC property – for a given Edje object.

This function retrieves the obj object's minimum size values, as declared in its EDC group definition. For instance, for an Edje object of minimum size 100x100 pixels: collections { group { name: "a_group"; min: 100 100; } }

Note
  If the `min` EDC property was not declared for this object, this call will return 0x0.
  On failure, this function also return 0x0.

See also edje_object_size_max_get.

Parameters

  [out] | minw | Pointer to a variable where to store the minimum width
  [out] | minh | Pointer to a variable where to store the minimum height

## ◆ edje_object_size_max_get()

void edje_object_size_max_get | ( | const Evas_Object * | obj,
|  | int * | maxw,
|  | int * | maxh
| ) |  |

Gets the maximum size specified – as an EDC property – for a given Edje object.

This function retrieves the object's maximum size values, as declared in its EDC group definition. For instance, for an Edje object of maximum size 100x100 pixels: collections { group { name: "a_group"; max: 100 100; } }

Note
  If the `max` EDC property was not declared for the object, this call will return the maximum size a given Edje object may have, for each axis.
  On failure, this function will return 0x0.

See also edje_object_size_min_get.

Parameters

  [out] | maxw | The maximum width
  [out] | maxh | The maximum height

## ◆ edje_object_item_provider_set()

void edje_object_item_provider_set | ( | Edje_Object * | obj,
|  | Edje_Item_Provider_Cb | func,
|  | void * | data
| ) |  |

Sets the function that provides item objects for named items in an edje entry text.

Item objects may be deleted any time by Edje, and will be deleted when the Edje object is deleted (or file is set to a new file).

Parameters

  [in] | obj | The object.
  [in] | func | The function to call (or `null` to disable) to get item objects
  [in] | data | The data pointer to pass to the func callback

## ◆ edje_object_animation_set()

void edje_object_animation_set | ( | Efl_Canvas_Layout * | obj,
|  | Eina_Bool | on
| ) |  |

Whether this object is animating or not.

This property indicates whether animations are stopped or not. Animations here refer to transitions between states.

If animations are disabled, transitions between states (as defined in EDC) are then instantaneous. This is conceptually similar to setting the Efl.Player.playback_speed to an infinitely high value.

Start or stop animating this object.

Parameters

  [in] | obj | The object.
  [in] | on | The animation state, `true` by default.

## ◆ edje_object_animation_get()

Eina_Bool edje_object_animation_get | ( | const Efl_Canvas_Layout * | obj | ) |

Whether this object is animating or not.

This property indicates whether animations are stopped or not. Animations here refer to transitions between states.

If animations are disabled, transitions between states (as defined in EDC) are then instantaneous. This is conceptually similar to setting the Efl.Player.playback_speed to an infinitely high value.

Get the current state of animation, `true` by default.

Parameters

  [in] | obj | The object.

Returns
  The animation state, `true` by default.

## ◆ edje_object_seat_get()

Efl_Input_Device* edje_object_seat_get | ( | const Efl_Canvas_Layout * | obj,
|  | Eina_Stringshare * | name
| ) |  |

Returns the seat device given its Edje's name.

Edje references seats by a name that differs from Evas. Edje naming follows a incrementional convention: first registered name is "seat1", second is "seat2", differently from Evas.

Parameters

  [in] | obj | The object.
  [in] | name | The name's character string.

Returns
  The seat device or `null` if not found.

Since
  1.19

## ◆ edje_object_seat_name_get()

Eina_Stringshare* edje_object_seat_name_get | ( | const Efl_Canvas_Layout * | obj,
|  | Efl_Input_Device * | device
| ) |  |

Gets the name given to a set by Edje.

Edje references seats by a name that differs from Evas. Edje naming follows a incrementional convention: first registered name is "seat1", second is "seat2", differently from Evas.

Parameters

  [in] | obj | The object.
  [in] | device | The seat device

Returns
  The name's character string or `null` if not found.

Since
  1.19

## ◆ edje_object_layout_load_error_get()

Eina_Error edje_object_layout_load_error_get | ( | const Efl_Canvas_Layout * | obj | ) |

Gets the (last) file loading error for a given object.

Parameters

  [in] | obj | The object.

Returns
  The load error code.

## ◆ edje_object_content_remove()

Eina_Bool edje_object_content_remove | ( | Efl_Canvas_Layout * | obj,
|  | Efl_Gfx_Entity * | content
| ) |  |

Unswallow an object from this Edje.

Parameters

  [in] | obj | The object.
  [in] | content | To be removed content.

Returns
  `false` if `content` was not a child or can not be removed.