2 * Get the widget object's handle which contains a given item
4 * @param it The Elementary object item
5 * @return The widget object
7 * @note This returns the widget object itself that an item belongs to.
8 * @note Every elm_object_item supports this API
11 EAPI Evas_Object *elm_object_item_widget_get(const Elm_Object_Item *it);
14 * Set a content of an object item
16 * @param it The Elementary object item
17 * @param part The content part name to set (NULL for the default content)
18 * @param content The new content of the object item
20 * @note Elementary object items may have many contents
24 EAPI void elm_object_item_part_content_set(Elm_Object_Item *it, const char *part, Evas_Object *content);
26 #define elm_object_item_content_set(it, content) elm_object_item_part_content_set((it), NULL, (content))
29 * Get a content of an object item
31 * @param it The Elementary object item
32 * @param part The content part name to unset (NULL for the default content)
33 * @return content of the object item or NULL for any error
35 * @note Elementary object items may have many contents
39 EAPI Evas_Object *elm_object_item_part_content_get(const Elm_Object_Item *it, const char *part);
41 #define elm_object_item_content_get(it) elm_object_item_part_content_get((it), NULL)
44 * Unset a content of an object item
46 * @param it The Elementary object item
47 * @param part The content part name to unset (NULL for the default content)
49 * @note Elementary object items may have many contents
53 EAPI Evas_Object *elm_object_item_part_content_unset(Elm_Object_Item *it, const char *part);
55 #define elm_object_item_content_unset(it) elm_object_item_part_content_unset((it), NULL)
58 * Set a label of an object item
60 * @param it The Elementary object item
61 * @param part The text part name to set (NULL for the default label)
62 * @param label The new text of the label
64 * @note Elementary object items may have many labels
68 EAPI void elm_object_item_part_text_set(Elm_Object_Item *it, const char *part, const char *label);
70 #define elm_object_item_text_set(it, label) elm_object_item_part_text_set((it), NULL, (label))
73 * Get a label of an object item
75 * @param it The Elementary object item
76 * @param part The text part name to get (NULL for the default label)
77 * @return text of the label or NULL for any error
79 * @note Elementary object items may have many labels
83 EAPI const char *elm_object_item_part_text_get(const Elm_Object_Item *it, const char *part);
85 #define elm_object_item_text_get(it) elm_object_item_part_text_get((it), NULL)
88 * Set the text to read out when in accessibility mode
90 * @param it The object item which is to be described
91 * @param txt The text that describes the widget to people with poor or no vision
95 EAPI void elm_object_item_access_info_set(Elm_Object_Item *it, const char *txt);
98 * Get the data associated with an object item
99 * @param it The Elementary object item
100 * @return The data associated with @p it
102 * @note Every elm_object_item supports this API
105 EAPI void *elm_object_item_data_get(const Elm_Object_Item *it);
108 * Set the data associated with an object item
109 * @param it The Elementary object item
110 * @param data The data to be associated with @p it
112 * @note Every elm_object_item supports this API
115 EAPI void elm_object_item_data_set(Elm_Object_Item *it, void *data);
118 * Send a signal to the edje object of the widget item.
120 * This function sends a signal to the edje object of the obj item. An
121 * edje program can respond to a signal by specifying matching
122 * 'signal' and 'source' fields.
124 * @param it The Elementary object item
125 * @param emission The signal's name.
126 * @param source The signal's source.
129 EAPI void elm_object_item_signal_emit(Elm_Object_Item *it, const char *emission, const char *source);
132 * Set the disabled state of an widget item.
134 * @param obj The Elementary object item
135 * @param disabled The state to put in in: @c EINA_TRUE for
136 * disabled, @c EINA_FALSE for enabled
138 * Elementary object item can be @b disabled, in which state they won't
139 * receive input and, in general, will be themed differently from
140 * their normal state, usually greyed out. Useful for contexts
141 * where you don't want your users to interact with some of the
142 * parts of you interface.
144 * This sets the state for the widget item, either disabling it or
149 EAPI void elm_object_item_disabled_set(Elm_Object_Item *it, Eina_Bool disabled);
152 * Get the disabled state of an widget item.
154 * @param obj The Elementary object
155 * @return @c EINA_TRUE, if the widget item is disabled, @c EINA_FALSE
156 * if it's enabled (or on errors)
158 * This gets the state of the widget, which might be enabled or disabled.
162 EAPI Eina_Bool elm_object_item_disabled_get(const Elm_Object_Item *it);
165 * @brief Set the function to be called when an item from the widget is
168 * @param it The item to set the callback on
169 * @param func The function called
171 * That function will receive these parameters:
172 * @li void * item data
173 * @li Evas_Object * widget object
174 * @li Elm_Object_Item * widget item
176 * @note Every elm_object_item supports this API
178 * @see elm_object_item_del()
181 EAPI void elm_object_item_del_cb_set(Elm_Object_Item *it, Evas_Smart_Cb del_cb);
184 * Delete the given item.
186 * @param it The item to be deleted.
190 EAPI void elm_object_item_del(Elm_Object_Item *it);
193 * Set the text to be shown in a given object item's tooltips.
195 * @param item Target item.
196 * @param text The text to set in the content.
198 * Setup the text as tooltip to object. The item can have only one tooltip,
199 * so any previous tooltip data - set with this function or
200 * elm_object_item_tooltip_content_cb_set() - is removed.
202 * @see elm_object_tooltip_text_set() for more details.
206 EAPI void elm_object_item_tooltip_text_set(Elm_Object_Item *item, const char *text);
209 * @brief Disable size restrictions on an object's tooltip
210 * @param item The tooltip's anchor object
211 * @param disable If EINA_TRUE, size restrictions are disabled
212 * @return EINA_FALSE on failure, EINA_TRUE on success
214 * This function allows a tooltip to expand beyond its parant window's canvas.
215 * It will instead be limited only by the size of the display.
217 EAPI Eina_Bool elm_object_item_tooltip_window_mode_set(Elm_Object_Item *item, Eina_Bool disable);
220 * @brief Retrieve size restriction state of an object's tooltip
221 * @param obj The tooltip's anchor object
222 * @return If EINA_TRUE, size restrictions are disabled
224 * This function returns whether a tooltip is allowed to expand beyond
225 * its parant window's canvas.
226 * It will instead be limited only by the size of the display.
228 EAPI Eina_Bool elm_object_item_tooltip_window_mode_get(const Elm_Object_Item *item);
231 * Set the content to be shown in the tooltip item.
233 * Setup the tooltip to item. The item can have only one tooltip,
234 * so any previous tooltip data is removed. @p func(with @p data) will
235 * be called every time that need show the tooltip and it should
236 * return a valid Evas_Object. This object is then managed fully by
237 * tooltip system and is deleted when the tooltip is gone.
239 * @param item the object item being attached a tooltip.
240 * @param func the function used to create the tooltip contents.
241 * @param data what to provide to @a func as callback data/context.
242 * @param del_cb called when data is not needed anymore, either when
243 * another callback replaces @a func, the tooltip is unset with
244 * elm_object_item_tooltip_unset() or the owner @a item
245 * dies. This callback receives as the first parameter the
246 * given @a data, and @c event_info is the item.
248 * @see elm_object_tooltip_content_cb_set() for more details.
252 EAPI void elm_object_item_tooltip_content_cb_set(Elm_Object_Item *item, Elm_Tooltip_Item_Content_Cb func, const void *data, Evas_Smart_Cb del_cb);
255 * Unset tooltip from item.
257 * @param item object item to remove previously set tooltip.
259 * Remove tooltip from item. The callback provided as del_cb to
260 * elm_object_item_tooltip_content_cb_set() will be called to notify
261 * it is not used anymore.
263 * @see elm_object_tooltip_unset() for more details.
264 * @see elm_object_item_tooltip_content_cb_set()
268 EAPI void elm_object_item_tooltip_unset(Elm_Object_Item *item);
271 * Sets a different style for this item tooltip.
273 * @note before you set a style you should define a tooltip with
274 * elm_object_item_tooltip_content_cb_set() or
275 * elm_object_item_tooltip_text_set()
277 * @param item object item with tooltip already set.
278 * @param style the theme style to use (default, transparent, ...)
280 * @see elm_object_tooltip_style_set() for more details.
284 EAPI void elm_object_item_tooltip_style_set(Elm_Object_Item *item, const char *style);
287 * Get the style for this item tooltip.
289 * @param item object item with tooltip already set.
290 * @return style the theme style in use, defaults to "default". If the
291 * object does not have a tooltip set, then NULL is returned.
293 * @see elm_object_tooltip_style_get() for more details.
294 * @see elm_object_item_tooltip_style_set()
298 EAPI const char *elm_object_item_tooltip_style_get(const Elm_Object_Item *item);
302 * Set the type of mouse pointer/cursor decoration to be shown,
303 * when the mouse pointer is over the given item
305 * @param ite, item to customize cursor on
306 * @param cursor the cursor type's name
308 * This function works analogously as elm_object_cursor_set(), but
309 * here the cursor's changing area is restricted to the item's
310 * area, and not the whole widget's. Note that that item cursors
311 * have precedence over widget cursors, so that a mouse over an
312 * item with custom cursor set will always show @b that cursor.
314 * If this function is called twice for an object, a previously set
315 * cursor will be unset on the second call.
317 * @see elm_object_cursor_set()
318 * @see elm_object_item_cursor_get()
319 * @see elm_object_item_cursor_unset()
323 EAPI void elm_object_item_cursor_set(Elm_Object_Item *item, const char *cursor);
326 * Get the type of mouse pointer/cursor decoration set to be shown,
327 * when the mouse pointer is over the given item
329 * @param item item with custom cursor set
330 * @return the cursor type's name or @c NULL, if no custom cursors
331 * were set to @p item (and on errors)
333 * @see elm_object_cursor_get()
334 * @see elm_object_item_cursor_set()
335 * @see elm_object_item_cursor_unset()
339 EAPI const char *elm_object_item_cursor_get(const Elm_Object_Item *item);
342 * Unset any custom mouse pointer/cursor decoration set to be
343 * shown, when the mouse pointer is over the given
344 * item, thus making it show the @b default cursor again.
346 * @param item the item
348 * Use this call to undo any custom settings on this item's cursor
349 * decoration, bringing it back to defaults (no custom style set).
351 * @see elm_object_cursor_unset()
352 * @see elm_object_item_cursor_set()
356 EAPI void elm_object_item_cursor_unset(Elm_Object_Item *item);
359 * Set a different @b style for a given custom cursor set for an
362 * @param item item with custom cursor set
363 * @param style the <b>theme style</b> to use (e.g. @c "default",
364 * @c "transparent", etc)
366 * This function only makes sense when one is using custom mouse
367 * cursor decorations <b>defined in a theme file</b>, which can have,
368 * given a cursor name/type, <b>alternate styles</b> on it. It
369 * works analogously as elm_object_cursor_style_set(), but here
370 * applyed only to item objects.
372 * @warning Before you set a cursor style you should have definen a
373 * custom cursor previously on the item, with
374 * elm_object_item_cursor_set()
376 * @see elm_object_item_cursor_engine_only_set()
377 * @see elm_object_item_cursor_style_get()
381 EAPI void elm_object_item_cursor_style_set(Elm_Object_Item *item, const char *style);
384 * Get the current @b style set for a given item's custom
387 * @param item item with custom cursor set.
388 * @return style the cursor style in use. If the object does not
389 * have a cursor set, then @c NULL is returned.
391 * @see elm_object_item_cursor_style_set() for more details
395 EAPI const char *elm_object_item_cursor_style_get(const Elm_Object_Item *item);
398 * Set if the (custom)cursor for a given item should be
399 * searched in its theme, also, or should only rely on the
402 * @param item item with custom (custom) cursor already set on
403 * @param engine_only Use @c EINA_TRUE to have cursors looked for
404 * only on those provided by the rendering engine, @c EINA_FALSE to
405 * have them searched on the widget's theme, as well.
407 * @note This call is of use only if you've set a custom cursor
408 * for items, with elm_object_item_cursor_set().
410 * @note By default, cursors will only be looked for between those
411 * provided by the rendering engine.
415 EAPI void elm_object_item_cursor_engine_only_set(Elm_Object_Item *item, Eina_Bool engine_only);
418 * Get if the (custom) cursor for a given item is being
419 * searched in its theme, also, or is only relying on the rendering
422 * @param item an item
423 * @return @c EINA_TRUE, if cursors are being looked for only on
424 * those provided by the rendering engine, @c EINA_FALSE if they
425 * are being searched on the widget's theme, as well.
427 * @see elm_object_item_cursor_engine_only_set(), for more details
431 EAPI Eina_Bool elm_object_item_cursor_engine_only_get(const Elm_Object_Item *item);