Tizen Native API
Functions | Typedefs
Toolbar
Elementary Widgets

Functions

Evas_Objectelm_toolbar_add (Evas_Object *parent)
 Adds a new toolbar widget to the given parent Elementary (container) object.
void elm_toolbar_icon_size_set (Evas_Object *obj, int icon_size)
 Sets the icon size, in pixels, to be used by toolbar items.
int elm_toolbar_icon_size_get (const Evas_Object *obj)
 Gets the icon size, in pixels, to be used by toolbar items.
void elm_toolbar_icon_order_lookup_set (Evas_Object *obj, Elm_Icon_Lookup_Order order)
 Sets the icon lookup order, for toolbar item icons.
Elm_Icon_Lookup_Order elm_toolbar_icon_order_lookup_get (const Evas_Object *obj)
 Gets the icon lookup order.
Elm_Object_Itemelm_toolbar_item_append (Evas_Object *obj, const char *icon, const char *label, Evas_Smart_Cb func, const void *data)
 Appends items to the toolbar.
Elm_Object_Itemelm_toolbar_item_prepend (Evas_Object *obj, const char *icon, const char *label, Evas_Smart_Cb func, const void *data)
 Prepends items to the toolbar.
Elm_Object_Itemelm_toolbar_item_insert_before (Evas_Object *obj, Elm_Object_Item *before, const char *icon, const char *label, Evas_Smart_Cb func, const void *data)
 Inserts a new item into the toolbar object before item before.
Elm_Object_Itemelm_toolbar_item_insert_after (Evas_Object *obj, Elm_Object_Item *after, const char *icon, const char *label, Evas_Smart_Cb func, const void *data)
 Inserts a new item into the toolbar object after item after.
Elm_Object_Itemelm_toolbar_first_item_get (const Evas_Object *obj)
 Gets the first item in the given toolbar widget's list of items.
Elm_Object_Itemelm_toolbar_last_item_get (const Evas_Object *obj)
 Gets the last item in the given toolbar widget's list of items.
Elm_Object_Itemelm_toolbar_item_next_get (const Elm_Object_Item *it)
 Gets the item after it in the toolbar.
Elm_Object_Itemelm_toolbar_item_prev_get (const Elm_Object_Item *it)
 Gets the item before it in the toolbar.
void elm_toolbar_item_priority_set (Elm_Object_Item *it, int priority)
 Sets the priority of a toolbar item.
int elm_toolbar_item_priority_get (const Elm_Object_Item *it)
 Gets the priority of a toolbar item.
Elm_Object_Itemelm_toolbar_item_find_by_label (const Evas_Object *obj, const char *label)
 Returns a pointer to a toolbar item by its label.
Eina_Bool elm_toolbar_item_selected_get (const Elm_Object_Item *it)
 Gets whether the it is selected.
void elm_toolbar_item_selected_set (Elm_Object_Item *it, Eina_Bool selected)
 Sets the selected state of an item.
Elm_Object_Itemelm_toolbar_selected_item_get (const Evas_Object *obj)
 Gets the selected item.
Elm_Object_Itemelm_toolbar_more_item_get (const Evas_Object *obj)
 Gets the more item.
void elm_toolbar_item_icon_set (Elm_Object_Item *it, const char *icon)
 Sets the icon associated with it.
const char * elm_toolbar_item_icon_get (const Elm_Object_Item *it)
 Gets the string used to set the icon of it.
Evas_Objectelm_toolbar_item_object_get (const Elm_Object_Item *it)
 Gets the object of it.
Evas_Objectelm_toolbar_item_icon_object_get (Elm_Object_Item *it)
 Gets the icon object of it.
Eina_Bool elm_toolbar_item_icon_memfile_set (Elm_Object_Item *it, const void *img, size_t size, const char *format, const char *key)
 Sets the icon associated with it to an image in a binary buffer.
Eina_Bool elm_toolbar_item_icon_file_set (Elm_Object_Item *it, const char *file, const char *key)
 Sets the icon associated with it to an image in a binary buffer.
void elm_toolbar_item_separator_set (Elm_Object_Item *it, Eina_Bool separator)
 Sets or unsets item as a separator.
Eina_Bool elm_toolbar_item_separator_get (const Elm_Object_Item *it)
 Gets a value that indicates whether the item is a separator.
void elm_toolbar_shrink_mode_set (Evas_Object *obj, Elm_Toolbar_Shrink_Mode shrink_mode)
 Sets the item displaying mode of a given toolbar widget obj.
Elm_Toolbar_Shrink_Mode elm_toolbar_shrink_mode_get (const Evas_Object *obj)
 Gets the shrink mode of the toolbar obj.
void elm_toolbar_transverse_expanded_set (Evas_Object *obj, Eina_Bool transverse_expanded)
 Sets the item's transverse expansion of a given toolbar widget obj.
Eina_Bool elm_toolbar_transverse_expanded_get (const Evas_Object *obj)
 Gets the transverse expansion of the toolbar obj.
void elm_toolbar_homogeneous_set (Evas_Object *obj, Eina_Bool homogeneous)
 Enables or disables the homogeneous mode.
Eina_Bool elm_toolbar_homogeneous_get (const Evas_Object *obj)
 Gets whether the homogeneous mode is enabled.
void elm_toolbar_menu_parent_set (Evas_Object *obj, Evas_Object *parent)
 Sets the parent object of the toolbar items menus.
Evas_Objectelm_toolbar_menu_parent_get (const Evas_Object *obj)
 Gets the parent object of the toolbar items menus.
void elm_toolbar_align_set (Evas_Object *obj, double align)
 Sets the alignment of the items.
double elm_toolbar_align_get (const Evas_Object *obj)
 Gets the alignment of the items.
Elm_Toolbar_Item_Stateelm_toolbar_item_state_add (Elm_Object_Item *it, const char *icon, const char *label, Evas_Smart_Cb func, const void *data)
 Adds a new state to it.
Eina_Bool elm_toolbar_item_state_del (Elm_Object_Item *it, Elm_Toolbar_Item_State *state)
 Deletes a previously added state to it.
Eina_Bool elm_toolbar_item_state_set (Elm_Object_Item *it, Elm_Toolbar_Item_State *state)
 Sets state as the current state of it.
void elm_toolbar_item_state_unset (Elm_Object_Item *it)
 Unsets the state of it.
Elm_Toolbar_Item_Stateelm_toolbar_item_state_get (const Elm_Object_Item *it)
 Gets the current state of it.
Elm_Toolbar_Item_Stateelm_toolbar_item_state_next (Elm_Object_Item *it)
 Gets the state after the selected state in the toolbar's it.
Elm_Toolbar_Item_Stateelm_toolbar_item_state_prev (Elm_Object_Item *it)
 Gets the state before the selected state in the toolbar's it.
void elm_toolbar_horizontal_set (Evas_Object *obj, Eina_Bool horizontal)
 Changes a toolbar's orientation.
Eina_Bool elm_toolbar_horizontal_get (const Evas_Object *obj)
 Gets a toolbar's orientation.
unsigned int elm_toolbar_items_count (const Evas_Object *obj)
 Gets the number of items in a toolbar.
void elm_toolbar_standard_priority_set (Evas_Object *obj, int priority)
 Sets the standard priority of visible items in a toolbar.
int elm_toolbar_standard_priority_get (const Evas_Object *obj)
 Gets the standard priority of visible items in a toolbar.
void elm_toolbar_select_mode_set (Evas_Object *obj, Elm_Object_Select_Mode mode)
 Sets the toolbar select mode.
Elm_Object_Select_Mode elm_toolbar_select_mode_get (const Evas_Object *obj)
 Gets the toolbar select mode.
void elm_toolbar_reorder_mode_set (Evas_Object *obj, Eina_Bool reorder_mode)
 Sets the reorder mode.
Eina_Bool elm_toolbar_reorder_mode_get (const Evas_Object *obj)
 Gets the reorder mode.
void elm_toolbar_item_show (Elm_Object_Item *it, Elm_Toolbar_Item_Scrollto_Type type)
 Shows a specific item, when the toolbar can be scrolled.
void elm_toolbar_item_bring_in (Elm_Object_Item *it, Elm_Toolbar_Item_Scrollto_Type type)
 Shows a specific item with scroll animation, when the toolbar can be scrolled.

Typedefs

typedef struct
_Elm_Toolbar_Item_State 
Elm_Toolbar_Item_State

A toolbar is a widget that displays a list of items inside a box.

toolbar_inheritance_tree.png
toolbar.png

It can be scrollable, can show a menu with items that don't fit to the toolbar size or an can even crop those menu items.

Only one item can be selected at a time.

Items can have multiple states, or show menus when selected by the user.

This widget implements the elm-scrollable-interface interface, so that all (non-deprecated) functions for the base Scroller widget also work for toolbars (

Since (EFL) :
1.8)

Smart callbacks that one can listen to:

Available styles for it:

Default text parts of the toolbar items that you can use are:

Supported common elm_object_item APIs.


Typedef Documentation

typedef struct _Elm_Toolbar_Item_State Elm_Toolbar_Item_State

States of a Elm_Toolbar_Item. Can be created with elm_toolbar_item_state_add() and removed with elm_toolbar_item_state_del()


Enumeration Type Documentation

Enumeration that defines where to position the item in the toolbar.

Since :
2.3
Enumerator:
ELM_TOOLBAR_ITEM_SCROLLTO_NONE 

Scroll to nowhere

ELM_TOOLBAR_ITEM_SCROLLTO_IN 

Scroll to the nearest viewport

ELM_TOOLBAR_ITEM_SCROLLTO_FIRST 

Scroll to the first of the viewport

ELM_TOOLBAR_ITEM_SCROLLTO_MIDDLE 

Scroll to the middle of the viewport

ELM_TOOLBAR_ITEM_SCROLLTO_LAST 

Scroll to the last of the viewport

Enumeration that sets the toolbar items display behavior, it can be scrollable, can show a menu with exceeding items, or simply hide them.

Since :
2.3
Remarks:
Default value is ELM_TOOLBAR_SHRINK_MENU. It reads values from elm config.
Values don't work as bitmask, only one can be chosen.
See also:
elm_toolbar_shrink_mode_set()
elm_toolbar_shrink_mode_get()
Enumerator:
ELM_TOOLBAR_SHRINK_NONE 

Sets minimum toolbar size to fit all the items

ELM_TOOLBAR_SHRINK_HIDE 

Hides exceeding items

ELM_TOOLBAR_SHRINK_SCROLL 

Allows accessing exceeding items through a scroller

ELM_TOOLBAR_SHRINK_MENU 

Inserts a button to pop up a menu with exceeding items

ELM_TOOLBAR_SHRINK_EXPAND 

Expands all items according to the size of the toolbar

ELM_TOOLBAR_SHRINK_LAST 

Indicates an error if returned by elm_toolbar_shrink_mode_get()


Function Documentation

Adds a new toolbar widget to the given parent Elementary (container) object.

This function inserts a new toolbar widget on the canvas.

Since :
2.3
Parameters:
[in]parentThe parent object
Returns:
A new toolbar widget handle, otherwise NULL in case of an error
double elm_toolbar_align_get ( const Evas_Object obj)

Gets the alignment of the items.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The toolbar items alignment, a float between 0.0 and 1.0
See also:
elm_toolbar_align_set()
void elm_toolbar_align_set ( Evas_Object obj,
double  align 
)

Sets the alignment of the items.

Since :
2.3
Remarks:
Alignment of the toolbar items, from 0.0 that indicates to align to the left, to 1.0 , that indicates to align to the right. 0.5 to centralize items.
Items are centered by default.
Parameters:
[in]objThe toolbar object
[in]alignThe new alignment, a float between 0.0 and 1.0
See also:
elm_toolbar_align_get()

Gets the first item in the given toolbar widget's list of items.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The first item, otherwise NULL if it has no items (and on errors)
See also:
elm_toolbar_item_append()
elm_toolbar_last_item_get()

Gets whether the homogeneous mode is enabled.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The boolean value that assumes that the items within the toolbar are of the same height and width (EINA_TRUE = on, EINA_FALSE = off)
See also:
elm_toolbar_homogeneous_set()
void elm_toolbar_homogeneous_set ( Evas_Object obj,
Eina_Bool  homogeneous 
)

Enables or disables the homogeneous mode.

This enables the homogeneous mode where items are of the same size.

Since :
2.3
Parameters:
[in]objThe toolbar object
[in]homogeneousThe boolean value that assumes that the items within the toolbar are of the same size (EINA_TRUE = on, EINA_FALSE = off)
The default is EINA_FALSE.
See also:
elm_toolbar_homogeneous_get()

Gets a toolbar's orientation.

Since :
2.3
Remarks:
By default, a toolbar is horizontal. Use this function to determine whether a toolbar is vertical.
Parameters:
[in]objThe toolbar object
Returns:
If EINA_TRUE, the toolbar is horizontal, otherwise EINA_FALSE
void elm_toolbar_horizontal_set ( Evas_Object obj,
Eina_Bool  horizontal 
)

Changes a toolbar's orientation.

Since :
2.3
Remarks:
By default, a toolbar is horizontal. Use this function to create a vertical toolbar.
Parameters:
[in]objThe toolbar object
[in]horizontalIf EINA_TRUE the toolbar is horizontal, otherwise EINA_FALSE

Gets the icon lookup order.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The icon lookup order
See also:
elm_toolbar_icon_order_lookup_set()

Sets the icon lookup order, for toolbar item icons.

Since :
2.3
Remarks:
Icons added before calling this function are not affected. The default lookup order is ELM_ICON_LOOKUP_THEME_FDO.
Parameters:
[in]objThe toolbar object
[in]orderThe icon lookup order
See also:
elm_toolbar_icon_order_lookup_get()
int elm_toolbar_icon_size_get ( const Evas_Object obj)

Gets the icon size, in pixels, to be used by toolbar items.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The icon size in pixels
See also:
elm_toolbar_icon_size_set()
void elm_toolbar_icon_size_set ( Evas_Object obj,
int  icon_size 
)

Sets the icon size, in pixels, to be used by toolbar items.

Since :
2.3
Remarks:
The default value is 32. It reads values from elm config.
Parameters:
[in]objThe toolbar object
[in]icon_sizeThe icon size in pixels
See also:
elm_toolbar_icon_size_get()
Elm_Object_Item* elm_toolbar_item_append ( Evas_Object obj,
const char *  icon,
const char *  label,
Evas_Smart_Cb  func,
const void *  data 
)

Appends items to the toolbar.

Since :
2.3
Remarks:
A new item is created and appended to the toolbar, i.e., it is set as the last item.
Items created with this method can be deleted with elm_object_item_del().
Associated data can be properly freed when an item is deleted if a callback function is set with elm_object_item_del_cb_set().
If a function is passed as an argument, it is called every time this item is selected, i.e., the user clicks over an unselected item. If such a function isn't needed, just passing NULL as func is enough. The same should be done for data.
Toolbar loads the icon image from fdo or the current theme. This behavior can be set by the elm_toolbar_icon_order_lookup_set() function. If an absolute path is provided it loads it directly from a file.
Parameters:
[in]objThe toolbar object
[in]iconA string with the icon name or the absolute path of an image file
[in]labelThe label of the item
[in]funcThe function to call when the item is clicked
[in]dataThe data to associate with the item for related callbacks
Returns:
The created item, otherwise NULL on failure
See also:
elm_toolbar_item_icon_set()
elm_object_item_del()

Shows a specific item with scroll animation, when the toolbar can be scrolled.

Since (EFL) :
1.8
Since :
2.3
Parameters:
[in]itThe toolbar item
[in]typeItem scroll to type
See also:
elm_toolbar_item_show()
Elm_Object_Item* elm_toolbar_item_find_by_label ( const Evas_Object obj,
const char *  label 
)

Returns a pointer to a toolbar item by its label.

Since :
2.3
Parameters:
[in]objThe toolbar object
[in]labelThe label of the item to find
Returns:
The pointer to the toolbar item matching label, otherwise NULL on failure
Eina_Bool elm_toolbar_item_icon_file_set ( Elm_Object_Item it,
const char *  file,
const char *  key 
)

Sets the icon associated with it to an image in a binary buffer.

Since :
2.3
Remarks:
The icon image set by this function can be changed by elm_toolbar_item_icon_set().
Parameters:
[in]itThe toolbar item
[in]fileThe file that contains the image
[in]keyThe optional key of img to pass to the image loader (eg. if img is an edje file)
Returns:
(EINA_TRUE = success, EINA_FALSE = error)
const char* elm_toolbar_item_icon_get ( const Elm_Object_Item it)

Gets the string used to set the icon of it.

Since :
2.3
Parameters:
[in]itThe toolbar item
Returns:
The string associated with the icon object
See also:
elm_toolbar_item_icon_set()
Eina_Bool elm_toolbar_item_icon_memfile_set ( Elm_Object_Item it,
const void *  img,
size_t  size,
const char *  format,
const char *  key 
)

Sets the icon associated with it to an image in a binary buffer.

Since :
2.3
Remarks:
The icon image set by this function can be changed by elm_toolbar_item_icon_set().
Parameters:
[in]itThe toolbar item
[in]imgThe binary data that is used as an image
[in]sizeThe size of binary data img
[in]formatThe optional format of img to pass to the image loader
[in]keyThe optional key of img to pass to the image loader (eg. if img is an edje file)
Returns:
(EINA_TRUE = success, EINA_FALSE = error)

Gets the icon object of it.

Since :
2.3
Parameters:
[in]itThe toolbar item
Returns:
The icon object
See also:
elm_toolbar_item_icon_set()
elm_toolbar_item_icon_file_set()
elm_toolbar_item_icon_memfile_set()
void elm_toolbar_item_icon_set ( Elm_Object_Item it,
const char *  icon 
)

Sets the icon associated with it.

Since :
2.3
Remarks:
Toolbar loads the icon image from fdo or the current theme. This behavior can be set by the elm_toolbar_icon_order_lookup_set() function. If an absolute path is provided it loads it directly from a file.
Parameters:
[in]itThe toolbar item
[in]iconA string with the icon name or the absolute path of an image file
See also:
elm_toolbar_icon_order_lookup_set()
elm_toolbar_icon_order_lookup_get()
Elm_Object_Item* elm_toolbar_item_insert_after ( Evas_Object obj,
Elm_Object_Item after,
const char *  icon,
const char *  label,
Evas_Smart_Cb  func,
const void *  data 
)

Inserts a new item into the toolbar object after item after.

Since :
2.3
Remarks:
If new item is created and added to the toolbar, its position in this toolbar is just after item after.
Items created with this method can be deleted with elm_object_item_del().
Associated data can be properly freed when an item is deleted if a callback function is set with elm_object_item_del_cb_set().
If a function is passed as an argument, it is called every time this item is selected, i.e., the user clicks over an unselected item. If such a function isn't needed, just passing NULL as func is enough. The same should be done for data.
Toolbar loads the icon image from fdo or the current theme. This behavior can be set by the elm_toolbar_icon_order_lookup_set() function. If an absolute path is provided it loads it directly from a file.
Parameters:
[in]objThe toolbar object
[in]afterThe toolbar item to insert after
[in]iconA string with the icon name or the absolute path of an image file
[in]labelThe label of the item
[in]funcThe function to call when the item is clicked
[in]dataThe data to associate with the item for related callbacks
Returns:
The created item, otherwise NULL on failure
See also:
elm_toolbar_item_icon_set()
elm_object_item_del()
Elm_Object_Item* elm_toolbar_item_insert_before ( Evas_Object obj,
Elm_Object_Item before,
const char *  icon,
const char *  label,
Evas_Smart_Cb  func,
const void *  data 
)

Inserts a new item into the toolbar object before item before.

Since :
2.3
Remarks:
A new item is created and added to the toolbar. Its position in this toolbar is just before item before.
Items created with this method can be deleted with elm_object_item_del().
Associated data can be properly freed when an item is deleted if a callback function is set with elm_object_item_del_cb_set().
If a function is passed as an argument, it is called every time this item is selected, i.e., the user clicks over an unselected item. If such a function isn't needed, just passing NULL as func is enough. The same should be done for data.
Toolbar loads the icon image from fdo or the current theme. This behavior can be set by the elm_toolbar_icon_order_lookup_set() function. If an absolute path is provided it loads it directly from a file.
Parameters:
[in]objThe toolbar object
[in]beforeThe toolbar item to insert before
[in]iconA string with the icon name or the absolute path of an image file
[in]labelThe label of the item
[in]funcThe function to call when the item is clicked
[in]dataThe data to associate with the item for related callbacks
Returns:
The created item, otherwise NULL on failure
See also:
elm_toolbar_item_icon_set()
elm_object_item_del()

Gets the item after it in the toolbar.

Since :
2.3
Remarks:
If it is the last item, NULL is returned.
Parameters:
[in]itThe toolbar item
Returns:
The item after it, otherwise NULL if none are present or on failure
See also:
elm_toolbar_item_append()

Gets the object of it.

Since :
2.3
Parameters:
[in]itThe toolbar item
Returns:
The object
Elm_Object_Item* elm_toolbar_item_prepend ( Evas_Object obj,
const char *  icon,
const char *  label,
Evas_Smart_Cb  func,
const void *  data 
)

Prepends items to the toolbar.

Since :
2.3
Remarks:
A new item is created and prepended to the toolbar, i.e., it is set as the first item.
Items created with this method can be deleted with elm_object_item_del().
Associated data can be properly freed when an item is deleted if a callback function is set with elm_object_item_del_cb_set().
If a function is passed as an argument, it is called every time this item is selected, i.e., the user clicks over an unselected item. If such a function isn't needed, just passing NULL as func is enough. The same should be done for data.
Toolbar loads the icon image from fdo or the current theme. This behavior can be set by the elm_toolbar_icon_order_lookup_set() function. If an absolute path is provided it loads it directly from a file.
Parameters:
[in]objThe toolbar object
[in]iconA string with the icon name or the absolute path of an image file
[in]labelThe label of the item
[in]funcThe function to call when the item is clicked
[in]dataThe data to associate with the item for related callbacks
Returns:
The created item, otherwise NULL on failure
See also:
elm_toolbar_item_icon_set()
elm_object_item_del()

Gets the item before it in the toolbar.

Since :
2.3
Remarks:
If it is the first item, NULL is returned.
Parameters:
[in]itThe toolbar item
Returns:
The item before it, otherwise NULL if none are present or on failure
See also:
elm_toolbar_item_prepend()

Gets the priority of a toolbar item.

Since :
2.3
Parameters:
[in]itThe toolbar item
Returns:
The it priority, otherwise 0 on failure
See also:
elm_toolbar_item_priority_set()
void elm_toolbar_item_priority_set ( Elm_Object_Item it,
int  priority 
)

Sets the priority of a toolbar item.

Since :
2.3
Remarks:
This is used only when the toolbar shrink mode is set to ELM_TOOLBAR_SHRINK_MENU or ELM_TOOLBAR_SHRINK_HIDE. When space is less than required, items with low priority are removed from the toolbar and added to a dynamically-created menu, while items with higher priority remain on the toolbar, in the same order as they were added.
Parameters:
[in]itThe toolbar item
[in]priorityThe item priority
The default is zero.
See also:
elm_toolbar_item_priority_get()

Gets whether the it is selected.

Since :
2.3
Parameters:
[in]itThe toolbar item
Returns:
EINA_TRUE indicates that the item is selected, otherwise EINA_FALSE indicates it's not
If obj is NULL, EINA_FALSE is returned.
See also:
elm_toolbar_selected_item_set() for details.
elm_toolbar_item_selected_get()

Sets the selected state of an item.

Since :
2.3

This sets the selected state of the given item it. EINA_TRUE for selected, EINA_FALSE for not selected.

Remarks:
If a new item is selected the previously selected item is unselected. Previously selected items can be obtained with elm_toolbar_selected_item_get(). Selected items are highlighted.
Parameters:
[in]itThe toolbar item
[in]selectedThe selected state
See also:
elm_toolbar_item_selected_get()
elm_toolbar_selected_item_get()

Gets a value that indicates whether the item is a separator.

Since :
2.3
Parameters:
[in]itThe toolbar item
Returns:
EINA_TRUE indicates that item it is a separator, otherwise EINA_FALSE indicates it's not
If it is NULL, EINA_FALSE is returned.
See also:
elm_toolbar_item_separator_set()

Sets or unsets item as a separator.

Since :
2.3
Remarks:
Items aren't set as a separator by default. If set as a separator it displays a separator theme, so it won't display icons or labels.
Parameters:
[in]itThe toolbar item
[in]separatorIf EINA_TRUE set item it as a separator, otherwise EINA_FALSE to unset it, i.e., the item is used as a regular item
See also:
elm_toolbar_item_separator_get()

Shows a specific item, when the toolbar can be scrolled.

Since (EFL) :
1.8
Since :
2.3
Parameters:
[in]itThe toolbar item
[in]typeItem scroll to type
See also:
elm_toolbar_item_bring_in()
Elm_Toolbar_Item_State* elm_toolbar_item_state_add ( Elm_Object_Item it,
const char *  icon,
const char *  label,
Evas_Smart_Cb  func,
const void *  data 
)

Adds a new state to it.

Since :
2.3
Remarks:
Toolbar loads the icon image from fdo or the current theme. This behavior can be set by the elm_toolbar_icon_order_lookup_set() function. If an absolute path is provided it loads it directly from a file.
States created with this function can be removed using elm_toolbar_item_state_del().
Parameters:
[in]itThe toolbar item
[in]iconA string with the icon name or the absolute path of an image file
[in]labelThe label of the new state
[in]funcThe function to call when the item is clicked and when this state is selected
[in]dataThe data to associate with the state
Returns:
The toolbar item state, otherwise NULL on failure
See also:
elm_toolbar_item_state_del()
elm_toolbar_item_state_sel()
elm_toolbar_item_state_get()

Deletes a previously added state to it.

Since :
2.3
Parameters:
[in]itThe toolbar item
[in]stateThe state to be deleted
Returns:
EINA_TRUE on success, otherwise EINA_FALSE on failure
See also:
elm_toolbar_item_state_add()

Gets the current state of it.

Since :
2.3
Parameters:
[in]itThe toolbar item
Returns:
The selected state, otherwise NULL if none are selected or on failure
See also:
elm_toolbar_item_state_set() for details.
elm_toolbar_item_state_unset()
elm_toolbar_item_state_add()

Gets the state after the selected state in the toolbar's it.

Since :
2.3
Remarks:
If the last state is selected, this function returns the first state.
Parameters:
[in]itThe toolbar item to change state
Returns:
The state after the current state, otherwise NULL on failure
See also:
elm_toolbar_item_state_set()
elm_toolbar_item_state_add()

Gets the state before the selected state in the toolbar's it.

Since :
2.3
Remarks:
If the first state is selected, this function returns the last state.
Parameters:
[in]itThe toolbar item to change state
Returns:
The state before the current state, otherwise NULL on failure
See also:
elm_toolbar_item_state_set()
elm_toolbar_item_state_add()

Sets state as the current state of it.

Since :
2.3
Remarks:
If state is NULL, it won't select any state and the default item's icon and label is used. It's the same behaviour as elm_toolbar_item_state_unset().
Parameters:
[in]itThe toolbar item
[in]stateThe state to use
Returns:
EINA_TRUE on success, otherwise EINA_FALSE on failure
See also:
elm_toolbar_item_state_unset()

Unsets the state of it.

Since :
2.3
Remarks:
The default icon and label from this item is displayed.
Parameters:
[in]itThe toolbar item
See also:
elm_toolbar_item_state_set()
unsigned int elm_toolbar_items_count ( const Evas_Object obj)

Gets the number of items in a toolbar.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The number of items in the obj toolbar

Gets the last item in the given toolbar widget's list of items.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The last item, otherwise NULL if it has no items (and on errors)
See also:
elm_toolbar_item_prepend()
elm_toolbar_first_item_get()

Gets the parent object of the toolbar items menus.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The parent of the menu objects
See also:
elm_toolbar_menu_parent_set()
void elm_toolbar_menu_parent_set ( Evas_Object obj,
Evas_Object parent 
)

Sets the parent object of the toolbar items menus.

Since :
2.3
Remarks:
Each item can be set as an item menu, with elm_toolbar_item_menu_set().
For more details about setting the parent for toolbar menus, see elm_menu_parent_set().
Parameters:
[in]objThe toolbar object
[in]parentThe parent of the menu objects
See also:
elm_menu_parent_set()
elm_toolbar_item_menu_set()

Gets the more item.

Since :
2.3
Remarks:
The more item can be changed with function elm_object_item_text_set() and elm_object_item_content_set.
Parameters:
[in]objThe toolbar object
Returns:
The toolbar more item

Gets the reorder mode.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The reorder mode (EINA_TRUE = on, EINA_FALSE = off)
void elm_toolbar_reorder_mode_set ( Evas_Object obj,
Eina_Bool  reorder_mode 
)

Sets the reorder mode.

Since :
2.3
Parameters:
[in]objThe toolbar object
[in]reorder_modeThe reorder mode (EINA_TRUE = on, EINA_FALSE = off)

Gets the toolbar select mode.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The select mode (If the getting mode fails, it returns ELM_OBJECT_SELECT_MODE_MAX)
See also:
elm_toolbar_select_mode_set()

Sets the toolbar select mode.

Since :
2.3
Remarks:
elm_toolbar_select_mode_set() changes the item select mode in the toolbar widget.
  • ELM_OBJECT_SELECT_MODE_DEFAULT : Items only call their selection func and callback on first getting selected. Any further clicks do nothing, unless you set the always select mode.
  • ELM_OBJECT_SELECT_MODE_ALWAYS : This means that, even if selected, every click calls the selected callbacks.
  • ELM_OBJECT_SELECT_MODE_NONE : This turns off the ability to select items entirely and they neither appear selected nor call selected callback functions.
Parameters:
[in]objThe toolbar object
[in]modeThe select mode
See also:
elm_toolbar_select_mode_get()

Gets the selected item.

Since :
2.3
Remarks:
The selected item can be unselected with function elm_toolbar_item_selected_set(). The selected item is highlighted on the toolbar.
Parameters:
[in]objThe toolbar object
Returns:
The selected toolbar item
See also:
elm_toolbar_selected_items_get()

Gets the shrink mode of the toolbar obj.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The toolbar's items display behavior
See also:
elm_toolbar_shrink_mode_set()

Sets the item displaying mode of a given toolbar widget obj.

Since :
2.3
Remarks:
The toolbar won't scroll under the ELM_TOOLBAR_SHRINK_NONE mode, but it would enforce a minimum size, so that all the items fit inside it. It won't scroll and won't show the items that don't fit under the ELM_TOOLBAR_SHRINK_HIDE mode. Finally, it scrolls under the ELM_TOOLBAR_SHRINK_SCROLL mode, and it creates a button to aggregate items which didn't fit with the ELM_TOOLBAR_SHRINK_MENU mode.
This function's behavior clashes with that of elm_scroller_policy_set(), so use either one of them, but not both.
Parameters:
[in]objThe toolbar object handle
[in]shrink_modeThe toolbar's items display behavior

Gets the standard priority of visible items in a toolbar.

Since (EFL) :
1.7
Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The standard priority of items in the obj toolbar
See also:
elm_toolbar_standard_priority_set()
void elm_toolbar_standard_priority_set ( Evas_Object obj,
int  priority 
)

Sets the standard priority of visible items in a toolbar.

Since (EFL) :
1.7
Since :
2.3
Remarks:
If the priority of the item is upto the standard priority, it is shown in the basic panel. The other items are located in the more menu or panel. The more menu or panel can be shown when the more item is clicked.
Parameters:
[in]objThe toolbar object
[in]priorityThe standard priority of visible items
See also:
elm_toolbar_standard_priority_get()

Gets the transverse expansion of the toolbar obj.

Since :
2.3
Parameters:
[in]objThe toolbar object
Returns:
The transverse expansion of the item (EINA_TRUE = on, EINA_FALSE = off, default = EINA_FALSE)
See also:
elm_toolbar_transverse_expand_set()
void elm_toolbar_transverse_expanded_set ( Evas_Object obj,
Eina_Bool  transverse_expanded 
)

Sets the item's transverse expansion of a given toolbar widget obj.

This expands the transverse length of the item according to the transverse length of the toolbar. The default is what the transverse length of the item is set to according to its minimum value.

Since :
2.3
Parameters:
[in]objThe toolbar object
[in]transverse_expandedThe transverse expansion of the item (EINA_TRUE = on, EINA_FALSE = off, default = EINA_FALSE)

Except as noted, this content - excluding the Code Examples - is licensed under Creative Commons Attribution 3.0 and all of the Code Examples contained herein are licensed under BSD-3-Clause.
For details, see the Content License