parent
9f634895bf
commit
9fb09cae7a
|
@ -1,9 +1,9 @@
|
|||
#!/bin/sh
|
||||
cp ./edje.c.in ./edje.c
|
||||
cat ./src/lib/Edje.h >> ./edje.c
|
||||
#for I in `find ./src/lib -name "*.c" -print`; do
|
||||
# cat $I >> ./edje.c
|
||||
#done
|
||||
for I in `find ./src/lib -name "*.c" -print`; do
|
||||
cat $I >> ./edje.c
|
||||
done
|
||||
rm -rf ./doc/html ./doc/latex ./doc/man
|
||||
doxygen
|
||||
cp doc/img/*.png doc/html/
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
|
||||
#include <Evas.h>
|
||||
|
||||
/* FIXDOC: Define these? */
|
||||
|
||||
#define EDJE_DRAG_DIR_NONE 0
|
||||
#define EDJE_DRAG_DIR_X 1
|
||||
#define EDJE_DRAG_DIR_Y 2
|
||||
|
@ -21,523 +23,88 @@
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
/***************************************************************************/
|
||||
/* Documentation is within .c files */
|
||||
/* Doc issues marked with FIXDOC: */
|
||||
|
||||
/** Initialize the EDJE library.
|
||||
*
|
||||
* @return The new init count.
|
||||
*/
|
||||
/* edje_main.c */
|
||||
int edje_init (void);
|
||||
|
||||
/** Shutdown the EET library.
|
||||
*
|
||||
* @return The new init count.
|
||||
*/
|
||||
int edje_shutdown (void);
|
||||
|
||||
/** Set the frametime
|
||||
* @param t The frametime
|
||||
*
|
||||
* Sets the frametime in seconds, by default this is 1/60.
|
||||
*/
|
||||
/* edje_program.c */
|
||||
void edje_frametime_set (double t);
|
||||
|
||||
/** Get the frametime
|
||||
* @return The frametime
|
||||
*
|
||||
* Returns the frametime in seconds, by default this is 1/60.
|
||||
*/
|
||||
double edje_frametime_get (void);
|
||||
|
||||
/** Freeze all objects in the Edje.
|
||||
*/
|
||||
/* edje_util.c */
|
||||
void edje_freeze (void);
|
||||
|
||||
/** Thaw all objects in Edje
|
||||
*/
|
||||
void edje_thaw (void);
|
||||
|
||||
/** Get the collection list from the edje file ?!
|
||||
* @param file The file path?
|
||||
*
|
||||
* @return The file Evas List of files
|
||||
*/
|
||||
/* edje_load.c */
|
||||
Evas_List *edje_file_collection_list (const char *file);
|
||||
|
||||
/** Free file collection ?!
|
||||
* @param lst The Evas List of files
|
||||
*
|
||||
* Frees the file collection.
|
||||
*/
|
||||
void edje_file_collection_list_free (Evas_List *lst);
|
||||
|
||||
/** Get edje file data
|
||||
* @param file The file
|
||||
* @param key The data key
|
||||
* @return The file data string
|
||||
*/
|
||||
char *edje_file_data_get (const char *file, const char *key);
|
||||
|
||||
|
||||
|
||||
/** Set Edje color class
|
||||
* @param color_class
|
||||
* @param r Object Red value
|
||||
* @param g Object Green value
|
||||
* @param b Object Blue value
|
||||
* @param a Object Alpha value
|
||||
* @param r2 Outline Red value
|
||||
* @param g2 Outline Green value
|
||||
* @param b2 Outline Blue value
|
||||
* @param a2 Outline Alpha value
|
||||
* @param r3 Shadow Red value
|
||||
* @param g3 Shadow Green value
|
||||
* @param b3 Shadow Blue value
|
||||
* @param a3 Shadow Alpha value
|
||||
*
|
||||
* Sets the color class for the Edje.
|
||||
*/
|
||||
/* edje_util.c */
|
||||
void edje_color_class_set(const char *color_class, int r, int g, int b, int a, int r2, int g2, int b2, int a2, int r3, int g3, int b3, int a3);
|
||||
|
||||
/** Set the Edje text class
|
||||
* @param text_class The text class name ?!
|
||||
* @param font The font name
|
||||
* @param size The font size
|
||||
*
|
||||
* This sets the Edje text class ?!
|
||||
*/
|
||||
void edje_text_class_set(const char *text_class, const char *font, Evas_Font_Size size);
|
||||
|
||||
/** Set the object minimum size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param minw The minimum width
|
||||
* @param minh The minimum height
|
||||
*
|
||||
* This sets the minimum size restriction for the object.
|
||||
*/
|
||||
void edje_extern_object_min_size_set (Evas_Object *obj, Evas_Coord minw, Evas_Coord minh);
|
||||
|
||||
/** Set the object maximum size
|
||||
* @param obj A vaild Evas_Object handle
|
||||
* @param maxw The maximum width
|
||||
* @param maxh The maximum height
|
||||
*
|
||||
* This sets the maximum size restriction for the object.
|
||||
*/
|
||||
void edje_extern_object_max_size_set (Evas_Object *obj, Evas_Coord maxw, Evas_Coord maxh);
|
||||
|
||||
/** Contruct edje object ?! What's the correct terminology?
|
||||
* @param evas A valid Evas handle
|
||||
* @return The Evas_Object pointer.
|
||||
*/
|
||||
/* edje_smart.c */
|
||||
Evas_Object *edje_object_add (Evas *evas);
|
||||
|
||||
/** Get Edje object data
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param key The data key
|
||||
* @return The data string
|
||||
*/
|
||||
/* edje_util.c */
|
||||
const char *edje_object_data_get (Evas_Object *obj, const char *key);
|
||||
|
||||
/** Sets the .eet location and loads the Edje. ?! Assuming eet file
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param file The path to the .eet file
|
||||
* @param part The group name in the eet
|
||||
* @return 0 on Error\n
|
||||
* 1 on Success
|
||||
*
|
||||
* This loads the .eet file and sets up the Edje.
|
||||
*/
|
||||
/* edje_load.c */
|
||||
int edje_object_file_set (Evas_Object *obj, const char *file, const char *part);
|
||||
|
||||
/** Get the .eet location and group for the Evas Object. ?! Assuming eet file
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param file The .eet file location pointer
|
||||
* @param part The eet part pointer
|
||||
*
|
||||
* @ return 0 on Error\n
|
||||
* 1 on Success
|
||||
*
|
||||
* This gets the .eet file location and group for the given Evas_Object.
|
||||
*/
|
||||
void edje_object_file_get (Evas_Object *obj, const char **file, const char **part);
|
||||
|
||||
/** Get the Edje load error
|
||||
* @param obj A valid Evas_Object handle
|
||||
*
|
||||
* @return The load error from the object's Edje. 1/0, one being no error ?!
|
||||
*/
|
||||
int edje_object_load_error_get (Evas_Object *obj);
|
||||
|
||||
/** Adds a callback for the object.
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param emission Signal to activate callback ?!
|
||||
* @param source Source of signal
|
||||
* @param func The function to be executed when the callback is signaled
|
||||
*
|
||||
* Creates a callback for the object to execute the given function.
|
||||
*/
|
||||
/* edje_program.c */
|
||||
void edje_object_signal_callback_add (Evas_Object *obj, const char *emission, const char *source, void (*func) (void *data, Evas_Object *obj, const char *emission, const char *source), void *data);
|
||||
|
||||
/** Delete an object callback
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param emission ?!
|
||||
* @param source ?!
|
||||
*
|
||||
* Deletes an existing callback
|
||||
*/
|
||||
void *edje_object_signal_callback_del (Evas_Object *obj, const char *emission, const char *source, void (*func) (void *data, Evas_Object *obj, const char *emission, const char *source));
|
||||
|
||||
/** Send a signal to the Edje
|
||||
* @param A vaild Evas_Object handle
|
||||
* @param emission The signal
|
||||
* @param source The signal source
|
||||
*
|
||||
* This sends a signal to the edje. These are defined in the programs section of an edc. ?! Better description of signals
|
||||
*/
|
||||
void edje_object_signal_emit (Evas_Object *obj, const char *emission, const char *source);
|
||||
|
||||
/** Set the Edje to play or pause
|
||||
* @param obj A vaild Evas_Object handle
|
||||
* @param play Play instruction (1 to play, 0 to pause)
|
||||
*
|
||||
* This sets the Edje to play or pause depending on the parameter. This has no effect if the Edje is already in that state. ?! Better description
|
||||
*/
|
||||
void edje_object_play_set (Evas_Object *obj, int play);
|
||||
|
||||
/** Get the Edje play/pause state
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return 0 if Edje not connected, Edje delete_me, or Edje paused\n
|
||||
* 1 if Edje set to play
|
||||
*/
|
||||
int edje_object_play_get (Evas_Object *obj);
|
||||
|
||||
/** Set
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param on ?!
|
||||
*/
|
||||
void edje_object_animation_set (Evas_Object *obj, int on);
|
||||
|
||||
/** Get the Edje object animation state
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return 0 on Error or not animated\n ?!
|
||||
* 1 if animated
|
||||
*/
|
||||
int edje_object_animation_get (Evas_Object *obj);
|
||||
|
||||
/** Freeze object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return The frozen state\n
|
||||
* 0 on Error
|
||||
*
|
||||
* This puts all changes on hold. Successive freezes will nest, requiring an equal number of thaws.
|
||||
*/
|
||||
/* edje_util.c */
|
||||
int edje_object_freeze (Evas_Object *obj);
|
||||
|
||||
/** Thaw object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return The frozen state\n
|
||||
* 0 on Error
|
||||
*
|
||||
* This allows frozen changes to occur.
|
||||
*/
|
||||
int edje_object_thaw (Evas_Object *obj);
|
||||
|
||||
/** Sets the object color class
|
||||
* @param color_class
|
||||
* @param r Object Red value
|
||||
* @param g Object Green value
|
||||
* @param b Object Blue value
|
||||
* @param a Object Alpha value
|
||||
* @param r2 Outline Red value
|
||||
* @param g2 Outline Green value
|
||||
* @param b2 Outline Blue value
|
||||
* @param a2 Outline Alpha value
|
||||
* @param r3 Shadow Red value
|
||||
* @param g3 Shadow Green value
|
||||
* @param b3 Shadow Blue value
|
||||
* @param a3 Shadow Alpha value
|
||||
*
|
||||
* Applys the color class to the object, where the first color is the object, the second is the outline, and the third is the shadow.
|
||||
*/
|
||||
void edje_object_color_class_set (Evas_Object *obj, const char *color_class, int r, int g, int b, int a, int r2, int g2, int b2, int a2, int r3, int g3, int b3, int a3);
|
||||
|
||||
/** Sets Edje text class
|
||||
* @param text_class The text class name
|
||||
* @param font Font name
|
||||
* @param size Font Size
|
||||
*
|
||||
* Sets the text class for the Edje.
|
||||
*/
|
||||
void edje_object_text_class_set (Evas_Object *obj, const char *text_class, const char *font, Evas_Font_Size size);
|
||||
|
||||
/** Get the minimum size for an object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param minw Minimum width pointer
|
||||
* @param minh Minimum height pointer
|
||||
*
|
||||
* Gets the object's minimum size values from the Edje. These are set to zero if no Edje is connected to the Evas Object.
|
||||
*/
|
||||
void edje_object_size_min_get (Evas_Object *obj, Evas_Coord *minw, Evas_Coord *minh);
|
||||
|
||||
/** Get the maximum size for an object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param maxw Maximum width pointer
|
||||
* @param maxh Maximum height pointer
|
||||
*
|
||||
* Gets the object's maximum size values from the Edje. These are set to zero if no Edje is connected to the Evas Object.
|
||||
*/
|
||||
void edje_object_size_max_get (Evas_Object *obj, Evas_Coord *maxw, Evas_Coord *maxh);
|
||||
|
||||
/** Calculate minimum size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param minw Minimum width pointer
|
||||
* @param minh Minimum height pointer
|
||||
*
|
||||
* Calculates the object's minimum size ?!
|
||||
*/
|
||||
void edje_object_size_min_calc (Evas_Object *obj, Evas_Coord *minw, Evas_Coord *minh);
|
||||
|
||||
/** Check if Edje part exists
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name to check
|
||||
* @return 0 on Error\n
|
||||
* 1 if Edje part exists
|
||||
*/
|
||||
int edje_object_part_exists (Evas_Object *obj, const char *part);
|
||||
|
||||
/** Get Edje part geometry
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The Edje part
|
||||
* @param x The x coordinate pointer
|
||||
* @param y The y coordinate pointer
|
||||
* @param w The width pointer
|
||||
* @param h The height pointer
|
||||
*
|
||||
* Gets the Edje part geometry
|
||||
*/
|
||||
void edje_object_part_geometry_get (Evas_Object *obj, const char *part, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h);
|
||||
|
||||
/** Sets the callback to be called when text for the specified part is changed
|
||||
* @param obj A valid Evas Object handle
|
||||
* @param part The part name
|
||||
* @param func The function callback to call when text has been changed
|
||||
* @param data The data to pass to the callback's data parameter
|
||||
*/
|
||||
void edje_object_text_change_cb_set(Evas_Object *obj, void (*func) (void *data, Evas_Object *obj, const char *part), void *data);
|
||||
|
||||
/** Sets the text for an object part
|
||||
* @param obj A valid Evas Object handle
|
||||
* @param part The part name
|
||||
* @param text The text string
|
||||
*/
|
||||
void edje_object_part_text_set (Evas_Object *obj, const char *part, const char *text);
|
||||
|
||||
/** Returns the text of the object part
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @return The text string
|
||||
*/
|
||||
const char *edje_object_part_text_get (Evas_Object *obj, const char *part);
|
||||
|
||||
/** Swallows an object into the edje
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param obj_swallow The object to swallow
|
||||
*
|
||||
* Describe swallowing ?!
|
||||
*/
|
||||
void edje_object_part_swallow (Evas_Object *obj, const char *part, Evas_Object *obj_swallow);
|
||||
|
||||
/** Unswallow an object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param obj_swallow The swallowed object
|
||||
*
|
||||
* Describe unswallowing ?!
|
||||
*/
|
||||
void edje_object_part_unswallow (Evas_Object *obj, Evas_Object *obj_swallow);
|
||||
|
||||
/** Get the swallowed part ?!
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @return The swallowed object
|
||||
*/
|
||||
Evas_Object *edje_object_part_swallow_get (Evas_Object *obj, const char *part);
|
||||
|
||||
/** Returns the state of the edje part
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param val_ret
|
||||
*
|
||||
* @return The part state:\n
|
||||
* "default" for the default state\n
|
||||
* "" for other states
|
||||
*/
|
||||
/* FIXME: Correctly return other states */
|
||||
const char *edje_object_part_state_get (Evas_Object *obj, const char *part, double *val_ret);
|
||||
|
||||
/** Determine if part is dragable ?!
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
*
|
||||
* @return 1 if dragable
|
||||
* 0 if Error/not ?!
|
||||
*/
|
||||
int edje_object_part_drag_dir_get (Evas_Object *obj, const char *part);
|
||||
|
||||
/** Set drag value
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx Change in x ?!
|
||||
* @param dy Change in y ?!
|
||||
*/
|
||||
void edje_object_part_drag_value_set (Evas_Object *obj, const char *part, double dx, double dy);
|
||||
|
||||
/** Get the part drag value
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The dx pointer
|
||||
* @param dy The dy pointer
|
||||
*
|
||||
* Gets the drag values for the object part ?!
|
||||
*/
|
||||
void edje_object_part_drag_value_get (Evas_Object *obj, const char *part, double *dx, double *dy);
|
||||
|
||||
/** Set the drag size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dw The drag width
|
||||
* @param dh The drag height
|
||||
*
|
||||
* Does?!
|
||||
*/
|
||||
void edje_object_part_drag_size_set (Evas_Object *obj, const char *part, double dw, double dh);
|
||||
|
||||
/** Get the drag size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dw The drag width pointer
|
||||
* @param dh The drag height pointer
|
||||
*
|
||||
* Gets the drag size for the Edje object.
|
||||
*/
|
||||
void edje_object_part_drag_size_get (Evas_Object *obj, const char *part, double *dw, double *dh);
|
||||
|
||||
/** Sets the drag step
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x step
|
||||
* @param dy The y step
|
||||
*
|
||||
* Sets the x and y step.?!
|
||||
*/
|
||||
void edje_object_part_drag_step_set (Evas_Object *obj, const char *part, double dx, double dy);
|
||||
|
||||
/** Gets the drag step
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part
|
||||
* @param dx The x step pointer
|
||||
* @param dy The y step pointer
|
||||
*
|
||||
* Gets the x and y step for the Edje object ?!
|
||||
*/
|
||||
void edje_object_part_drag_step_get (Evas_Object *obj, const char *part, double *dx, double *dy);
|
||||
|
||||
/** Sets the drag page
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx ?!
|
||||
* @param df ?!
|
||||
*
|
||||
* Sets the drag page dx dy
|
||||
*/
|
||||
void edje_object_part_drag_page_set (Evas_Object *obj, const char *part, double dx, double dy);
|
||||
|
||||
/** Gets the drag page
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x drag pointer
|
||||
* @param dy The y drag pointer
|
||||
*
|
||||
* Gets the x and y drag page settings.
|
||||
*/
|
||||
void edje_object_part_drag_page_get (Evas_Object *obj, const char *part, double *dx, double *dy);
|
||||
|
||||
/** Step now ?!
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x step
|
||||
* @param dy The y step
|
||||
*
|
||||
* Steps x,y ?!
|
||||
*/
|
||||
void edje_object_part_drag_step (Evas_Object *obj, const char *part, double dx, double dy);
|
||||
|
||||
/** Page now
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x page
|
||||
* @param dy The y page
|
||||
*
|
||||
* Pages x,y ?!
|
||||
*/
|
||||
void edje_object_part_drag_page (Evas_Object *obj, const char *part, double dx, double dy);
|
||||
|
||||
/** Returns the variable ID
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param name The variable name
|
||||
*
|
||||
* @return Variable ID\n
|
||||
* 0 on Error.
|
||||
*/
|
||||
/* edje_misc.c */
|
||||
int edje_object_variable_id_get (Evas_Object *obj, char *name);
|
||||
|
||||
/** Returns the variable int
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
*
|
||||
* @return Variable int\n
|
||||
* 0 on Error
|
||||
*/
|
||||
int edje_object_variable_int_get (Evas_Object *obj, int id);
|
||||
|
||||
/** Sets the variable int
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
* @param val The int value to set
|
||||
*/
|
||||
void edje_object_variable_int_set (Evas_Object *obj, int id, int val);
|
||||
|
||||
/** Returns the variable float
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
*
|
||||
* @return Variable float\n
|
||||
* 0 on Error
|
||||
*/
|
||||
double edje_object_variable_float_get (Evas_Object *obj, int id);
|
||||
|
||||
/** Sets the variable float
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
* @param val The float value to set
|
||||
*/
|
||||
void edje_object_variable_float_set (Evas_Object *obj, int id, double val);
|
||||
|
||||
/** Returns the variable string
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
*
|
||||
* @return Variable String\n
|
||||
* 0 on Error
|
||||
*/
|
||||
char *edje_object_variable_str_get (Evas_Object *obj, int id);
|
||||
|
||||
/** Sets the variable string
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
* @param str The string value to set
|
||||
*/
|
||||
void edje_object_variable_str_set (Evas_Object *obj, int id, char *str);
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
|
@ -8,7 +8,18 @@ static void _edje_collection_free_part_description_free(Edje_Part_Description *d
|
|||
static int _edje_collection_free_prog_cache_matches_free_cb(Evas_Hash *hash, const char *key, void *data, void *fdata);
|
||||
#endif
|
||||
|
||||
/* API Routines */
|
||||
/************************** API Routines **************************/
|
||||
|
||||
/* FIXDOC: Verify/expand doc */
|
||||
/** Sets the .eet file to be used
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param file The path to the .eet file
|
||||
* @param part The group name in the eet
|
||||
* @return 0 on Error\n
|
||||
* 1 on Success and sets EDJE_LOAD_ERROR_NONE
|
||||
*
|
||||
* This loads the .eet file and sets up the Edje.
|
||||
*/
|
||||
int
|
||||
edje_object_file_set(Evas_Object *obj, const char *file, const char *part)
|
||||
{
|
||||
|
@ -244,6 +255,14 @@ edje_object_file_set(Evas_Object *obj, const char *file, const char *part)
|
|||
return 1;
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/expand doc. */
|
||||
/** Get the .eet location and group for the Evas Object. ?! Assuming eet file
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param file The .eet file location pointer
|
||||
* @param part The eet part pointer
|
||||
*
|
||||
* This gets the .eet file location and group for the given Evas_Object.
|
||||
*/
|
||||
void
|
||||
edje_object_file_get(Evas_Object *obj, const char **file, const char **part)
|
||||
{
|
||||
|
@ -260,6 +279,20 @@ edje_object_file_get(Evas_Object *obj, const char **file, const char **part)
|
|||
if (part) *part = ed->part;
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify. return error? */
|
||||
/** Gets the Edje load error
|
||||
* @param obj A valid Evas_Object handle
|
||||
*
|
||||
* @return The Edje load error:\n
|
||||
* 0: No Error\n
|
||||
* 1: Generic Error\n
|
||||
* 2: Does not Exist\n
|
||||
* 3: Permission Denied\n
|
||||
* 4: Resource Allocation Failed\n
|
||||
* 5: Corrupt File\n
|
||||
* 6: Unknown Format\n
|
||||
* 7: Incompatible File
|
||||
*/
|
||||
int
|
||||
edje_object_load_error_get(Evas_Object *obj)
|
||||
{
|
||||
|
@ -270,6 +303,12 @@ edje_object_load_error_get(Evas_Object *obj)
|
|||
return ed->load_error;
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/expand */
|
||||
/** Get the collection list from the edje file ?
|
||||
* @param file The file path?
|
||||
*
|
||||
* @return The Evas_List of files
|
||||
*/
|
||||
Evas_List *
|
||||
edje_file_collection_list(const char *file)
|
||||
{
|
||||
|
@ -313,6 +352,12 @@ edje_file_collection_list(const char *file)
|
|||
return lst;
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Free file collection
|
||||
* @param lst The Evas_List of files
|
||||
*
|
||||
* Frees the file collection.
|
||||
*/
|
||||
void
|
||||
edje_file_collection_list_free(Evas_List *lst)
|
||||
{
|
||||
|
@ -323,6 +368,12 @@ edje_file_collection_list_free(Evas_List *lst)
|
|||
}
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Get edje file data
|
||||
* @param file The file
|
||||
* @param key The data key
|
||||
* @return The file data string
|
||||
*/
|
||||
char *
|
||||
edje_file_data_get(const char *file, const char *key)
|
||||
{
|
||||
|
|
|
@ -3,6 +3,12 @@
|
|||
|
||||
static int initted = 0;
|
||||
|
||||
/************************** API Routines **************************/
|
||||
|
||||
/** Initialize the EDJE library.
|
||||
*
|
||||
* @return The new init count.
|
||||
*/
|
||||
int
|
||||
edje_init(void)
|
||||
{
|
||||
|
@ -16,6 +22,10 @@ edje_init(void)
|
|||
return initted;
|
||||
}
|
||||
|
||||
/** Shutdown the EET library.
|
||||
*
|
||||
* @return The new init count.
|
||||
*/
|
||||
int
|
||||
edje_shutdown(void)
|
||||
{
|
||||
|
@ -30,6 +40,8 @@ edje_shutdown(void)
|
|||
return 0;
|
||||
}
|
||||
|
||||
/* Private Routines */
|
||||
|
||||
Edje *
|
||||
_edje_add(Evas_Object *obj)
|
||||
{
|
||||
|
|
|
@ -1,6 +1,16 @@
|
|||
#include "Edje.h"
|
||||
#include "edje_private.h"
|
||||
|
||||
/************************** API Routines **************************/
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Returns the variable ID
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param name The variable name
|
||||
*
|
||||
* @return Variable ID\n
|
||||
* 0 on Error.
|
||||
*/
|
||||
int
|
||||
edje_object_variable_id_get(Evas_Object *obj, char *name)
|
||||
{
|
||||
|
@ -12,6 +22,14 @@ edje_object_variable_id_get(Evas_Object *obj, char *name)
|
|||
return _edje_var_string_id_get(ed, name);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Returns the variable int
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
*
|
||||
* @return Variable int\n
|
||||
* 0 on Error
|
||||
*/
|
||||
int
|
||||
edje_object_variable_int_get(Evas_Object *obj, int id)
|
||||
{
|
||||
|
@ -22,6 +40,12 @@ edje_object_variable_int_get(Evas_Object *obj, int id)
|
|||
return _edje_var_int_get(ed, id);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Sets the variable int
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
* @param val The int value to set
|
||||
*/
|
||||
void
|
||||
edje_object_variable_int_set(Evas_Object *obj, int id, int val)
|
||||
{
|
||||
|
@ -32,6 +56,14 @@ edje_object_variable_int_set(Evas_Object *obj, int id, int val)
|
|||
_edje_var_int_set(ed, id, val);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Returns the variable float
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
*
|
||||
* @return Variable float\n
|
||||
* 0 on Error
|
||||
*/
|
||||
double
|
||||
edje_object_variable_float_get(Evas_Object *obj, int id)
|
||||
{
|
||||
|
@ -42,6 +74,12 @@ edje_object_variable_float_get(Evas_Object *obj, int id)
|
|||
return _edje_var_float_get(ed, id);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Sets the variable float
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
* @param val The float value to set
|
||||
*/
|
||||
void
|
||||
edje_object_variable_float_set(Evas_Object *obj, int id, double val)
|
||||
{
|
||||
|
@ -52,6 +90,14 @@ edje_object_variable_float_set(Evas_Object *obj, int id, double val)
|
|||
_edje_var_float_set(ed, id, val);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Returns the variable string
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
*
|
||||
* @return Variable String\n
|
||||
* 0 on Error
|
||||
*/
|
||||
char *
|
||||
edje_object_variable_str_get(Evas_Object *obj, int id)
|
||||
{
|
||||
|
@ -65,6 +111,12 @@ edje_object_variable_str_get(Evas_Object *obj, int id)
|
|||
return strdup(s);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Sets the variable string
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param id The variable id
|
||||
* @param str The string value to set
|
||||
*/
|
||||
void
|
||||
edje_object_variable_str_set(Evas_Object *obj, int id, char *str)
|
||||
{
|
||||
|
|
|
@ -9,7 +9,14 @@ int _edje_anim_count = 0;
|
|||
Ecore_Timer *_edje_timer = NULL;
|
||||
Evas_List *_edje_animators = NULL;
|
||||
|
||||
/* API Routines */
|
||||
/************************** API Routines **************************/
|
||||
|
||||
/* FIXDOC: Expand */
|
||||
/** Set the frametime
|
||||
* @param t The frametime
|
||||
*
|
||||
* Sets the frametime in seconds, by default this is 1/60.
|
||||
*/
|
||||
void
|
||||
edje_frametime_set(double t)
|
||||
{
|
||||
|
@ -23,12 +30,27 @@ edje_frametime_set(double t)
|
|||
_edje_var_anim_frametime_reset();
|
||||
}
|
||||
|
||||
/* FIXDOC: Expand */
|
||||
/** Get the frametime
|
||||
* @return The frametime
|
||||
*
|
||||
* Returns the frametime in seconds, by default this is 1/60.
|
||||
*/
|
||||
double
|
||||
edje_frametime_get(void)
|
||||
{
|
||||
return _edje_frametime;
|
||||
}
|
||||
|
||||
/* FIXDOC: Expand */
|
||||
/** Adds a callback for the object.
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param emission Signal to activate callback FIXDOC: Naming Convention?
|
||||
* @param source Source of signal
|
||||
* @param func The function to be executed when the callback is signaled
|
||||
*
|
||||
* Creates a callback for the object to execute the given function.
|
||||
*/
|
||||
void
|
||||
edje_object_signal_callback_add(Evas_Object *obj, const char *emission, const char *source, void (*func) (void *data, Evas_Object *o, const char *emission, const char *source), void *data)
|
||||
{
|
||||
|
@ -52,6 +74,14 @@ edje_object_signal_callback_add(Evas_Object *obj, const char *emission, const ch
|
|||
}
|
||||
}
|
||||
|
||||
/* FIXDOC: Expand */
|
||||
/** Delete an object's callback
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param emission ? FIXDOC
|
||||
* @param source ? FIXDOC
|
||||
*
|
||||
* Deletes an existing callback
|
||||
*/
|
||||
void *
|
||||
edje_object_signal_callback_del(Evas_Object *obj, const char *emission, const char *source, void (*func) (void *data, Evas_Object *o, const char *emission, const char *source))
|
||||
{
|
||||
|
@ -92,6 +122,14 @@ edje_object_signal_callback_del(Evas_Object *obj, const char *emission, const ch
|
|||
return NULL;
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Send a signal to the Edje
|
||||
* @param A vaild Evas_Object handle
|
||||
* @param emission The signal
|
||||
* @param source The signal source
|
||||
*
|
||||
* This sends a signal to the edje. These are defined in the programs section of an edc.
|
||||
*/
|
||||
void
|
||||
edje_object_signal_emit(Evas_Object *obj, const char *emission, const char *source)
|
||||
{
|
||||
|
@ -104,6 +142,13 @@ edje_object_signal_emit(Evas_Object *obj, const char *emission, const char *sour
|
|||
_edje_emit(ed, (char *)emission, (char *)source);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Set the Edje to play or pause
|
||||
* @param obj A vaild Evas_Object handle
|
||||
* @param play Play instruction (1 to play, 0 to pause)
|
||||
*
|
||||
* This sets the Edje to play or pause depending on the parameter. This has no effect if the Edje is already in that state.
|
||||
*/
|
||||
void
|
||||
edje_object_play_set(Evas_Object *obj, int play)
|
||||
{
|
||||
|
@ -135,6 +180,12 @@ edje_object_play_set(Evas_Object *obj, int play)
|
|||
}
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Get the Edje play/pause state
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return 0 if Edje not connected, Edje delete_me, or Edje paused\n
|
||||
* 1 if Edje set to play
|
||||
*/
|
||||
int
|
||||
edje_object_play_get(Evas_Object *obj)
|
||||
{
|
||||
|
@ -147,6 +198,13 @@ edje_object_play_get(Evas_Object *obj)
|
|||
return 1;
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Set Animation state
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param on Animation State
|
||||
*
|
||||
* Stop or start an Edje animation.
|
||||
*/
|
||||
void
|
||||
edje_object_animation_set(Evas_Object *obj, int on)
|
||||
{
|
||||
|
@ -193,6 +251,12 @@ edje_object_animation_set(Evas_Object *obj, int on)
|
|||
_edje_unblock(ed);
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Get the animation state
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return 0 on Error or if not animated\n
|
||||
* 1 if animated
|
||||
*/
|
||||
int
|
||||
edje_object_animation_get(Evas_Object *obj)
|
||||
{
|
||||
|
|
|
@ -20,7 +20,15 @@ static Evas_Smart *_edje_smart = NULL;
|
|||
|
||||
Evas_List *_edje_edjes = NULL;
|
||||
|
||||
/* API Routines */
|
||||
/************************** API Routines **************************/
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Contructs the edje object
|
||||
* @param evas A valid Evas handle
|
||||
* @return The Evas_Object pointer.
|
||||
*
|
||||
* Creates the edje smart object, returning the Evas_Object handle.
|
||||
*/
|
||||
Evas_Object *
|
||||
edje_object_add(Evas *evas)
|
||||
{
|
||||
|
|
|
@ -7,6 +7,14 @@ Evas_Hash *_edje_color_class_member_hash = NULL;
|
|||
Evas_Hash *_edje_text_class_hash = NULL;
|
||||
Evas_Hash *_edje_text_class_member_hash = NULL;
|
||||
|
||||
|
||||
/************************** API Routines **************************/
|
||||
|
||||
/* FIXDOC: These all need to be looked over, Verified/Expanded upon. I just got lazy and stopped putting FIXDOC next to each function in this file. */
|
||||
|
||||
/* FIXDOC: Expand */
|
||||
/** Freeze all objects in the Edje.
|
||||
*/
|
||||
void
|
||||
edje_freeze(void)
|
||||
{
|
||||
|
@ -16,6 +24,9 @@ edje_freeze(void)
|
|||
edje_object_freeze((Evas_Object *)(l->data));
|
||||
}
|
||||
|
||||
/* FIXDOC: Expand */
|
||||
/** Thaw all objects in Edje
|
||||
*/
|
||||
void
|
||||
edje_thaw(void)
|
||||
{
|
||||
|
@ -25,6 +36,12 @@ edje_thaw(void)
|
|||
edje_object_thaw((Evas_Object *)(l->data));
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Get Edje object data
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param key The data key
|
||||
* @return The data string
|
||||
*/
|
||||
const char *
|
||||
edje_object_data_get(Evas_Object *obj, const char *key)
|
||||
{
|
||||
|
@ -45,6 +62,14 @@ edje_object_data_get(Evas_Object *obj, const char *key)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
/* FIXDOC: Verify/Expand */
|
||||
/** Freeze object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return The frozen state\n
|
||||
* 0 on Error
|
||||
*
|
||||
* This puts all changes on hold. Successive freezes will nest, requiring an equal number of thaws.
|
||||
*/
|
||||
int
|
||||
edje_object_freeze(Evas_Object *obj)
|
||||
{
|
||||
|
@ -55,6 +80,13 @@ edje_object_freeze(Evas_Object *obj)
|
|||
return _edje_freeze(ed);
|
||||
}
|
||||
|
||||
/** Thaw object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @return The frozen state\n
|
||||
* 0 on Error
|
||||
*
|
||||
* This allows frozen changes to occur.
|
||||
*/
|
||||
int
|
||||
edje_object_thaw(Evas_Object *obj)
|
||||
{
|
||||
|
@ -65,6 +97,23 @@ edje_object_thaw(Evas_Object *obj)
|
|||
return _edje_thaw(ed);
|
||||
}
|
||||
|
||||
/** Set Edje color class
|
||||
* @param color_class
|
||||
* @param r Object Red value
|
||||
* @param g Object Green value
|
||||
* @param b Object Blue value
|
||||
* @param a Object Alpha value
|
||||
* @param r2 Outline Red value
|
||||
* @param g2 Outline Green value
|
||||
* @param b2 Outline Blue value
|
||||
* @param a2 Outline Alpha value
|
||||
* @param r3 Shadow Red value
|
||||
* @param g3 Shadow Green value
|
||||
* @param b3 Shadow Blue value
|
||||
* @param a3 Shadow Alpha value
|
||||
*
|
||||
* Sets the color class for the Edje.
|
||||
*/
|
||||
void
|
||||
edje_color_class_set(const char *color_class, int r, int g, int b, int a, int r2, int g2, int b2, int a2, int r3, int g3, int b3, int a3)
|
||||
{
|
||||
|
@ -134,6 +183,23 @@ edje_color_class_set(const char *color_class, int r, int g, int b, int a, int r2
|
|||
}
|
||||
}
|
||||
|
||||
/** Sets the object color class
|
||||
* @param color_class
|
||||
* @param r Object Red value
|
||||
* @param g Object Green value
|
||||
* @param b Object Blue value
|
||||
* @param a Object Alpha value
|
||||
* @param r2 Outline Red value
|
||||
* @param g2 Outline Green value
|
||||
* @param b2 Outline Blue value
|
||||
* @param a2 Outline Alpha value
|
||||
* @param r3 Shadow Red value
|
||||
* @param g3 Shadow Green value
|
||||
* @param b3 Shadow Blue value
|
||||
* @param a3 Shadow Alpha value
|
||||
*
|
||||
* Applys the color class to the object, where the first color is the object, the second is the outline, and the third is the shadow.
|
||||
*/
|
||||
void
|
||||
edje_object_color_class_set(Evas_Object *obj, const char *color_class, int r, int g, int b, int a, int r2, int g2, int b2, int a2, int r3, int g3, int b3, int a3)
|
||||
{
|
||||
|
@ -205,6 +271,13 @@ edje_object_color_class_set(Evas_Object *obj, const char *color_class, int r, in
|
|||
_edje_recalc(ed);
|
||||
}
|
||||
|
||||
/** Set the Edje text class
|
||||
* @param text_class The text class name ?!
|
||||
* @param font The font name
|
||||
* @param size The font size
|
||||
*
|
||||
* This sets the Edje text class ?!
|
||||
*/
|
||||
void
|
||||
edje_text_class_set(const char *text_class, const char *font, Evas_Font_Size size)
|
||||
{
|
||||
|
@ -264,6 +337,13 @@ edje_text_class_set(const char *text_class, const char *font, Evas_Font_Size siz
|
|||
}
|
||||
}
|
||||
|
||||
/** Sets Edje text class
|
||||
* @param text_class The text class name
|
||||
* @param font Font name
|
||||
* @param size Font Size
|
||||
*
|
||||
* Sets the text class for the Edje.
|
||||
*/
|
||||
void
|
||||
edje_object_text_class_set(Evas_Object *obj, const char *text_class, const char *font, Evas_Font_Size size)
|
||||
{
|
||||
|
@ -311,6 +391,12 @@ edje_object_text_class_set(Evas_Object *obj, const char *text_class, const char
|
|||
_edje_recalc(ed);
|
||||
}
|
||||
|
||||
/** Check if Edje part exists
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name to check
|
||||
* @return 0 on Error\n
|
||||
* 1 if Edje part exists
|
||||
*/
|
||||
int
|
||||
edje_object_part_exists(Evas_Object *obj, const char *part)
|
||||
{
|
||||
|
@ -324,6 +410,16 @@ edje_object_part_exists(Evas_Object *obj, const char *part)
|
|||
return 1;
|
||||
}
|
||||
|
||||
/** Get Edje part geometry
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The Edje part
|
||||
* @param x The x coordinate pointer
|
||||
* @param y The y coordinate pointer
|
||||
* @param w The width pointer
|
||||
* @param h The height pointer
|
||||
*
|
||||
* Gets the Edje part geometry
|
||||
*/
|
||||
void
|
||||
edje_object_part_geometry_get(Evas_Object *obj, const char *part, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h )
|
||||
{
|
||||
|
@ -354,6 +450,7 @@ edje_object_part_geometry_get(Evas_Object *obj, const char *part, Evas_Coord *x,
|
|||
if (h) *h = rp->h;
|
||||
}
|
||||
|
||||
/* FIXDOC: New Function */
|
||||
void
|
||||
edje_object_text_change_cb_set(Evas_Object *obj, void (*func) (void *data, Evas_Object *obj, const char *part), void *data)
|
||||
{
|
||||
|
@ -366,6 +463,11 @@ edje_object_text_change_cb_set(Evas_Object *obj, void (*func) (void *data, Evas_
|
|||
ed->text_change.data = data;
|
||||
}
|
||||
|
||||
/** Sets the text for an object part
|
||||
* @param obj A valid Evas Object handle
|
||||
* @param part The part name
|
||||
* @param text The text string
|
||||
*/
|
||||
void
|
||||
edje_object_part_text_set(Evas_Object *obj, const char *part, const char *text)
|
||||
{
|
||||
|
@ -389,6 +491,11 @@ edje_object_part_text_set(Evas_Object *obj, const char *part, const char *text)
|
|||
if (ed->text_change.func) ed->text_change.func(ed->text_change.data, obj, part);
|
||||
}
|
||||
|
||||
/** Returns the text of the object part
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @return The text string
|
||||
*/
|
||||
const char *
|
||||
edje_object_part_text_get(Evas_Object *obj, const char *part)
|
||||
{
|
||||
|
@ -404,6 +511,13 @@ edje_object_part_text_get(Evas_Object *obj, const char *part)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
/** Swallows an object into the edje
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param obj_swallow The object to swallow
|
||||
*
|
||||
* Swallows the object into the edje part so that all geometry changes for the part affect the swallowed object. (e.g. resize, move, show, raise/lower, etc.)
|
||||
*/
|
||||
void
|
||||
edje_object_part_swallow(Evas_Object *obj, const char *part, Evas_Object *obj_swallow)
|
||||
{
|
||||
|
@ -480,6 +594,13 @@ edje_object_part_swallow(Evas_Object *obj, const char *part, Evas_Object *obj_sw
|
|||
_edje_recalc(ed);
|
||||
}
|
||||
|
||||
/** Set the object minimum size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param minw The minimum width
|
||||
* @param minh The minimum height
|
||||
*
|
||||
* This sets the minimum size restriction for the object.
|
||||
*/
|
||||
void
|
||||
edje_extern_object_min_size_set(Evas_Object *obj, Evas_Coord minw, Evas_Coord minh)
|
||||
{
|
||||
|
@ -499,6 +620,13 @@ edje_extern_object_min_size_set(Evas_Object *obj, Evas_Coord minw, Evas_Coord mi
|
|||
evas_object_data_del(obj, "\377 edje.minh");
|
||||
}
|
||||
|
||||
/** Set the object maximum size
|
||||
* @param obj A vaild Evas_Object handle
|
||||
* @param maxw The maximum width
|
||||
* @param maxh The maximum height
|
||||
*
|
||||
* This sets the maximum size restriction for the object.
|
||||
*/
|
||||
void
|
||||
edje_extern_object_max_size_set(Evas_Object *obj, Evas_Coord maxw, Evas_Coord maxh)
|
||||
{
|
||||
|
@ -516,6 +644,12 @@ edje_extern_object_max_size_set(Evas_Object *obj, Evas_Coord maxw, Evas_Coord ma
|
|||
evas_object_data_del(obj, "\377 edje.maxh");
|
||||
}
|
||||
|
||||
/** Unswallow an object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param obj_swallow The swallowed object
|
||||
*
|
||||
* Causes the edje to regurgitate a previously swallowed object. :)
|
||||
*/
|
||||
void
|
||||
edje_object_part_unswallow(Evas_Object *obj, Evas_Object *obj_swallow)
|
||||
{
|
||||
|
@ -548,6 +682,11 @@ edje_object_part_unswallow(Evas_Object *obj, Evas_Object *obj_swallow)
|
|||
}
|
||||
}
|
||||
|
||||
/** Get the swallowed part ?!
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @return The swallowed object
|
||||
*/
|
||||
Evas_Object *
|
||||
edje_object_part_swallow_get(Evas_Object *obj, const char *part)
|
||||
{
|
||||
|
@ -561,6 +700,13 @@ edje_object_part_swallow_get(Evas_Object *obj, const char *part)
|
|||
return rp->swallowed_object;
|
||||
}
|
||||
|
||||
/** Get the minimum size for an object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param minw Minimum width pointer
|
||||
* @param minh Minimum height pointer
|
||||
*
|
||||
* Gets the object's minimum size values from the Edje. These are set to zero if no Edje is connected to the Evas Object.
|
||||
*/
|
||||
void
|
||||
edje_object_size_min_get(Evas_Object *obj, Evas_Coord *minw, Evas_Coord *minh)
|
||||
{
|
||||
|
@ -577,6 +723,13 @@ edje_object_size_min_get(Evas_Object *obj, Evas_Coord *minw, Evas_Coord *minh)
|
|||
if (minh) *minh = ed->collection->prop.min.h;
|
||||
}
|
||||
|
||||
/** Get the maximum size for an object
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param maxw Maximum width pointer
|
||||
* @param maxh Maximum height pointer
|
||||
*
|
||||
* Gets the object's maximum size values from the Edje. These are set to zero if no Edje is connected to the Evas Object.
|
||||
*/
|
||||
void
|
||||
edje_object_size_max_get(Evas_Object *obj, Evas_Coord *maxw, Evas_Coord *maxh)
|
||||
{
|
||||
|
@ -607,6 +760,13 @@ edje_object_size_max_get(Evas_Object *obj, Evas_Coord *maxw, Evas_Coord *maxh)
|
|||
}
|
||||
}
|
||||
|
||||
/** Calculate minimum size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param minw Minimum width pointer
|
||||
* @param minh Minimum height pointer
|
||||
*
|
||||
* Calculates the object's minimum size ?!
|
||||
*/
|
||||
void
|
||||
edje_object_size_min_calc(Evas_Object *obj, Evas_Coord *minw, Evas_Coord *minh)
|
||||
{
|
||||
|
@ -677,6 +837,16 @@ edje_object_size_min_calc(Evas_Object *obj, Evas_Coord *minw, Evas_Coord *minh)
|
|||
ed->calc_only = 0;
|
||||
}
|
||||
|
||||
/** Returns the state of the edje part
|
||||
* @param obj A valid Evas_Objectart handle
|
||||
* @param part The part name
|
||||
* @param val_ret
|
||||
*
|
||||
* @return The part state:\n
|
||||
* "default" for the default state\n
|
||||
* "" for other states
|
||||
*/
|
||||
/* FIXME: Correctly return other states */
|
||||
const char *
|
||||
edje_object_part_state_get(Evas_Object *obj, const char *part, double *val_ret)
|
||||
{
|
||||
|
@ -716,6 +886,15 @@ edje_object_part_state_get(Evas_Object *obj, const char *part, double *val_ret)
|
|||
return "";
|
||||
}
|
||||
|
||||
/** Determine dragable directions
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
*
|
||||
* @return 0: Not dragable\n
|
||||
* 1: Dragable in X direction\n
|
||||
* 2: Dragable in Y direction\n
|
||||
* 3: Dragable in X & Y directions
|
||||
*/
|
||||
int
|
||||
edje_object_part_drag_dir_get(Evas_Object *obj, const char *part)
|
||||
{
|
||||
|
@ -738,6 +917,14 @@ edje_object_part_drag_dir_get(Evas_Object *obj, const char *part)
|
|||
return EDJE_DRAG_DIR_NONE;
|
||||
}
|
||||
|
||||
/** Set the dragable object location
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x value
|
||||
* @param dy The y value
|
||||
*
|
||||
* Places the dragable object at the given location.
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_value_set(Evas_Object *obj, const char *part, double dx, double dy)
|
||||
{
|
||||
|
@ -770,7 +957,15 @@ edje_object_part_drag_value_set(Evas_Object *obj, const char *part, double dx, d
|
|||
_edje_dragable_pos_set(ed, rp, dx, dy);
|
||||
_edje_emit(ed, "drag,set", rp->part->name);
|
||||
}
|
||||
|
||||
/** Get the dragable object location
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The X value pointer
|
||||
* @param dy The Y value pointer
|
||||
*
|
||||
* Gets the drag location values.
|
||||
*/
|
||||
/* FIXME: Should this be x and y instead of dx/dy? */
|
||||
void
|
||||
edje_object_part_drag_value_get(Evas_Object *obj, const char *part, double *dx, double *dy)
|
||||
{
|
||||
|
@ -800,6 +995,14 @@ edje_object_part_drag_value_get(Evas_Object *obj, const char *part, double *dx,
|
|||
if (dy) *dy = ddy;
|
||||
}
|
||||
|
||||
/** Set the dragable object size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dw The drag width
|
||||
* @param dh The drag height
|
||||
*
|
||||
* Sets the size of the dragable object
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_size_set(Evas_Object *obj, const char *part, double dw, double dh)
|
||||
{
|
||||
|
@ -827,6 +1030,14 @@ edje_object_part_drag_size_set(Evas_Object *obj, const char *part, double dw, do
|
|||
_edje_recalc(ed);
|
||||
}
|
||||
|
||||
/** Get the dragable object size
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dw The drag width pointer
|
||||
* @param dh The drag height pointer
|
||||
*
|
||||
* Gets the dragable object size.
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_size_get(Evas_Object *obj, const char *part, double *dw, double *dh)
|
||||
{
|
||||
|
@ -851,6 +1062,14 @@ edje_object_part_drag_size_get(Evas_Object *obj, const char *part, double *dw, d
|
|||
if (dh) *dh = rp->drag.size.y;
|
||||
}
|
||||
|
||||
/** Sets the drag step increment
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x step ammount
|
||||
* @param dy The y step ammount
|
||||
*
|
||||
* Sets the x,y step increments for a dragable object.
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_step_set(Evas_Object *obj, const char *part, double dx, double dy)
|
||||
{
|
||||
|
@ -876,6 +1095,14 @@ edje_object_part_drag_step_set(Evas_Object *obj, const char *part, double dx, do
|
|||
rp->drag.step.y = dy;
|
||||
}
|
||||
|
||||
/** Gets the drag step increment values.
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part
|
||||
* @param dx The x step increment pointer
|
||||
* @param dy The y step increment pointer
|
||||
*
|
||||
* Gets the x and y step increments for the dragable object.
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_step_get(Evas_Object *obj, const char *part, double *dx, double *dy)
|
||||
{
|
||||
|
@ -900,6 +1127,14 @@ edje_object_part_drag_step_get(Evas_Object *obj, const char *part, double *dx, d
|
|||
if (dy) *dy = rp->drag.step.y;
|
||||
}
|
||||
|
||||
/** Sets the page step increments
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x page step increment
|
||||
* @param df The y page step increment
|
||||
*
|
||||
* Sets the x,y page step increment values.
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_page_set(Evas_Object *obj, const char *part, double dx, double dy)
|
||||
{
|
||||
|
@ -925,6 +1160,14 @@ edje_object_part_drag_page_set(Evas_Object *obj, const char *part, double dx, do
|
|||
rp->drag.page.y = dy;
|
||||
}
|
||||
|
||||
/** Gets the page step increments
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The dx page increment pointer
|
||||
* @param dy The dy page increment pointer
|
||||
*
|
||||
* Gets the x,y page step increments for the dragable object.
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_page_get(Evas_Object *obj, const char *part, double *dx, double *dy)
|
||||
{
|
||||
|
@ -949,6 +1192,14 @@ edje_object_part_drag_page_get(Evas_Object *obj, const char *part, double *dx, d
|
|||
if (dy) *dy = rp->drag.page.y;
|
||||
}
|
||||
|
||||
/** Steps the dragable x,y steps
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x step
|
||||
* @param dy The y step
|
||||
*
|
||||
* Steps x,y where the step increment is the ammount set by edje_object_part_drag_step_set.
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_step(Evas_Object *obj, const char *part, double dx, double dy)
|
||||
{
|
||||
|
@ -980,6 +1231,15 @@ edje_object_part_drag_step(Evas_Object *obj, const char *part, double dx, double
|
|||
_edje_emit(ed, "drag,step", rp->part->name);
|
||||
}
|
||||
|
||||
/** Pages x,y steps
|
||||
* @param obj A valid Evas_Object handle
|
||||
* @param part The part name
|
||||
* @param dx The x step
|
||||
* @param dy The y step
|
||||
*
|
||||
* Pages x,y where the increment is defined by edje_object_part_drag_page_set.\n
|
||||
* WARNING: Paging is bugged!
|
||||
*/
|
||||
void
|
||||
edje_object_part_drag_page(Evas_Object *obj, const char *part, double dx, double dy)
|
||||
{
|
||||
|
@ -1013,7 +1273,7 @@ edje_object_part_drag_page(Evas_Object *obj, const char *part, double dx, double
|
|||
|
||||
|
||||
|
||||
|
||||
/* Private Routines */
|
||||
|
||||
Edje_Real_Part *
|
||||
_edje_real_part_get(Edje *ed, char *part)
|
||||
|
|
|
@ -231,7 +231,7 @@ _edje_var_string_id_get(Edje *ed, char *string)
|
|||
if (!ed) return 0;
|
||||
if (!ed->collection) return 0;
|
||||
if (!ed->collection->script) return 0;
|
||||
if (!string) return;
|
||||
if (!string) return 0;
|
||||
cell = embryo_program_variable_find(ed->collection->script, string);
|
||||
if (cell == EMBRYO_CELL_NONE) return 0;
|
||||
cptr = embryo_data_address_get(ed->collection->script, cell);
|
||||
|
|
Loading…
Reference in New Issue