- Elementary
- Main
- Authors
- Examples
- Files
- Pages
- Types
- Modules

Macros | Enumerations | Enumerator | Functions
Icon

## Macros
#define | elm_obj_icon_thumb_set(file, group) ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_THUMB_SET), EO_TYPECHECK(const char *, file), EO_TYPECHECK(const char *, group)
#define | elm_obj_icon_standard_set(name, ret) ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_STANDARD_SET), EO_TYPECHECK(const char *, name), EO_TYPECHECK(Eina_Bool *, ret)
#define | elm_obj_icon_standard_get(ret) ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_STANDARD_GET), EO_TYPECHECK(const char **, ret)
#define | elm_obj_icon_order_lookup_set(order) ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_ORDER_LOOKUP_SET), EO_TYPECHECK(Elm_Icon_Lookup_Order, order)
#define | elm_obj_icon_order_lookup_get(ret) ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_ORDER_LOOKUP_GET), EO_TYPECHECK(Elm_Icon_Lookup_Order *, ret)

## Enumerations
enum | Elm_Icon_Lookup_Order { ELM_ICON_LOOKUP_FDO_THEME, ELM_ICON_LOOKUP_THEME_FDO, ELM_ICON_LOOKUP_FDO, ELM_ICON_LOOKUP_THEME }
| Lookup order used by elm_icon_standard_set(). More...

## Functions
EINA_DEPRECATED Eina_Bool | elm_icon_file_set (Evas_Object *obj, const char *file, const char *group)
| Set the file that will be used as icon. More...
EINA_DEPRECATED Eina_Bool | elm_icon_memfile_set (Evas_Object *obj, const void *img, size_t size, const char *format, const char *key)
| Set a location in memory to be used as an icon. More...
EINA_DEPRECATED void | elm_icon_file_get (const Evas_Object *obj, const char **file, const char **group)
| Get the file that will be used as icon. More...
EINA_DEPRECATED void | elm_icon_smooth_set (Evas_Object *obj, Eina_Bool smooth)
| Set the smooth scaling for an icon object. More...
EINA_DEPRECATED Eina_Bool | elm_icon_smooth_get (const Evas_Object *obj)
| Get whether smooth scaling is enabled for an icon object. More...
EINA_DEPRECATED void | elm_icon_no_scale_set (Evas_Object *obj, Eina_Bool no_scale)
| Disable scaling of this object. More...
EINA_DEPRECATED Eina_Bool | elm_icon_no_scale_get (const Evas_Object *obj)
| Get whether scaling is disabled on the object. More...
EINA_DEPRECATED void | elm_icon_resizable_set (Evas_Object *obj, Eina_Bool size_up, Eina_Bool size_down)
| Set if the object is (up/down) resizable. More...
EINA_DEPRECATED void | elm_icon_resizable_get (const Evas_Object *obj, Eina_Bool *size_up, Eina_Bool *size_down)
| Get if the object is (up/down) resizable. More...
EINA_DEPRECATED void | elm_icon_size_get (const Evas_Object *obj, int *w, int *h)
| Get the object's image size. More...
EINA_DEPRECATED void | elm_icon_fill_outside_set (Evas_Object *obj, Eina_Bool fill_outside)
| Set if the icon fill the entire object area. More...
EINA_DEPRECATED Eina_Bool | elm_icon_fill_outside_get (const Evas_Object *obj)
| Get if the object is filled outside. More...
EINA_DEPRECATED void | elm_icon_prescale_set (Evas_Object *obj, int size)
| Set the prescale size for the icon. More...
EINA_DEPRECATED int | elm_icon_prescale_get (const Evas_Object *obj)
| Get the prescale size for the icon. More...
EINA_DEPRECATED Evas_Object * | elm_icon_object_get (Evas_Object *obj)
| Get the image object of the icon. More...
EINA_DEPRECATED void | elm_icon_preload_disabled_set (Evas_Object *obj, Eina_Bool disabled)
| Enable or disable preloading of the icon. More...
EINA_DEPRECATED Eina_Bool | elm_icon_animated_available_get (const Evas_Object *obj)
| Get if the icon supports animation or not. More...
EINA_DEPRECATED void | elm_icon_animated_set (Evas_Object *obj, Eina_Bool animated)
| Set animation mode of the icon. More...
EINA_DEPRECATED Eina_Bool | elm_icon_animated_get (const Evas_Object *obj)
| Get animation mode of the icon. More...
EINA_DEPRECATED void | elm_icon_animated_play_set (Evas_Object *obj, Eina_Bool play)
| Set animation play mode of the icon. More...
EINA_DEPRECATED Eina_Bool | elm_icon_animated_play_get (const Evas_Object *obj)
| Get animation play mode of the icon. More...
EINA_DEPRECATED void | elm_icon_aspect_fixed_set (Evas_Object *obj, Eina_Bool fixed)
| Set whether the original aspect ratio of the icon should be kept on resize. More...
EINA_DEPRECATED Eina_Bool | elm_icon_aspect_fixed_get (const Evas_Object *obj)
| Get if the object retains the original aspect ratio. More...
Evas_Object * | elm_icon_add (Evas_Object *parent)
| Add a new icon object to the parent. More...
void | elm_icon_thumb_set (Evas_Object *obj, const char *file, const char *group)
| Set the file that will be used, but use a generated thumbnail. More...
Eina_Bool | elm_icon_standard_set (Evas_Object *obj, const char *name)
| Set the icon by icon standards names. More...
const char * | elm_icon_standard_get (const Evas_Object *obj)
| Get the icon name set by icon standard names. More...
void | elm_icon_order_lookup_set (Evas_Object *obj, Elm_Icon_Lookup_Order order)
| Sets the icon lookup order used by elm_icon_standard_set(). More...
Elm_Icon_Lookup_Order | elm_icon_order_lookup_get (const Evas_Object *obj)
| Get the icon lookup order. More...

## Detailed Description

An icon object is used to display standard icon images ("delete", "edit", "arrows", etc.) or images coming from a custom file (PNG, JPG, EDJE, etc.), on icon contexts.

The icon image requested can be in the Elementary theme in use, or in the `freedesktop.org` theme paths. It's possible to set the order of preference from where an image will be fetched.

This widget inherits from the Image one, so that all the functions acting on it also work for icon objects.

You should be using an icon, instead of an image, whenever one of the following apply:

- you need a thumbnail version of an original image
- you need freedesktop.org provided icon images
- you need theme provided icon images (Edje groups)

Various calls on the icon's API are marked as deprecated, as they just wrap the image counterpart functions. Use the ones we point you to, for each case of deprecation here, instead – eventually the deprecated ones will be discarded (next major release).

Default images provided by Elementary's default theme are described below.

These are names for icons that were first intended to be used in toolbars, but can be used in many other places too:

- `"home"`
- `"close"`
- `"apps"`
- `"arrow_up"`
- `"arrow_down"`
- `"arrow_left"`
- `"arrow_right"`
- `"chat"`
- `"clock"`
- `"delete"`
- `"edit"`
- `"refresh"`
- `"folder"`
- `"file"`

These are names for icons that were designed to be used in menus (but again, you can use them anywhere else):

- `"menu/home"`
- `"menu/close"`
- `"menu/apps"`
- `"menu/arrow_up"`
- `"menu/arrow_down"`
- `"menu/arrow_left"`
- `"menu/arrow_right"`
- `"menu/chat"`
- `"menu/clock"`
- `"menu/delete"`
- `"menu/edit"`
- `"menu/refresh"`
- `"menu/folder"`
- `"menu/file"`

And these are names for some media player specific icons:

- `"media_player/forward"`
- `"media_player/info"`
- `"media_player/next"`
- `"media_player/pause"`
- `"media_player/play"`
- `"media_player/prev"`
- `"media_player/rewind"`
- `"media_player/stop"`

This widget emits the following signals, besides the ones sent from Image:

- `"thumb,done"` - elm_icon_thumb_set() has completed with success (since 1.7)
- `"thumb,error"` - elm_icon_thumb_set() has failed (since 1.7)

Elementary icon objects support the following API calls:

- elm_object_signal_emit()
- elm_object_signal_callback_add()
- elm_object_signal_callback_del() for emmiting and listening to signals on the object, when the internal image comes from an Edje object. This behavior was added unintentionally, though, and is deprecated. Expect it to be dropped on future releases.

An example of usage for this API follows:

- Icon example

## Macro Definition Documentation

#define elm_obj_icon_order_lookup_get | ( |  | ret | ) | ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_ORDER_LOOKUP_GET), EO_TYPECHECK(Elm_Icon_Lookup_Order *, ret)

Since
  1.8

Get the icon lookup order.

Parameters

  [out] | ret |

See Also
  elm_icon_order_lookup_get

Referenced by elm_icon_order_lookup_get().

#define elm_obj_icon_order_lookup_set | ( |  | order | ) | ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_ORDER_LOOKUP_SET), EO_TYPECHECK(Elm_Icon_Lookup_Order, order)

Since
  1.8

Sets the icon lookup order used by elm_icon_standard_set().

Parameters

  [in] | order |

See Also
  elm_icon_order_lookup_set

Referenced by elm_icon_order_lookup_set().

#define elm_obj_icon_standard_get | ( |  | ret | ) | ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_STANDARD_GET), EO_TYPECHECK(const char **, ret)

Since
  1.8

Get the icon name set by icon standard names.

Parameters

  [out] | ret |

See Also
  elm_icon_standard_get

Referenced by elm_icon_standard_get().

#define elm_obj_icon_standard_set | ( |  | name,
|  |  | ret
| ) |  | ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_STANDARD_SET), EO_TYPECHECK(const char *, name), EO_TYPECHECK(Eina_Bool *, ret)

Since
  1.8

Set the icon by icon standards names.

Parameters

  [in] | name |
  [out] | ret |

See Also
  elm_icon_standard_set

Referenced by elm_icon_standard_set().

#define elm_obj_icon_thumb_set | ( |  | file,
|  |  | group
| ) |  | ELM_OBJ_ICON_ID(ELM_OBJ_ICON_SUB_ID_THUMB_SET), EO_TYPECHECK(const char *, file), EO_TYPECHECK(const char *, group)

Since
  1.8

Set the file that will be used, but use a generated thumbnail.

Parameters

  [in] | file |
  [in] | group |

See Also
  elm_icon_thumb_set

Referenced by elm_icon_thumb_set().

## Enumeration Type Documentation

enum Elm_Icon_Lookup_Order

Lookup order used by elm_icon_standard_set().

Should look for icons in the theme, FDO paths, or both?

Enumerator
ELM_ICON_LOOKUP_FDO_THEME | icon look up order: freedesktop, theme
ELM_ICON_LOOKUP_THEME_FDO | icon look up order: theme, freedesktop
ELM_ICON_LOOKUP_FDO | icon look up order: freedesktop
ELM_ICON_LOOKUP_THEME | icon look up order: theme

## Function Documentation

Evas_Object* elm_icon_add | ( | Evas_Object * | parent | ) |

Add a new icon object to the parent.

Parameters

  parent | The parent object

Returns
  The new object or NULL if it cannot be created

See Also
  elm_image_file_set()

Referenced by elm_toolbar_item_icon_file_set(), elm_toolbar_item_icon_memfile_set(), elm_toolbar_item_icon_set(), and elm_toolbar_item_state_add().

EINA_DEPRECATED Eina_Bool elm_icon_animated_available_get | ( | const Evas_Object * | obj | ) |

Get if the icon supports animation or not.

Parameters

  obj | The icon object

Returns
  `EINA_TRUE` if the icon supports animation, `EINA_FALSE` otherwise.

Return if this elm icon's image can be animated. Currently Evas only supports gif animation. If the return value is EINA_FALSE, other elm_icon_animated_xxx APIs won't work.

Deprecated:
  Use elm_image_animated_available_get() instead.

References elm_image_animated_available_get().

EINA_DEPRECATED Eina_Bool elm_icon_animated_get | ( | const Evas_Object * | obj | ) |

Get animation mode of the icon.

Parameters

  obj | The icon object

Returns
  The animation mode of the icon object

See Also
  elm_icon_animated_set

Deprecated:
  Use elm_image_animated_get() instead.

References elm_image_animated_get().

EINA_DEPRECATED Eina_Bool elm_icon_animated_play_get | ( | const Evas_Object * | obj | ) |

Get animation play mode of the icon.

Parameters

  obj | The icon object

Returns
  The play mode of the icon object

See Also
  elm_icon_animated_play_get

Deprecated:
  Use elm_image_animated_play_get() instead.

References elm_image_animated_play_get().

EINA_DEPRECATED void elm_icon_animated_play_set | ( | Evas_Object * | obj,
|  | Eina_Bool | play
| ) |  |

Set animation play mode of the icon.

Parameters

  obj | The icon object
  play | `EINA_TRUE` the object play animation images, `EINA_FALSE` otherwise. Default is `EINA_FALSE`.

To play elm icon's animation, set play to EINA_TRUE. For example, you make gif player using this set/get API and click event. This literally lets you control current play or paused state. To have this work with animated GIF files for example, you first, before setting the file have to use elm_icon_animated_set() to enable animation at all on the icon.

1. Click event occurs
2. Check play flag using elm_icon_animated_play_get
3. If elm icon was playing, set play to EINA_FALSE. Then animation will be stopped and vice versa

Deprecated:
  Use elm_image_animated_play_set() instead.

References elm_image_animated_play_set().

EINA_DEPRECATED void elm_icon_animated_set | ( | Evas_Object * | obj,
|  | Eina_Bool | animated
| ) |  |

Set animation mode of the icon.

Parameters

  obj | The icon object
  animated | `EINA_TRUE` if the object do animation job, `EINA_FALSE` otherwise. Default is `EINA_FALSE`.

Since the default animation mode is set to EINA_FALSE, the icon is shown without animation. Files like animated GIF files can animate, and this is supported if you enable animated support on the icon. Set it to EINA_TRUE when the icon needs to be animated.

Deprecated:
  Use elm_image_animated_set() instead.

References elm_image_animated_set().

EINA_DEPRECATED Eina_Bool elm_icon_aspect_fixed_get | ( | const Evas_Object * | obj | ) |

Get if the object retains the original aspect ratio.

Parameters

  obj | The icon object.

Returns
  `EINA_TRUE` if the object keeps the original aspect, `EINA_FALSE` otherwise.

Deprecated:
  Use elm_image_aspect_fixed_get() instead.

References elm_image_aspect_fixed_get().

EINA_DEPRECATED void elm_icon_aspect_fixed_set | ( | Evas_Object * | obj,
|  | Eina_Bool | fixed
| ) |  |

Set whether the original aspect ratio of the icon should be kept on resize.

Parameters

  obj | The icon object.
  fixed | `EINA_TRUE` if the icon should retain the aspect, `EINA_FALSE` otherwise.

The original aspect ratio (width / height) of the icon is usually distorted to match the object's size. Enabling this option will retain this original aspect, and the way that the icon is fit into the object's area depends on the option set by elm_icon_fill_outside_set().

See Also
  elm_icon_aspect_fixed_get()
  elm_icon_fill_outside_set()

Deprecated:
  Use elm_image_aspect_fixed_set() instead.

References elm_image_aspect_fixed_set().

EINA_DEPRECATED void elm_icon_file_get | ( | const Evas_Object * | obj,
|  | const char ** | file,
|  | const char ** | group
| ) |  |

Get the file that will be used as icon.

Parameters

  obj | The icon object
  file | The path to file that will be used as the icon image
  group | The group that the icon belongs to, in edje file

See Also
  elm_image_file_set()

Deprecated:
  Use elm_image_file_get() instead.

References elm_image_file_get().

EINA_DEPRECATED Eina_Bool elm_icon_file_set | ( | Evas_Object * | obj,
|  | const char * | file,
|  | const char * | group
| ) |  |

Set the file that will be used as icon.

Parameters

  obj | The icon object
  file | The path to file that will be used as icon image
  group | The group that the icon belongs to an edje file

Returns
  (`EINA_TRUE` = success, `EINA_FALSE` = error)

Note
  The icon image set by this function can be changed by elm_icon_standard_set().

See Also
  elm_icon_file_get()

Deprecated:
  Use elm_image_file_set() instead.

References elm_obj_image_file_set.

EINA_DEPRECATED Eina_Bool elm_icon_fill_outside_get | ( | const Evas_Object * | obj | ) |

Get if the object is filled outside.

Parameters

  obj | The icon object

Returns
  `EINA_TRUE` if the object is filled outside, `EINA_FALSE` otherwise.

See Also
  elm_icon_fill_outside_set()

Deprecated:
  Use elm_image_fill_outside_get() instead.

References elm_image_fill_outside_get().

EINA_DEPRECATED void elm_icon_fill_outside_set | ( | Evas_Object * | obj,
|  | Eina_Bool | fill_outside
| ) |  |

Set if the icon fill the entire object area.

Parameters

  obj | The icon object
  fill_outside | `EINA_TRUE` if the object is filled outside, `EINA_FALSE` otherwise. Default is `EINA_FALSE`.

When the icon object is resized to a different aspect ratio from the original icon image, the icon image will still keep its aspect. This flag tells how the image should fill the object's area. They are: keep the entire icon inside the limits of height and width of the object (`fill_outside` is `EINA_FALSE`) or let the extra width or height go outside of the object, and the icon will fill the entire object (`fill_outside` is `EINA_TRUE`).

Note
  Unlike Image, there's no option in icon to set the aspect ratio retain property to false. Thus, the icon image will always keep its original aspect ratio.

See Also
  elm_icon_fill_outside_get()

Deprecated:
  Use elm_image_fill_outside_set() instead.

References elm_image_fill_outside_set().

EINA_DEPRECATED Eina_Bool elm_icon_memfile_set | ( | Evas_Object * | obj,
|  | const void * | img,
|  | size_t | size,
|  | const char * | format,
|  | const char * | key
| ) |  |

Set a location in memory to be used as an icon.

Parameters

  obj | The icon object
  img | The binary data that will be used as an image
  size | The size of binary data `img`
  format | Optional format of `img` to pass to the image loader
  key | Optional key of `img` to pass to the image loader (eg. if `img` is an edje file)

The `format` string should be something like "png", "jpg", "tga", "tiff", "bmp" etc. if it is provided (NULL if not). This improves the loader performance as it tries the "correct" loader first before trying a range of other possible loaders until one succeeds.

Returns
  (`EINA_TRUE` = success, `EINA_FALSE` = error)

Note
  The icon image set by this function can be changed by elm_icon_standard_set().

Deprecated:
  Use elm_image_memfile_set() instead.

References elm_obj_image_memfile_set.

EINA_DEPRECATED Eina_Bool elm_icon_no_scale_get | ( | const Evas_Object * | obj | ) |

Get whether scaling is disabled on the object.

Parameters

  obj | The icon object

Returns
  `EINA_TRUE` if scaling is disabled, `EINA_FALSE` otherwise

See Also
  elm_icon_no_scale_set()

Deprecated:
  Use elm_image_no_scale_get() instead.

References elm_image_no_scale_get().

EINA_DEPRECATED void elm_icon_no_scale_set | ( | Evas_Object * | obj,
|  | Eina_Bool | no_scale
| ) |  |

Disable scaling of this object.

Parameters

  obj | The icon object.
  no_scale | `EINA_TRUE` if the object is not scalable, `EINA_FALSE` otherwise. Default is `EINA_FALSE`.

This function disables scaling of the icon object through the function elm_object_scale_set(). However, this does not affect the object size/resize in any way. For that effect, take a look at elm_icon_resizable_set().

See Also
  elm_icon_no_scale_get()
  elm_icon_resizable_set()
  elm_object_scale_set()

Deprecated:
  Use elm_image_no_scale_set() instead.

References elm_image_no_scale_set().

EINA_DEPRECATED Evas_Object* elm_icon_object_get | ( | Evas_Object * | obj | ) |

Get the image object of the icon.

DO NOT MODIFY THIS.

Parameters

  obj | The icon object

Returns
  The internal icon object

Deprecated:
  Use elm_image_object_get() instead.

References elm_image_object_get().

Elm_Icon_Lookup_Order elm_icon_order_lookup_get | ( | const Evas_Object * | obj | ) |

Get the icon lookup order.

Parameters

  obj | The icon object

Returns
  The icon lookup order

See Also
  elm_icon_order_lookup_set()
  Elm_Icon_Lookup_Order

References ELM_ICON_LOOKUP_THEME_FDO, and elm_obj_icon_order_lookup_get.

void elm_icon_order_lookup_set | ( | Evas_Object * | obj,
|  | Elm_Icon_Lookup_Order | order
| ) |  |

Sets the icon lookup order used by elm_icon_standard_set().

Parameters

  obj | The icon object
  order | The icon lookup order (can be one of ELM_ICON_LOOKUP_FDO_THEME, ELM_ICON_LOOKUP_THEME_FDO, ELM_ICON_LOOKUP_FDO or ELM_ICON_LOOKUP_THEME)

See Also
  elm_icon_order_lookup_get()
  Elm_Icon_Lookup_Order

References elm_obj_icon_order_lookup_set.

Referenced by elm_toolbar_item_state_add().

EINA_DEPRECATED void elm_icon_preload_disabled_set | ( | Evas_Object * | obj,
|  | Eina_Bool | disabled
| ) |  |

Enable or disable preloading of the icon.

Parameters

  obj | The icon object
  disabled | If EINA_TRUE, preloading will be disabled

Deprecated:
  Use elm_image_preload_disabled_set() instead.

References elm_image_preload_disabled_set().

EINA_DEPRECATED int elm_icon_prescale_get | ( | const Evas_Object * | obj | ) |

Get the prescale size for the icon.

Parameters

  obj | The icon object

Returns
  The prescale size

See Also
  elm_icon_prescale_set()

Deprecated:
  Use elm_image_prescale_get() instead.

References elm_image_prescale_get().

EINA_DEPRECATED void elm_icon_prescale_set | ( | Evas_Object * | obj,
|  | int | size
| ) |  |

Set the prescale size for the icon.

Parameters

  obj | The icon object
  size | The prescale size. This value is used for both width and height.

This function sets a new size for pixmap representation of the given icon. It allows the icon to be loaded already in the specified size, reducing the memory usage and load time when loading a big icon with load size set to a smaller size.

It's equivalent to the elm_bg_load_size_set() function for bg.

Note
  this is just a hint, the real size of the pixmap may differ depending on the type of icon being loaded, being bigger than requested.

See Also
  elm_icon_prescale_get()
  elm_bg_load_size_set()

Deprecated:
  Use elm_image_prescale_set() instead.

References elm_image_prescale_set().

EINA_DEPRECATED void elm_icon_resizable_get | ( | const Evas_Object * | obj,
|  | Eina_Bool * | size_up,
|  | Eina_Bool * | size_down
| ) |  |

Get if the object is (up/down) resizable.

Parameters

  obj | The icon object
  size_up | A bool to set if the object is resizable up
  size_down | A bool to set if the object is resizable down

See Also
  elm_icon_resizable_set()

Deprecated:
  Use elm_image_resizable_get() instead.

References elm_image_resizable_get().

EINA_DEPRECATED void elm_icon_resizable_set | ( | Evas_Object * | obj,
|  | Eina_Bool | size_up,
|  | Eina_Bool | size_down
| ) |  |

Set if the object is (up/down) resizable.

Parameters

  obj | The icon object
  size_up | A bool to set if the object is resizable up. Default is `EINA_TRUE`.
  size_down | A bool to set if the object is resizable down. Default is `EINA_TRUE`.

This function limits the icon object resize ability. If `size_up` is set to `EINA_FALSE`, the object can't have its height or width resized to a value higher than the original icon size. Same is valid for `size_down`.

See Also
  elm_icon_resizable_get()

Deprecated:
  Use elm_image_resizable_set() instead.

References elm_image_resizable_set().

EINA_DEPRECATED void elm_icon_size_get | ( | const Evas_Object * | obj,
|  | int * | w,
|  | int * | h
| ) |  |

Get the object's image size.

Parameters

  obj | The icon object
  w | A pointer to store the width in
  h | A pointer to store the height in

Deprecated:
  Use elm_image_object_size_get() instead.

References elm_image_object_size_get().

EINA_DEPRECATED Eina_Bool elm_icon_smooth_get | ( | const Evas_Object * | obj | ) |

Get whether smooth scaling is enabled for an icon object.

Parameters

  obj | The icon object

Returns
  `EINA_TRUE` if smooth scaling is enabled, `EINA_FALSE` otherwise.

See Also
  elm_icon_smooth_set()

Deprecated:
  Use elm_image_smooth_get() instead.

References elm_image_smooth_get().

EINA_DEPRECATED void elm_icon_smooth_set | ( | Evas_Object * | obj,
|  | Eina_Bool | smooth
| ) |  |

Set the smooth scaling for an icon object.

Parameters

  obj | The icon object
  smooth | `EINA_TRUE` if smooth scaling should be used, `EINA_FALSE` otherwise. Default is `EINA_TRUE`.

Set the scaling algorithm to be used when scaling the icon image. Smooth scaling provides a better resulting image, but is slower.

The smooth scaling should be disabled when making animations that change the icon size, since they will be faster. Animations that don't require resizing of the icon can keep the smooth scaling enabled (even if the icon is already scaled, since the scaled icon image will be cached).

See Also
  elm_icon_smooth_get()

Deprecated:
  Use elm_image_smooth_set() instead.

References elm_image_smooth_set().

const char* elm_icon_standard_get | ( | const Evas_Object * | obj | ) |

Get the icon name set by icon standard names.

Parameters

  obj | The icon object

Returns
  The icon name

If the icon image was set using elm_image_file_set() instead of elm_icon_standard_set(), then this function will return `NULL`.

See Also
  elm_icon_standard_set()

References elm_obj_icon_standard_get.

Eina_Bool elm_icon_standard_set | ( | Evas_Object * | obj,
|  | const char * | name
| ) |  |

Set the icon by icon standards names.

Parameters

  obj | The icon object
  name | The icon name

Returns
  (`EINA_TRUE` = success, `EINA_FALSE` = error)

For example, freedesktop.org defines standard icon names such as "home", "network", etc. There can be different icon sets to match those icon keys. The `name` given as parameter is one of these "keys", and will be used to look in the freedesktop.org paths and elementary theme. One can change the lookup order with elm_icon_order_lookup_set().

If name is not found in any of the expected locations and it is the absolute path of an image file, this image will be used.

Note
  The icon image set by this function can be changed by elm_image_file_set().
  This function does not accept relative icon path.

See Also
  elm_icon_standard_get()
  elm_image_file_set()

References elm_obj_icon_standard_set.

Referenced by elm_menu_item_icon_name_set().

void elm_icon_thumb_set | ( | Evas_Object * | obj,
|  | const char * | file,
|  | const char * | group
| ) |  |

Set the file that will be used, but use a generated thumbnail.

Parameters

  obj | The icon object
  file | The path to file that will be used as icon image
  group | The group that the icon belongs to an edje file

This functions like elm_image_file_set() but requires the Ethumb library support to be enabled successfully with elm_need_ethumb(). When set the file indicated has a thumbnail generated and cached on disk for future use or will directly use an existing cached thumbnail if it is valid.

See Also
  elm_image_file_set()

References elm_obj_icon_thumb_set.

Copyright ©2000-2014 Enlightenment.org - Samsung Electronics supports the EFL Documentation Project - Generated Wed Jan 8 2014 20:51:13