Color Class Editor

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

Typedefs | Functions
Color Class Editor

This group provides a UI for editing color classes in applications. More...

## Typedefs
typedef char *(* | Elm_Color_Class_Name_Cb) (char *)
| A callback used to translate color class descriptions.
typedef Eina_List *(* | Elm_Color_Class_List_Cb) (void)
| A callback used to provide a list of allocated Edje_Color_Class structs used by an application.

## Functions
Evas_Object * | elm_color_class_editor_add (Evas_Object *obj)
| Create a new color class editor.
void | elm_color_class_translate_cb_set (Elm_Color_Class_Name_Cb cb)
| Set a callback to provide translations for color class descriptions.
void | elm_color_class_list_cb_set (Elm_Color_Class_List_Cb cb)
| Set a callback to provide a list of supplementary color classes.
Eina_List * | elm_color_class_util_edje_file_list (Eina_File *f)
| Create an allocated list of allocated Edje_Color_Class structs from an open edje file.

## Detailed Description

This group provides a UI for editing color classes in applications.

## Typedef Documentation

## ◆ Elm_Color_Class_Name_Cb

Elm_Color_Class_Name_Cb

A callback used to translate color class descriptions.

Since
  1.14

## ◆ Elm_Color_Class_List_Cb

Elm_Color_Class_List_Cb

A callback used to provide a list of allocated Edje_Color_Class structs used by an application.

Since
  1.14

The list and its members will be freed internally.

## Function Documentation

## ◆ elm_color_class_editor_add()

Evas_Object * elm_color_class_editor_add | ( | Evas_Object * | obj | ) |

Create a new color class editor.

Parameters

  obj | The parent object

A color class editor is a visual representation of the color schemes in an application. Values changed in the editor are stored in Elementary's config and will remain until they are reset or the config is cleared. By default, the editor will load only the currently active color classes in an application.

Since
  1.14

- FIXME: translate *‍/

References ecore_timer_add(), edje_color_class_active_iterator_new(), edje_color_class_set(), eina_hash_add(), eina_hash_find(), eina_hash_free(), eina_hash_string_superfast_new(), eina_inlist_append(), EINA_INLIST_GET, EINA_ITERATOR_FOREACH, eina_iterator_free(), eina_list_append(), EINA_LIST_FREE, eina_stringshare_add(), eina_stringshare_del(), eldbus_connection_get(), eldbus_name_request(), ELDBUS_NAME_REQUEST_FLAG_DO_NOT_QUEUE, eldbus_service_interface_register(), elm_button_add(), elm_colorselector_add(), ELM_COLORSELECTOR_COMPONENTS, ELM_COLORSELECTOR_EVENT_CHANGED_USER, elm_genlist_add(), elm_genlist_homogeneous_set(), elm_genlist_item_append(), elm_genlist_item_sorted_insert(), elm_genlist_mode_set(), elm_layout_add(), elm_layout_signal_callback_add(), elm_layout_theme_set(), ELM_LIST_COMPRESS, elm_object_part_content_set(), elm_object_style_set(), elm_scroller_bounce_set(), ELM_SCROLLER_POLICY_AUTO, ELM_SCROLLER_POLICY_OFF, elm_scroller_policy_set(), EVAS_CALLBACK_DEL, evas_object_event_callback_add(), and evas_object_smart_callback_add().

## ◆ elm_color_class_translate_cb_set()

void elm_color_class_translate_cb_set | ( | Elm_Color_Class_Name_Cb | cb | ) |

Set a callback to provide translations for color class descriptions.

Parameters

  cb | The callback to use

This callback will be called globally by the application to translate any available color class description strings from the theme's color classes.

Since
  1.14

## ◆ elm_color_class_list_cb_set()

void elm_color_class_list_cb_set | ( | Elm_Color_Class_List_Cb | cb | ) |

Set a callback to provide a list of supplementary color classes.

Parameters

  cb | The callback to use

This callback will be called globally by the application to provide extra color classes that an application may use but which may not be currently loaded.

See also
  Elm_Color_Class_List_Cb

Since
  1.14

## ◆ elm_color_class_util_edje_file_list()

Eina_List * elm_color_class_util_edje_file_list | ( | Eina_File * | f | ) |

Create an allocated list of allocated Edje_Color_Class structs from an open edje file.

Parameters

  f | The file to list color classes from

Returns
  The list of color classes present in the file

This is a helper function to create a list for use with Elm_Color_Class_List_Cb callbacks.

See also
  Elm_Color_Class_List_Cb

Since
  1.14

References edje_mmap_color_class_iterator_new(), EINA_ITERATOR_FOREACH, eina_iterator_free(), eina_list_append(), EINA_SAFETY_ON_NULL_RETURN_VAL, and eina_stringshare_add().