/**
* @defgroup Index Index
+ * @ingroup Elementary
*
* @image html img/widget/index/preview-00.png
* @image latex img/widget/index/preview-00.eps
* @addtogroup Index
* @{
*/
-
/**
* Add a new index widget to the given parent Elementary
* (container) object
*
* @ingroup Index
*/
-EAPI Evas_Object *
- elm_index_add(Evas_Object *parent)
-EINA_ARG_NONNULL(1);
+EAPI Evas_Object *elm_index_add(Evas_Object *parent);
/**
- * Set whether a given index widget is or not visible,
- * programatically.
+ * Enable or disable auto hiding feature for a given index widget.
*
* @param obj The index object
- * @param active @c EINA_TRUE to show it, @c EINA_FALSE to hide it
- *
- * Not to be confused with visible as in @c evas_object_show() --
- * visible with regard to the widget's auto hiding feature.
+ * @param disabled @c EINA_TRUE to disable auto hiding, @c EINA_FALSE to enable
*
- * @see elm_index_active_get()
+ * @see elm_index_autohide_disabled_get()
*
* @ingroup Index
*/
-EAPI void elm_index_active_set(Evas_Object *obj, Eina_Bool active) EINA_ARG_NONNULL(1);
+EAPI void elm_index_autohide_disabled_set(Evas_Object *obj, Eina_Bool disabled);
/**
- * Get whether a given index widget is currently visible or not.
+ * Get whether auto hiding feature is enabled or not for a given index widget.
*
* @param obj The index object
- * @return @c EINA_TRUE, if it's shown, @c EINA_FALSE otherwise
+ * @return @c EINA_TRUE, if auto hiding is disabled, @c EINA_FALSE otherwise
*
- * @see elm_index_active_set() for more details
+ * @see elm_index_autohide_disabled_set() for more details
*
* @ingroup Index
*/
-EAPI Eina_Bool elm_index_active_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
+EAPI Eina_Bool elm_index_autohide_disabled_get(const Evas_Object *obj);
/**
* Set the items level for a given index widget.
*
* @ingroup Index
*/
-EAPI void elm_index_item_level_set(Evas_Object *obj, int level) EINA_ARG_NONNULL(1);
+EAPI void elm_index_item_level_set(Evas_Object *obj, int level);
/**
* Get the items level set for a given index widget.
*
* @ingroup Index
*/
-EAPI int elm_index_item_level_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
+EAPI int elm_index_item_level_get(const Evas_Object *obj);
+
+/**
+ * Set the selected state of an item.
+ *
+ * @param it The index item
+ * @param selected The selected state
+ *
+ * This sets the selected state of the given item @p it.
+ * @c EINA_TRUE for selected, @c EINA_FALSE for not selected.
+ *
+ * If a new item is selected the previously selected will be unselected.
+ * Previously selected item can be get with function
+ * elm_index_selected_item_get().
+ *
+ * Selected items will be highlighted.
+ *
+ * @see elm_index_selected_item_get()
+ *
+ * @ingroup Index
+ */
+EAPI void elm_index_item_selected_set(Elm_Object_Item *it, Eina_Bool selected);
/**
* Returns the last selected item, for a given index widget.
*
* @param obj The index object.
+ * @param level @c 0 or @c 1, the currently implemented levels.
* @return The last item @b selected on @p obj (or @c NULL, on errors).
*
* @ingroup Index
*/
-EAPI Elm_Object_Item *elm_index_item_selected_get(const Evas_Object *obj, int level) EINA_ARG_NONNULL(1);
+EAPI Elm_Object_Item *elm_index_selected_item_get(const Evas_Object *obj, int level);
/**
* Append a new item on a given index widget.
*
* @param obj The index object.
* @param letter Letter under which the item should be indexed
- * @param item The item data to set for the index's item
+ * @param func The function to call when the item is selected.
+ * @param data The item data to set for the index's item
+ * @return A handle to the item added or @c NULL, on errors
*
* Despite the most common usage of the @p letter argument is for
* single char strings, one could use arbitrary strings as index
*
* @ingroup Index
*/
-EAPI void elm_index_item_append(Evas_Object *obj, const char *letter, const void *item) EINA_ARG_NONNULL(1);
+EAPI Elm_Object_Item *elm_index_item_append(Evas_Object *obj, const char *letter, Evas_Smart_Cb func, const void *data);
/**
* Prepend a new item on a given index widget.
*
* @param obj The index object.
* @param letter Letter under which the item should be indexed
- * @param item The item data to set for the index's item
+ * @param func The function to call when the item is selected.
+ * @param data The item data to set for the index's item
+ * @return A handle to the item added or @c NULL, on errors
*
* Despite the most common usage of the @p letter argument is for
* single char strings, one could use arbitrary strings as index
*
* @ingroup Index
*/
-EAPI void elm_index_item_prepend(Evas_Object *obj, const char *letter, const void *item) EINA_ARG_NONNULL(1);
+EAPI Elm_Object_Item *elm_index_item_prepend(Evas_Object *obj, const char *letter, Evas_Smart_Cb func, const void *data);
/**
- * Append a new item, on a given index widget, <b>after the item
- * having @p relative as data</b>.
+ * Insert a new item into the index object after item @p after.
*
* @param obj The index object.
+ * @param after The index item to insert after.
* @param letter Letter under which the item should be indexed
- * @param item The item data to set for the index's item
- * @param relative The index item to be the predecessor of this new one
+ * @param func The function to call when the item is clicked.
+ * @param data The item data to set for the index's item
+ * @return A handle to the item added or @c NULL, on errors
*
* Despite the most common usage of the @p letter argument is for
* single char strings, one could use arbitrary strings as index
*
* @ingroup Index
*/
-EAPI void elm_index_item_append_relative(Evas_Object *obj, const char *letter, const void *item, const Elm_Object_Item *relative) EINA_ARG_NONNULL(1);
+EAPI Elm_Object_Item *elm_index_item_insert_after(Evas_Object *obj, Elm_Object_Item *after, const char *letter, Evas_Smart_Cb func, const void *data);
/**
- * Prepend a new item, on a given index widget, <b>after the item
- * having @p relative as data</b>.
+ * Insert a new item into the index object before item @p before.
*
* @param obj The index object.
+ * @param before The index item to insert after.
* @param letter Letter under which the item should be indexed
- * @param item The item data to set for the index's item
- * @param relative The index item to be the successor of this new one
+ * @param func The function to call when the item is clicked.
+ * @param data The item data to set for the index's item
+ * @return A handle to the item added or @c NULL, on errors
*
* Despite the most common usage of the @p letter argument is for
* single char strings, one could use arbitrary strings as index
*
* @ingroup Index
*/
-EAPI void elm_index_item_prepend_relative(Evas_Object *obj, const char *letter, const void *item, const Elm_Object_Item *relative) EINA_ARG_NONNULL(1);
+EAPI Elm_Object_Item *elm_index_item_insert_before(Evas_Object *obj, Elm_Object_Item *before, const char *letter, Evas_Smart_Cb func, const void *data);
/**
* Insert a new item into the given index widget, using @p cmp_func
*
* @param obj The index object.
* @param letter Letter under which the item should be indexed
- * @param item The item data to set for the index's item
+ * @param func The function to call when the item is clicked.
+ * @param data The item data to set for the index's item
* @param cmp_func The comparing function to be used to sort index
* items <b>by #index item handles</b>
* @param cmp_data_func A @b fallback function to be called for the
* because all references to it will be lost. If this function is
* not provided (@c NULL is given), index items will be @b
* duplicated, if @p cmp_func returns @c 0.
+ * @return A handle to the item added or @c NULL, on errors
*
* Despite the most common usage of the @p letter argument is for
* single char strings, one could use arbitrary strings as index
*
* @ingroup Index
*/
-EAPI void elm_index_item_sorted_insert(Evas_Object *obj, const char *letter, const void *item, Eina_Compare_Cb cmp_func, Eina_Compare_Cb cmp_data_func) EINA_ARG_NONNULL(1);
-
-/**
- * Remove an item from a given index widget, <b>to be referenced by
- * it's data value</b>.
- *
- * @param obj The index object
- * @param item The item to be removed from @p obj
- *
- * If a deletion callback is set, via elm_index_item_del_cb_set(),
- * that callback function will be called by this one.
- *
- * @ingroup Index
- */
-EAPI void elm_index_item_del(Evas_Object *obj, Elm_Object_Item *item) EINA_ARG_NONNULL(1);
+EAPI Elm_Object_Item *elm_index_item_sorted_insert(Evas_Object *obj, const char *letter, Evas_Smart_Cb func, const void *data, Eina_Compare_Cb cmp_func, Eina_Compare_Cb cmp_data_func);
/**
* Find a given index widget's item, <b>using item data</b>.
*
* @param obj The index object
- * @param item The item data pointed to by the desired index item
+ * @param data The item data pointed to by the desired index item
* @return The index item handle, if found, or @c NULL otherwise
*
* @ingroup Index
*/
-EAPI Elm_Object_Item *elm_index_item_find(Evas_Object *obj, const void *item) EINA_ARG_NONNULL(1);
+EAPI Elm_Object_Item *elm_index_item_find(Evas_Object *obj, const void *data);
/**
* Removes @b all items from a given index widget.
*
* @param obj The index object.
*
- * If deletion callbacks are set, via elm_index_item_del_cb_set(),
+ * If deletion callbacks are set, via elm_object_item_del_cb_set(),
* that callback function will be called for each item in @p obj.
*
* @ingroup Index
*/
-EAPI void elm_index_item_clear(Evas_Object *obj) EINA_ARG_NONNULL(1);
+EAPI void elm_index_item_clear(Evas_Object *obj);
/**
* Go to a given items level on a index widget
*
* @ingroup Index
*/
-EAPI void elm_index_item_go(Evas_Object *obj, int level) EINA_ARG_NONNULL(1);
+EAPI void elm_index_level_go(Evas_Object *obj, int level);
/**
- * Return the data associated with a given index widget item
- *
- * @param it The index widget item handle
- * @return The data associated with @p it
- * @deprecated Use elm_object_item_data_get() instead
+ * Get the letter (string) set on a given index widget item.
*
- * @see elm_index_item_data_set()
+ * @param item The index item handle
+ * @return The letter string set on @p it
*
* @ingroup Index
*/
-EINA_DEPRECATED EAPI void *elm_index_item_data_get(const Elm_Object_Item *item) EINA_ARG_NONNULL(1);
+EAPI const char *elm_index_item_letter_get(const Elm_Object_Item *item);
/**
- * Set the data associated with a given index widget item
+ * Set the indicator as to be disabled.
*
- * @param it The index widget item handle
- * @param data The new data pointer to set to @p it
+ * @param obj The index object
+ * @param disabled @c EINA_TRUE to disable it, @c EINA_FALSE to enable it
*
- * This sets new item data on @p it.
+ * In Index widget, Indicator notes popup text, which shows a letter has been selecting.
*
- * @warning The old data pointer won't be touched by this function, so
- * the user had better to free that old data himself/herself.
+ * @see elm_index_indicator_disabled_get()
*
- * @deprecated Use elm_object_item_data_set() instead
* @ingroup Index
*/
-EINA_DEPRECATED EAPI void elm_index_item_data_set(Elm_Object_Item *it, const void *data) EINA_ARG_NONNULL(1);
+EAPI void elm_index_indicator_disabled_set(Evas_Object *obj, Eina_Bool disabled);
/**
- * Set the function to be called when a given index widget item is freed.
+ * Get the value of indicator's disabled status.
*
- * @param it The item to set the callback on
- * @param func The function to call on the item's deletion
+ * @param obj The index object
+ * @return EINA_TRUE if the indicator is disabled.
*
- * When called, @p func will have both @c data and @c event_info
- * arguments with the @p it item's data value and, naturally, the
- * @c obj argument with a handle to the parent index widget.
+ * @see elm_index_indicator_disabled_set()
*
* @ingroup Index
*/
-EAPI void elm_index_item_del_cb_set(Elm_Object_Item *it, Evas_Smart_Cb func) EINA_ARG_NONNULL(1);
+EAPI Eina_Bool elm_index_indicator_disabled_get(const Evas_Object *obj);
/**
- * Get the letter (string) set on a given index widget item.
+ * Enable or disable horizontal mode on the index object
*
- * @param it The index item handle
- * @return The letter string set on @p it
+ * @param obj The index object.
+ * @param horizontal @c EINA_TRUE to enable horizontal or @c EINA_FALSE to
+ * disable it, i.e., to enable vertical mode. it's an area one @ref Fingers
+ * "finger" wide on the bottom side of the index widget's container.
+ *
+ * @note Vertical mode is set by default.
+ *
+ * On horizontal mode items are displayed on index from left to right,
+ * instead of from top to bottom. Also, the index will scroll horizontally.
+ *
+ * @see elm_index_horizontal_get()
+ *
+ * @ingroup Index
+ */
+EAPI void elm_index_horizontal_set(Evas_Object *obj, Eina_Bool horizontal);
+
+/**
+ * Get a value whether horizontal mode is enabled or not.
+ *
+ * @param obj The index object.
+ * @return @c EINA_TRUE means horizontal mode selection is enabled.
+ * @c EINA_FALSE indicates it's disabled. If @p obj is @c NULL,
+ * @c EINA_FALSE is returned.
+ *
+ * @see elm_index_horizontal_set() for details.
*
* @ingroup Index
*/
-EAPI const char *elm_index_item_letter_get(const Elm_Object_Item *item) EINA_ARG_NONNULL(1);
+EAPI Eina_Bool elm_index_horizontal_get(const Evas_Object *obj);
/**
* @}