Eobj: Added docs to the examples (needed for introspection).

Patch by Yakov Goldberg.

SVN revision: 70417
This commit is contained in:
Tom Hacohen 2012-04-23 12:32:34 +00:00
parent 44e549e812
commit 5b529c506b
7 changed files with 95 additions and 8 deletions

View File

@ -12,6 +12,11 @@ enum {
#define ELW_BOX_ID(sub_id) (ELW_BOX_BASE_ID + sub_id)
/**
* @def ELW_BOX_PACK_END(obj)
* @brief Pack object to the end of the box
* @param[in] obj object to pack into box
*/
#define ELW_BOX_PACK_END(obj) ELW_BOX_ID(ELW_BOX_SUB_ID_PACK_END), EOBJ_TYPECHECK(Eobj *, obj)
#define ELW_BOX_CLASS elw_box_class_get()

View File

@ -12,8 +12,13 @@ enum {
#define ELW_BUTTON_ID(sub_id) (ELW_BUTTON_BASE_ID + sub_id)
/* FIXME Doesn't belong here, but just for the example... */
#define ELW_BUTTON_TEXT_SET(obj) ELW_BUTTON_ID(ELW_BUTTON_SUB_ID_TEXT_SET), EOBJ_TYPECHECK(const char *, obj)
/**
* @def ELW_BUTTON_TEXT_SET(text)
* @brief Set button text
* @param[in] text text to assing to button
* FIXME Doesn't belong here, but just for the example...
*/
#define ELW_BUTTON_TEXT_SET(text) ELW_BUTTON_ID(ELW_BUTTON_SUB_ID_TEXT_SET), EOBJ_TYPECHECK(const char *, text)
extern const Eobj_Event_Description _SIG_CLICKED;
#define SIG_CLICKED (&(_SIG_CLICKED))

View File

@ -17,11 +17,54 @@ enum {
#define EVAS_OBJ_ID(sub_id) (EVAS_OBJ_BASE_ID + sub_id)
/**
* @def EVAS_OBJ_POSITION_SET(x, y)
* @brief Set object's position
* @param[in] x object's X position
* @param[in] y object's Y position
*/
#define EVAS_OBJ_POSITION_SET(x, y) EVAS_OBJ_ID(EVAS_OBJ_SUB_ID_POSITION_SET), EOBJ_TYPECHECK(Evas_Coord, x), EOBJ_TYPECHECK(Evas_Coord, y)
/**
* @def EVAS_OBJ_SIZE_SET(w, h)
* @brief Set object's size
* @param[in] w object's width
* @param[in] h object's height
*/
#define EVAS_OBJ_SIZE_SET(w, h) EVAS_OBJ_ID(EVAS_OBJ_SUB_ID_SIZE_SET), EOBJ_TYPECHECK(Evas_Coord, w), EOBJ_TYPECHECK(Evas_Coord, h)
/**
* @def EVAS_OBJ_COLOR_SET(r, g, b, a)
* @brief Set object's color
* @param[in] r r-value of color
* @param[in] g g-value of color
* @param[in] b b-value of color
* @param[in] a a-value of color
*/
#define EVAS_OBJ_COLOR_SET(r, g, b, a) EVAS_OBJ_ID(EVAS_OBJ_SUB_ID_COLOR_SET), EOBJ_TYPECHECK(int, r), EOBJ_TYPECHECK(int, g), EOBJ_TYPECHECK(int, b), EOBJ_TYPECHECK(int, a)
/**
* @def EVAS_OBJ_COLOR_GET(r, g, b, a)
* @brief Set object's position
* @param[out] r integer pointer for r-value of color
* @param[out] g integer pointer for g-value of color
* @param[out] b integer pointer for b-value of color
* @param[out] a integer pointer for a-value of color
*/
#define EVAS_OBJ_COLOR_GET(r, g, b, a) EVAS_OBJ_ID(EVAS_OBJ_SUB_ID_COLOR_GET), EOBJ_TYPECHECK(int *, r), EOBJ_TYPECHECK(int *, g), EOBJ_TYPECHECK(int *, b), EOBJ_TYPECHECK(int *, a)
/**
* @def EVAS_OBJ_VISIBILITY_SET(v)
* @brief Set object's visible property
* @param[in] v True/False value
*/
#define EVAS_OBJ_VISIBILITY_SET(v) EVAS_OBJ_ID(EVAS_OBJ_SUB_ID_VISIBILITY_SET), EOBJ_TYPECHECK(Eina_Bool, v)
/**
* @def EVAS_OBJ_CHILD_ADD(child)
* @brief Add child to current object
* @param[in] pointer to child object
*/
#define EVAS_OBJ_CHILD_ADD(child) EVAS_OBJ_ID(EVAS_OBJ_SUB_ID_CHILD_ADD), EOBJ_TYPECHECK(Eobj *, child)
#define EVAS_OBJ_CLASS evas_object_class_get()

View File

@ -12,6 +12,12 @@ enum {
#define MIXIN_ID(sub_id) (MIXIN_BASE_ID + sub_id)
/**
* @def MIXIN_AB_SUM_GET(sum)
* @brief Get sum of a,b integer elements
* @param[out] sum integer pointer to sum - value
*/
#define MIXIN_AB_SUM_GET(sum) MIXIN_ID(MIXIN_SUB_ID_AB_SUM_GET), EOBJ_TYPECHECK(int *, sum)
#define MIXIN_CLASS mixin_class_get()

View File

@ -15,9 +15,32 @@ enum {
#define SIMPLE_ID(sub_id) (SIMPLE_BASE_ID + sub_id)
/**
* @def SIMPLE_A_SET(a)
* @brief Set value to a-property
* @param[in] a integer value to set
*/
#define SIMPLE_A_SET(a) SIMPLE_ID(SIMPLE_SUB_ID_A_SET), EOBJ_TYPECHECK(int, a)
/**
* @def SIMPLE_A_GET(a)
* @brief Get value of a-property
* @param[out] integer pointer to a-value
*/
#define SIMPLE_A_GET(a) SIMPLE_ID(SIMPLE_SUB_ID_A_GET), EOBJ_TYPECHECK(int *, a)
/**
* @def SIMPLE_B_SET(b)
* @brief Set value to b-property
* @param[in] a integer value to set
*/
#define SIMPLE_B_SET(b) SIMPLE_ID(SIMPLE_SUB_ID_B_SET), EOBJ_TYPECHECK(int, b)
/**
* @def SIMPLE_B_GET(b)
* @brief Get value of b-property
* @param[out] integer pointer to b-value
*/
#define SIMPLE_B_GET(b) SIMPLE_ID(SIMPLE_SUB_ID_B_GET), EOBJ_TYPECHECK(int *, b)
#define SIMPLE_CLASS simple_class_get()

View File

@ -17,6 +17,11 @@ typedef struct
#define SIMPLE_ID(sub_id) (SIMPLE_BASE_ID + sub_id)
/**
* @def SIMPLE_A_SET(a)
* @brief Set value to a - property
* @param[in] a integer value to set
*/
#define SIMPLE_A_SET(a) SIMPLE_ID(SIMPLE_SUB_ID_A_SET), EOBJ_TYPECHECK(int, a)
extern const Eobj_Event_Description _SIG_A_CHANGED;

View File

@ -793,9 +793,9 @@ enum {
/**
* @def EOBJ_BASE_DATA_SET(key, data, free_func)
* Set generic data to object.
* @param key the key associated with the data
* @param data the data to set.
* @param free_func the func to free data with (NULL means "do nothing").
* @param[in] key the key associated with the data
* @param[in] data the data to set.
* @param[in] free_func the func to free data with (NULL means "do nothing").
*
* @see #EOBJ_BASE_DATA_GET
* @see #EOBJ_BASE_DATA_DEL
@ -805,8 +805,8 @@ enum {
/**
* @def EOBJ_BASE_DATA_GET(key, data)
* Get generic data from object.
* @param key the key associated with the data
* @param data the data for the key
* @param[in] key the key associated with the data
* @param[out] data the data for the key
*
* @see #EOBJ_BASE_DATA_SET
* @see #EOBJ_BASE_DATA_DEL
@ -816,7 +816,7 @@ enum {
/**
* @def EOBJ_BASE_DATA_DEL(key)
* Del generic data from object.
* @param key the key associated with the data
* @param[in] key the key associated with the data
*
* @see #EOBJ_BASE_DATA_SET
* @see #EOBJ_BASE_DATA_GET