Rechercher une page de manuel
Evas_Smart_Object_Group
Langue: en
Version: 382396 (fedora - 01/12/10)
Section: 3 (Bibliothèques de fonctions)
Sommaire
- NAME
- Detailed Description
- Function Documentation
- EAPI Evas_Object* evas_object_smart_add (Evas * e, Evas_Smart * s)
- EAPI void evas_object_smart_calculate (Evas_Object * obj)
- EAPI void evas_object_smart_callback_add (Evas_Object * obj, const char * event, void(*)(void *data, Evas_Object *obj, void *event_info) func, const void * data)
- EAPI void evas_object_smart_callback_call (Evas_Object * obj, const char * event, void * event_info)
- EAPI void* evas_object_smart_callback_del (Evas_Object * obj, const char * event, void(*)(void *data, Evas_Object *obj, void *event_info) func)
- EAPI void evas_object_smart_callbacks_descriptions_get (const Evas_Object * obj, const Evas_Smart_Cb_Description *** class_descriptions, unsigned int * class_count, const Evas_Smart_Cb_Description *** instance_descriptions, unsigned int * instance_count)
- EAPI Eina_Bool evas_object_smart_callbacks_descriptions_set (Evas_Object * obj, const Evas_Smart_Cb_Description * descriptions)
- EAPI void evas_object_smart_changed (Evas_Object * obj)
- EAPI void* evas_object_smart_data_get (const Evas_Object * obj)
- EAPI void evas_object_smart_data_set (Evas_Object * obj, void * data)
- EAPI void evas_object_smart_member_add (Evas_Object * obj, Evas_Object * smart_obj)
- EAPI void evas_object_smart_member_del (Evas_Object * obj)
- EAPI Eina_Bool evas_object_smart_need_recalculate_get (const Evas_Object * obj)
- EAPI void evas_object_smart_need_recalculate_set (Evas_Object * obj, Eina_Bool value)
- EAPI Evas_Object* evas_object_smart_parent_get (const Evas_Object * obj)
- EAPI Evas_Smart* evas_object_smart_smart_get (const Evas_Object * obj)
- EAPI Eina_Bool evas_object_smart_type_check (const Evas_Object * obj, const char * type)
- EAPI Eina_Bool evas_object_smart_type_check_ptr (const Evas_Object * obj, const char * type)
- EAPI void evas_smart_objects_calculate (Evas * e)
- Author
NAME
Smart Object Functions -Functions dealing with evas smart objects (instances).
Modules
Clipped Smart Object
Clipped smart object is a base to construct other smart objects that based on the concept of having an internal clipper that is applied to all its other children.
Box (Sequence) Smart Object.
Convenience smart object that packs children as a sequence using a layout function specified by user.
Table Smart Object.
Convenience smart object that packs children using a tabular layout using children size hints to define their size and alignment inside their cell space.
Functions
EAPI void evas_object_smart_data_set (Evas_Object *obj, void *data)
Store a pointer to user data for a smart object.
EAPI void * evas_object_smart_data_get (const Evas_Object *obj)
Retrieve user data stored on a smart object.
EAPI Evas_Smart * evas_object_smart_smart_get (const Evas_Object *obj)
Get the Evas_Smart from which obj was created.
EAPI void evas_object_smart_member_add (Evas_Object *obj, Evas_Object *smart_obj)
Set an evas object as a member of a smart object.
EAPI void evas_object_smart_member_del (Evas_Object *obj)
Removes a member object from a smart object.
EAPI Evas_Object * evas_object_smart_parent_get (const Evas_Object *obj)
Gets the smart parent of an Evas_Object.
EAPI Eina_Bool evas_object_smart_type_check (const Evas_Object *obj, const char *type)
Checks the Smart type of the object and its parents.
EAPI Eina_Bool evas_object_smart_type_check_ptr (const Evas_Object *obj, const char *type)
Checks the Smart type of the object and its parents using pointer comparison.
EAPI Evas_Object * evas_object_smart_add (Evas *e, Evas_Smart *s)
Instantiates a new smart object described by s.
EAPI void evas_object_smart_callback_add (Evas_Object *obj, const char *event, void(*func)(void *data, Evas_Object *obj, void *event_info), const void *data)
Add a callback for the smart event specified by event.
EAPI void * evas_object_smart_callback_del (Evas_Object *obj, const char *event, void(*func)(void *data, Evas_Object *obj, void *event_info))
Remove a smart callback.
EAPI void evas_object_smart_callback_call (Evas_Object *obj, const char *event, void *event_info)
Call any smart callbacks on obj for event.
EAPI Eina_Bool evas_object_smart_callbacks_descriptions_set (Evas_Object *obj, const Evas_Smart_Cb_Description *descriptions)
Set smart object instance callbacks descriptions.
EAPI void evas_object_smart_callbacks_descriptions_get (const Evas_Object *obj, const Evas_Smart_Cb_Description ***class_descriptions, unsigned int *class_count, const Evas_Smart_Cb_Description ***instance_descriptions, unsigned int *instance_count)
Get the callbacks descriptions known by this smart object.
EAPI void evas_object_smart_need_recalculate_set (Evas_Object *obj, Eina_Bool value)
Set the need_recalculate flag of given smart object.
EAPI Eina_Bool evas_object_smart_need_recalculate_get (const Evas_Object *obj)
Get the current value of need_recalculate flag.
EAPI void evas_object_smart_calculate (Evas_Object *obj)
Call user provided calculate() and unset need_calculate.
EAPI void evas_smart_objects_calculate (Evas *e)
Call user provided calculate() and unset need_calculate on all objects.
EAPI void evas_object_smart_changed (Evas_Object *obj)
Mark smart object as changed, dirty.
Detailed Description
Functions dealing with evas smart objects (instances).
Smart objects are groupings of primitive evas objects that behave as a cohesive group. For instance, a file manager icon may be a smart object composed of an image object, a text label and two rectangles that appear behind the image and text when the icon is selected. As a smart object, the normal evas api could be used on the icon object.
See also:
- Smart Functions for class definitions.
Function Documentation
EAPI Evas_Object* evas_object_smart_add (Evas * e, Evas_Smart * s)
Instantiates a new smart object described by s. Parameters:
- e the evas on which to add the object
s the Evas_Smart describing the smart object
Returns:
- a new Evas_Object
Referenced by evas_object_box_add(), and evas_object_table_add().
EAPI void evas_object_smart_calculate (Evas_Object * obj)
Call user provided calculate() and unset need_calculate. Parameters:
- obj the smart object
EAPI void evas_object_smart_callback_add (Evas_Object * obj, const char * event, void(*)(void *data, Evas_Object *obj, void *event_info) func, const void * data)
Add a callback for the smart event specified by event. Parameters:
- obj a smart object
event the event name
func the callback function
data user data to be passed to the callback function
EAPI void evas_object_smart_callback_call (Evas_Object * obj, const char * event, void * event_info)
Call any smart callbacks on obj for event. Parameters:
- obj the smart object
event the event name
event_info an event specific struct of info to pass to the callback
This should be called internally in the smart object when some specific event has occured. The documentation for the smart object should include a list of possible events and what type of event_info to expect.
EAPI void* evas_object_smart_callback_del (Evas_Object * obj, const char * event, void(*)(void *data, Evas_Object *obj, void *event_info) func)
Remove a smart callback. Removes a callback that was added by evas_object_smart_callback_add()
Parameters:
- obj a smart object
event the event name
func the callback function
Returns:
- the data pointer
EAPI void evas_object_smart_callbacks_descriptions_get (const Evas_Object * obj, const Evas_Smart_Cb_Description *** class_descriptions, unsigned int * class_count, const Evas_Smart_Cb_Description *** instance_descriptions, unsigned int * instance_count)
Get the callbacks descriptions known by this smart object. This call retrieves processed callbacks descriptions for both instance and class. These arrays are sorted by description's name and are NULL terminated, so both class_count and instance_count can be ignored, the terminator NULL is not counted in these values.
Parameters:
- obj the smart object.
class_descriptions where to store class callbacks descriptions array, if any is known. If no descriptions are known, NULL is returned. This parameter may be NULL if it is not of interest.
class_count returns how many class callbacks descriptions are known.
instance_descriptions where to store instance callbacks descriptions array, if any is known. If no descriptions are known, NULL is returned. This parameter may be NULL if it is not of interest.
instance_count returns how many instance callbacks descriptions are known.
Note:
- if just class descriptions are of interest, try evas_smart_callbacks_descriptions_get() instead.
See also:
- evas_smart_callbacks_descriptions_get()
EAPI Eina_Bool evas_object_smart_callbacks_descriptions_set (Evas_Object * obj, const Evas_Smart_Cb_Description * descriptions)
Set smart object instance callbacks descriptions. These descriptions are hints to be used by introspection and are not enforced in any way.
It will not be checked if instance callbacks descriptions have the same name as another in class. Both are kept in different arrays and users of evas_object_smart_callbacks_descriptions_get() should handle this case as they wish.
Parameters:
- obj The smart object
descriptions NULL terminated (name != NULL) array with descriptions. Array elements will not be modified, but reference to them and their contents will be made, so this array should be kept alive during object lifetime.
Returns:
- 1 on success, 0 on failure.
Note:
- while instance callbacks descriptions are possible, they are not recommended. Use class callbacks descriptions instead as they make user's life simpler and will use less memory as descriptions and arrays will be shared among all instances.
References _Evas_Smart_Cb_Description::name.
EAPI void evas_object_smart_changed (Evas_Object * obj)
Mark smart object as changed, dirty. This will inform the scene that it changed and needs to be redraw, also setting need_recalculate on the given object.
See also:
- evas_object_smart_need_recalculate_set().
References evas_object_smart_need_recalculate_set().
Referenced by evas_object_box_align_set(), evas_object_box_append(), evas_object_box_insert_after(), evas_object_box_insert_at(), evas_object_box_insert_before(), evas_object_box_layout_set(), evas_object_box_option_property_vset(), evas_object_box_padding_set(), evas_object_box_prepend(), evas_object_box_remove(), evas_object_box_remove_all(), evas_object_box_remove_at(), evas_object_table_align_set(), evas_object_table_clear(), evas_object_table_homogeneous_set(), evas_object_table_pack(), evas_object_table_padding_set(), and evas_object_table_unpack().
EAPI void* evas_object_smart_data_get (const Evas_Object * obj)
Retrieve user data stored on a smart object. Parameters:
- obj The smart object
Returns:
- A pointer to data stored using evas_object_smart_data_set(), or NULL if none has been set.
Referenced by evas_object_smart_clipped_clipper_get().
EAPI void evas_object_smart_data_set (Evas_Object * obj, void * data)
Store a pointer to user data for a smart object. Parameters:
- obj The smart object
data A pointer to user data
EAPI void evas_object_smart_member_add (Evas_Object * obj, Evas_Object * smart_obj)
Set an evas object as a member of a smart object. Parameters:
- obj The member object
smart_obj The smart object
Members will automatically be stacked and layered with the smart object. The various stacking function will operate on members relative to the other members instead of the entire canvas.
Non-member objects can not interleave a smart object's members.
References evas_object_smart_member_del().
Referenced by evas_object_box_add_to(), evas_object_box_append(), evas_object_box_insert_after(), evas_object_box_insert_at(), evas_object_box_insert_before(), evas_object_box_prepend(), evas_object_table_add_to(), and evas_object_table_pack().
EAPI void evas_object_smart_member_del (Evas_Object * obj)
Removes a member object from a smart object. Parameters:
- obj the member object
This removes a member object from a smart object. The object will still be on the canvas, but no longer associated with whichever smart object it was associated with.
Referenced by evas_object_box_remove(), evas_object_box_remove_all(), evas_object_box_remove_at(), evas_object_smart_member_add(), evas_object_table_clear(), and evas_object_table_unpack().
EAPI Eina_Bool evas_object_smart_need_recalculate_get (const Evas_Object * obj)
Get the current value of need_recalculate flag. Note:
- this flag will be unset during the render phase, after calculate() is called if one is provided. If no calculate() is provided, then the flag will be left unchanged after render phase.
Parameters:
- obj the smart object
Returns:
- if flag is set or not.
EAPI void evas_object_smart_need_recalculate_set (Evas_Object * obj, Eina_Bool value)
Set the need_recalculate flag of given smart object. If this flag is set then calculate() callback (method) of the given smart object will be called, if one is provided, during render phase usually evas_render(). After this step, this flag will be automatically unset.
If no calculate() is provided, this flag will be left unchanged.
Note:
- just setting this flag will not make scene dirty and evas_render() will have no effect. To do that, use evas_object_smart_changed(), that will automatically call this function with 1 as parameter.
Parameters:
- obj the smart object
value if one want to set or unset the need_recalculate flag.
Referenced by evas_object_smart_changed().
EAPI Evas_Object* evas_object_smart_parent_get (const Evas_Object * obj)
Gets the smart parent of an Evas_Object. Parameters:
- obj the Evas_Object you want to get the parent
Returns:
- Returns the smart parent of obj, or NULL if obj is not a smart member of another Evas_Object
Referenced by evas_object_table_unpack().
EAPI Evas_Smart* evas_object_smart_smart_get (const Evas_Object * obj)
Get the Evas_Smart from which obj was created. Parameters:
- obj a smart object
Returns:
- the Evas_Smart
EAPI Eina_Bool evas_object_smart_type_check (const Evas_Object * obj, const char * type)
Checks the Smart type of the object and its parents. Parameters:
- obj the Evas_Object to check the type of
type the type to check for
Returns:
- EINA_TRUE if obj or any of its parents if of type type, EINA_FALSE otherwise
References _Evas_Smart_Class::name, and _Evas_Smart_Class::parent.
EAPI Eina_Bool evas_object_smart_type_check_ptr (const Evas_Object * obj, const char * type)
Checks the Smart type of the object and its parents using pointer comparison. Parameters:
- obj the Evas_Object to check the type of
type the type to check for. Must be the name pointer in the smart class used to create the object
Returns:
- EINA_TRUE if obj or any of its parents if of type type, EINA_FALSE otherwise
References _Evas_Smart_Class::name, and _Evas_Smart_Class::parent.
EAPI void evas_smart_objects_calculate (Evas * e)
Call user provided calculate() and unset need_calculate on all objects. Parameters:
- e The canvas to calculate all objects in
Author
Generated automatically by Doxygen for Evas from the source code.
Contenus ©2006-2024 Benjamin Poulain
Design ©2006-2024 Maxime Vantorre