Tizen Native API
5.5
|
Functions that manipulate generic Evas objects.
All Evas displaying units are Evas objects. One handles them all by means of the handle Evas_Object. Besides Evas treats their objects equally, they have types that define their specific behavior (and individual API).
Evas comes with a set of built-in object types:
These functions apply to any Evas object, whatever type they may have.
Functions | |
Eina_Bool | evas_object_pointer_mode_set (Efl_Canvas_Object *obj, Evas_Object_Pointer_Mode pointer_mode) |
Low-level pointer behaviour. | |
Evas_Object_Pointer_Mode | evas_object_pointer_mode_get (const Efl_Canvas_Object *obj) |
Low-level pointer behaviour. | |
void | evas_object_clip_set (Efl_Canvas_Object *obj, Efl_Canvas_Object *clip) |
Clip one object to another. | |
Efl_Canvas_Object * | evas_object_clip_get (const Efl_Canvas_Object *obj) |
Get the object clipping obj (if any). | |
void | evas_object_repeat_events_set (Efl_Canvas_Object *obj, Eina_Bool repeat) |
Set whether an Evas object is to repeat events. | |
Eina_Bool | evas_object_repeat_events_get (const Efl_Canvas_Object *obj) |
Determine whether an object is set to repeat events. | |
void | evas_object_focus_set (Efl_Canvas_Object *obj, Eina_Bool focus) |
Indicates that this object is the keyboard event receiver on its canvas. | |
Eina_Bool | evas_object_focus_get (const Efl_Canvas_Object *obj) |
Indicates that this object is the keyboard event receiver on its canvas. | |
void | evas_object_precise_is_inside_set (Efl_Canvas_Object *obj, Eina_Bool precise) |
Set whether to use precise (usually expensive) point collision detection for a given Evas object. | |
Eina_Bool | evas_object_precise_is_inside_get (const Efl_Canvas_Object *obj) |
Determine whether an object is set to use precise point collision detection. | |
void | evas_object_propagate_events_set (Efl_Canvas_Object *obj, Eina_Bool propagate) |
Set whether events on a smart object's member should be propagated up to its parent. | |
Eina_Bool | evas_object_propagate_events_get (const Efl_Canvas_Object *obj) |
Retrieve whether an Evas object is set to propagate events. | |
void | evas_object_pass_events_set (Efl_Canvas_Object *obj, Eina_Bool pass) |
Set whether an Evas object is to pass (ignore) events. | |
Eina_Bool | evas_object_pass_events_get (const Efl_Canvas_Object *obj) |
Determine whether an object is set to pass (ignore) events. | |
void | evas_object_anti_alias_set (Efl_Canvas_Object *obj, Eina_Bool anti_alias) |
Sets whether or not the given Evas object is to be drawn anti-aliased. | |
Eina_Bool | evas_object_anti_alias_get (const Efl_Canvas_Object *obj) |
Retrieves whether or not the given Evas object is to be drawn anti_aliased. | |
Efl_Canvas_Object * | evas_object_smart_parent_get (const Efl_Canvas_Object *obj) |
Gets the parent smart object of a given Evas object, if it has one. | |
void | evas_object_paragraph_direction_set (Efl_Canvas_Object *obj, Evas_BiDi_Direction dir) |
This handles text paragraph direction of the given object. Even if the given object is not textblock or text, its smart child objects can inherit the paragraph direction from the given object. The default paragraph direction is inherit . | |
Evas_BiDi_Direction | evas_object_paragraph_direction_get (const Efl_Canvas_Object *obj) |
This handles text paragraph direction of the given object. Even if the given object is not textblock or text, its smart child objects can inherit the paragraph direction from the given object. The default paragraph direction is inherit . | |
Eina_Bool | evas_object_clipees_has (const Efl_Canvas_Object *obj) |
Test if any object is clipped by obj . | |
void | evas_object_is_frame_object_set (Efl_Canvas_Object *obj, Eina_Bool is_frame) |
If true the object belongs to the window border decorations. | |
Eina_Bool | evas_object_is_frame_object_get (const Efl_Canvas_Object *obj) |
If true the object belongs to the window border decorations. | |
void | evas_object_freeze_events_set (Efl_Canvas_Object *obj, Eina_Bool freeze) |
Set whether an Evas object is to freeze (discard) events. | |
Eina_Bool | evas_object_freeze_events_get (const Efl_Canvas_Object *obj) |
Determine whether an object is set to freeze (discard) events. | |
Typedefs | |
typedef Eo | Efl_Canvas_Object |
typedef Efl_Canvas_Object | Evas_Object |
An Evas Object handle
An Evas Object handle.
Eina_Bool evas_object_anti_alias_get | ( | const Efl_Canvas_Object * | obj | ) |
Retrieves whether or not the given Evas object is to be drawn anti_aliased.
[in] | obj | The object. |
true
if the object is to be anti_aliased, false
otherwise. void evas_object_anti_alias_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | anti_alias | ||
) |
Sets whether or not the given Evas object is to be drawn anti-aliased.
[in] | obj | The object. |
[in] | anti_alias | true if the object is to be anti_aliased, false otherwise. |
Efl_Canvas_Object* evas_object_clip_get | ( | const Efl_Canvas_Object * | obj | ) |
Get the object clipping obj
(if any).
This function returns the object clipping obj
. If obj
is not being clipped at all, null
is returned. The object obj
must be a valid Evas_Object.
[in] | obj | The object. |
obj
by. void evas_object_clip_set | ( | Efl_Canvas_Object * | obj, |
Efl_Canvas_Object * | clip | ||
) |
Clip one object to another.
This function will clip the object obj
to the area occupied by the object clip
. This means the object obj
will only be visible within the area occupied by the clipping object ($clip).
The color of the object being clipped will be multiplied by the color of the clipping one, so the resulting color for the former will be "RESULT = (OBJ * CLIP) / (255 * 255)", per color element (red, green, blue and alpha).
Clipping is recursive, so clipping objects may be clipped by others, and their color will in term be multiplied. You may not set up circular clipping lists (i.e. object 1 clips object 2, which clips object 1): the behavior of Evas is undefined in this case.
Objects which do not clip others are visible in the canvas as normal; those that clip one or more objects become invisible themselves, only affecting what they clip. If an object ceases to have other objects being clipped by it, it will become visible again.
The visibility of an object affects the objects that are clipped by it, so if the object clipping others is not shown (as in Efl::Gfx::Entity::visible), the objects clipped by it will not be shown either.
If obj
was being clipped by another object when this function is called, it gets implicitly removed from the old clipper's domain and is made now to be clipped by its new clipper.
If clip
is null
, this call will disable clipping for the object i.e. its visibility and color get detached from the previous clipper. If it wasn't, this has no effect.
[in] | obj | The object. |
[in] | clip | The object to clip obj by. |
Eina_Bool evas_object_clipees_has | ( | const Efl_Canvas_Object * | obj | ) |
Test if any object is clipped by obj
.
[in] | obj | The object. |
true
if any object is clipped by obj
, false
otherwiseEina_Bool evas_object_focus_get | ( | const Efl_Canvas_Object * | obj | ) |
Indicates that this object is the keyboard event receiver on its canvas.
Changing focus only affects where (key) input events go. There can be only one object focused at any time. If focus
is true
, obj
will be set as the currently focused object and it will receive all keyboard events that are not exclusive key grabs on other objects. See also Efl::Canvas::Object::seat_focus_check, Efl::Canvas::Object::seat_focus_add, Efl::Canvas::Object::seat_focus_del.
[in] | obj | The object. |
true
when set as focused or false
otherwise. void evas_object_focus_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | focus | ||
) |
Indicates that this object is the keyboard event receiver on its canvas.
Changing focus only affects where (key) input events go. There can be only one object focused at any time. If focus
is true
, obj
will be set as the currently focused object and it will receive all keyboard events that are not exclusive key grabs on other objects. See also Efl::Canvas::Object::seat_focus_check, Efl::Canvas::Object::seat_focus_add, Efl::Canvas::Object::seat_focus_del.
[in] | obj | The object. |
[in] | focus | true when set as focused or false otherwise. |
Eina_Bool evas_object_freeze_events_get | ( | const Efl_Canvas_Object * | obj | ) |
Determine whether an object is set to freeze (discard) events.
[in] | obj | The object. |
obj
is to freeze events ($true) or not ($false).void evas_object_freeze_events_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | freeze | ||
) |
Set whether an Evas object is to freeze (discard) events.
If freeze
is true
, it will force events on obj
to be discarded. Unlike evas_object_pass_events_set, events will not be passed to next lower object. This API can be used for blocking events while obj
is in transition.
If freeze
is false
, events will be processed on that object as normal.
[in] | obj | The object. |
[in] | freeze | Pass when obj is to freeze events ($true) or not ($false). |
Eina_Bool evas_object_is_frame_object_get | ( | const Efl_Canvas_Object * | obj | ) |
If true
the object belongs to the window border decorations.
This will be false
by default, and should be false
for all objects created by the application, unless swallowed in some very specific parts of the window.
It is very unlikely that an application needs to call this manually, as the window will handle this feature automatically.
[in] | obj | The object. |
true
if the object is a frame, false
otherwisevoid evas_object_is_frame_object_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | is_frame | ||
) |
If true
the object belongs to the window border decorations.
This will be false
by default, and should be false
for all objects created by the application, unless swallowed in some very specific parts of the window.
It is very unlikely that an application needs to call this manually, as the window will handle this feature automatically.
[in] | obj | The object. |
[in] | is_frame | true if the object is a frame, false otherwise |
Evas_BiDi_Direction evas_object_paragraph_direction_get | ( | const Efl_Canvas_Object * | obj | ) |
This handles text paragraph direction of the given object. Even if the given object is not textblock or text, its smart child objects can inherit the paragraph direction from the given object. The default paragraph direction is inherit
.
[in] | obj | The object. |
void evas_object_paragraph_direction_set | ( | Efl_Canvas_Object * | obj, |
Evas_BiDi_Direction | dir | ||
) |
This handles text paragraph direction of the given object. Even if the given object is not textblock or text, its smart child objects can inherit the paragraph direction from the given object. The default paragraph direction is inherit
.
[in] | obj | The object. |
[in] | dir | Paragraph direction for the given object. |
Eina_Bool evas_object_pass_events_get | ( | const Efl_Canvas_Object * | obj | ) |
Determine whether an object is set to pass (ignore) events.
See also evas_object_repeat_events_get, evas_object_propagate_events_get.
[in] | obj | The object. |
obj
is to pass events ($true) or not ($false). void evas_object_pass_events_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | pass | ||
) |
Set whether an Evas object is to pass (ignore) events.
If pass
is true
, it will make events on obj
to be ignored. They will be triggered on the next lower object (that is not set to pass events), instead (see Efl::Gfx::Stack::below).
If pass
is false
events will be processed on that object as normal.
See also evas_object_repeat_events_set, evas_object_propagate_events_set
[in] | obj | The object. |
[in] | pass | Whether obj is to pass events ($true) or not ($false). |
Low-level pointer behaviour.
This function has a direct effect on event callbacks related to pointers (mouse, ...).
If the value is EVAS_OBJECT_POINTER_MODE_AUTO_GRAB (default), then when mouse is pressed down over this object, events will be restricted to it as source, mouse moves, for example, will be emitted even when the pointer goes outside this objects geometry.
If the value is EVAS_OBJECT_POINTER_MODE_NO_GRAB, then events will be emitted just when inside this object area.
The default value is EVAS_OBJECT_POINTER_MODE_AUTO_GRAB. See also: Efl::Canvas::Object::pointer_mode_by_device::get and Efl::Canvas::Object::pointer_mode_by_device::set Note: This function will only set/get the mode for the default pointer.
[in] | obj | The object. |
Eina_Bool evas_object_pointer_mode_set | ( | Efl_Canvas_Object * | obj, |
Evas_Object_Pointer_Mode | pointer_mode | ||
) |
Low-level pointer behaviour.
This function has a direct effect on event callbacks related to pointers (mouse, ...).
If the value is EVAS_OBJECT_POINTER_MODE_AUTO_GRAB (default), then when mouse is pressed down over this object, events will be restricted to it as source, mouse moves, for example, will be emitted even when the pointer goes outside this objects geometry.
If the value is EVAS_OBJECT_POINTER_MODE_NO_GRAB, then events will be emitted just when inside this object area.
The default value is EVAS_OBJECT_POINTER_MODE_AUTO_GRAB. See also: Efl::Canvas::Object::pointer_mode_by_device::get and Efl::Canvas::Object::pointer_mode_by_device::set Note: This function will only set/get the mode for the default pointer.
[in] | obj | The object. |
[in] | pointer_mode | Input pointer mode |
true
if pointer behaviour was set, false
otherwise Eina_Bool evas_object_precise_is_inside_get | ( | const Efl_Canvas_Object * | obj | ) |
Determine whether an object is set to use precise point collision detection.
[in] | obj | The object. |
void evas_object_precise_is_inside_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | precise | ||
) |
Set whether to use precise (usually expensive) point collision detection for a given Evas object.
Use this function to make Evas treat objects' transparent areas as not belonging to it with regard to mouse pointer events. By default, all of the object's boundary rectangle will be taken in account for them.
[in] | obj | The object. |
[in] | precise | Whether to use precise point collision detection or not. The default value is false. |
Eina_Bool evas_object_propagate_events_get | ( | const Efl_Canvas_Object * | obj | ) |
Retrieve whether an Evas object is set to propagate events.
See also evas_object_repeat_events_get, evas_object_pass_events_get.
[in] | obj | The object. |
void evas_object_propagate_events_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | propagate | ||
) |
Set whether events on a smart object's member should be propagated up to its parent.
This function has no effect if obj
is not a member of a smart object.
If prop
is true
, events occurring on this object will be propagated on to the smart object of which obj
is a member. If prop
is false
, events occurring on this object will not be propagated on to the smart object of which obj
is a member. The default value is true
.
See also evas_object_repeat_events_set, evas_object_pass_events_set.
[in] | obj | The object. |
[in] | propagate | Whether to propagate events ($true) or not ($false). |
Eina_Bool evas_object_repeat_events_get | ( | const Efl_Canvas_Object * | obj | ) |
Determine whether an object is set to repeat events.
[in] | obj | The object. |
obj
is to repeat events ($true) or not ($false). void evas_object_repeat_events_set | ( | Efl_Canvas_Object * | obj, |
Eina_Bool | repeat | ||
) |
Set whether an Evas object is to repeat events.
If repeat
is true
, it will make events on obj
to also be repeated for the next lower object in the objects' stack (see see Efl::Gfx::Stack::below).
If repeat
is false
, events occurring on obj
will be processed only on it.
[in] | obj | The object. |
[in] | repeat | Whether obj is to repeat events ($true) or not ($false). |
Efl_Canvas_Object* evas_object_smart_parent_get | ( | const Efl_Canvas_Object * | obj | ) |
Gets the parent smart object of a given Evas object, if it has one.
This can be different from Efl::Object::parent because this one is used internally for rendering and the normal parent is what the user expects to be the parent.
[in] | obj | The object. |
obj
or null
.