Efreet_Icon: The FDO Icon Theme

- Main Page
- Related Pages
- Modules
- Namespaces
- Data Structures
- Files
- Examples

Data Structures | Typedefs | Enumerations | Functions | Variables
Efreet_Icon: The FDO Icon Theme
Efreet

Specification functions and structures. More...

## Data Structures
struct | Efreet_Icon_Theme
| Efreet_Icon_Theme. More...
struct | Efreet_Icon_Theme_Directory
| Efreet_Icon_Theme_Directory. More...
struct | Efreet_Icon
| Efreet_Icon. More...
struct | Efreet_Icon_Point
| Efreet_Icon_Point. More...

## Typedefs
typedef enum Efreet_Icon_Theme_Context | Efreet_Icon_Theme_Context
| The possible contexts for an icon directory.
typedef enum Efreet_Icon_Size_Type | Efreet_Icon_Size_Type
| The possible size types for an icon directory.
typedef struct Efreet_Icon_Theme | Efreet_Icon_Theme
| Efreet_Icon_Theme.
typedef struct Efreet_Icon_Theme_Directory | Efreet_Icon_Theme_Directory
| Efreet_Icon_Theme_Directory.
typedef struct Efreet_Icon | Efreet_Icon
| Efreet_Icon.
typedef struct Efreet_Icon_Point | Efreet_Icon_Point
| Efreet_Icon_Point.

## Enumerations
enum | Efreet_Icon_Theme_Context { EFREET_ICON_THEME_CONTEXT_NONE, EFREET_ICON_THEME_CONTEXT_ACTIONS, EFREET_ICON_THEME_CONTEXT_DEVICES, EFREET_ICON_THEME_CONTEXT_FILESYSTEMS, EFREET_ICON_THEME_CONTEXT_MIMETYPES }
| The possible contexts for an icon directory.
enum | Efreet_Icon_Size_Type { EFREET_ICON_SIZE_TYPE_NONE, EFREET_ICON_SIZE_TYPE_FIXED, EFREET_ICON_SIZE_TYPE_SCALABLE, EFREET_ICON_SIZE_TYPE_THRESHOLD }
| The possible size types for an icon directory.

## Functions
const char * | efreet_icon_user_dir_get (void)
| Returns the user icon directory. More...
const char * | efreet_icon_deprecated_user_dir_get (void)
| Returns the deprecated user icon directory. More...
void | efreet_icon_extension_add (const char *ext)
| Adds the given extension to the list of possible icon extensions. More...
Eina_List ** | efreet_icon_extra_list_get (void)
| Gets the list of all extra directories to look for icons. These directories are used to look for icons after looking in the user icon dir and before looking in standard system directories. The order of search is from first to last directory in this list. the strings in the list should be created with eina_stringshare_add(). More...
Eina_List * | efreet_icon_extensions_list_get (void)
| Gets the list of all icon extensions to look for. More...
Eina_List * | efreet_icon_theme_list_get (void)
| Retrieves all of the non-hidden icon themes available on the system. The returned list must be freed. Do not free the list data. More...
Efreet_Icon_Theme * | efreet_icon_theme_find (const char *theme_name)
| Tries to get the icon theme structure for the given theme name. More...
Efreet_Icon * | efreet_icon_find (const char *theme_name, const char *icon, unsigned int size)
| Retrieves all of the information about the given icon. More...
const char * | efreet_icon_list_find (const char *theme_name, Eina_List *icons, unsigned int size)
| Retrieves all of the information about the first found icon in the list. More...
const char * | efreet_icon_path_find (const char *theme_name, const char *icon, unsigned int size)
| Retrives the path to the given icon. More...
void | efreet_icon_free (Efreet_Icon *icon)
| Free's the given icon and all its internal data. More...

## Variables
int | EFREET_EVENT_ICON_CACHE_UPDATE
| Event id for cache update.

## Detailed Description

Specification functions and structures.

## Function Documentation

const char* efreet_icon_user_dir_get | ( | void |  | ) |

Returns the user icon directory.

Returns
  Returns the user icon directory

References alloca(), efreet_data_home_get(), eina_file_path_sanitize(), and eina_stringshare_add_length().

Referenced by efreet_icon_free().

const char* efreet_icon_deprecated_user_dir_get | ( | void |  | ) |

Returns the deprecated user icon directory.

Returns
  Returns the deprecated user icon directory

References alloca(), eina_file_path_sanitize(), and eina_stringshare_add_length().

Referenced by efreet_icon_free().

void efreet_icon_extension_add | ( | const char * | ext | ) |

Adds the given extension to the list of possible icon extensions.

Parameters

  ext | The extension to add to the list of checked extensions

Returns
  Returns no value.

References eina_list_data_find_list(), eina_list_prepend(), eina_list_promote_list(), eina_stringshare_add(), and eina_stringshare_del().

Eina_List** efreet_icon_extra_list_get | ( | void |  | ) |

Gets the list of all extra directories to look for icons. These directories are used to look for icons after looking in the user icon dir and before looking in standard system directories. The order of search is from first to last directory in this list. the strings in the list should be created with eina_stringshare_add().

Returns
  Returns a list of strings that are paths to other icon directories

References ecore_job_add().

Eina_List* efreet_icon_extensions_list_get | ( | void |  | ) |

Gets the list of all icon extensions to look for.

Returns
  Returns a list of strings that are icon extensions to look for

Eina_List* efreet_icon_theme_list_get | ( | void |  | ) |

Retrieves all of the non-hidden icon themes available on the system. The returned list must be freed. Do not free the list data.

Returns
  Returns a list of Efreet_Icon structs for all the non-hidden icon themes

Efreet_Icon_Theme* efreet_icon_theme_find | ( | const char * | theme_name | ) |

Tries to get the icon theme structure for the given theme name.

Parameters

  theme_name | The theme to look for

Returns
  Returns the icon theme related to the given theme name or NULL if none exists.

References EINA_LIST_FOREACH, and WRN.

Referenced by efreet_icon_free(), efreet_icon_list_find(), and efreet_icon_path_find().

Efreet_Icon* efreet_icon_find | ( | const char * | theme_name,
|  | const char * | icon,
|  | unsigned int | size
| ) |  |

Retrieves all of the information about the given icon.

Parameters

  theme_name | The icon theme to look for
  icon | The icon to look for
  size | The icon size to look for

Returns
  Returns the Efreet_Icon structure representing this icon or NULL if the icon is not found

References ecore_file_file_get(), efreet_icon_path_find(), eina_stringshare_add(), name, and path.

const char* efreet_icon_list_find | ( | const char * | theme_name,
|  | Eina_List * | icons,
|  | unsigned int | size
| ) |  |

Retrieves all of the information about the first found icon in the list.

Parameters

  theme_name | The icon theme to look for
  icons | List of icons to look for
  size; | The icon size to look for

Returns
  Returns the path representing first found icon or NULL if none of the icons are found

Note
  This function will search the given theme for all icons before falling back. This is useful when searching for mimetype icons.

There is no guarantee for how long the pointer to the path will be valid. If the pointer is to be kept, the user must create a copy of the path.

References efreet_icon_theme_find(), eina_list_append(), EINA_LIST_FOREACH, eina_list_free(), EINA_LIST_FREE, and Efreet_Icon_Theme::name.

Referenced by efreet_mime_type_icon_get().

const char* efreet_icon_path_find | ( | const char * | theme_name,
|  | const char * | icon,
|  | unsigned int | size
| ) |  |

Retrives the path to the given icon.

Parameters

  theme_name | The icon theme to look for
  icon | The icon to look for
  size; | The icon size to look for

Returns
  Returns the path to the given icon or NULL if none found There is no guarantee for how long the pointer to the path will be valid. If the pointer is to be kept, the user must create a copy of the path.

References efreet_icon_theme_find(), and INF.

Referenced by efreet_icon_find().

void efreet_icon_free | ( | Efreet_Icon * | icon | ) |

Free's the given icon and all its internal data.

Parameters

  icon | The Efreet_Icon to cleanup

Returns
  Returns no value.

References alloca(), attach_points, Efreet_Ini::data, efreet_data_dirs_get(), efreet_icon_deprecated_user_dir_get(), efreet_icon_theme_find(), efreet_icon_user_dir_get(), eina_file_path_sanitize(), eina_list_append(), EINA_LIST_FOREACH, eina_stringshare_add(), EINA_UNUSED, embedded_text_rectangle, has_embedded_text_rectangle, Efreet_Icon_Theme::inherits, Efreet_Icon_Theme::name, name, efl::eo::parent, path, ref_count, Efreet_Icon_Point::x, x0, x1, Efreet_Icon_Point::y, y0, and y1.