Tizen Native API
|
Functions | |
Eina_Bool | elm_config_focus_highlight_enabled_get (void) |
Get the enable status of the focus highlight. | |
void | elm_config_focus_highlight_enabled_set (Eina_Bool enable) |
Set the enable status of the focus highlight. | |
Eina_Bool | elm_config_focus_highlight_animate_get (void) |
Get the enable status of the focus highlight animation. | |
void | elm_config_focus_highlight_animate_set (Eina_Bool animate) |
Set the enable status of the highlight animation. | |
Eina_Bool | elm_object_focus_get (const Evas_Object *obj) |
Get the whether an Elementary object has the focus or not. | |
void | elm_object_focus_set (Evas_Object *obj, Eina_Bool focus) |
Set/unset focus to a given Elementary object. | |
void | elm_object_focus_allow_set (Evas_Object *obj, Eina_Bool enable) |
Set the ability for an Elementary object to be focused. | |
Eina_Bool | elm_object_focus_allow_get (const Evas_Object *obj) |
Get whether an Elementary object is focusable or not. | |
void | elm_object_focus_custom_chain_set (Evas_Object *obj, Eina_List *objs) |
Set custom focus chain. | |
void | elm_object_focus_custom_chain_unset (Evas_Object *obj) |
Unset a custom focus chain on a given Elementary widget. | |
const Eina_List * | elm_object_focus_custom_chain_get (const Evas_Object *obj) |
Get custom focus chain. | |
void | elm_object_focus_custom_chain_append (Evas_Object *obj, Evas_Object *child, Evas_Object *relative_child) |
Append object to custom focus chain. | |
void | elm_object_focus_custom_chain_prepend (Evas_Object *obj, Evas_Object *child, Evas_Object *relative_child) |
Prepend object to custom focus chain. | |
void | elm_object_focus_next (Evas_Object *obj, Elm_Focus_Direction dir) |
Give focus to next object in object tree. | |
Evas_Object * | elm_object_focus_next_object_get (const Evas_Object *obj, Elm_Focus_Direction dir) |
Get next object which was set with specific focus direction. | |
void | elm_object_focus_next_object_set (Evas_Object *obj, Evas_Object *next, Elm_Focus_Direction dir) |
Set next object with specific focus direction. | |
Evas_Object * | elm_object_focused_object_get (const Evas_Object *obj) |
Get focused object in object tree. | |
void | elm_object_tree_focus_allow_set (Evas_Object *obj, Eina_Bool focusable) |
Make the elementary object and its children to be focusable (or unfocusable). | |
Eina_Bool | elm_object_tree_focus_allow_get (const Evas_Object *obj) |
Get whether an Elementary object and its children are focusable or not. |
An Elementary application has, at all times, one (and only one) focused object. This is what determines where the input events go to within the application's window. Also, focused objects can be decorated differently, in order to signal to the user where the input is, at a given moment.
Elementary applications also have the concept of focus chain: one can cycle through all the windows' focusable objects by input (tab key) or programmatically. The default focus chain for an application is the one define by the order in which the widgets where added in code. One will cycle through top level widgets, and, for each one containing sub-objects, cycle through them all, before returning to the level above. Elementary also allows one to set custom focus chains for their applications.
Besides the focused decoration a widget may exhibit, when it gets focus, Elementary has a global focus highlight object that can be enabled for a window. If one chooses to do so, this extra highlight effect will surround the current focused object, too.
- Note:
- Some Elementary widgets are unfocusable, after creation, by their very nature: they are not meant to be interacted with input events, but are there just for visual purposes.
Enumeration Type Documentation
enum Elm_Focus_Direction |
Function Documentation
Get the enable status of the focus highlight animation.
- Since :
- 2.3
- Returns:
- animate
EINA_TRUE
if the focus highlight animation is enabled,EINA_FALSE
otherwise.
- Remarks:
- Get whether the focus highlight, if enabled, will animate its switch from one object to the next
void elm_config_focus_highlight_animate_set | ( | Eina_Bool | animate | ) |
Set the enable status of the highlight animation.
- Since :
- 2.3
- Parameters:
-
[in] animate Enable animation if EINA_TRUE
, disable otherwise
- Remarks:
- Set whether the focus highlight, if enabled, will animate its switch from one object to the next
- Note that it will take effect only to Elementary windows created after this is called.
Get the enable status of the focus highlight.
- Since :
- 2.3
- Remarks:
- This gets whether the highlight on focused objects is enabled or not
- Returns:
- enable
EINA_TRUE
if the focus highlight is enabled,EINA_FALSE
otherwise.
void elm_config_focus_highlight_enabled_set | ( | Eina_Bool | enable | ) |
Set the enable status of the focus highlight.
- Since :
- 2.3
- Parameters:
-
[in] enable Enable highlight if EINA_TRUE
, disable otherwise
- Remarks:
- Set whether to show or not the highlight on focused objects
- Note that it will take effect only to Elementary windows created after this is called.
Eina_Bool elm_object_focus_allow_get | ( | const Evas_Object * | obj | ) |
Get whether an Elementary object is focusable or not.
- Since :
- 2.3
- Parameters:
-
[in] obj The Elementary object to operate on
- Returns:
EINA_TRUE
if the object is allowed to be focused,EINA_FALSE
if not (and on errors)
- Remarks:
- Objects which are meant to be interacted with by input events are created able to be focused, by default. All the others are not.
void elm_object_focus_allow_set | ( | Evas_Object * | obj, |
Eina_Bool | enable | ||
) |
Set the ability for an Elementary object to be focused.
- Since :
- 2.3
- Parameters:
-
[in] obj The Elementary object to operate on [in] enable EINA_TRUE
if the object can be focused,EINA_FALSE
if not (and on errors)
- Remarks:
- This sets whether the object
obj
is able to take focus or not. Unfocusable objects do nothing when programmatically focused, being the nearest focusable parent object the one really getting focus. Also, when they receive mouse input, they will get the event, but not take away the focus from where it was previously.
void elm_object_focus_custom_chain_append | ( | Evas_Object * | obj, |
Evas_Object * | child, | ||
Evas_Object * | relative_child | ||
) |
Append object to custom focus chain.
- Since :
- 2.3
- Remarks:
- If relative_child equal to NULL or not in custom chain, the object will be added in end.
- On focus cycle, only will be evaluated children of this container.
- Parameters:
-
[in] obj The container object [in] child The child to be added in custom chain [in] relative_child The relative object to position the child
const Eina_List* elm_object_focus_custom_chain_get | ( | const Evas_Object * | obj | ) |
Get custom focus chain.
- Since :
- 2.3
- Parameters:
-
[in] obj The container object
void elm_object_focus_custom_chain_prepend | ( | Evas_Object * | obj, |
Evas_Object * | child, | ||
Evas_Object * | relative_child | ||
) |
Prepend object to custom focus chain.
- Since :
- 2.3
- Remarks:
- If relative_child equal to NULL or not in custom chain, the object will be added in begin.
- On focus cycle, only will be evaluated children of this container.
- Parameters:
-
[in] obj The container object [in] child The child to be added in custom chain [in] relative_child The relative object to position the child
void elm_object_focus_custom_chain_set | ( | Evas_Object * | obj, |
Eina_List * | objs | ||
) |
Set custom focus chain.
- Since :
- 2.3
- Remarks:
- This function overwrites any previous custom focus chain within the list of objects. The previous list will be deleted and this list will be managed by elementary. After it is set, don't modify it.
- On focus cycle, only will be evaluated children of this container.
- Parameters:
-
[in] obj The container object [in] objs Chain of objects to pass focus
void elm_object_focus_custom_chain_unset | ( | Evas_Object * | obj | ) |
Unset a custom focus chain on a given Elementary widget.
- Since :
- 2.3
- Parameters:
-
[in] obj The container object to remove focus chain from
- Remarks:
- Any focus chain previously set on
obj
(for its child objects) is removed entirely after this call.
Eina_Bool elm_object_focus_get | ( | const Evas_Object * | obj | ) |
Get the whether an Elementary object has the focus or not.
- Since :
- 2.3
- Parameters:
-
[in] obj The Elementary object to get the information from
- Returns:
EINA_TRUE
, if the object is focused,EINA_FALSE
if not (and on errors).
- See also:
- elm_object_focus_set()
void elm_object_focus_next | ( | Evas_Object * | obj, |
Elm_Focus_Direction | dir | ||
) |
Give focus to next object in object tree.
- Since :
- 2.3
- Remarks:
- Give focus to next object in focus chain of one object sub-tree. If the last object of chain already have focus, the focus will go to the first object of chain.
- Parameters:
-
[in] obj The object root of sub-tree [in] dir Direction to move the focus
Evas_Object* elm_object_focus_next_object_get | ( | const Evas_Object * | obj, |
Elm_Focus_Direction | dir | ||
) |
Get next object which was set with specific focus direction.
- Since :
- 2.3
- Remarks:
- Get next object which was set by elm_object_focus_next_object_set with specific focus direction.
- Parameters:
-
[in] obj The Elementary object [in] dir Focus direction
- Returns:
- Focus next object or
NULL
, if there is no focus next object.
- Since (EFL) :
- 1.8
void elm_object_focus_next_object_set | ( | Evas_Object * | obj, |
Evas_Object * | next, | ||
Elm_Focus_Direction | dir | ||
) |
Set next object with specific focus direction.
- Since :
- 2.3
- Remarks:
- When focus next object is set with specific focus direction, this object will be the first candidate when finding next focusable object. Focus next object can be registered with six directions that are previous, next, up, down, right, and left.
- Parameters:
-
[in] obj The Elementary object [in] next Focus next object [in] dir Focus direction
- Since (EFL) :
- 1.8
void elm_object_focus_set | ( | Evas_Object * | obj, |
Eina_Bool | focus | ||
) |
Set/unset focus to a given Elementary object.
- Since :
- 2.3
- Parameters:
-
[in] obj The Elementary object to operate on. [in] focus EINA_TRUE
Set focus to a given object,EINA_FALSE
Unset focus to a given object.
- Remarks:
- When you set focus to this object, if it can handle focus, will take the focus away from the one who had it previously and will, for now on, be the one receiving input events. Unsetting focus will remove the focus from
obj
, passing it back to the previous element in the focus chain list.
- Warning:
- Only visible object can get a focus. Call evas_object_show(o) before calling this API, if you want to give a focus to the evas object.
Evas_Object* elm_object_focused_object_get | ( | const Evas_Object * | obj | ) |
Get focused object in object tree.
- Since :
- 2.3
- Remarks:
- This function returns current focused object in one object sub-tree.
- Parameters:
-
[in] obj The object root of sub-tree
- Returns:
- Current focused or
NULL
, if there is no focused object.
- Since (EFL) :
- 1.8
Eina_Bool elm_object_tree_focus_allow_get | ( | const Evas_Object * | obj | ) |
Get whether an Elementary object and its children are focusable or not.
- Since :
- 2.3
- Parameters:
-
[in] obj The Elementary object to get the information from
- Returns:
EINA_TRUE
, if the tree is focusable,EINA_FALSE
if not (and on errors).
- See also:
- elm_object_tree_focus_allow_set()
void elm_object_tree_focus_allow_set | ( | Evas_Object * | obj, |
Eina_Bool | focusable | ||
) |
Make the elementary object and its children to be focusable (or unfocusable).
- Since :
- 2.3
- Parameters:
-
[in] obj The Elementary object to operate on [in] focusable EINA_TRUE
for focusable,EINA_FALSE
for unfocusable.
- Remarks:
- This sets whether the object
obj
and its children objects are able to take focus or not. If the tree is set as unfocusable, newest focused object which is not in this tree will get focus. This API can be helpful for an object to be deleted. When an object will be deleted soon, it and its children may not want to get focus (by focus reverting or by other focus controls). Then, just use this API before deleting.
- See also:
- elm_object_tree_focus_allow_get()