_Elm_Prefs_Page_Iface Struct Reference
Elementary » Elementary Prefs

Interface between pages of the Prefs widget and the real widgets implementing them. More...

`#include <elm_prefs_common.h>`

## Data Fields

unsigned int | abi_version
| always use:
Evas_Object *(* | add )(const Elm_Prefs_Page_Iface *iface, Evas_Object *prefs)
| Function to instantiate the page widget.
Eina_Bool(* | title_set )(Evas_Object *obj, const char *title)
| function to set a title on the page widget
Eina_Bool(* | sub_title_set )(Evas_Object *obj, const char *sub_title)
| function to set a sub-title on the page widget
Eina_Bool(* | icon_set )(Evas_Object *obj, const char *icon)
| function to set an icon on the page widget
Eina_Bool(* | item_pack )(Evas_Object *obj, Evas_Object *it, const Elm_Prefs_Item_Type type, const Elm_Prefs_Item_Iface *iface)
| function to pack an item (widget) on the page widget
Eina_Bool(* | item_unpack )(Evas_Object *obj, Evas_Object *it)
| function to unpack an item (widget) on the page widget
Eina_Bool(* | item_pack_before )(Evas_Object *obj, Evas_Object *it, Evas_Object *it_before, const Elm_Prefs_Item_Type type, const Elm_Prefs_Item_Iface *iface)
| function to pack an item (widget) on the page widget, before a pre-existing, referential, packed one
Eina_Bool(* | item_pack_after )(Evas_Object *obj, Evas_Object *it, Evas_Object *it_after, const Elm_Prefs_Item_Type type, const Elm_Prefs_Item_Iface *iface)

## Detailed Description

Interface between pages of the Prefs widget and the real widgets implementing them.

This structure defines the interface between the Prefs widget's pages and Elementary widgets implementing them.

It is mandatory that the following functions be implemented, at least, for a page widget:

- Elm_Prefs_Page_Iface::add
- Elm_Prefs_Page_Iface::item_pack
- Elm_Prefs_Page_Iface::item_unpack
- Elm_Prefs_Page_Iface::item_pack_before
- #Elm_Prefs_Page_Iface::item_pack_after

Note
  For regular, non-page prefs items, refer to #Elm_Prefs_Item_Iface.

Since
  1.8

## Field Documentation

## abi_version

unsigned int _Elm_Prefs_Page_Iface::abi_version

always use:

- #ELM_PREFS_PAGE_IFACE_ABI_VERSION to declare.
- elm_prefs_widget_iface_abi_version_get() to check.

Referenced by elm_prefs_page_iface_register().

## add

Evas_Object *(* _Elm_Prefs_Page_Iface::add) (const Elm_Prefs_Page_Iface *iface, Evas_Object *prefs)

Function to instantiate the page widget.

It must return the widget handle, which should be the `obj` argument on the functions which follow. That object argument, by the way, should always have their respective #Elm_Prefs_Page_Node handle accessible via a `"prefs_page"` Evas object data value. The return value of the following functions should be `EINA_TRUE`, on success or `EINA_FALSE`, otherwise.