1 #ifndef _EDJE_EDIT_H 2 #define _EDJE_EDIT_H 3 4 #ifndef EDJE_EDIT_IS_UNSTABLE_AND_I_KNOW_ABOUT_IT 5 #error "Do not use the Edje_Edit API unless you know what you are doing. It's meant only for writing editors and nothing else." 6 #endif 7 8 #include <Edje.h> 9 10 #ifdef EAPI 11 # undef EAPI 12 #endif 13 14 #ifdef _WIN32 15 # ifdef EFL_BUILD 16 # ifdef DLL_EXPORT 17 # define EAPI __declspec(dllexport) 18 # else 19 # define EAPI 20 # endif 21 # else 22 # define EAPI __declspec(dllimport) 23 # endif 24 #else 25 # ifdef __GNUC__ 26 # if __GNUC__ >= 4 27 # define EAPI __attribute__ ((visibility("default"))) 28 # else 29 # define EAPI 30 # endif 31 # else 32 # define EAPI 33 # endif 34 #endif 35 36 /** 37 * Compression type for the image. 38 * 39 * @ref edcref 40 */ 41 typedef enum _Edje_Edit_Image_Comp 42 { 43 EDJE_EDIT_IMAGE_COMP_RAW, 44 EDJE_EDIT_IMAGE_COMP_USER, 45 EDJE_EDIT_IMAGE_COMP_COMP, 46 EDJE_EDIT_IMAGE_COMP_LOSSY, 47 EDJE_EDIT_IMAGE_COMP_LOSSY_ETC1, 48 EDJE_EDIT_IMAGE_COMP_LOSSY_ETC2 49 } Edje_Edit_Image_Comp; 50 51 /** 52 * Mode for a textblock part. 53 * 54 * @ref edcref 55 */ 56 typedef enum _Edje_Edit_Select_Mode 57 { 58 EDJE_EDIT_SELECT_MODE_DEFAULT, 59 EDJE_EDIT_SELECT_MODE_EXPLICIT 60 } Edje_Edit_Select_Mode; 61 62 /** 63 * Sound type compression. 64 * 65 * @ref edcref 66 */ 67 typedef enum _Edje_Edit_Sound_Comp 68 { 69 EDJE_EDIT_SOUND_COMP_NONE, 70 EDJE_EDIT_SOUND_COMP_RAW, 71 EDJE_EDIT_SOUND_COMP_COMP, 72 EDJE_EDIT_SOUND_COMP_LOSSY, 73 EDJE_EDIT_SOUND_COMP_AS_IS 74 } Edje_Edit_Sound_Comp; 75 76 /** 77 * Mode for a textblock part. 78 * 79 * @ref edcref 80 */ 81 typedef enum _Edje_Edit_Entry_Mode 82 { 83 EDJE_EDIT_ENTRY_MODE_NONE, 84 EDJE_EDIT_ENTRY_MODE_PLAIN, 85 EDJE_EDIT_ENTRY_MODE_EDITABLE, 86 EDJE_EDIT_ENTRY_MODE_PASSWORD 87 } Edje_Edit_Entry_Mode; 88 89 /** 90 * @typedef Edje_Edit_Script_Error 91 * 92 * This is structure used for the list of errors that resulted from the last 93 * attempt to rebuild the Embryo script for the edited group. 94 * 95 * @see edje_edit_script_error_list_get() 96 */ 97 struct _Edje_Edit_Script_Error 98 { 99 const char *program_name; /**< name of the script, if null then it is group shared script */ 100 int line; /**< Line of the error inside in scriptcode */ 101 const char *error_str; /**< Error Message */ 102 }; 103 typedef struct _Edje_Edit_Script_Error Edje_Edit_Script_Error; 104 105 /** 106 * @typedef Edje_Part_Image_Use 107 * 108 * This is structure used for the list of group-part-state triplets where certain 109 * image is being used and pointed. 110 * 111 * @see edje_edit_image_usage_list_get() 112 * @see edje_edit_vector_usage_list_get() 113 * @see edje_edit_image_usage_list_free() 114 */ 115 struct _Edje_Part_Image_Use 116 { 117 const char *group; /**< name of group (or set) that use image */ 118 const char *part; /**< name of part that use image */ 119 struct { 120 const char *name; /**< name of the state */ 121 double value; /**< value of the state (-1 if it is set) */ 122 } state; /**< structure that contain state's information */ 123 }; 124 typedef struct _Edje_Part_Image_Use Edje_Part_Image_Use; 125 126 /** 127 * @typedef Edje_Edit_Limit 128 * 129 * This is structure used for list with the item names inside the limits block. 130 * 131 * @see edje_edit_group_limits_vertical_list_get() 132 * @see edje_edit_group_limits_horizontal_list_get() 133 * @see edje_edit_group_limits_vertical_del() 134 * @see edje_edit_group_limits_horizontal_del() 135 * @see edje_edit_group_limits_vertical_add() 136 * @see edje_edit_group_limits_horizontal_add() 137 * @see edje_edit_limits_list_free() 138 */ 139 struct _Edje_Edit_Limit 140 { 141 Eina_Stringshare *name; /**< name of the limit */ 142 int value; /**< value of the limit */ 143 }; 144 typedef struct _Edje_Edit_Limit Edje_Edit_Limit; 145 146 /** 147 * @file 148 * @brief Functions to deal with edje internal object. Don't use in standard 149 * situations. The use of any of the edje_edit_* functions can break your 150 * theme ability, remember that the program must be separated from the interface! 151 * 152 * This was intended ONLY for use in an actual edje editor program. Unless 153 * you are writing one of these, do NOT use this API here. 154 * 155 * The API can be used to query or set every part of an edje object in real time. 156 * You can manage every aspect of parts, part states, programs, script and whatever 157 * is contained in the edje file. For a reference of what all parameter means 158 * look at the complete @ref edcref. 159 * 160 * Don't forget to free all the strings and the lists returned by any edje_edit_*() 161 * functions using edje_edit_string_free() and edje_edit_string_list_free() when 162 * you don't need anymore. 163 * 164 * Example: print all the part in a loaded edje_object 165 * @code 166 * Eina_List *parts, *l; 167 * char *part; 168 * 169 * parts = edje_edit_parts_list_get(edje_object); 170 * EINA_LIST_FOREACH(parts, l, part) 171 * { 172 * printf("Part: %s\n", part); 173 * } 174 * edje_edit_string_list_free(parts); 175 * @endcode 176 * 177 * Example: Change the color of a rect inside an edje file 178 * @code 179 * Evas_Object *edje; 180 * 181 * edje = edje_edit_object_add(evas); 182 * edje_object_file_set(edje, "edj/file/name", "group to load"); 183 * edje_edit_state_color_set(edje, "MyRectName", "default", 0.00, 255, 255, 0, 255); 184 * edje_edit_save(edje); 185 * @endcode 186 * 187 */ 188 189 190 #ifdef __cplusplus 191 extern "C" { 192 #endif 193 194 /******************************************************************************/ 195 /************************** GENERAL API ***********************************/ 196 /******************************************************************************/ 197 /** 198 * @name General API 199 * General functions that don't fit in other categories. 200 */ //@{ 201 202 /** 203 * @brief Adds an editable Edje object to the canvas. 204 * An Edje_Edit object is, for the most part, a standard Edje object. Only 205 * difference is you can use the Edje_Edit API on them. 206 * 207 * @param e Evas canvas where to add the object. 208 * 209 * @return An Evas_Object of type Edje_Edit, or NULL if an error occurred. 210 */ 211 EAPI Evas_Object * edje_edit_object_add(Evas *e); 212 213 /** 214 * @brief Frees a generic Eina_List of (char *) allocated by an edje_edit_*_get() function. 215 * @param lst List of strings to free. 216 */ 217 EAPI void edje_edit_string_list_free(Eina_List *lst); 218 219 /** 220 * @brief Frees a generic string (char *) allocated by an edje_edit_*_get() function. 221 * @param str String to free. 222 */ 223 EAPI void edje_edit_string_free(const char *str); 224 225 /** 226 * @brief Gets the name of the program that compiled the edje file. 227 * Can be 'edje_cc' or 'edje_edit' 228 * 229 * @param obj Object being edited. 230 * 231 * @return Compiler stored in the Edje file 232 */ 233 EAPI const char * edje_edit_compiler_get(Evas_Object *obj); 234 235 /** 236 * @brief Saves the modified edje object back to his file. 237 * Use this function when you are done with your editing, all the change made 238 * to the current loaded group will be saved back to the original file. 239 * 240 * @note Source for the whole file will be auto generated and will overwrite 241 * any previously stored source. 242 * 243 * @param obj Object to save back to the file it was loaded from. 244 * 245 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 246 * 247 * @todo Add a way to check what the error actually was, the way Edje Load does. 248 */ 249 EAPI Eina_Bool edje_edit_save(Evas_Object *obj); 250 251 /** 252 * @brief Saves every group back into the file. 253 * @param obj Object to save. 254 * 255 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 256 * 257 * @see edje_edit_save() 258 */ 259 EAPI Eina_Bool edje_edit_save_all(Evas_Object *obj); 260 261 /** 262 * @brief Saves every group into new file. 263 * Use this function when you need clean eet dictionary in .edj file from 264 * unnecessary text entries (e.g. names of deleted groups etc.). 265 * 266 * @param obj Object to save. 267 * @param new_file_name Where to save object. File should not exist, otherwise 268 * EINA_FALSE will be returned. 269 * 270 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 271 * 272 * @see edje_edit_save() 273 */ 274 EAPI Eina_Bool edje_edit_clean_save_as(Evas_Object *obj, const char* new_file_name); 275 276 /** 277 * @brief Saves the group(s) back to the file, without generation source code. 278 * This function saves changes in group(s) back into the edj file. Process of 279 * saving takes a bit time in compare with @see edje_edit_save() and @see edje_edit_save_all(), 280 * because this function DOES NOT generate source code for groups. 281 * 282 * @note With using this function all source code will be erased. And DOES NOT 283 * generated new code. In attempt to decompile edj file, which was saved with 284 * using this functions will unpacked only resources(like fonts, images, sounds). 285 * If needed saving source code into file, please use @see edje_edit_save() or 286 * @see edje_edit_save_all(). 287 288 * @param obj Object to save back to the file it was loaded from. 289 * @param current_group EINA_TRUE if needed save only group which loaded with obj, 290 * or EINA_FALSE for save all groups, which exists in edj file. 291 * 292 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 293 * @since 1.11 294 */ 295 EAPI Eina_Bool edje_edit_without_source_save(Evas_Object *obj, Eina_Bool current_group); 296 297 /** 298 * @brief Prints on standard output many information about the internal status 299 * of the edje object. 300 * 301 * This is probably only useful to debug. 302 * 303 * @param obj Object being edited. 304 */ 305 EAPI void edje_edit_print_internal_status(Evas_Object *obj); 306 307 308 //@} 309 /******************************************************************************/ 310 /************************** GROUPS API ************************************/ 311 /******************************************************************************/ 312 /** 313 * @name Groups API 314 * Functions to deal with groups property (see @ref edcref). 315 */ //@{ 316 317 /** 318 * @brief Adds an edje (empty) group to an edje object's group set. 319 * 320 * @param obj The pointer to edje object. 321 * @param name The name of the group. 322 * 323 * @return @c EINA_TRUE If it could allocate memory to the part group added 324 * or zero if not. 325 * 326 * This function adds, at run time, one more group, which will reside 327 * in memory, to the group set found in the .edj file which @a obj was 328 * loaded with. This group can be manipulated by other API functions, 329 * like @c edje_edit_part_add(), for example. If desired, the new 330 * group can be actually committed the respective .edj by use of @c 331 * edje_edit_save(). 332 * 333 */ 334 EAPI Eina_Bool edje_edit_group_add(Evas_Object *obj, const char *name); 335 336 /** 337 * @brief Copies whole group and all it's data into separate group. 338 * 339 * @param obj The pointer to edje object. 340 * @param group_name The name of the group. 341 * @param copy_name The name of the new group that is a copy. 342 * 343 * @return @c EINA_TRUE on success, @c EINA_FALSE on failure. 344 * 345 * This function copy, at run time, a whole group, which will reside 346 * in memory, to the group set found in the .edj file which @a obj was 347 * loaded with. This group can be manipulated by other API functions, 348 * like @c edje_edit_part_add(), for example. 349 * 350 * You need to save everything to make sure the file won't have broken 351 * references the next time is loaded. 352 * @see edje_edit_save_all(), edje_edit_without_source_save(). 353 * 354 * @attention This group will copy the whole group and this operation can't be undone as all references to the group will be added to the file. 355 * (for example all scripts will be written to the file directly) 356 * 357 */ 358 EAPI Eina_Bool edje_edit_group_copy(Evas_Object *obj, const char *group_name, const char *copy_name); 359 360 /** 361 * @brief Deletes the specified group from the edje file. 362 * 363 * @param obj The pointer to the edje object. 364 * @param group_name Group to delete. 365 * 366 * @return @c EINA_TRUE on success, @c EINA_FALSE on failure. 367 * 368 * This function deletes the given group from the file @a obj is set to. This 369 * operation can't be undone as all references to the group are removed from 370 * the file. 371 * This function may fail if the group to be deleted is currently in use. 372 * You need to save everything to make sure the file won't have broken 373 * references the next time is loaded. 374 * @see edje_edit_save_all(), edje_edit_without_source_save(). 375 * 376 * @attention be careful, if you deleting group, it will delete all it's aliases also, 377 * if you deleting alias, then it will delete alias only. 378 * 379 */ 380 EAPI Eina_Bool edje_edit_group_del(Evas_Object *obj, const char *group_name); 381 382 /** 383 * @brief Checks if a group with the given name exist in the edje. 384 * @param obj Object being edited. 385 * @param group Group name to check for. 386 * 387 * @return @c EINA_TRUE if group exists, @c EINA_FALSE if not. 388 */ 389 EAPI Eina_Bool edje_edit_group_exist(Evas_Object *obj, const char *group); 390 391 /** 392 * @brief Sets a new name for the current open group. 393 * 394 * You can only rename a group that is currently loaded 395 * Note that the relative getter function don't exist as it doesn't make sense ;) 396 * @param obj Object being edited. 397 * @param new_name New name for the group. 398 * 399 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 400 */ 401 EAPI Eina_Bool edje_edit_group_name_set(Evas_Object *obj, const char *new_name); 402 403 /** 404 * @brief Gets the group minimum width. 405 * 406 * @param obj Object being edited. 407 * 408 * @return The minimum width set for the group. -1 if an error occurred. 409 */ 410 EAPI int edje_edit_group_min_w_get(Evas_Object *obj); 411 412 /** 413 * @brief Sets the group minimum width. 414 * 415 * @param obj Object being edited. 416 * @param w New minimum width for the group. 417 * 418 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 419 */ 420 EAPI Eina_Bool edje_edit_group_min_w_set(Evas_Object *obj, int w); 421 422 /** 423 * @brief Gets the group minimum height. 424 * 425 * @param obj Object being edited. 426 * 427 * @return The minimum height set for the group. @c -1 if an error occurred. 428 */ 429 EAPI int edje_edit_group_min_h_get(Evas_Object *obj); 430 431 /** 432 * @brief Sets the group minimum height. 433 * 434 * @param obj Object being edited. 435 * @param h New minimum height for the group. 436 * 437 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 438 */ 439 EAPI Eina_Bool edje_edit_group_min_h_set(Evas_Object *obj, int h); 440 441 /** 442 * @brief Gets the group maximum width. 443 * 444 * @param obj Object being edited. 445 * 446 * @return The maximum width set for the group. @c -1 if an error occurred. 447 */ 448 EAPI int edje_edit_group_max_w_get(Evas_Object *obj); 449 450 /** 451 * @brief Sets the group maximum width. 452 * 453 * @param obj Object being edited. 454 * @param w New maximum width for the group. 455 * 456 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 457 */ 458 EAPI Eina_Bool edje_edit_group_max_w_set(Evas_Object *obj, int w); 459 460 /** 461 * @brief Gets the group maximum height. 462 * 463 * @param obj Object being edited. 464 * 465 * @return The maximum height set for the group. @c -1 if an error occurred. 466 */ 467 EAPI int edje_edit_group_max_h_get(Evas_Object *obj); 468 469 /** 470 * @brief Sets the group maximum height. 471 * 472 * @param obj Object being edited. 473 * @param h New maximum height for the group. 474 * 475 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 476 */ 477 EAPI Eina_Bool edje_edit_group_max_h_set(Evas_Object *obj, int h); 478 479 /** 480 * @brief Gets the group broadcast_signal. 481 * 482 * @param obj Object being edited. 483 * 484 * @return @c EINA_FALSE if group not accept broadcast signal, @c EINA_TRUE otherwise (Default to true since 1.1.). 485 * @since 1.11 486 */ 487 EAPI Eina_Bool edje_edit_group_broadcast_signal_get(Evas_Object *obj); 488 489 /** 490 * @brief Sets the group broadcast signal. 491 * 492 * @param obj Object being edited. 493 * @param bs @c EINA_TRUE if group will accept broadcast signal, @c EINA_FALSE otherwise. 494 * 495 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 496 * @since 1.11 497 */ 498 EAPI Eina_Bool edje_edit_group_broadcast_signal_set(Evas_Object *obj, Eina_Bool bs); 499 500 //@} 501 502 503 /** 504 * @brief Retrieves a list with the item names inside the vertical limits block at the group level. 505 * 506 * @param obj Object being edited. 507 * 508 * @return List of strings, each being a name of vertical limit in the limits block for the group. 509 */ 510 EAPI Eina_List * edje_edit_group_limits_vertical_list_get(Evas_Object *obj); 511 512 /** 513 * @brief Deletes given pair name-value from the vertical limits block at the group level. 514 * 515 * @param obj Object being edited. 516 * @param name Limit name. 517 * @param value Limit value. 518 * 519 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 520 */ 521 EAPI Eina_Bool edje_edit_group_limits_vertical_del(Evas_Object *obj, const char *name, int value); 522 523 /** 524 * @brief Adds given pair name-value to the vertical limits block at the group level. 525 * 526 * @param obj Object being edited. 527 * @param name Limit name. 528 * @param value Limit value. 529 * 530 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 531 */ 532 EAPI Eina_Bool edje_edit_group_limits_vertical_add(Evas_Object *obj, const char *name, int value); 533 534 /** 535 * @brief Retrieves a list with the item names inside the horizontal limits block at the group level. 536 * 537 * @param obj Object being edited. 538 * 539 * @return List of strings, each being a name of horizontal limit in the limits block for the group. 540 */ 541 EAPI Eina_List * edje_edit_group_limits_horizontal_list_get(Evas_Object *obj); 542 543 /** 544 * @brief Deletes given pair name-value from the horizontal limits block at the group level. 545 * 546 * @param obj Object being edited. 547 * @param name Limit name. 548 * @param value Limit value. 549 * 550 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 551 */ 552 EAPI Eina_Bool edje_edit_group_limits_horizontal_del(Evas_Object *obj, const char *name, int value); 553 554 /** 555 * @brief Adds given pair name-value to the horizontal limits block at the group level. 556 * 557 * @param obj Object being edited. 558 * @param name Limit name. 559 * @param value Limit value. 560 * 561 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 562 */ 563 EAPI Eina_Bool edje_edit_group_limits_horizontal_add(Evas_Object *obj, const char *name, int value); 564 565 /** 566 @brief Frees an Eina_List of (Edje_Edit_List *) allocated by an edje_edit_limits_vertical_list_get() or edje_edit_limits_horizontal_list_get() functions. 567 * 568 * @param lst List to free. 569 */ 570 EAPI void edje_edit_limits_list_free(Eina_List *lst); 571 572 /******************************************************************************/ 573 /************************** ALIAS API **************************************/ 574 /******************************************************************************/ 575 /** 576 * @name Alias API 577 * Functions to deal with aliases that just another names of the group in the edje (see @ref edcref). 578 */ //@{ 579 580 /** 581 * @brief Retrieves a list of aliases for this group. 582 * If given group name is an alias name then this function will return NULL. 583 * 584 * @attention After you done using returned list, please use edje_edit_string_list_free to free this list. 585 * 586 * @param obj Object being edited. 587 * @param group_name Group name or alias. 588 * 589 * @return List of strings, each being a name of alias of given group or alias name. 590 */ 591 EAPI Eina_List * edje_edit_group_aliases_get(Evas_Object *obj, const char *group_name); 592 593 /** 594 * @brief Checks if this group is an alias name. 595 * 596 * @param obj Object being edited. 597 * @param alias_name Group name that is alias. 598 * 599 * @return @c EINA_TRUE if alias, @c EINA_FALSE otherwise. 600 */ 601 EAPI Eina_Bool edje_edit_group_alias_is(Evas_Object *obj, const char *alias_name); 602 603 /** 604 * @brief Returns the main group name that is aliased by given alias name. 605 * 606 * @attention After you done using this string, please use edje_edit_string_free to free this string. 607 * 608 * @param obj Object being edited. 609 * @param alias_name Group name that is alias. 610 * 611 * @return name of the main group that is being aliased. 612 */ 613 EAPI const char * edje_edit_group_aliased_get(Evas_Object *obj, const char *alias_name); 614 615 /** 616 * @brief Adds new alias to the given group. 617 * 618 * @attention when aliasing a group, be sure that the given group_name is no an alias. 619 * 620 * @param obj Object being edited. 621 * @param group_name Group name that is being aliased. 622 * @param alias_name Group name that is alias. 623 * 624 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 625 */ 626 EAPI Eina_Bool edje_edit_group_alias_add(Evas_Object *obj, const char *group_name, const char *alias_name); 627 628 //@} 629 /******************************************************************************/ 630 /************************** DATA API **************************************/ 631 /******************************************************************************/ 632 /** 633 * @name Data API 634 * Functions to deal with data embedded in the edje (see @ref edcref). 635 */ //@{ 636 637 /** 638 * @brief Retrieves a list with the item names inside the data block. 639 * 640 * @param obj Object being edited. 641 * 642 * @return List of strings, each being a name entry in the global data block for the file. 643 */ 644 EAPI Eina_List * edje_edit_data_list_get(Evas_Object *obj); 645 646 /** 647 * @brief Creates a new *global* data object in the given edje file. 648 * 649 * If another data entry with the same name exists, nothing is created and 650 * EINA_FALSE is returned. 651 * 652 * @param obj Object being edited. 653 * @param itemname Name for the new data entry. 654 * @param value Value for the new data entry. 655 * 656 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 657 */ 658 EAPI Eina_Bool edje_edit_data_add(Evas_Object *obj, const char *itemname, const char *value); 659 660 /** 661 * @brief Deletes the given data object from edje. 662 * 663 * @param obj Object being edited. 664 * @param itemname Data entry to remove from the global data block. 665 * 666 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 667 */ 668 EAPI Eina_Bool edje_edit_data_del(Evas_Object *obj, const char *itemname); 669 670 /** 671 * @brief Gets the data associated with the given itemname. 672 * 673 * @param obj Object being edited. 674 * @param itemname Name of the data entry to fetch the value for. 675 * 676 * @return Value of the given entry, or NULL if not found. 677 */ 678 EAPI const char * edje_edit_data_value_get(Evas_Object *obj, const char *itemname); 679 680 /** 681 * @brief Sets the data associated with the given itemname. 682 * 683 * @param obj Object being edited. 684 * @param itemname Name of data entry to change the value. 685 * @param value New value for the entry. 686 * 687 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 688 */ 689 EAPI Eina_Bool edje_edit_data_value_set(Evas_Object *obj, const char *itemname, const char *value); 690 691 /** 692 * @brief Changes the name of the given data object. 693 * 694 * @param obj Object being edited. 695 * @param itemname Data entry to rename. 696 * @param newname New name for the data entry. 697 * 698 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 699 */ 700 EAPI Eina_Bool edje_edit_data_name_set(Evas_Object *obj, const char *itemname, const char *newname); 701 702 /** 703 * @brief Retrieves a list with the item names inside the data block at the group level. 704 * 705 * @param obj Object being edited. 706 * 707 * @return List of strings, each being a name entry in the data block for the group. 708 */ 709 EAPI Eina_List * edje_edit_group_data_list_get(Evas_Object *obj); 710 711 /** 712 * @brief Creates a new data object in the given edje file *belonging to the current group*. 713 * 714 * If another data entry with the same name exists, 715 * nothing is created and EINA_FALSE is returned. 716 * 717 * @param obj Object being edited. 718 * @param itemname Name for the new data entry. 719 * @param value Value for the new data entry. 720 * 721 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 722 */ 723 EAPI Eina_Bool edje_edit_group_data_add(Evas_Object *obj, const char *itemname, const char *value); 724 725 /** 726 * @brief Deletes the given data object from the group. 727 * 728 * @param obj Object being edited. 729 * @param itemname Name of the data entry to remove. 730 * 731 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 732 */ 733 EAPI Eina_Bool edje_edit_group_data_del(Evas_Object *obj, const char *itemname); 734 735 /** 736 * @brief Gets the data associated with the given itemname. 737 * 738 * @param obj Object being edited. 739 * @param itemname Name of the data entry. 740 * 741 * @return Value of the data entry or NULL if not found. 742 */ 743 EAPI const char * edje_edit_group_data_value_get(Evas_Object *obj, const char *itemname); 744 745 /** 746 * @brief Sets the data associated with the given itemname. 747 * 748 * @param obj Object being edited. 749 * @param itemname Name of the data entry to set the value. 750 * @param value Value to set for the data entry. 751 * 752 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 753 */ 754 EAPI Eina_Bool edje_edit_group_data_value_set(Evas_Object *obj, const char *itemname, const char *value); 755 756 /** 757 * @brief Changes the name of the given data object. 758 * 759 * @param obj Object being edited. 760 * @param itemname Name of the data entry to rename. 761 * @param newname New name for the data entry. 762 * 763 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 764 */ 765 EAPI Eina_Bool edje_edit_group_data_name_set(Evas_Object *obj, const char *itemname, const char *newname); 766 767 768 //@} 769 /*****************************************************************************/ 770 /*********************** SIZE CLASSES API ********************************/ 771 /*****************************************************************************/ 772 /** 773 * @name Size Classes API 774 * Functions to deal with Size Classes (see @ref edcref). 775 */ //@{ 776 777 /** 778 * @brief Gets the list of all the Size Classes in the given edje object. 779 * 780 * @param obj Object being edited. 781 * 782 * @return List of strings, each being one size class. 783 * The return value should be freed with edje_edit_string_list_free(). 784 * 785 * @see edje_edit_string_list_free() 786 * 787 * @since 1.18 788 */ 789 EAPI Eina_List * 790 edje_edit_size_classes_list_get(Evas_Object *obj); 791 792 /** 793 * @brief Creates a new size class object in the given edje. 794 * 795 * If class is already exist then nothing is created and EINA_FALSE returned. 796 * 797 * @param obj Object being edited. 798 * @param name Name for the new size class. 799 * 800 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 801 * 802 * @since 1.18 803 */ 804 EAPI Eina_Bool 805 edje_edit_size_class_add(Evas_Object *obj, const char *name); 806 807 /** 808 * @brief Deletes size class object from edje. 809 * 810 * @param obj Object being edited. 811 * @param name Size class to delete. 812 * 813 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 814 * 815 * @since 1.18 816 */ 817 EAPI Eina_Bool 818 edje_edit_size_class_del(Evas_Object *obj, const char *name); 819 820 /** 821 * @brief Changes name of a size class. 822 * 823 * @param obj Object being edited. 824 * @param name Size class to rename. 825 * @param newname New name for the size class. 826 * 827 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 828 * 829 * @since 1.18 830 */ 831 EAPI Eina_Bool 832 edje_edit_size_class_name_set(Evas_Object *obj, const char *name, const char *newname); 833 834 /** 835 * @brief Returns width min size of specified size class. 836 * 837 * @param obj Object being edited. 838 * @param class_name Size class to fetch values. 839 * 840 * @return @c Evas_Coord. 841 * 842 * @since 1.18 843 */ 844 EAPI Evas_Coord 845 edje_edit_size_class_min_w_get(Evas_Object *obj, const char *class_name); 846 847 /** 848 * @brief Sets width min size of specified size class. 849 * 850 * @param obj Object being edited. 851 * @param class_name Size class to set values. 852 * @param size Size which is greater or equal than zero (0). 853 * 854 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 855 * 856 * @since 1.18 857 */ 858 EAPI Eina_Bool 859 edje_edit_size_class_min_w_set(Evas_Object *obj, const char *class_name, Evas_Coord size); 860 861 /** 862 * @brief Returns width max size of specified size class. 863 * 864 * @param obj Object being edited. 865 * @param class_name Size class to fetch values. 866 * 867 * @return @c Evas_Coord. 868 * 869 * @since 1.18 870 */ 871 EAPI Evas_Coord 872 edje_edit_size_class_max_w_get(Evas_Object *obj, const char *class_name); 873 874 /** 875 * @brief Sets width max size of specified size class. 876 * 877 * @param obj Object being edited. 878 * @param class_name Size class to set values. 879 * @param size Size which is greater or equal than zero (0). 880 * 881 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 882 * 883 * @since 1.18 884 */ 885 EAPI Eina_Bool 886 edje_edit_size_class_max_w_set(Evas_Object *obj, const char *class_name, Evas_Coord size); 887 888 /** 889 * @brief Returns height min size of specified size class. 890 * 891 * @param obj Object being edited. 892 * @param class_name Size class to fetch values. 893 * 894 * @return @c Evas_Coord. 895 * 896 * @since 1.18 897 */ 898 EAPI Evas_Coord 899 edje_edit_size_class_min_h_get(Evas_Object *obj, const char *class_name); 900 901 /** 902 * @brief Sets height min size of specified size class. 903 * 904 * @param obj Object being edited. 905 * @param class_name Size class to set values. 906 * @param size Size which is greater or equal than zero (0). 907 * 908 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 909 * 910 * @since 1.18 911 */ 912 EAPI Eina_Bool 913 edje_edit_size_class_min_h_set(Evas_Object *obj, const char *class_name, Evas_Coord size); 914 915 /** 916 * @brief Returns height max size of specified size class. 917 * 918 * @param obj Object being edited. 919 * @param class_name Size class to fetch values. 920 * 921 * @return @c Evas_Coord (-1 is default value). 922 * 923 * @since 1.18 924 */ 925 EAPI Evas_Coord 926 edje_edit_size_class_max_h_get(Evas_Object *obj, const char *class_name); 927 928 /** 929 * @brief Sets height max size of specified size class. 930 * 931 * @param obj Object being edited. 932 * @param class_name Size class to set values. 933 * @param size Size which is greater or equal minus one (-1, which is default value). 934 * 935 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 936 * 937 * @since 1.18 938 */ 939 EAPI Eina_Bool 940 edje_edit_size_class_max_h_set(Evas_Object *obj, const char *class_name, Evas_Coord size); 941 942 //@} 943 /*****************************************************************************/ 944 /*********************** TEXT CLASSES API ********************************/ 945 /*****************************************************************************/ 946 /** 947 * @name Text Classes API 948 * Functions to deal with Text Classes (see @ref edcref). 949 */ //@{ 950 951 /** 952 * @brief Gets the list of all the Text Classes in the given edje object. 953 * 954 * @param obj Object being edited. 955 * 956 * @return List of strings, each being one text class. 957 * The return value should be freed with edje_edit_string_list_free(). 958 * 959 * @see edje_edit_string_list_free() 960 * 961 * @since 1.18 962 */ 963 EAPI Eina_List * 964 edje_edit_text_classes_list_get(Evas_Object *obj); 965 966 /** 967 * @brief Creates a new text class object in the given edje. 968 * 969 * If class is already exist then nothing is created and EINA_FALSE returned. 970 * 971 * @param obj Object being edited. 972 * @param name Name for the new text class. 973 * 974 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 975 * 976 * @since 1.18 977 */ 978 EAPI Eina_Bool 979 edje_edit_text_class_add(Evas_Object *obj, const char *name); 980 981 /** 982 * @brief Deletes text class object from edje. 983 * 984 * @param obj Object being edited. 985 * @param name Text class to delete. 986 * 987 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 988 * 989 * @since 1.18 990 */ 991 EAPI Eina_Bool 992 edje_edit_text_class_del(Evas_Object *obj, const char *name); 993 994 /** 995 * @brief Changes name of a text class. 996 * 997 * @param obj Object being edited. 998 * @param name Text class to rename. 999 * @param newname New name for the text class. 1000 * 1001 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1002 * 1003 * @since 1.18 1004 */ 1005 EAPI Eina_Bool 1006 edje_edit_text_class_name_set(Evas_Object *obj, const char *name, const char *newname); 1007 1008 /** 1009 * @brief Returns font name of specified text class. 1010 * 1011 * @param obj Object being edited. 1012 * @param class_name Text class to fetch values. 1013 * 1014 * @return font name in case of success, NULL otherwise. 1015 * 1016 * @since 1.18 1017 */ 1018 EAPI Eina_Stringshare * 1019 edje_edit_text_class_font_get(Evas_Object *obj, const char *class_name); 1020 1021 /** 1022 * @brief Sets font for the given text class. 1023 * 1024 * NULL is possible value. 1025 * 1026 * @param obj Object being edited. 1027 * @param class_name Text class to set values. 1028 * @param font Name of font. 1029 * 1030 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1031 * 1032 * @since 1.18 1033 */ 1034 EAPI Eina_Bool 1035 edje_edit_text_class_font_set(Evas_Object *obj, const char *class_name, const char *font); 1036 1037 /** 1038 * @brief Returns font size of specified text class. 1039 * 1040 * @param obj Object being edited. 1041 * @param class_name Text class to fetch values. 1042 * 1043 * @return @c Evas_Font_Size. 1044 * 1045 * @since 1.18 1046 */ 1047 EAPI Evas_Font_Size 1048 edje_edit_text_class_size_get(Evas_Object *obj, const char *class_name); 1049 1050 /** 1051 * @brief Sets font size for specified text class 1052 * 1053 * @param obj Object being edited. 1054 * @param class_name Text class to set values. 1055 * @param size Font size which is greater or equal than zero (0). 1056 * 1057 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1058 * 1059 * @since 1.18 1060 */ 1061 EAPI Eina_Bool 1062 edje_edit_text_class_size_set(Evas_Object *obj, const char *class_name, Evas_Font_Size size); 1063 1064 1065 //@} 1066 /******************************************************************************/ 1067 /*********************** COLOR CLASSES API ********************************/ 1068 /******************************************************************************/ 1069 /** 1070 * @name Color Classes API 1071 * Functions to deal with Color Classes (see @ref edcref). 1072 */ //@{ 1073 1074 /** 1075 * @brief Gets the list of all the Color Classes in the given edje object. 1076 * 1077 * @param obj Object being edited. 1078 * 1079 * @return List of strings, each being one color class. 1080 */ 1081 EAPI Eina_List * edje_edit_color_classes_list_get(Evas_Object *obj); 1082 1083 /** 1084 * @brief Creates a new color class object in the given edje. 1085 * 1086 * If another class with the same name exists nothing is created and EINA_FALSE is returned. 1087 * 1088 * @param obj Object being edited. 1089 * @param name Name for the new color class. 1090 * 1091 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1092 */ 1093 EAPI Eina_Bool edje_edit_color_class_add(Evas_Object *obj, const char *name); 1094 1095 /** 1096 * @brief Deletes the given class object from edje. 1097 * 1098 * @param obj Object being edited. 1099 * @param name Color class to delete. 1100 * 1101 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1102 */ 1103 EAPI Eina_Bool edje_edit_color_class_del(Evas_Object *obj, const char *name); 1104 1105 /** 1106 * @brief Gets all the colors that compose the class. 1107 * 1108 * You can pass NULL to colors you are not interested in. 1109 * 1110 * @param obj Object being edited. 1111 * @param class_name Color class to fetch values. 1112 * @param r Red component of main color. 1113 * @param g Green component of main color. 1114 * @param b Blue component of main color. 1115 * @param a Alpha component of main color. 1116 * @param r2 Red component of secondary color. 1117 * @param g2 Green component of secondary color. 1118 * @param b2 Blue component of secondary color. 1119 * @param a2 Alpha component of secondary color. 1120 * @param r3 Red component of tertiary color. 1121 * @param g3 Green component of tertiary color. 1122 * @param b3 Blue component of tertiary color. 1123 * @param a3 Alpha component of tertiary color. 1124 * 1125 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1126 */ 1127 EAPI Eina_Bool edje_edit_color_class_colors_get(Evas_Object *obj, const char *class_name, int *r, int *g, int *b, int *a, int *r2, int *g2, int *b2, int *a2, int *r3, int *g3, int *b3, int *a3); 1128 1129 /** 1130 * @brief Sets the colors for the given color class. 1131 * 1132 * If you set a color to -1 it will not be touched. 1133 * 1134 * @param obj Object being edited. 1135 * @param class_name Color class to fetch values. 1136 * @param r Red component of main color. 1137 * @param g Green component of main color. 1138 * @param b Blue component of main color. 1139 * @param a Alpha component of main color. 1140 * @param r2 Red component of secondary color. 1141 * @param g2 Green component of secondary color. 1142 * @param b2 Blue component of secondary color. 1143 * @param a2 Alpha component of secondary color. 1144 * @param r3 Red component of tertiary color. 1145 * @param g3 Green component of tertiary color. 1146 * @param b3 Blue component of tertiary color. 1147 * @param a3 Alpha component of tertiary color. 1148 * 1149 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1150 */ 1151 EAPI Eina_Bool edje_edit_color_class_colors_set(Evas_Object *obj, const char *class_name, int r, int g, int b, int a, int r2, int g2, int b2, int a2, int r3, int g3, int b3, int a3); 1152 1153 /** 1154 * @brief Changes the name of a color class. 1155 * 1156 * @param obj Object being edited. 1157 * @param name Color class to rename. 1158 * @param newname New name for the color class. 1159 * 1160 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1161 */ 1162 EAPI Eina_Bool edje_edit_color_class_name_set(Evas_Object *obj, const char *name, const char *newname); 1163 1164 /** 1165 * @brief Gets the description of a color class. 1166 * 1167 * @param obj Object being edited. 1168 * @param class_name Color class to get the description of. 1169 * 1170 * @return The description of the color class or @c NULL if not found 1171 * @since 1.14 1172 */ 1173 EAPI Eina_Stringshare *edje_edit_color_class_description_get(Evas_Object *obj, const char *class_name); 1174 1175 /** 1176 * @brief Changes the description of a color class. 1177 * 1178 * @param obj Object being edited. 1179 * @param class_name Color class to edit. 1180 * @param desc New description for the color class 1181 * 1182 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1183 * @since 1.14 1184 */ 1185 EAPI Eina_Bool edje_edit_color_class_description_set(Evas_Object *obj, const char *class_name, const char *desc); 1186 //@} 1187 1188 1189 /******************************************************************************/ 1190 /************************** TEXT STYLES *************************************/ 1191 /******************************************************************************/ 1192 /** 1193 * @name Text styles API 1194 * Functions to deal with text styles (see @ref edcref). 1195 */ //@{ 1196 1197 /** 1198 * @brief Gets the list of all the text styles in the given edje object. 1199 * 1200 * @param obj Object being edited. 1201 * 1202 * @return List of strings, each being the name for a text style. 1203 */ 1204 EAPI Eina_List * edje_edit_styles_list_get(Evas_Object *obj); 1205 1206 /** 1207 * @brief Creates a new text style object in the given edje. 1208 * 1209 * If another style with the same name exists nothing is created and EINA_FALSE is returned. 1210 * 1211 * @param obj Object being edited. 1212 * @param style Name for the new style. 1213 * 1214 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1215 */ 1216 EAPI Eina_Bool edje_edit_style_add(Evas_Object *obj, const char *style); 1217 1218 /** 1219 * @brief Deletes the given text style and all the child tags. 1220 * 1221 * @param obj Object being edited. 1222 * @param style Style to delete. 1223 * 1224 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1225 */ 1226 EAPI Eina_Bool edje_edit_style_del(Evas_Object *obj, const char *style); 1227 1228 /** 1229 * @brief Gets the list of all the tags name in the given text style. 1230 * 1231 * @param obj Object being edited. 1232 * @param style Style to get the tags for. 1233 * 1234 * @return List of strings, each being one tag in the given style. 1235 */ 1236 EAPI Eina_List * edje_edit_style_tags_list_get(Evas_Object *obj, const char *style); 1237 1238 /** 1239 * @brief Gets the value of the given tag. 1240 * 1241 * @param obj Object being edited. 1242 * @param style Style containing the tag being. 1243 * @param tag Tag to get the value for. 1244 * 1245 * @return Value of the given tag. 1246 */ 1247 EAPI const char * edje_edit_style_tag_value_get(Evas_Object *obj, const char *style, const char *tag); 1248 1249 /** 1250 * @brief Sets the value of the given tag. 1251 * 1252 * @param obj Object being edited. 1253 * @param style Style containing the tag to change. 1254 * @param tag Name of the tag to set the value for. 1255 * @param new_value Value for the tag. 1256 * 1257 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1258 */ 1259 EAPI Eina_Bool edje_edit_style_tag_value_set(Evas_Object *obj, const char *style, const char *tag, const char *new_value); 1260 1261 /** 1262 * @brief Sets the name of the given tag. 1263 * 1264 * @param obj Object being edited. 1265 * @param style Style containing the tag to rename. 1266 * @param tag Tag to rename. 1267 * @param new_name New name for the tag. 1268 * 1269 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1270 */ 1271 EAPI Eina_Bool edje_edit_style_tag_name_set(Evas_Object *obj, const char *style, const char *tag, const char *new_name); 1272 1273 /** 1274 @ @brief Adds a new tag to the given text style. 1275 * 1276 * If another tag with the same name exists nothing is created and EINA_FALSE is returned. 1277 * 1278 * @param obj Object being edited. 1279 * @param style Style where to add the new tag. 1280 * @param tag_name Name for the new tag. 1281 * 1282 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1283 */ 1284 EAPI Eina_Bool edje_edit_style_tag_add(Evas_Object *obj, const char *style, const char *tag_name); 1285 1286 /** 1287 * @brief Deletes the given tag. 1288 * 1289 * @param obj Object being edited. 1290 * @param style Style from where to remove the tag. 1291 * @param tag Tag to delete. 1292 * 1293 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1294 */ 1295 EAPI Eina_Bool edje_edit_style_tag_del(Evas_Object *obj, const char *style, const char *tag); 1296 1297 1298 //@} 1299 /******************************************************************************/ 1300 /************************ EXTERNALS API ***********************************/ 1301 /******************************************************************************/ 1302 /** 1303 * @name Externals API 1304 * Functions to deal with list of external modules (see @ref edcref). 1305 */ //@{ 1306 1307 /** 1308 * @brief Gets the list of all the externals requested in the given edje object. 1309 * 1310 * @param obj Object being edited. 1311 * 1312 * @return List of strings, each being an entry in the block of automatically loaded external modules. 1313 */ 1314 EAPI Eina_List * edje_edit_externals_list_get(Evas_Object *obj); 1315 1316 /** 1317 * @brief Adds an external module to be requested on edje load. 1318 * 1319 * @param obj Object being edited. 1320 * @param external Name of the external module to add to the list of autoload. 1321 * 1322 * @return @c EINA_TRUE on success (or it was already there), @c EINA_FALSE otherwise. 1323 */ 1324 EAPI Eina_Bool edje_edit_external_add(Evas_Object *obj, const char *external); 1325 1326 /** 1327 * @brief Deletes the given external from the list. 1328 * 1329 * @param obj Object being edited. 1330 * @param external Name of the external module to remove from the autoload list. 1331 * 1332 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1333 */ 1334 EAPI Eina_Bool edje_edit_external_del(Evas_Object *obj, const char *external); 1335 1336 1337 //@} 1338 /******************************************************************************/ 1339 /************************** PARTS API *************************************/ 1340 /******************************************************************************/ 1341 /** 1342 * @name Parts API 1343 * Functions to deal with part objects (see @ref edcref). 1344 */ //@{ 1345 1346 /** 1347 * @brief Gets the select mode for a textblock part. 1348 1349 * @param obj Object being edited. 1350 * @param part Name of the part. 1351 * 1352 * @return One of possible enum Edje_Edit_Select_Mode. 1353 * @since 1.11 1354 */ 1355 EAPI Edje_Edit_Select_Mode edje_edit_part_select_mode_get(Evas_Object *obj, const char *part); 1356 1357 /** 1358 * @brief Sets the select mode for a textblock part. 1359 * 1360 * @param obj Object being edited. 1361 * @param part Name of the part. 1362 * @param mode One of possible enum Edje_Edit_Select_Mode: 1363 * EDJE_EDIT_SELECT_MODE_DEFAULT, EDJE_EDIT_SELECT_MODE_EXPLICIT. 1364 * 1365 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1366 * @since 1.11 1367 */ 1368 EAPI Eina_Bool edje_edit_part_select_mode_set(Evas_Object *obj, const char *part, Edje_Edit_Select_Mode mode); 1369 1370 /** 1371 * @brief Gets the edit mode for a textblock part. 1372 * 1373 * @param obj Object being edited. 1374 * @param part Name of the part. 1375 * 1376 * @return One of possible enum Edje_Entry_Mode. 1377 * @since 1.11 1378 */ 1379 EAPI Edje_Edit_Entry_Mode edje_edit_part_entry_mode_get(Evas_Object *obj, const char *part); 1380 1381 /** 1382 * @brief Sets the edit mode for a textblock part. 1383 * 1384 * @param obj Object being edited. 1385 * @param part Name of the part. 1386 * @param mode One of possible enum Edje_Entry_Mode: 1387 * EDJE_EDIT_ENTRY_MODE_NONE, EDJE_EDIT_ENTRY_MODE_PLAIN, EDJE_EDIT_ENTRY_MODE_EDITABLE, EDJE_EDIT_ENTRY_MODE_PASSWORD. 1388 1389 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1390 * @since 1.11 1391 */ 1392 EAPI Eina_Bool edje_edit_part_entry_mode_set(Evas_Object *obj, const char *part, Edje_Edit_Entry_Mode mode); 1393 1394 /** 1395 * @brief Gets the list of all the parts in the given edje object. 1396 * 1397 * @param obj Object being edited. 1398 * 1399 * @return List of strings, each being the name for a part in the open group. 1400 * The return value should be freed with edje_edit_string_list_free(). 1401 * 1402 * @see edje_edit_string_list_free() 1403 */ 1404 EAPI Eina_List * edje_edit_parts_list_get(Evas_Object *obj); 1405 1406 /** 1407 * @brief Creates a new part in the given edje. 1408 * 1409 * If another part with the same name just exists nothing is created and EINA_FALSE is returned. 1410 * Note that this function also create a default description for the part. 1411 * 1412 * @param obj Object being edited. 1413 * @param name Name for the new part. 1414 * @param type Type of the new part. See @ref edcref for more info on this. 1415 * 1416 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1417 */ 1418 EAPI Eina_Bool edje_edit_part_add(Evas_Object *obj, const char *name, Edje_Part_Type type); 1419 1420 /** 1421 * @brief Creates a new part of type EXTERNAL in the given edje. 1422 * 1423 * If another part with the same name just exists nothing is created and EINA_FALSE is returned. 1424 * Note that this function also create a default description for the part. 1425 * 1426 * @param obj Object being edited. 1427 * @param name Name for the new part. 1428 * @param source The registered external type to use for this part. 1429 * 1430 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1431 */ 1432 EAPI Eina_Bool edje_edit_part_external_add(Evas_Object *obj, const char *name, const char *source); 1433 1434 /** 1435 * @brief Deletes the given part from the edje. 1436 * 1437 * All the reference to this part will be zeroed. 1438 * 1439 * @param obj Object being edited. 1440 * @param part Name of part to delete. 1441 * 1442 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1443 */ 1444 EAPI Eina_Bool edje_edit_part_del(Evas_Object *obj, const char *part); 1445 1446 /** 1447 * @brief Copies the given part in edje. 1448 * 1449 * If another part with the same name just exists nothing is created and EINA_FALSE is returned. 1450 * 1451 * @param obj Object being edited. 1452 * @param part Name of the part. 1453 * @param new_copy Name of the new copied part. 1454 * 1455 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1456 * @since 1.11 1457 */ 1458 EAPI Eina_Bool edje_edit_part_copy(Evas_Object *obj, const char *part, const char *new_copy); 1459 1460 /** 1461 * @brief Checks if a part with the given name exist in the edje object. 1462 * 1463 * @param obj Object being edited. 1464 * @param part Name of part to check for its existence. 1465 * 1466 * @return @c EINA_TRUE if the part exists, @c EINA_FALSE if not. 1467 */ 1468 EAPI Eina_Bool edje_edit_part_exist(Evas_Object *obj, const char *part); 1469 1470 /** 1471 * @brief Gets the name of part stacked above the one passed. 1472 * 1473 * @param obj Object being edited. 1474 * @param part Name of part of which to check the one above. 1475 * 1476 * @return Name of the part above. NULL if an error occurred or if @p part is 1477 * the topmost part in the group. 1478 */ 1479 EAPI const char * edje_edit_part_above_get(Evas_Object *obj, const char *part); 1480 1481 /** 1482 * @brief Gets the name of part stacked below the one passed. 1483 * 1484 * @param obj Object being edited. 1485 * @param part Name of part of which to check the one below. 1486 * 1487 * @return Name of the part below. NULL if an error occurred or if @p part is 1488 * the bottommost part in the group. 1489 */ 1490 EAPI const char * edje_edit_part_below_get(Evas_Object *obj, const char *part); 1491 1492 /** 1493 * @brief Moves the given part below the previous one. 1494 * 1495 * @param obj Object being edited. 1496 * @param part Name of part to move one step below. 1497 * 1498 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1499 */ 1500 EAPI Eina_Bool edje_edit_part_restack_below(Evas_Object *obj, const char *part); 1501 1502 /** 1503 * @brief Moves the given part below the part named below. 1504 * 1505 * @param obj Object being edited. 1506 * @param part Name of part which will be moved. 1507 * @param below Name of part for which will be moved 'part'. 1508 * 1509 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1510 */ 1511 EAPI Eina_Bool edje_edit_part_restack_part_below(Evas_Object *obj, const char* part, const char *below); 1512 1513 /** 1514 * @brief Moves the given part above the next one. 1515 * 1516 * @param obj Object being edited. 1517 * @param part Name of part to move one step above. 1518 * 1519 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1520 */ 1521 EAPI Eina_Bool edje_edit_part_restack_above(Evas_Object *obj, const char *part); 1522 1523 /** 1524 * @brief Moves the given part above the part named above. 1525 * 1526 * @param obj Object being edited. 1527 * @param part Name of part which will be moved. 1528 * @param above Name of part for which will be moved 'part'. 1529 * 1530 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1531 */ 1532 EAPI Eina_Bool edje_edit_part_restack_part_above(Evas_Object *obj, const char* part, const char *above); 1533 1534 /** 1535 * @brief Sets a new name for part. 1536 * 1537 * Note that the relative getter function don't exist as it don't make sense ;) 1538 * 1539 * @param obj Object being edited. 1540 * @param part Name of part to rename. 1541 * @param new_name New name for the given part. 1542 * 1543 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1544 */ 1545 EAPI Eina_Bool edje_edit_part_name_set(Evas_Object *obj, const char *part, const char *new_name); 1546 1547 /** 1548 * @brief Gets api's name of a part. 1549 * 1550 * @param obj Object being edited. 1551 * @param part Name of the part. 1552 * 1553 * @return Name of the API if successful, NULL otherwise. 1554 */ 1555 EAPI const char * edje_edit_part_api_name_get(Evas_Object *obj, const char *part); 1556 1557 /** 1558 * @brief Gets api's description of a part. 1559 * 1560 * @param obj Object being edited. 1561 * @param part Name of the part. 1562 * 1563 * @return Description of the api if successful, NULL otherwise. 1564 */ 1565 EAPI const char * edje_edit_part_api_description_get(Evas_Object *obj, const char *part); 1566 1567 /** 1568 * @brief Sets api's name of a part. 1569 * 1570 * @param obj Object being edited. 1571 * @param part Name of the part. 1572 * @param name New name for the api property. 1573 * 1574 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1575 */ 1576 EAPI Eina_Bool edje_edit_part_api_name_set(Evas_Object *obj, const char *part, const char *name); 1577 1578 /** 1579 * @brief Sets api's description of a part. 1580 * 1581 * @param obj Object being edited. 1582 * @param part Name of part. 1583 * @param description New description for the api property. 1584 * 1585 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1586 */ 1587 EAPI Eina_Bool edje_edit_part_api_description_set(Evas_Object *obj, const char *part, const char *description); 1588 1589 /** 1590 * @brief Gets the type of a part. 1591 * 1592 * @param obj Object being edited. 1593 * @param part Name of part to get the type of. 1594 * 1595 * @return Type of the part. See @ref edcref for details. 1596 */ 1597 EAPI Edje_Part_Type edje_edit_part_type_get(Evas_Object *obj, const char *part); 1598 1599 /** 1600 * @brief Gets the clip_to part. 1601 * 1602 * @param obj Object being edited. 1603 * @param part Name of the part whose clipper to get. 1604 * 1605 * @return Name of the part @p part is clipped to. NULL is returned on errors and if the part don't have a clip. 1606 */ 1607 EAPI const char * edje_edit_part_clip_to_get(Evas_Object *obj, const char *part); 1608 1609 /** 1610 * @brief Sets a part to clip part to. 1611 * 1612 * @param obj Object being edited. 1613 * @param part Part to set the clipper to. 1614 * @param clip_to Part to use as clipper, if NULL then the clipping value will be cancelled (unset clipping). 1615 * 1616 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1617 */ 1618 EAPI Eina_Bool edje_edit_part_clip_to_set(Evas_Object *obj, const char *part, const char *clip_to); 1619 1620 /** 1621 * @brief Gets the source of part. 1622 * 1623 * The meaning of this parameter varies depending on the type of the part. 1624 * For GROUP parts, it's the name of another group in the Edje file which will 1625 * be autoloaded and swallowed on this part. 1626 * For TEXTBLOCK parts, it's the name of a group to be used for selection 1627 * display under the text. 1628 * For EXTERNAL parts, it's the name of the registered external widget to load 1629 * and swallow on this part. 1630 * 1631 * @param obj Object being edited. 1632 * @param part Part to get the source from. 1633 * 1634 * @return Content of the source parameter or NULL if nothing set or an error occurred. 1635 */ 1636 EAPI const char * edje_edit_part_source_get(Evas_Object *obj, const char *part); 1637 1638 /** 1639 * @brief Sets the source of part. 1640 * 1641 * If setting source of the part will lead to recursive reference 1642 * (when A source to B, and B is going to be source to A because of this function), 1643 * then it will return EINA_FALSE. 1644 * 1645 * @param obj Object being edited. 1646 * @param part Part to set the source of. 1647 * @param source Value for the source parameter. 1648 * 1649 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1650 * 1651 * @see edje_edit_part_source_get() 1652 * 1653 * @note You can't change the source for EXTERNAL parts, it's akin to changing 1654 * the type of the part. 1655 * 1656 * NOTE: This is not applied now. You must reload the edje to see the change. 1657 */ 1658 EAPI Eina_Bool edje_edit_part_source_set(Evas_Object *obj, const char *part, const char *source); 1659 1660 /** 1661 * @brief Gets the source2 of part. 1662 * 1663 * Only available to TEXTBLOCK parts. It is used for the group to be loaded and 1664 * used for selection display OVER the selected text. source is used for under 1665 * of the selected text, if source is specified. 1666 * 1667 * @param obj Object being edited. 1668 * @param part Part to get the source from. 1669 * 1670 * @return Content of the source2 parameter or NULL if nothing set or an error occurred. 1671 * @since 1.11 1672 */ 1673 EAPI const char * edje_edit_part_source2_get(Evas_Object *obj, const char *part); 1674 1675 /** 1676 * @brief Sets the source2 of part. 1677 * 1678 * @param obj Object being edited. 1679 * @param part Part to set the source of. 1680 * @param source Value for the source parameter. 1681 * 1682 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1683 * 1684 * @see edje_edit_part_source2_get() 1685 * @since 1.11 1686 */ 1687 EAPI Eina_Bool edje_edit_part_source2_set(Evas_Object *obj, const char *part, const char *source); 1688 1689 /** 1690 * @brief Gets the source3 of part. 1691 * 1692 * Only available to TEXTBLOCK parts. It is used for the group to be loaded and 1693 * used for cursor display UNDER the cursor position. source4 is used for over 1694 * the cursor text, if source4 is specified. 1695 * 1696 * @param obj Object being edited. 1697 * @param part Part to get the source from. 1698 * 1699 * @return Content of the source3 parameter or NULL if nothing set or an error occurred. 1700 * @since 1.11 1701 */ 1702 EAPI const char * edje_edit_part_source3_get(Evas_Object *obj, const char *part); 1703 1704 /** 1705 * @brief Sets the source3 of part. 1706 * 1707 * @param obj Object being edited. 1708 * @param part Part to set the source of. 1709 * @param source Value for the source parameter. 1710 * 1711 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1712 * 1713 * @see edje_edit_part_source3_get() 1714 * @since 1.11 1715 * 1716 * NOTE: This is not applied now. You must reload the edje to see the change. 1717 */ 1718 EAPI Eina_Bool edje_edit_part_source3_set(Evas_Object *obj, const char *part, const char *source); 1719 1720 /** 1721 * @brief Gets the source4 of part. 1722 * 1723 * Only available to TEXTBLOCK parts. It is used for the group to be loaded and 1724 * used for cursor display OVER the cursor position. source3 is used for under 1725 * the cursor text, if source4 is specified. 1726 * 1727 * @param obj Object being edited. 1728 * @param part Part to get the source from. 1729 * 1730 * @return Content of the source4 parameter or NULL if nothing set or an error occurred. 1731 * @since 1.11 1732 */ 1733 EAPI const char * edje_edit_part_source4_get(Evas_Object *obj, const char *part); 1734 1735 /** 1736 * @brief Sets the source4 of part. 1737 * 1738 * @param obj Object being edited. 1739 * @param part Part to set the source of. 1740 * @param source Value for the source parameter. 1741 * 1742 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1743 * 1744 * @see edje_edit_part_source4_get() 1745 * @since 1.11 1746 * 1747 * NOTE: This is not applied now. You must reload the edje to see the change. 1748 */ 1749 EAPI Eina_Bool edje_edit_part_source4_set(Evas_Object *obj, const char *part, const char *source); 1750 1751 /** 1752 * @brief Gets the source5 of part. 1753 * 1754 * Only available to TEXTBLOCK parts. It is used for the group to be loaded and 1755 * used for anchors display UNDER the anchor position. source6 is used for over 1756 * the anchors text, if source6 is specified. 1757 * 1758 * @param obj Object being edited. 1759 * @param part Part to get the source from. 1760 * 1761 * @return Content of the source5 parameter or NULL if nothing set or an error occurred. 1762 * @since 1.11 1763 */ 1764 EAPI const char * edje_edit_part_source5_get(Evas_Object *obj, const char *part); 1765 1766 /** 1767 * @brief Sets the source5 of part. 1768 * 1769 * @param obj Object being edited. 1770 * @param part Part to set the source of. 1771 * @param source Value for the source parameter. 1772 * 1773 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1774 * 1775 * @see edje_edit_part_source5_get() 1776 * @since 1.11 1777 */ 1778 EAPI Eina_Bool edje_edit_part_source5_set(Evas_Object *obj, const char *part, const char *source); 1779 1780 /** 1781 * @brief Gets the source6 of part. 1782 * 1783 * Only available to TEXTBLOCK parts. It is used for the group to be loaded and 1784 * used for anchor display OVER the anchor position. source5 is used for under 1785 * the anchor text, if source6 is specified. 1786 * 1787 * @param obj Object being edited. 1788 * @param part Part to get the source from. 1789 * 1790 * @return Content of the source6 parameter or NULL if nothing set or an error occurred. 1791 * @since 1.11 1792 */ 1793 EAPI const char * edje_edit_part_source6_get(Evas_Object *obj, const char *part); 1794 1795 /** 1796 * @brief Sets the source6 of part. 1797 * 1798 * @param obj Object being edited. 1799 * @param part Part to set the source of. 1800 * @param source Value for the source parameter. 1801 * 1802 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1803 * 1804 * @see edje_edit_part_source6_get() 1805 * @since 1.11 1806 */ 1807 EAPI Eina_Bool edje_edit_part_source6_set(Evas_Object *obj, const char *part, const char *source); 1808 1809 /** 1810 * @brief Gets the effect for a given part. 1811 * 1812 * Gets the effect used for parts of type TEXT. See @ref edcref for more details. 1813 * 1814 * @param obj Object being edited. 1815 * @param part Part to get the effect of. 1816 * 1817 * @return The effect set for the part. 1818 */ 1819 EAPI Edje_Text_Effect edje_edit_part_effect_get(Evas_Object *obj, const char *part); 1820 1821 /** 1822 * @brief Sets the effect for a given part. 1823 * Effects and shadow directions can be combined. 1824 * 1825 * For effect and shadow direction list please look at Edje Part Text ref page. 1826 * 1827 * @param obj Object being edited. 1828 * @param part Part to set the effect to. Only makes sense on type TEXT. 1829 * @param effect Effect to set for the part. 1830 * 1831 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1832 * 1833 * @see Edje_Part_Text 1834 */ 1835 EAPI Eina_Bool edje_edit_part_effect_set(Evas_Object *obj, const char *part, Edje_Text_Effect effect); 1836 1837 /** 1838 * @brief Gets the current selected state in part. 1839 * 1840 * @param obj Object being edited. 1841 * @param part Part to get the selected state of. 1842 * @param value Pointer to a double where the value of the state will be stored. 1843 * 1844 * @return The name of the currently selected state for the part. 1845 */ 1846 EAPI const char * edje_edit_part_selected_state_get(Evas_Object *obj, const char *part, double *value); 1847 1848 /** 1849 * @brief Sets the current state in part. 1850 * 1851 * @param obj Object being edited. 1852 * @param part Part to set the state of. 1853 * @param state Name of the state to set. 1854 * @param value Value of the state. 1855 * 1856 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1857 */ 1858 EAPI Eina_Bool edje_edit_part_selected_state_set(Evas_Object *obj, const char *part, const char *state, double value); 1859 1860 /** 1861 * @brief Gets mouse_events for part. 1862 * 1863 * @param obj Object being edited. 1864 * @param part Part to get if the mouse events is accepted. 1865 * 1866 * @return @c EINA_TRUE if part will accept mouse events, @c EINA_FALSE otherwise. 1867 */ 1868 EAPI Eina_Bool edje_edit_part_mouse_events_get(Evas_Object *obj, const char *part); 1869 1870 /** 1871 * @brief Sets mouse_events for part. 1872 * 1873 * @param obj Object being edited. 1874 * @param part The part to set if the mouse events is accepted. 1875 * @param mouse_events @c EINA_TRUE if part will accept mouse events, @c EINA_FALSE otherwise. 1876 * 1877 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1878 */ 1879 EAPI Eina_Bool edje_edit_part_mouse_events_set(Evas_Object *obj, const char *part, Eina_Bool mouse_events); 1880 1881 /** 1882 * @brief Gets required value for part. 1883 * 1884 * @param obj Object being edited. 1885 * @param part Part to get if the part is required by API. 1886 * 1887 * @return @c EINA_TRUE if part is required by the object's implementation, @c EINA_FALSE otherwise. 1888 * @since 1.23 1889 */ 1890 EAPI Eina_Bool edje_edit_part_required_get(Evas_Object *obj, const char *part); 1891 1892 /** 1893 * @brief Gets anti-aliasing for part. 1894 * 1895 * @param obj Object being edited. 1896 * @param part Part to get if the anti-aliasing is accepted. 1897 * 1898 * @return @c EINA_TRUE if part will draw anti-aliased, @c EINA_FALSE otherwise. 1899 */ 1900 EAPI Eina_Bool edje_edit_part_anti_alias_get(Evas_Object *obj, const char *part); 1901 1902 /** 1903 * @brief Sets anti-aliasing for part. 1904 * 1905 * @param obj Object being edited. 1906 * @param part The part to set if the anti-aliasing is accepted. 1907 * @param anti_alias @c EINA_TRUE if part should be drawn anti-aliased, @c EINA_FALSE otherwise. 1908 * 1909 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1910 */ 1911 EAPI Eina_Bool edje_edit_part_anti_alias_set(Evas_Object *obj, const char *part, Eina_Bool anti_alias); 1912 1913 1914 /** 1915 * @brief Gets repeat_events for part. 1916 * 1917 * @param obj Object being edited. 1918 * @param part Part to get if it will pass all events to the other parts. 1919 * 1920 * @return @c EINA_TRUE if the events received will propagate to other parts, @c EINA_FALSE otherwise 1921 */ 1922 EAPI Eina_Bool edje_edit_part_repeat_events_get(Evas_Object *obj, const char *part); 1923 1924 /** 1925 * @brief Sets repeat_events for part. 1926 * 1927 * @param obj Object being edited. 1928 * @param part Part to set if will repeat all the received mouse events to other parts. 1929 * @param repeat_events @c EINA_TRUE if the events received will propagate to other parts, @c EINA_FALSE otherwise 1930 * 1931 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1932 */ 1933 EAPI Eina_Bool edje_edit_part_repeat_events_set(Evas_Object *obj, const char *part, Eina_Bool repeat_events); 1934 1935 /** 1936 * @brief Gets use_alternate_font_metrics variable for part. 1937 * 1938 * @param obj Object being edited. 1939 * @param part Part to get use_alternate_font_metrics for text or textblock part is enabled. 1940 * 1941 * @return @c EINA_TRUE if use_alternate_font_metrics, @c EINA_FALSE otherwise 1942 * @since 1.18 1943 */ 1944 EAPI Eina_Bool 1945 edje_edit_part_use_alternate_font_metrics_get(Evas_Object *obj, const char *part); 1946 1947 /** 1948 * @brief Sets use_alternate_font_metrics variable for part. 1949 * 1950 * @param obj Object being edited. 1951 * @param part Part to set use_alternate_font_metrics for text or textblock part is enabled. 1952 * @param use EINA_TRUE if use_alternate_font_metrics, @c EINA_FALSE otherwise 1953 * 1954 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1955 * @since 1.18 1956 */ 1957 EAPI Eina_Bool 1958 edje_edit_part_use_alternate_font_metrics_set(Evas_Object *obj, const char *part, Eina_Bool use); 1959 1960 /** 1961 * @brief Gets multiline for part. 1962 * 1963 * @param obj Object being edited. 1964 * @param part Part to get if editing multiple lines for text or textblock part is enabled. 1965 * 1966 * @return @c EINA_TRUE if multiple lines for editing is enabled, @c EINA_FALSE otherwise 1967 * @since 1.11 1968 */ 1969 EAPI Eina_Bool edje_edit_part_multiline_get(Evas_Object *obj, const char *part); 1970 1971 /** 1972 * @brief Sets multiline for part. 1973 * 1974 * @param obj Object being edited. 1975 * @param part Part to set if editing multiple lines for text or textblock part is enabled. 1976 * @param multiline @c EINA_TRUE if multiple lines for editing is enabled, @c EINA_FALSE otherwise 1977 * 1978 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 1979 * @since 1.11 1980 */ 1981 EAPI Eina_Bool edje_edit_part_multiline_set(Evas_Object *obj, const char *part, Eina_Bool multiline); 1982 1983 /** 1984 * @brief Gets precise_is_inside for part. 1985 * 1986 * @param obj Object being edited. 1987 * @param part Part to get if it will enable point collision detection for the part. 1988 * 1989 * @return @c EINA_TRUE if point collision detection for the part is enabled, @c EINA_FALSE otherwise 1990 * @since 1.11 1991 */ 1992 EAPI Eina_Bool edje_edit_part_precise_is_inside_get(Evas_Object *obj, const char *part); 1993 1994 /** 1995 * @brief Sets precise_is_inside for part. 1996 * 1997 * @param obj Object being edited. 1998 * @param part Part to set if it will enable point collision detection for the part. 1999 * @param precise_is_inside EINA_TRUE if point collision detection for the part is enabled, @c EINA_FALSE otherwise 2000 * 2001 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2002 * @since 1.11 2003 */ 2004 EAPI Eina_Bool edje_edit_part_precise_is_inside_set(Evas_Object *obj, const char *part, Eina_Bool precise_is_inside); 2005 2006 /** 2007 * @brief Gets accessibility for part. 2008 * 2009 * @param obj Object being edited. 2010 * @param part Part to get if it uses accessibility feature. 2011 * 2012 * @return @c EINA_TRUE if part uses accessibility feature, @c EINA_FALSE otherwise 2013 * @since 1.11 2014 */ 2015 EAPI Eina_Bool edje_edit_part_access_get(Evas_Object *obj, const char *part); 2016 2017 /** 2018 * @brief Sets accessibility for part. 2019 * 2020 * @param obj Object being edited. 2021 * @param part Part to set if it uses accessibility feature. 2022 * @param access EINA_TRUE if part uses accessibility feature, @c EINA_FALSE otherwise 2023 * 2024 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2025 * @since 1.11 2026 */ 2027 EAPI Eina_Bool edje_edit_part_access_set(Evas_Object *obj, const char *part, Eina_Bool access); 2028 2029 /** 2030 * @brief Gets ignore_flags for part. 2031 * 2032 * @param obj Object being edited. 2033 * @param part Part to get which event_flags are being ignored. 2034 * 2035 * @return The Event flags set to the part. 2036 */ 2037 EAPI Evas_Event_Flags edje_edit_part_ignore_flags_get(Evas_Object *obj, const char *part); 2038 2039 /** 2040 * @brief Sets ignore_flags for part. 2041 * 2042 * @param obj Object being edited. 2043 * @param part Part to set which event flags will be ignored. 2044 * @param ignore_flags The Event flags to be ignored by the part. 2045 * 2046 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2047 */ 2048 EAPI Eina_Bool edje_edit_part_ignore_flags_set(Evas_Object *obj, const char *part, Evas_Event_Flags ignore_flags); 2049 2050 /** 2051 * @brief Gets mask_flags for part. 2052 * 2053 * @param obj Object being edited. 2054 * @param part Part to get which event_flags are being masked. 2055 * 2056 * @return The Event flags set to the part. 2057 */ 2058 EAPI Evas_Event_Flags edje_edit_part_mask_flags_get(Evas_Object *obj, const char *part); 2059 2060 /** 2061 * @brief Sets mask_flags for part. 2062 * 2063 * @param obj Object being edited. 2064 * @param part Part to set which event flags will be masked. 2065 * @param mask_flags The Event flags to be masked by the part. 2066 * 2067 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2068 */ 2069 EAPI Eina_Bool edje_edit_part_mask_flags_set(Evas_Object *obj, const char *part, Evas_Event_Flags mask_flags); 2070 2071 /** 2072 * @brief Gets pointer_mode of a part. 2073 * 2074 * @param obj Object being edited. 2075 * @param part Part name to get it's pointer_mode. 2076 * 2077 * @return Pointer Mode of the part. 2078 * @since 1.11 2079 */ 2080 EAPI Evas_Object_Pointer_Mode edje_edit_part_pointer_mode_get(Evas_Object *obj, const char *part); 2081 2082 /** 2083 * @brief Gets pointer_mode of a part. 2084 * 2085 * Note that Pointer Mode can be: 2086 * - EVAS_OBJECT_POINTER_MODE_AUTOGRAB - default, X11-like 2087 * - EVAS_OBJECT_POINTER_MODE_NOGRAB - pointer always bound to the object right below it 2088 * - EVAS_OBJECT_POINTER_MODE_NOGRAB_NO_REPEAT_UPDOWN - useful on object with "repeat events" enabled, @since 1.2 2089 * 2090 * @param obj Object being edited. 2091 * @param part Part name to get it's pointer_mode. 2092 * @param pointer_mode Pointer Mode. 2093 * 2094 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2095 * @since 1.11 2096 */ 2097 EAPI Eina_Bool edje_edit_part_pointer_mode_set(Evas_Object *obj, const char *part, Evas_Object_Pointer_Mode pointer_mode); 2098 2099 /** 2100 * @brief Gets cursor_mode of a part. 2101 * 2102 * Note that Cursor Mode can be: 2103 * 0 - UNDER cursor mode means the cursor will draw below the character pointed 2104 * at. That's the default. 2105 * 1 - BEFORE cursor mode means the cursor is drawn as a vertical line before 2106 * the current character, just like many other GUI toolkits handle it. 2107 * 2108 * @param obj Object being edited. 2109 * @param part Part name to get it's cursor_mode. 2110 * 2111 * @return Pointer Mode of the part. 2112 * @since 1.11 2113 */ 2114 EAPI unsigned char edje_edit_part_cursor_mode_get(Evas_Object *obj, const char *part); 2115 2116 /** 2117 * @brief Gets pointer_mode of a part. 2118 * 2119 * Note that Cursor Mode can be: 2120 * 0 - UNDER cursor mode means the cursor will draw below the character pointed 2121 * at. That's the default. 2122 * 1 - BEFORE cursor mode means the cursor is drawn as a vertical line before 2123 * the current character, just like many other GUI toolkits handle it. 2124 * 2125 * @param obj Object being edited. 2126 * @param part Part name to get it's pointer_mode. 2127 * @param cursor_mode Pointer Mode. 2128 * 2129 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2130 * @since 1.11 2131 */ 2132 EAPI Eina_Bool edje_edit_part_cursor_mode_set(Evas_Object *obj, const char *part, unsigned char cursor_mode); 2133 2134 /** 2135 * @brief Sets scale property for the part. 2136 * 2137 * This property tells Edje that the given part should be scaled by the 2138 * Edje scale factor. 2139 * 2140 * @param obj Object being edited. 2141 * @param part Part to set scale for. 2142 * @param scale Scale value to set. 2143 * 2144 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2145 */ 2146 EAPI Eina_Bool edje_edit_part_scale_set(Evas_Object *obj, const char *part, Eina_Bool scale); 2147 2148 /** 2149 * @brief Gets scale for the part. 2150 * 2151 * @param obj Object being edited. 2152 * @param part Part to get the scale value of. 2153 * 2154 * @return Whether scale is on (EINA_TRUE) or not. 2155 */ 2156 EAPI Eina_Bool edje_edit_part_scale_get(Evas_Object *obj, const char *part); 2157 2158 /** 2159 * @brief Gets horizontal draggable state for part. 2160 * 2161 * @param obj Object being edited. 2162 * @param part Part to get if can be dragged horizontally. 2163 * 2164 * @return @c 1 (or -1) if the part can be dragged horizontally, @c 0 otherwise. 2165 */ 2166 EAPI int edje_edit_part_drag_x_get(Evas_Object *obj, const char *part); 2167 2168 /** 2169 * @brief Sets horizontal draggable state for part. 2170 * 2171 * @param obj Object being edited. 2172 * @param part Part to set if should be dragged horizontally. 2173 * @param drag @c 1 (or -1) if the part should be dragged horizontally, @c 0 otherwise. 2174 * 2175 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2176 */ 2177 EAPI Eina_Bool edje_edit_part_drag_x_set(Evas_Object *obj, const char *part, int drag); 2178 2179 /** 2180 * @brief Gets vertical draggable state for part. 2181 * 2182 * @param obj Object being edited. 2183 * @param part Part to get if can be dragged vertically. 2184 * 2185 * @return @c 1 (or - 1) if the part can be dragged vertically, @c 0 otherwise. 2186 */ 2187 EAPI int edje_edit_part_drag_y_get(Evas_Object *obj, const char *part); 2188 2189 /** 2190 * @brief Sets vertical draggable state for part. 2191 * 2192 * @param obj Object being edited. 2193 * @param part Part to set if should be dragged vertically. 2194 * @param drag @c 1 (or -1) of the part should be dragged vertically, @c 0 otherwise. 2195 * 2196 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2197 */ 2198 EAPI Eina_Bool edje_edit_part_drag_y_set(Evas_Object *obj, const char *part, int drag); 2199 2200 /** 2201 * @brief Gets horizontal draggable step for part. 2202 * 2203 * @param obj Object being edited. 2204 * @param part Part to get the drag horizontal step value. 2205 * 2206 * @return The step value. 2207 */ 2208 EAPI int edje_edit_part_drag_step_x_get(Evas_Object *obj, const char *part); 2209 2210 /** 2211 * @brief Sets horizontal draggable state for part. 2212 * 2213 * @param obj Object being edited. 2214 * @param part Part to set the drag horizontal step value. 2215 * @param step The step the will be dragged. 2216 * 2217 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2218 */ 2219 EAPI Eina_Bool edje_edit_part_drag_step_x_set(Evas_Object *obj, const char *part, int step); 2220 2221 /** 2222 * @brief Gets vertical draggable step for part. 2223 * 2224 * @param obj Object being edited. 2225 * @param part Part to get the drag vertical step value. 2226 * 2227 * @return The step value. 2228 */ 2229 EAPI int edje_edit_part_drag_step_y_get(Evas_Object *obj, const char *part); 2230 2231 /** 2232 * @brief Sets vertical draggable state for part. 2233 * 2234 * @param obj Object being edited. 2235 * @param part Part to set the drag vertical step value. 2236 * @param step The step the will be dragged. 2237 * 2238 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2239 */ 2240 EAPI Eina_Bool edje_edit_part_drag_step_y_set(Evas_Object *obj, const char *part, int step); 2241 2242 /** 2243 * @brief Gets horizontal draggable count for part. 2244 * 2245 * @param obj Object being edited. 2246 * @param part Part to get the drag horizontal count value. 2247 * 2248 * @return Horizontal draggable count value 2249 */ 2250 EAPI int edje_edit_part_drag_count_x_get(Evas_Object *obj, const char *part); 2251 2252 /** 2253 * @brief Sets horizontal draggable count for part. 2254 * 2255 * @param obj Object being edited. 2256 * @param part Part to set the drag horizontal count value. 2257 * @param count The count value. 2258 * 2259 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2260 */ 2261 EAPI Eina_Bool edje_edit_part_drag_count_x_set(Evas_Object *obj, const char *part, int count); 2262 2263 /** 2264 * @brief Gets vertical draggable count for part. 2265 * 2266 * @param obj Object being edited. 2267 * @param part Part to get the drag vertical count value. 2268 * 2269 * @return Vertical draggable count value 2270 */ 2271 EAPI int edje_edit_part_drag_count_y_get(Evas_Object *obj, const char *part); 2272 2273 /** 2274 * @brief Sets vertical draggable count for part. 2275 * 2276 * @param obj Object being edited. 2277 * @param part Part to set the drag vertical count value. 2278 * @param count The count value. 2279 * 2280 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2281 */ 2282 EAPI Eina_Bool edje_edit_part_drag_count_y_set(Evas_Object *obj, const char *part, int count); 2283 2284 /** 2285 * @brief Gets the name of the part that is used as 'confine' for the given draggies. 2286 * 2287 * @param obj Object being edited. 2288 * @param part Part to get the name that is used as 'confine' for the given draggies. 2289 * 2290 * @return The name of the confine part, or NULL (if unset). 2291 */ 2292 EAPI const char * edje_edit_part_drag_confine_get(Evas_Object *obj, const char *part); 2293 2294 /** 2295 * @brief Sets the name of the part that is used as 'confine' for the given draggies. 2296 * 2297 * @param obj Object being edited. 2298 * @param part Part to set the name that is used as 'confine' for the given draggies. 2299 * @param confine The name of the confine part, or NULL to unset confine. 2300 * 2301 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2302 */ 2303 EAPI Eina_Bool edje_edit_part_drag_confine_set(Evas_Object *obj, const char *part, const char *confine); 2304 2305 /** 2306 * @brief Gets the name of the part that is used as the receiver of the drag event. 2307 * 2308 * @param obj Object being edited. 2309 * @param part Part to get the name that is used as the receiver of the drag event. 2310 * 2311 * @return The name of the part that will receive events, or NULL (if unset). 2312 */ 2313 EAPI const char * edje_edit_part_drag_event_get(Evas_Object *obj, const char *part); 2314 2315 /** 2316 * @brief Sets the name of the part that will receive events from the given draggies. 2317 * 2318 * @param obj Object being edited. 2319 * @param part Part to set the name that will receive events from the given draggies. 2320 * @param event The name of the part that will receive events, or NULL to unset. 2321 * 2322 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2323 */ 2324 EAPI Eina_Bool edje_edit_part_drag_event_set(Evas_Object *obj, const char *part, const char *event); 2325 2326 /** 2327 * @brief Gets the name of the part that is used as 'threshold' for the given draggies. 2328 * 2329 * @param obj Object being edited. 2330 * @param part Part to get the name that is used as 'threshold' for the given draggies. 2331 * 2332 * @return The name of the threshold part, or NULL (if unset). 2333 */ 2334 EAPI const char * edje_edit_part_drag_threshold_get(Evas_Object *obj, const char *part); 2335 2336 /** 2337 * @brief Sets the name of the part that is used as 'threshold' for the given draggies. 2338 * 2339 * @param obj Object being edited. 2340 * @param part Part to set the name that is used as 'threshold' for the given draggies. 2341 * @param threshold The name of the threshold part, or NULL to unset confine. 2342 * 2343 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2344 */ 2345 EAPI Eina_Bool edje_edit_part_drag_threshold_set(Evas_Object *obj, const char *part, const char *threshold); 2346 2347 //@} 2348 /******************************************************************************/ 2349 /******************************* BOX API ****************************/ 2350 /******************************************************************************/ 2351 /** 2352 * @name Box Description API 2353 * Functions to deal with box (see @ref edcref). 2354 */ //@{ 2355 2356 /** 2357 * @brief Gets primary layout of the box. 2358 * 2359 * @note The returned string should be freed with @c eina_stringshare_del(). 2360 * @param obj Object being edited. 2361 * @param part Part that have BOX type. 2362 * @param state Name of the state. 2363 * @param value Value of the state. 2364 * 2365 * @return Primary layout of a BOX part in given state. 2366 * @since 1.14 2367 */ 2368 EAPI Eina_Stringshare * edje_edit_state_box_layout_get(Evas_Object *obj, const char *part, const char *state, double value); 2369 2370 /** 2371 * @brief Sets primary layout of the box. 2372 * 2373 * When trying to set primary layout to NULL, function will use 2374 * alternative layout instead. 2375 * 2376 * @param obj Object being edited. 2377 * @param part Part that have BOX type. 2378 * @param state Name of the state. 2379 * @param value Value of the state. 2380 * @param layout New primary layout to set name. 2381 * 2382 * Possible layouts: 2383 * @li horizontal (default) 2384 * @li vertical 2385 * @li horizontal_homogeneous 2386 * @li vertical_homogeneous 2387 * @li horizontal_max (homogeneous to the max sized child) 2388 * @li vertical_max 2389 * @li horizontal_flow 2390 * @li vertical_flow 2391 * @li stack 2392 * @li some_other_custom_layout_set_by_the_application 2393 * 2394 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2395 * @since 1.14 2396 */ 2397 EAPI Eina_Bool edje_edit_state_box_layout_set(Evas_Object *obj, const char *part, const char *state, double value, char *layout); 2398 2399 /** 2400 * @brief Gets fallback layout of the box. 2401 * 2402 * @note The returned string should be freed with @c eina_stringshare_del(). 2403 * @param obj Object being edited. 2404 * @param part Part that have BOX type. 2405 * @param state Name of the state. 2406 * @param value Value of the state. 2407 * 2408 * @return Fallback layout of a BOX part in given state. 2409 * @since 1.14 2410 */ 2411 EAPI Eina_Stringshare * edje_edit_state_box_alt_layout_get(Evas_Object *obj, const char *part, const char *state, double value); 2412 2413 /** 2414 * @brief Sets fallback layout of the box. 2415 * 2416 * When trying to set fallback layout to NULL, function will use 2417 * default layout ("horizontal") instead. 2418 * 2419 * @param obj Object being edited. 2420 * @param part Part that have BOX type. 2421 * @param state Name of the state. 2422 * @param value Value of the state. 2423 * @param layout New fallback layout to set name. 2424 * 2425 * Possible layouts: 2426 * @li horizontal (default) 2427 * @li vertical 2428 * @li horizontal_homogeneous 2429 * @li vertical_homogeneous 2430 * @li horizontal_max (homogeneous to the max sized child) 2431 * @li vertical_max 2432 * @li horizontal_flow 2433 * @li vertical_flow 2434 * @li stack 2435 * @li some_other_custom_layout_set_by_the_application 2436 * 2437 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2438 * @since 1.14 2439 */ 2440 EAPI Eina_Bool edje_edit_state_box_alt_layout_set(Evas_Object *obj, const char *part, const char *state, double value, char *layout); 2441 2442 //@} 2443 /******************************************************************************/ 2444 /************************** TABLE API *************************************/ 2445 /******************************************************************************/ 2446 /** 2447 * @name Table Description API 2448 * Functions to deal with table (see @ref edcref). 2449 */ //@{ 2450 2451 /** 2452 * @brief Sets homogeneous mode for TABLE part. 2453 * 2454 * @param obj Object being edited. 2455 * @param part Part that have TABLE type. 2456 * @param state Name of the state. 2457 * @param value Value of the state. 2458 * @param homogeneous Homogeneous mode for table. 2459 * 2460 * Possible modes: 2461 * @li EDJE_OBJECT_TABLE_HOMOGENEOUS_NONE, 2462 * @li EDJE_OBJECT_TABLE_HOMOGENEOUS_TABLE, 2463 * @li EDJE_OBJECT_TABLE_HOMOGENEOUS_ITEM 2464 * 2465 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2466 * @since 1.14 2467 */ 2468 EAPI Eina_Bool 2469 edje_edit_state_table_homogeneous_set(Evas_Object *obj, const char *part, const char *state, double value, unsigned char homogeneous); 2470 /** 2471 * @brief Gets homogeneous mode for TABLE part. 2472 * 2473 * @param obj Object being edited. 2474 * @param part Part that have TABLE type. 2475 * @param state Name of the state. 2476 * @param value Value of the state. 2477 * 2478 * Possible modes: 2479 * @li EDJE_OBJECT_TABLE_HOMOGENEOUS_NONE, 2480 * @li EDJE_OBJECT_TABLE_HOMOGENEOUS_TABLE, 2481 * @li EDJE_OBJECT_TABLE_HOMOGENEOUS_ITEM 2482 * 2483 * @return Table homogeneous mode on success, or @c 0 on any error. 2484 * @since 1.14 2485 */ 2486 EAPI unsigned char edje_edit_state_table_homogeneous_get(Evas_Object *obj, const char *part, const char *state, double value); 2487 2488 //@} 2489 /******************************************************************************/ 2490 /*********************** TABLE & BOX API **********************************/ 2491 /******************************************************************************/ 2492 /** 2493 * @name "Container" Description API 2494 * Functions to deal both with box and table (see @ref edcref). 2495 * Those functions called edje_edit_state_container_<something> because they 2496 * are working both for TABLE and BOX at same time. 2497 */ //@{ 2498 2499 /** 2500 * @deprecated Use edje_edit_state_container_min_h_get() and 2501 * edje_edit_state_container_min_v_get() instead. 2502 * 2503 * @brief Gets whether vertical or horizontal minimum size's of the box are equal 2504 * to the minimum vertical or horizontal size of items 2505 * (function for BOX or TABLE part. 2506 * If EINA_TRUE - is equal, if EINA_FALSE - is not) 2507 * 2508 * @param obj Object being edited. 2509 * @param part Part that have BOX/TABLE type. 2510 * @param state Name of the state. 2511 * @param value Value of the state. 2512 * @param h Variable to store horizontal min value. 2513 * @param v Variable to store vertical min value. 2514 * 2515 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2516 * @since 1.14 2517 */ 2518 EINA_DEPRECATED 2519 EAPI Eina_Bool edje_edit_state_container_min_get(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool *h, Eina_Bool *v); 2520 2521 /** 2522 * @brief Gets whether horizontal min size of the container is equal to the min 2523 * horizontal size of items (BOX and TABLE part functions). 2524 * 2525 * @param obj Object being edited. 2526 * @param part Part that has BOX/TABLE type. 2527 * @param state Name of the state. 2528 * @param value Value of the state. 2529 * 2530 * @return @c EINA_TRUE If the part forces container's minimal horizontal size, 2531 * @c EINA_FALSE otherwise. 2532 * @since 1.16 2533 */ 2534 EAPI Eina_Bool 2535 edje_edit_state_container_min_h_get(Evas_Object *obj, const char *part, const char *state, double value); 2536 2537 /** 2538 * @brief Gets whether vertical min size of the container is equal to the min vertical 2539 * size of items (BOX and TABLE part functions). 2540 * 2541 * @param obj Object being edited. 2542 * @param part Part that has BOX/TABLE type. 2543 * @param state Name of the state. 2544 * @param value Value of the state. 2545 * 2546 * @return @c EINA_TRUE If the part forces container's minimal horizontal size, 2547 * @c EINA_FALSE otherwise. 2548 * @since 1.16 2549 */ 2550 EAPI Eina_Bool 2551 edje_edit_state_container_min_v_get(Evas_Object *obj, const char *part, const char *state, double value); 2552 2553 /** 2554 * @deprecated Use edje_edit_state_container_min_h_set() and 2555 * edje_edit_state_container_min_v_set() instead. 2556 * 2557 * @brief Sets whether vertical or horizontal minimum size's of the box are equal 2558 * to the minimum vertical or horizontal size of items 2559 * (function for BOX or TABLE part. 2560 * If EINA_TRUE - is equal, if EINA_FALSE - is not) 2561 * 2562 * @param obj Object being edited. 2563 * @param part Part that have BOX/TABLE type. 2564 * @param state Name of the state. 2565 * @param value Value of the state. 2566 * @param h horizontal min value. 2567 * @param v vertical min value. 2568 * 2569 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2570 * @since 1.14 2571 */ 2572 EINA_DEPRECATED 2573 EAPI Eina_Bool edje_edit_state_container_min_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool h, Eina_Bool v); 2574 2575 /** 2576 * @brief Sets whether horizontal min size of the container should be equal to the min 2577 * horizontal size of items (BOX and TABLE part functions). 2578 * 2579 * @param obj Object being edited. 2580 * @param part Part that has BOX/TABLE type. 2581 * @param state Name of the state. 2582 * @param value Value of the state. 2583 * @param h New horizontal min value. 2584 * 2585 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2586 * 2587 * @since 1.16 2588 */ 2589 EAPI Eina_Bool 2590 edje_edit_state_container_min_h_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool h); 2591 2592 /** 2593 * @brief Sets whether vertical min size of the container should be equal to the min 2594 * vertical size of items (BOX and TABLE part functions). 2595 * 2596 * @param obj Object being edited. 2597 * @param part Part that has BOX/TABLE type. 2598 * @param state Name of the state. 2599 * @param value Value of the state. 2600 * @param v New vertical min value. 2601 * 2602 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2603 * @since 1.16 2604 */ 2605 EAPI Eina_Bool 2606 edje_edit_state_container_min_v_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool v); 2607 2608 /** 2609 * @deprecated Use edje_edit_state_container_padding_x_get() and 2610 * edje_edit_state_container_padding_y_get() instead. 2611 * 2612 * @brief Gets x and y paddings for BOX or TABLE part. 2613 * 2614 * @param obj Object being edited. 2615 * @param part Part that have BOX/TABLE type. 2616 * @param state Name of the state. 2617 * @param value Value of the state. 2618 * @param x Variable to store x padding. 2619 * @param y Variable to store y padding. 2620 * 2621 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2622 * @since 1.14 2623 */ 2624 EINA_DEPRECATED EAPI Eina_Bool 2625 edje_edit_state_container_padding_get(Evas_Object *obj, const char *part, const char *state, double value, int *x, int *y); 2626 2627 /** 2628 * @brief Gets x padding for BOX or TABLE part. 2629 * 2630 * @param obj Object being edited. 2631 * @param part Part that has BOX/TABLE type. 2632 * @param state Name of the state. 2633 * @param value Value of the state. 2634 * 2635 * @return The padding by x axis. 2636 * @since 1.16 2637 */ 2638 EAPI int 2639 edje_edit_state_container_padding_x_get(Evas_Object *obj, const char *part, const char *state, double value); 2640 2641 /** 2642 * @brief Gets y padding for BOX or TABLE part. 2643 * 2644 * @param obj Object being edited. 2645 * @param part Part that has BOX/TABLE type. 2646 * @param state Name of the state. 2647 * @param value Value of the state. 2648 * 2649 * @return The padding by y axis. 2650 * @since 1.16 2651 */ 2652 EAPI int 2653 edje_edit_state_container_padding_y_get(Evas_Object *obj, const char *part, const char *state, double value); 2654 2655 /** 2656 * @deprecated Use edje_edit_state_container_padding_x_set() and 2657 * edje_edit_state_container_padding_y_set() instead. 2658 * 2659 * @brief Sets x and y paddings for BOX or TABLE part. 2660 * 2661 * @param obj Object being edited. 2662 * @param part Part that have BOX/TABLE type. 2663 * @param state Name of the state. 2664 * @param value Value of the state. 2665 * @param x Value for setting x padding. 2666 * @param y Value for setting y padding. 2667 * 2668 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2669 * @since 1.14 2670 */ 2671 EINA_DEPRECATED EAPI Eina_Bool 2672 edje_edit_state_container_padding_set(Evas_Object *obj, const char *part, const char *state, double value, int x, int y); 2673 2674 /** 2675 * @brief Sets x padding for BOX or TABLE part. 2676 * 2677 * @param obj Object being edited. 2678 * @param part Part that has BOX/TABLE type. 2679 * @param state Name of the state. 2680 * @param value Value of the state. 2681 * @param x New x padding value. 2682 * 2683 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2684 * @since 1.16 2685 */ 2686 EAPI Eina_Bool 2687 edje_edit_state_container_padding_x_set(Evas_Object *obj, const char *part, const char *state, double value, int x); 2688 2689 /** 2690 * @brief Sets y padding for BOX or TABLE part. 2691 * 2692 * @param obj Object being edited. 2693 * @param part Part that has BOX/TABLE type. 2694 * @param state Name of the state. 2695 * @param value Value of the state. 2696 * @param y New y padding value. 2697 * 2698 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2699 * @since 1.16 2700 */ 2701 EAPI Eina_Bool 2702 edje_edit_state_container_padding_y_set(Evas_Object *obj, const char *part, const char *state, double value, int y); 2703 2704 /** 2705 * @deprecated Use edje_edit_state_container_align_x_set() and 2706 * edje_edit_state_container_align_y_set() instead. 2707 * 2708 * @brief Sets x and y align for BOX or TABLE part. 2709 * 2710 * @param obj Object being edited. 2711 * @param part Part that have BOX/TABLE type. 2712 * @param state Name of the state. 2713 * @param value Value of the state. 2714 * @param x Variable to store x value. 2715 * @param y Variable to store y value. 2716 * 2717 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2718 * @since 1.14 2719 */ 2720 EINA_DEPRECATED EAPI Eina_Bool 2721 edje_edit_state_container_align_set(Evas_Object *obj, const char *part, const char *state, double value, double x, double y); 2722 2723 /** 2724 * @brief Sets x align for BOX or TABLE part. 2725 * 2726 * @param obj Object being edited. 2727 * @param part Part that has BOX/TABLE type. 2728 * @param state Name of the state. 2729 * @param value Value of the state. 2730 * @param x New x align value. 2731 * 2732 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2733 * @since 1.16 2734 */ 2735 EAPI Eina_Bool 2736 edje_edit_state_container_align_x_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 2737 2738 /** 2739 * @brief Sets y align for BOX or TABLE part. 2740 * 2741 * @param obj Object being edited. 2742 * @param part Part that has BOX/TABLE type. 2743 * @param state Name of the state. 2744 * @param value Value of the state. 2745 * @param y New y align value. 2746 * 2747 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2748 * @since 1.16 2749 */ 2750 EAPI Eina_Bool 2751 edje_edit_state_container_align_y_set(Evas_Object *obj, const char *part, const char *state, double value, double y); 2752 2753 /** 2754 * @deprecated Use edje_edit_state_container_align_x_set() and 2755 * edje_edit_state_container_align_y_set() instead. 2756 * 2757 * @brief Gets x and y align for BOX or TABLE part. 2758 * 2759 * @param obj Object being edited. 2760 * @param part Part that have BOX/TABLE type. 2761 * @param state Name of the state. 2762 * @param value Value of the state. 2763 * @param x Value for setting x align. 2764 * @param y Value for setting y align. 2765 * 2766 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2767 * @since 1.14 2768 */ 2769 EINA_DEPRECATED EAPI Eina_Bool 2770 edje_edit_state_container_align_get(Evas_Object *obj, const char *part, const char *state, double value, double *x, double *y); 2771 2772 /** 2773 * @brief Gets x align for BOX or TABLE part. 2774 * 2775 * @param obj Object being edited. 2776 * @param part Part that has BOX/TABLE type. 2777 * @param state Name of the state. 2778 * @param value Value of the state. 2779 * 2780 * @return The align by x axis. 2781 * @since 1.16 2782 */ 2783 EAPI double 2784 edje_edit_state_container_align_x_get(Evas_Object *obj, const char *part, const char *state, double value); 2785 /** 2786 * @brief Gets y align for BOX or TABLE part. 2787 * 2788 * @param obj Object being edited. 2789 * @param part Part that has BOX/TABLE type. 2790 * @param state Name of the state. 2791 * @param value Value of the state. 2792 * 2793 * @return The align by y axis. 2794 * @since 1.16 2795 */ 2796 EAPI double 2797 edje_edit_state_container_align_y_get(Evas_Object *obj, const char *part, const char *state, double value); 2798 2799 //@} 2800 /******************************************************************************/ 2801 /************************** BOX & TABLE ITEMS API *************************/ 2802 /******************************************************************************/ 2803 /** 2804 * @name Items API 2805 * Functions to deal with table and box part's items (see @ref edcref). 2806 */ //@{ 2807 2808 /** 2809 * @brief Appends new item to box or table part. 2810 * 2811 * @param obj Object being edited. 2812 * @param part Part to add a new item. This part should have BOX or TABLE type. 2813 * @param item_name Name of new item that is not exist in BOX or TABLE yet. 2814 * @param source_group Source (means group name) of the new item 2815 * 2816 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2817 * @since 1.11 2818 */ 2819 EAPI Eina_Bool edje_edit_part_item_append(Evas_Object *obj, const char *part, const char *item_name, const char *source_group); 2820 2821 /** 2822 * @brief Inserts new item to box or table part before specified existing item. 2823 * 2824 * @param obj Object being edited. 2825 * @param part Part to add a new item. This part should have BOX or TABLE type. 2826 * @param item_name Name of new item that is not exist in BOX or TABLE yet. 2827 * @param item_before Name of repeated item that is exist in BOX or TABLE. 2828 * @param source_group Source (means group name) of the new item. 2829 * 2830 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2831 * @since 1.18 2832 */ 2833 EINA_DEPRECATED 2834 EAPI Eina_Bool 2835 edje_edit_part_item_insert_before(Evas_Object *obj, const char *part, const char *item_name, const char *item_before, const char *source_group); 2836 2837 /** 2838 * @brief Inserts new item to box or table part before specified existing item. 2839 * 2840 * @param obj Object being edited. 2841 * @param part Part to add a new item. This part should have BOX or TABLE type. 2842 * @param item_name Name of new item that is not exist in BOX or TABLE yet. 2843 * @param index Index of repeated item that is exist in BOX or TABLE. 2844 * @param source_group Source (means group name) of the new item. 2845 * 2846 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2847 * @since 1.18 2848 */ 2849 EAPI Eina_Bool 2850 edje_edit_part_item_insert_before_index(Evas_Object *obj, const char *part, const char *item_name, unsigned int index, const char *source_group); 2851 2852 /** 2853 * @brief Inserts new item to box or table part after specified existing item. 2854 * 2855 * @param obj Object being edited. 2856 * @param part Part to add a new item. This part should have BOX or TABLE type. 2857 * @param item_name Name of new item that is not exist in BOX or TABLE yet. 2858 * @param item_after Name of repeated item that is exist in BOX or TABLE. 2859 * @param source_group Source (means group name) of the new item. 2860 * 2861 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2862 * @since 1.18 2863 */ 2864 EINA_DEPRECATED 2865 EAPI Eina_Bool 2866 edje_edit_part_item_insert_after(Evas_Object *obj, const char *part, const char *item_name, const char *item_after, const char *source_group); 2867 2868 /** 2869 * @brief Inserts new item to box or table part after specified existing item. 2870 * 2871 * @param obj Object being edited. 2872 * @param part Part to add a new item. This part should have BOX or TABLE type. 2873 * @param item_name Name of new item that is not exist in BOX or TABLE yet. 2874 * @param index Index of repeated item that is exist in BOX or TABLE. 2875 * @param source_group Source (means group name) of the new item. 2876 * 2877 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2878 * @since 1.18 2879 */ 2880 EAPI Eina_Bool 2881 edje_edit_part_item_insert_after_index(Evas_Object *obj, const char *part, const char *item_name, unsigned int index, const char *source_group); 2882 2883 /** 2884 * @brief Inserts new item to box or table part directly into specified position. 2885 * 2886 * @param obj Object being edited. 2887 * @param part Part to add a new item. This part should have BOX or TABLE type. 2888 * @param item_name Name of new item that is not exist in BOX or TABLE yet. 2889 * @param source_group Source (means group name) of the new item. 2890 * @param place Specified place to insert item into. Place cannot be less than 0 or 2891 * greater than current number of items in BOX or TABLE. 2892 * 2893 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2894 * @since 1.18 2895 */ 2896 EAPI Eina_Bool 2897 edje_edit_part_item_insert_at(Evas_Object *obj, const char *part, const char *item_name, const char *source_group, unsigned int place); 2898 2899 /** 2900 * @brief Restacks existing item above. 2901 * 2902 * @param obj Object being edited. 2903 * @param part Part which contain items. This part should have BOX or TABLE type. 2904 * @param item_name Name of item that will be moved above. 2905 * 2906 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2907 * @since 1.18 2908 */ 2909 EINA_DEPRECATED 2910 EAPI Eina_Bool 2911 edje_edit_part_item_move_above(Evas_Object *obj, const char *part, const char *item_name); 2912 2913 /** 2914 * @brief Restacks existing item above. 2915 * 2916 * @param obj Object being edited. 2917 * @param part Part which contain items. This part should have BOX or TABLE type. 2918 * @param index Index of item that will be moved above. 2919 * 2920 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2921 * @since 1.18 2922 */ 2923 EAPI Eina_Bool 2924 edje_edit_part_item_move_above_index(Evas_Object *obj, const char *part, unsigned int index); 2925 2926 /** 2927 * @brief Restacks existing item below. 2928 * 2929 * @param obj Object being edited. 2930 * @param part Part which contain items. This part should have BOX or TABLE type. 2931 * @param item_name Name of item that will be moved below. 2932 * 2933 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2934 * @since 1.18 2935 */ 2936 EINA_DEPRECATED 2937 EAPI Eina_Bool 2938 edje_edit_part_item_move_below(Evas_Object *obj, const char *part, const char *item_name); 2939 2940 /** 2941 * @brief Restacks existing item below. 2942 * 2943 * @param obj Object being edited. 2944 * @param part Part which contain items. This part should have BOX or TABLE type. 2945 * @param index Index of item that will be moved below. 2946 * 2947 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2948 * @since 1.18 2949 */ 2950 EAPI Eina_Bool 2951 edje_edit_part_item_move_below_index(Evas_Object *obj, const char *part, unsigned int index); 2952 2953 /** 2954 * @brief Gets the list of all part items in the given edje. 2955 * 2956 * @param obj Object being edited. 2957 * @param part Name of part which is TABLE or BOX part and contain items. 2958 * 2959 * @return A List containing all part items names found in the edje file. 2960 * @since 1.11 2961 */ 2962 EINA_DEPRECATED 2963 EAPI Eina_List * edje_edit_part_items_list_get(Evas_Object *obj, const char *part); 2964 2965 /** 2966 * @brief Gets the count of part items in the given edje. 2967 * 2968 * @param obj Object being edited. 2969 * @param part Name of part which is TABLE or BOX part and contain items. 2970 * 2971 * @return A count part items in case of success, and -1 otherwise. 2972 * @since 1.18 2973 */ 2974 EAPI int 2975 edje_edit_part_items_count_get(Evas_Object *obj, const char *part); 2976 2977 /** 2978 * @brief Deletes item from box or table part. 2979 * 2980 * @param obj Object being edited. 2981 * @param part Part to delete exist item. This part should have BOX or TABLE type. 2982 * @param name Name of exist item to delete it from BOX or TABLE. 2983 * 2984 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2985 * @since 1.11 2986 */ 2987 EINA_DEPRECATED 2988 EAPI Eina_Bool edje_edit_part_item_del(Evas_Object *obj, const char *part, const char* name); 2989 2990 /** 2991 * @brief Deletes item from box or table part by index. 2992 * 2993 * @param obj Object being edited. 2994 * @param part Part to delete exist item. This part should have BOX or TABLE type. 2995 * @param index Index of exist item to delete it from BOX or TABLE. 2996 * 2997 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 2998 * @since 1.18 2999 */ 3000 EAPI Eina_Bool 3001 edje_edit_part_item_index_del(Evas_Object *obj, const char *part, unsigned int index); 3002 3003 /** 3004 * @brief Sets name for item from table or box items. 3005 * 3006 * @param obj Object being edited. 3007 * @param part Part to change item's source. This part should have BOX or TABLE type. 3008 * @param index Index of item 3009 * @param name New item name. 3010 * 3011 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3012 * @since 1.18 3013 */ 3014 EAPI Eina_Bool 3015 edje_edit_part_item_index_name_set(Evas_Object *obj, const char *part, unsigned int index, const char *name); 3016 3017 /** 3018 * @brief Gets name for item from table or box items. 3019 * 3020 * @param obj Object being edited. 3021 * @param part Part to return item's source. This part should have BOX or TABLE type. 3022 * @param index Index of item. 3023 * 3024 * @return name of the given item. 3025 * @since 1.18 3026 */ 3027 EAPI const char * 3028 edje_edit_part_item_index_name_get(Evas_Object *obj, const char *part, unsigned int index); 3029 3030 /** 3031 * @brief Sets source for item from table or box items. 3032 * 3033 * @param obj Object being edited. 3034 * @param part Part to change item's source. This part should have BOX or TABLE type. 3035 * @param item_name Name of item. 3036 * @param source_group New group name. 3037 * 3038 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3039 * @since 1.11 3040 */ 3041 EINA_DEPRECATED 3042 EAPI Eina_Bool edje_edit_part_item_source_set(Evas_Object *obj, const char *part, const char *item_name, const char *source_group); 3043 3044 /** 3045 * @brief Sets source for item from table or box items. 3046 * 3047 * @param obj Object being edited. 3048 * @param part Part to change item's source. This part should have BOX or TABLE type. 3049 * @param index Index of item 3050 * @param source_group New group name. 3051 * 3052 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3053 * @since 1.18 3054 */ 3055 EAPI Eina_Bool 3056 edje_edit_part_item_index_source_set(Evas_Object *obj, const char *part, unsigned int index, const char *source_group); 3057 3058 /** 3059 * @brief Gets source for item from table or box items. 3060 * 3061 * @param obj Object being edited. 3062 * @param part Part to return item's source. This part should have BOX or TABLE type. 3063 * @param item_name Name of item. 3064 * 3065 * @return source of the given item. 3066 * @since 1.11 3067 */ 3068 EINA_DEPRECATED 3069 EAPI const char * edje_edit_part_item_source_get(Evas_Object *obj, const char *part, const char *item_name); 3070 3071 /** 3072 * @brief Gets source for item from table or box items. 3073 * 3074 * @param obj Object being edited. 3075 * @param part Part to return item's source. This part should have BOX or TABLE type. 3076 * @param index Index of item. 3077 * 3078 * @return source of the given item. 3079 * @since 1.18 3080 */ 3081 EAPI const char * 3082 edje_edit_part_item_index_source_get(Evas_Object *obj, const char *part, unsigned int index); 3083 3084 /** 3085 * @brief Gets the minimum width value of a part's item. 3086 * 3087 * @param obj Object being edited. 3088 * @param part Part that contain state. 3089 * @param item The name of the item to get minimum width. 3090 * 3091 * @return The minimum width value. 3092 * @since 1.11 3093 */ 3094 EINA_DEPRECATED 3095 EAPI int edje_edit_part_item_min_w_get(Evas_Object *obj, const char *part, const char *item); 3096 3097 /** 3098 * @brief Sets the minimum width value of a part's item. 3099 * The minimum width should be greater than 0. 3100 * 3101 * @param obj Object being edited. 3102 * @param part Part that contain state. 3103 * @param item The name of the item to set minimum width. 3104 * @param min_w Minimum width value. 3105 * 3106 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3107 * @since 1.11 3108 */ 3109 EINA_DEPRECATED 3110 EAPI Eina_Bool edje_edit_part_item_min_w_set(Evas_Object *obj, const char *part, const char *item, int min_w); 3111 3112 /** 3113 * @brief Gets the minimum height value of a part's item. 3114 * 3115 * @param obj Object being edited. 3116 * @param part Part that contain state. 3117 * @param item The name of the item to get minimum height. 3118 * 3119 * @return The minimum height value. 3120 * @since 1.11 3121 */ 3122 EINA_DEPRECATED 3123 EAPI int edje_edit_part_item_min_h_get(Evas_Object *obj, const char *part, const char *item); 3124 3125 /** 3126 * @brief Sets the minimum height value of a part's item. 3127 * The minimum height should be greater than 0. 3128 * 3129 * @param obj Object being edited. 3130 * @param part Part that contain state. 3131 * @param item The name of the item to set minimum height. 3132 * @param min_h Minimum height value. 3133 * 3134 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3135 * @since 1.11 3136 */ 3137 EINA_DEPRECATED 3138 EAPI Eina_Bool edje_edit_part_item_min_h_set(Evas_Object *obj, const char *part, const char *item, int min_h); 3139 3140 /** 3141 * @brief Gets the maximum width value of a part's item. 3142 * 3143 * @param obj Object being edited. 3144 * @param part Part that contain state. 3145 * @param item The name of the item to get maximum width. 3146 * 3147 * @return The maximum width value. 3148 * @since 1.11 3149 */ 3150 EINA_DEPRECATED 3151 EAPI int edje_edit_part_item_max_w_get(Evas_Object *obj, const char *part, const char *item); 3152 3153 /** 3154 * @brief Sets the maximum width value of a part's item. 3155 * The maximum width should be greater than -1. 3156 * The value -1 means that state doesn't have any boundaries on width direction. 3157 * (it can be any size that is bigger than it's min) 3158 * 3159 * @param obj Object being edited. 3160 * @param part Part that contain state. 3161 * @param item The name of the item to set maximum width. 3162 * @param max_w Maximum width value. 3163 * 3164 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3165 * @since 1.11 3166 */ 3167 EINA_DEPRECATED 3168 EAPI Eina_Bool edje_edit_part_item_max_w_set(Evas_Object *obj, const char *part, const char *item, int max_w); 3169 3170 /** 3171 * @brief Gets the maximum height value of a part's item. 3172 * 3173 * @param obj Object being edited. 3174 * @param part Part that contain state. 3175 * @param item The name of the item to get maximum height. 3176 * 3177 * @return The maximum height value. 3178 * @since 1.11 3179 */ 3180 EINA_DEPRECATED 3181 EAPI int edje_edit_part_item_max_h_get(Evas_Object *obj, const char *part, const char *item); 3182 3183 /** 3184 * @brief Sets the maximum height value of a part's item. 3185 * The maximum height should be greater than -1. 3186 * The value -1 means that state doesn't have any boundaries on height direction. 3187 * (it can be any size that is bigger than it's min) 3188 * 3189 * @param obj Object being edited. 3190 * @param part Part that contain state. 3191 * @param item The name of the item to set maximum height. 3192 * @param max_h Maximum height value. 3193 * 3194 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3195 * @since 1.11 3196 */ 3197 EINA_DEPRECATED 3198 EAPI Eina_Bool edje_edit_part_item_max_h_set(Evas_Object *obj, const char *part, const char *item, int max_h); 3199 3200 /** 3201 * @brief Gets the aspect width value of a part's item. 3202 * 3203 * @param obj Object being edited. 3204 * @param part Part that contain state. 3205 * @param item The name of the item to get aspect width. 3206 * 3207 * @return The aspect width value. 3208 * @since 1.11 3209 */ 3210 EINA_DEPRECATED 3211 EAPI int edje_edit_part_item_aspect_w_get(Evas_Object *obj, const char *part, const char *item); 3212 3213 /** 3214 * @brief Sets the aspect width value of a part's item. 3215 * 3216 * @param obj Object being edited. 3217 * @param part Part that contain state. 3218 * @param item The name of the item to set aspect width. 3219 * @param aspect_w Aspect width value. 3220 * 3221 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3222 * @since 1.11 3223 */ 3224 EINA_DEPRECATED 3225 EAPI Eina_Bool edje_edit_part_item_aspect_w_set(Evas_Object *obj, const char *part, const char *item, int aspect_w); 3226 3227 /** 3228 * @brief Gets the aspect height value of a part's item. 3229 * 3230 * @param obj Object being edited. 3231 * @param part Part that contain state. 3232 * @param item The name of the item to get aspect height. 3233 * 3234 * @return The maximum height value. 3235 * @since 1.11 3236 */ 3237 EINA_DEPRECATED 3238 EAPI int edje_edit_part_item_aspect_h_get(Evas_Object *obj, const char *part, const char *item); 3239 3240 /** 3241 * @brief Sets the aspect height value of a part's item. 3242 * 3243 * @param obj Object being edited. 3244 * @param part Part that contain state. 3245 * @param item The name of the item to set aspect height. 3246 * @param aspect_h Aspect height value. 3247 * 3248 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3249 * @since 1.11 3250 */ 3251 EINA_DEPRECATED 3252 EAPI Eina_Bool edje_edit_part_item_aspect_h_set(Evas_Object *obj, const char *part, const char *item, int aspect_h); 3253 3254 /** 3255 * @brief Gets the prefer width value of a part's item. 3256 * 3257 * @param obj Object being edited. 3258 * @param part Part that contain state. 3259 * @param item The name of the item to get prefer width. 3260 * 3261 * @return The prefer width value. 3262 * @since 1.11 3263 */ 3264 EINA_DEPRECATED 3265 EAPI int edje_edit_part_item_prefer_w_get(Evas_Object *obj, const char *part, const char *item); 3266 3267 /** 3268 * @brief Gets aspect mode for an item of TABLE or BOX. 3269 * 3270 * This may return next values: 3271 * - EDJE_ASPECT_CONTROL_NONE 3272 * - EDJE_ASPECT_CONTROL_NEITHER 3273 * - EDJE_ASPECT_CONTROL_HORIZONTAL 3274 * - EDJE_ASPECT_CONTROL_VERTICAL 3275 * - EDJE_ASPECT_CONTROL_BOTH 3276 * 3277 * @param obj Object being edited. 3278 * @param part Part that contain item. 3279 * @param item The name of the item to set aspect mode. 3280 * 3281 * @return One of possible enum Edje_Aspect_Control. 3282 * @since 1.11 3283 */ 3284 EINA_DEPRECATED 3285 EAPI Edje_Aspect_Control 3286 edje_edit_part_item_aspect_mode_get(Evas_Object *obj, const char *part, const char *item); 3287 3288 /** 3289 * @brief Sets aspect mode for an item of TABLE or BOX. 3290 * 3291 * Mode may be next: 3292 * - EDJE_ASPECT_CONTROL_NONE 3293 * - EDJE_ASPECT_CONTROL_NEITHER 3294 * - EDJE_ASPECT_CONTROL_HORIZONTAL 3295 * - EDJE_ASPECT_CONTROL_VERTICAL 3296 * - EDJE_ASPECT_CONTROL_BOTH 3297 * 3298 * @param obj Object being edited. 3299 * @param part Part that contain item. 3300 * @param item The name of the item to set aspect mode. 3301 * @param mode One of possible enum from Edje_Aspect_Control: 3302 3303 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3304 * @since 1.11 3305 */ 3306 EINA_DEPRECATED 3307 EAPI Eina_Bool edje_edit_part_item_aspect_mode_set(Evas_Object *obj, const char *part, const char *item, Edje_Aspect_Control mode); 3308 3309 /** 3310 * @brief Sets the prefer width value of a part's item. 3311 * 3312 * @param obj Object being edited. 3313 * @param part Part that contain state. 3314 * @param item The name of the item to set prefer width. 3315 * @param prefer_w Prefer width value. 3316 * 3317 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3318 * @since 1.11 3319 */ 3320 EINA_DEPRECATED 3321 EAPI Eina_Bool edje_edit_part_item_prefer_w_set(Evas_Object *obj, const char *part, const char *item, int prefer_w); 3322 3323 /** 3324 * @brief Gets the prefer height value of a part's item. 3325 * 3326 * @param obj Object being edited. 3327 * @param part Part that contain state. 3328 * @param item The name of the item to get prefer height. 3329 * 3330 * @return The maximum height value. 3331 * @since 1.11 3332 */ 3333 EINA_DEPRECATED 3334 EAPI int edje_edit_part_item_prefer_h_get(Evas_Object *obj, const char *part, const char *item); 3335 3336 /** 3337 * @brief Sets the prefer height value of a part's item. 3338 * 3339 * @param obj Object being edited. 3340 * @param part Part that contain state. 3341 * @param item The name of the item to set prefer height. 3342 * @param prefer_h Prefer height value. 3343 * 3344 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3345 * @since 1.11 3346 */ 3347 EINA_DEPRECATED 3348 EAPI Eina_Bool edje_edit_part_item_prefer_h_set(Evas_Object *obj, const char *part, const char *item, int prefer_h); 3349 3350 /** 3351 * @brief Gets the spread width value of a part's item. 3352 * 3353 * @param obj Object being edited. 3354 * @param part Part that contain state. 3355 * @param item The name of the item to get spread width. 3356 * 3357 * @return The spread width value. 3358 * @since 1.11 3359 */ 3360 EINA_DEPRECATED 3361 EAPI int edje_edit_part_item_spread_w_get(Evas_Object *obj, const char *part, const char *item); 3362 3363 /** 3364 * @brief Sets the spread width value of a part's item. 3365 * 3366 * @attention be careful, if you set up huge number (like 10 or 100) width and height of 3367 * spread is being multiplied and you will get huge number of objects that may "eat" 3368 * all of your processor performance at once... Or if you want, you may 3369 * get some coffee and wait until it will recalculate all of those objects :) 3370 * 3371 * @param obj Object being edited. 3372 * @param part Part that contain state. 3373 * @param item The name of the item to set spread width. 3374 * @param spread_w Maximum width value. 3375 * 3376 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 3377 * @since 1.11 3378 */ 3379 EINA_DEPRECATED 3380 EAPI Eina_Bool edje_edit_part_item_spread_w_set(Evas_Object *obj, const char *part, const char *item, int spread_w); 3381 3382 /** 3383 * @brief Gets the spread height value of a part's item. 3384 * 3385 * @attention be careful, if you set up huge number (like 10 or 100) width and height of 3386 * spread is being multiplied and you will get huge number of objects that may "eat" 3387 * all of your processor performance at once... Or if you want, you may 3388 * get some coffee and wait until it will recalculate all of those objects :) 3389 * 3390 * @param obj Object being edited. 3391 * @param part Part that contain state. 3392 * @param item The name of the item to get spread height. 3393 * 3394 * @return The spread height value. 3395 * @since 1.11 3396 */ 3397 EINA_DEPRECATED 3398 EAPI int edje_edit_part_item_spread_h_get(Evas_Object *obj, const char *part, const char *item); 3399 3400 /** 3401 * @brief Sets the spread height value of a part's item. 3402 * 3403 * @param obj Object being edited. 3404 * @param part Part that contain state. 3405 * @param item The name of the item to set spread height. 3406 * @param spread_h spread height value. 3407 * 3408 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 3409 * @since 1.11 3410 */ 3411 EINA_DEPRECATED 3412 EAPI Eina_Bool edje_edit_part_item_spread_h_set(Evas_Object *obj, const char *part, const char *item, int spread_h); 3413 3414 /** 3415 * @brief Gets the minimum width value of a part's item. 3416 * 3417 * @param obj Object being edited. 3418 * @param part Part that contain state. 3419 * @param index Index of the item to get minimum width. 3420 * 3421 * @return The minimum width value. 3422 * @since 1.18 3423 */ 3424 EAPI int 3425 edje_edit_part_item_index_min_w_get(Evas_Object *obj, const char *part, unsigned int index); 3426 3427 /** 3428 * @brief Sets the minimum width value of a part's item. 3429 * The minimum width should be greater than 0. 3430 * 3431 * @param obj Object being edited. 3432 * @param part Part that contain state. 3433 * @param index Index of the item to set minimum width. 3434 * @param min_w Minimum width value. 3435 * 3436 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3437 * @since 1.18 3438 */ 3439 EAPI Eina_Bool 3440 edje_edit_part_item_index_min_w_set(Evas_Object *obj, const char *part, unsigned int index, int min_w); 3441 3442 /** 3443 * @brief Gets the minimum height value of a part's item. 3444 * 3445 * @param obj Object being edited. 3446 * @param part Part that contain state. 3447 * @param index Index of the item to get minimum height. 3448 * 3449 * @return The minimum height value. 3450 * @since 1.18 3451 */ 3452 EAPI int 3453 edje_edit_part_item_index_min_h_get(Evas_Object *obj, const char *part, unsigned int index); 3454 3455 /** 3456 * @brief Sets the minimum height value of a part's item. 3457 * The minimum height should be greater than 0. 3458 * 3459 * @param obj Object being edited. 3460 * @param part Part that contain state. 3461 * @param index Index of the item to set minimum height. 3462 * @param min_h Minimum height value. 3463 * 3464 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3465 * @since 1.18 3466 */ 3467 EAPI Eina_Bool 3468 edje_edit_part_item_index_min_h_set(Evas_Object *obj, const char *part, unsigned int index, int min_h); 3469 3470 /** 3471 * @brief Gets the maximum width value of a part's item. 3472 * 3473 * @param obj Object being edited. 3474 * @param part Part that contain state. 3475 * @param index Index of the item to get maximum width. 3476 * 3477 * @return The maximum width value. 3478 * @since 1.18 3479 */ 3480 EAPI int 3481 edje_edit_part_item_index_max_w_get(Evas_Object *obj, const char *part, unsigned int index); 3482 3483 /** 3484 * @brief Sets the maximum width value of a part's item. 3485 * The maximum width should be greater than -1. 3486 * The value -1 means that state doesn't have any boundaries on width direction. 3487 * (it can be any size that is bigger than it's min) 3488 * 3489 * @param obj Object being edited. 3490 * @param part Part that contain state. 3491 * @param index Index of the item to set maximum width. 3492 * @param max_w Maximum width value. 3493 * 3494 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3495 * @since 1.18 3496 */ 3497 EAPI Eina_Bool 3498 edje_edit_part_item_index_max_w_set(Evas_Object *obj, const char *part, unsigned int index, int max_w); 3499 3500 /** 3501 * @brief Gets the maximum height value of a part's item. 3502 * 3503 * @param obj Object being edited. 3504 * @param part Part that contain state. 3505 * @param index Index of the item to get maximum height. 3506 * 3507 * @return The maximum height value. 3508 * @since 1.18 3509 */ 3510 EAPI int 3511 edje_edit_part_item_index_max_h_get(Evas_Object *obj, const char *part, unsigned int index); 3512 3513 /** 3514 * @brief Sets the maximum height value of a part's item. 3515 * The maximum height should be greater than -1. 3516 * The value -1 means that state doesn't have any boundaries on height direction. 3517 * (it can be any size that is bigger than it's min) 3518 * 3519 * @param obj Object being edited. 3520 * @param part Part that contain state. 3521 * @param index Index of the item to set maximum height. 3522 * @param max_h Maximum height value. 3523 * 3524 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3525 * @since 1.18 3526 */ 3527 EAPI Eina_Bool 3528 edje_edit_part_item_index_max_h_set(Evas_Object *obj, const char *part, unsigned int index, int max_h); 3529 3530 /** 3531 * @brief Gets the aspect width value of a part's item. 3532 * 3533 * @param obj Object being edited. 3534 * @param part Part that contain state. 3535 * @param index Index of the item to get aspect width. 3536 * 3537 * @return The aspect width value. 3538 * @since 1.18 3539 */ 3540 EAPI int 3541 edje_edit_part_item_index_aspect_w_get(Evas_Object *obj, const char *part, unsigned int index); 3542 3543 /** 3544 * @brief Sets the aspect width value of a part's item. 3545 * 3546 * @param obj Object being edited. 3547 * @param part Part that contain state. 3548 * @param index Index of the item to set aspect width. 3549 * @param aspect_w Aspect width value. 3550 * 3551 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3552 * @since 1.18 3553 */ 3554 EAPI Eina_Bool 3555 edje_edit_part_item_index_aspect_w_set(Evas_Object *obj, const char *part, unsigned int index, int aspect_w); 3556 3557 /** 3558 * @brief Gets the aspect height value of a part's item. 3559 * 3560 * @param obj Object being edited. 3561 * @param part Part that contain state. 3562 * @param index Index of the item to get aspect height. 3563 * 3564 * @return The maximum height value. 3565 * @since 1.18 3566 */ 3567 EAPI int 3568 edje_edit_part_item_index_aspect_h_get(Evas_Object *obj, const char *part, unsigned int index); 3569 3570 /** 3571 * @brief Sets the aspect height value of a part's item. 3572 * 3573 * @param obj Object being edited. 3574 * @param part Part that contain state. 3575 * @param index Index of the item to set aspect height. 3576 * @param aspect_h Aspect height value. 3577 * 3578 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3579 * @since 1.18 3580 */ 3581 EAPI Eina_Bool 3582 edje_edit_part_item_index_aspect_h_set(Evas_Object *obj, const char *part, unsigned int index, int aspect_h); 3583 3584 /** 3585 * @brief Gets the prefer width value of a part's item. 3586 * 3587 * @param obj Object being edited. 3588 * @param part Part that contain state. 3589 * @param index Index of the item to get prefer width. 3590 * 3591 * @return The prefer width value. 3592 * @since 1.18 3593 */ 3594 EAPI int 3595 edje_edit_part_item_index_prefer_w_get(Evas_Object *obj, const char *part, unsigned int index); 3596 3597 /** 3598 * @brief Gets aspect mode for an item of TABLE or BOX. 3599 * 3600 * This may return next values: 3601 * - EDJE_ASPECT_CONTROL_NONE 3602 * - EDJE_ASPECT_CONTROL_NEITHER 3603 * - EDJE_ASPECT_CONTROL_HORIZONTAL 3604 * - EDJE_ASPECT_CONTROL_VERTICAL 3605 * - EDJE_ASPECT_CONTROL_BOTH 3606 * 3607 * @param obj Object being edited. 3608 * @param part Part that contain item. 3609 * @param index Index of the item to set aspect mode. 3610 * 3611 * @return One of possible enum Edje_Aspect_Control. 3612 * @since 1.18 3613 */ 3614 EAPI Edje_Aspect_Control 3615 edje_edit_part_item_index_aspect_mode_get(Evas_Object *obj, const char *part, unsigned int index); 3616 3617 /** 3618 * @brief Sets aspect mode for an item of TABLE or BOX. 3619 * 3620 * Mode may be next: 3621 * - EDJE_ASPECT_CONTROL_NONE 3622 * - EDJE_ASPECT_CONTROL_NEITHER 3623 * - EDJE_ASPECT_CONTROL_HORIZONTAL 3624 * - EDJE_ASPECT_CONTROL_VERTICAL 3625 * - EDJE_ASPECT_CONTROL_BOTH 3626 * 3627 * @param obj Object being edited. 3628 * @param part Part that contain item. 3629 * @param index Index of the item to set aspect mode. 3630 * @param mode One of possible enum from Edje_Aspect_Control: 3631 3632 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3633 * @since 1.18 3634 */ 3635 EAPI Eina_Bool 3636 edje_edit_part_item_index_aspect_mode_set(Evas_Object *obj, const char *part, unsigned int index, Edje_Aspect_Control mode); 3637 3638 /** 3639 * @brief Sets the prefer width value of a part's item. 3640 * 3641 * @param obj Object being edited. 3642 * @param part Part that contain state. 3643 * @param index Index of the item to set prefer width. 3644 * @param prefer_w Prefer width value. 3645 * 3646 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3647 * @since 1.18 3648 */ 3649 EAPI Eina_Bool 3650 edje_edit_part_item_index_prefer_w_set(Evas_Object *obj, const char *part, unsigned int index, int prefer_w); 3651 3652 /** 3653 * @brief Gets the prefer height value of a part's item. 3654 * 3655 * @param obj Object being edited. 3656 * @param part Part that contain state. 3657 * @param index Index of the item to get prefer height. 3658 * 3659 * @return The maximum height value. 3660 * @since 1.18 3661 */ 3662 EAPI int 3663 edje_edit_part_item_index_prefer_h_get(Evas_Object *obj, const char *part, unsigned int index); 3664 3665 /** 3666 * @brief Sets the prefer height value of a part's item. 3667 * 3668 * @param obj Object being edited. 3669 * @param part Part that contain state. 3670 * @param index Index of the item to set prefer height. 3671 * @param prefer_h Prefer height value. 3672 * 3673 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3674 * @since 1.18 3675 */ 3676 EAPI Eina_Bool 3677 edje_edit_part_item_index_prefer_h_set(Evas_Object *obj, const char *part, unsigned int index, int prefer_h); 3678 3679 /** 3680 * @brief Gets the spread width value of a part's item. 3681 * 3682 * @param obj Object being edited. 3683 * @param part Part that contain state. 3684 * @param index Index of the item to get spread width. 3685 * 3686 * @return The spread width value. 3687 * @since 1.18 3688 */ 3689 EAPI int 3690 edje_edit_part_item_index_spread_w_get(Evas_Object *obj, const char *part, unsigned int index); 3691 3692 /** 3693 * @brief Sets the spread width value of a part's item. 3694 * 3695 * @attention be careful, if you set up huge number (like 10 or 100) width and height of 3696 * spread is being multiplied and you will get huge number of objects that may "eat" 3697 * all of your processor performance at once... Or if you want, you may 3698 * get some coffee and wait until it will recalculate all of those objects :) 3699 * 3700 * @param obj Object being edited. 3701 * @param part Part that contain state. 3702 * @param index Index of the item to set spread width. 3703 * @param spread_w Maximum width value. 3704 * 3705 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 3706 * @since 1.18 3707 */ 3708 EAPI Eina_Bool 3709 edje_edit_part_item_index_spread_w_set(Evas_Object *obj, const char *part, unsigned int index, int spread_w); 3710 3711 /** 3712 * @brief Gets the spread height value of a part's item. 3713 * 3714 * @attention be careful, if you set up huge number (like 10 or 100) width and height of 3715 * spread is being multiplied and you will get huge number of objects that may "eat" 3716 * all of your processor performance at once... Or if you want, you may 3717 * get some coffee and wait until it will recalculate all of those objects :) 3718 * 3719 * @param obj Object being edited. 3720 * @param part Part that contain state. 3721 * @param index Index of the item to get spread height. 3722 * 3723 * @return The spread height value. 3724 * @since 1.18 3725 */ 3726 EAPI int 3727 edje_edit_part_item_index_spread_h_get(Evas_Object *obj, const char *part, unsigned int index); 3728 3729 /** 3730 * @brief Sets the spread height value of a part's item. 3731 * 3732 * @param obj Object being edited. 3733 * @param part Part that contain state. 3734 * @param index Index of the item to set spread height. 3735 * @param spread_h spread height value. 3736 * 3737 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 3738 * @since 1.18 3739 */ 3740 EAPI Eina_Bool 3741 edje_edit_part_item_index_spread_h_set(Evas_Object *obj, const char *part, unsigned int index, int spread_h); 3742 3743 /** 3744 * @brief Gets paddings of the part's item. 3745 * 3746 * @param obj Object being edited. 3747 * @param part Part that contain item. 3748 * @param item_name The name of the item. 3749 * @param l A pointer to store the left padding value. 3750 * @param r A pointer to store the right padding value. 3751 * @param t A pointer to store the top padding value. 3752 * @param b A pointer to store the bottom padding value. 3753 * 3754 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3755 * @since 1.11 3756 */ 3757 EINA_DEPRECATED 3758 EAPI Eina_Bool edje_edit_part_item_padding_get(Evas_Object *obj, const char *part, const char *item_name, int *l, int *r, int *t, int *b); 3759 3760 /** 3761 * @brief Sets paddings of the part's item. 3762 * 3763 * @param obj Object being edited. 3764 * @param part Part that contain item. 3765 * @param item_name The name of the item. 3766 * @param l Value of the left padding. 3767 * @param r Value of the right padding. 3768 * @param t Value of the top padding. 3769 * @param b Value of the bottom padding. 3770 * 3771 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3772 * @since 1.11 3773 */ 3774 EINA_DEPRECATED 3775 EAPI Eina_Bool edje_edit_part_item_padding_set(Evas_Object *obj, const char *part, const char *item_name, int l, int r, int t, int b); 3776 3777 /** 3778 * @brief Gets paddings of the part's item. 3779 * 3780 * @param obj Object being edited. 3781 * @param part Part that contain item. 3782 * @param index Index of the item. 3783 * @param l A pointer to store the left padding value. 3784 * @param r A pointer to store the right padding value. 3785 * @param t A pointer to store the top padding value. 3786 * @param b A pointer to store the bottom padding value. 3787 * 3788 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3789 * @since 1.18 3790 */ 3791 EAPI Eina_Bool 3792 edje_edit_part_item_index_padding_get(Evas_Object *obj, const char *part, unsigned int index, int *l, int *r, int *t, int *b); 3793 3794 /** 3795 * @brief Sets paddings of the part's item. 3796 * 3797 * @param obj Object being edited. 3798 * @param part Part that contain item. 3799 * @param index Index of the item. 3800 * @param l Value of the left padding. 3801 * @param r Value of the right padding. 3802 * @param t Value of the top padding. 3803 * @param b Value of the bottom padding. 3804 * 3805 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3806 * @since 1.18 3807 */ 3808 EAPI Eina_Bool 3809 edje_edit_part_item_index_padding_set(Evas_Object *obj, const char *part, unsigned int index, int l, int r, int t, int b); 3810 3811 /** 3812 * @brief Gets the horizontal align value of a part state. 3813 * 3814 * @param obj Object being edited. 3815 * @param part Part that contain item. 3816 * @param item The name of the item to get horizontal align value. 3817 * 3818 * @return The horizontal align value for the given align (value is between -1.0 and 1.0) 3819 * @since 1.11 3820 */ 3821 EINA_DEPRECATED 3822 EAPI double edje_edit_part_item_align_x_get(Evas_Object *obj, const char *part, const char *item); 3823 3824 /** 3825 * @brief Gets the horizontal align value of a part state. 3826 * 3827 * @param obj Object being edited. 3828 * @param part Part that contain item. 3829 * @param index Index of the item to get horizontal align value. 3830 * 3831 * @return The horizontal align value for the given align (value is between -1.0 and 1.0) 3832 * @since 1.18 3833 */ 3834 EAPI double 3835 edje_edit_part_item_index_align_x_get(Evas_Object *obj, const char *part, unsigned int index); 3836 3837 /** 3838 * @brief Sets the horizontal align value of a part state. 3839 * 3840 * @param obj Object being edited. 3841 * @param part Part that contains item 3842 * @param item The name of the item to set horizontal align value. 3843 * @param align_x New value of the horizontal align. 3844 * 3845 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3846 * @since 1.11 3847 */ 3848 EINA_DEPRECATED 3849 EAPI Eina_Bool edje_edit_part_item_align_x_set(Evas_Object *obj, const char *part, const char *item, double align_x); 3850 3851 /** 3852 * @brief Sets the horizontal align value of a part state. 3853 * 3854 * @param obj Object being edited. 3855 * @param part Part that contains item 3856 * @param index Index of the item to set horizontal align value. 3857 * @param align_x New value of the horizontal align. 3858 * 3859 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3860 * @since 1.18 3861 */ 3862 EAPI Eina_Bool 3863 edje_edit_part_item_index_align_x_set(Evas_Object *obj, const char *part, unsigned int index, double align_x); 3864 3865 /** 3866 * @brief Gets the vertical align value of a part state. 3867 * 3868 * @param obj Object being edited. 3869 * @param part Part that contain item. 3870 * @param item The name of the item to get vertical align value. 3871 * 3872 * @return The vertical align value for the given align (value is between -1.0 and 1.0) 3873 * @since 1.11 3874 */ 3875 EINA_DEPRECATED 3876 EAPI double edje_edit_part_item_align_y_get(Evas_Object *obj, const char *part, const char *item); 3877 3878 /** 3879 * @brief Gets the vertical align value of a part state. 3880 * 3881 * @param obj Object being edited. 3882 * @param part Part that contain item. 3883 * @param index Index of the item to get vertical align value. 3884 * 3885 * @return The vertical align value for the given align (value is between -1.0 and 1.0) 3886 * @since 1.18 3887 */ 3888 EAPI double 3889 edje_edit_part_item_index_align_y_get(Evas_Object *obj, const char *part, unsigned int index); 3890 3891 /** 3892 * @brief Sets the vertical align value of a part state. 3893 * 3894 * @param obj Object being edited. 3895 * @param part Part that contain item. 3896 * @param item The name of the item to set vertical align value. 3897 * @param align_y New value of the vertical align. 3898 * 3899 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3900 * @since 1.11 3901 */ 3902 EINA_DEPRECATED 3903 EAPI Eina_Bool edje_edit_part_item_align_y_set(Evas_Object *obj, const char *part, const char *item, double align_y); 3904 3905 /** 3906 * @brief Sets the vertical align value of a part state. 3907 * 3908 * @param obj Object being edited. 3909 * @param part Part that contain item. 3910 * @param index Index of the item to set vertical align value. 3911 * @param align_y New value of the vertical align. 3912 * 3913 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 3914 * @since 1.18 3915 */ 3916 EAPI Eina_Bool 3917 edje_edit_part_item_index_align_y_set(Evas_Object *obj, const char *part, unsigned int index, double align_y); 3918 3919 /** 3920 * @brief Gets the horizontal weight value of a part item. 3921 * 3922 * @param obj Object being edited. 3923 * @param part Part that contain item. 3924 * @param item The name of the item to get horizontal weight value. 3925 * 3926 * @return The horizontal weight value for the given item (value is between -1.0 and 1.0) 3927 * @since 1.11 3928 */ 3929 EINA_DEPRECATED 3930 EAPI double edje_edit_part_item_weight_x_get(Evas_Object *obj, const char *part, const char *item); 3931 3932 /** 3933 * @brief Gets the horizontal weight value of a part item. 3934 * 3935 * @param obj Object being edited. 3936 * @param part Part that contain item. 3937 * @param index Index of the item to get horizontal weight value. 3938 * 3939 * @return The horizontal weight value for the given item (value is between -1.0 and 1.0) 3940 * @since 1.18 3941 */ 3942 EAPI double 3943 edje_edit_part_item_index_weight_x_get(Evas_Object *obj, const char *part, unsigned int index); 3944 3945 /** 3946 * @brief Sets the horizontal we value of a part item. 3947 * 3948 * @param obj Object being edited. 3949 * @param part Part that contains item 3950 * @param item The name of the item to set horizontal weight value. 3951 * @param weight_x New value of the horizontal weight. 3952 * 3953 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 3954 * @since 1.11 3955 */ 3956 EINA_DEPRECATED 3957 EAPI Eina_Bool edje_edit_part_item_weight_x_set(Evas_Object *obj, const char *part, const char *item, double weight_x); 3958 3959 /** 3960 * @brief Sets the horizontal we value of a part item. 3961 * 3962 * @param obj Object being edited. 3963 * @param part Part that contains item 3964 * @param index Index of the item to set horizontal weight value. 3965 * @param weight_x New value of the horizontal weight. 3966 * 3967 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 3968 * @since 1.18 3969 */ 3970 EAPI Eina_Bool 3971 edje_edit_part_item_index_weight_x_set(Evas_Object *obj, const char *part, unsigned int index, double weight_x); 3972 3973 /** 3974 * @brief Gets the vertical weight value of a part item. 3975 * 3976 * @param obj Object being edited. 3977 * @param part Part that contain item. 3978 * @param item The name of the item to get vertical weight value. 3979 * 3980 * @return The vertical weight value for the given item (value is between -1.0 and 1.0) 3981 * @since 1.11 3982 */ 3983 EINA_DEPRECATED 3984 EAPI double edje_edit_part_item_weight_y_get(Evas_Object *obj, const char *part, const char *item); 3985 3986 /** 3987 * @brief Gets the vertical weight value of a part item. 3988 * 3989 * @param obj Object being edited. 3990 * @param part Part that contain item. 3991 * @param index Index of the item to get vertical weight value. 3992 * 3993 * @return The vertical weight value for the given item (value is between -1.0 and 1.0) 3994 * @since 1.18 3995 */ 3996 EAPI double 3997 edje_edit_part_item_index_weight_y_get(Evas_Object *obj, const char *part, unsigned int index); 3998 3999 /** 4000 * @brief Sets the vertical weight value of a part item. 4001 * 4002 * @param obj Object being edited. 4003 * @param part Part that contain item. 4004 * @param item The name of the item to set vertical weight value. 4005 * @param weight_y New value of the vertical weight. 4006 * 4007 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4008 * @since 1.11 4009 */ 4010 EINA_DEPRECATED 4011 EAPI Eina_Bool edje_edit_part_item_weight_y_set(Evas_Object *obj, const char *part, const char *item, double weight_y); 4012 4013 /** 4014 * @brief Sets the vertical weight value of a part item. 4015 * 4016 * @param obj Object being edited. 4017 * @param part Part that contain item. 4018 * @param index Index of the item to set vertical weight value. 4019 * @param weight_y New value of the vertical weight. 4020 * 4021 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4022 * @since 1.18 4023 */ 4024 EAPI Eina_Bool 4025 edje_edit_part_item_index_weight_y_set(Evas_Object *obj, const char *part, unsigned int index, double weight_y); 4026 4027 /** 4028 * @deprecated Use edje_edit_part_item_position_col_get() and 4029 * edje_edit_part_item_position_row_get() instead. 4030 * 4031 * @brief Gets column/row position of the part's item. 4032 * 4033 * @param obj Object being edited. 4034 * @param part Part that contain item. 4035 * @param item_name The name of the item. 4036 * @param col Column item position. 4037 * @param row Row item position. 4038 * 4039 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4040 * @since 1.11 4041 */ 4042 EINA_DEPRECATED 4043 EAPI Eina_Bool edje_edit_part_item_position_get(Evas_Object *obj, const char *part, const char *item_name, unsigned short *col, unsigned short *row); 4044 4045 /** 4046 * @brief Gets the horizontal align value of a part state. 4047 * 4048 * @param obj Object being edited. 4049 * @param part Part that contain item. 4050 * @param index Index of the item to get horizontal align value. 4051 * 4052 * @return The horizontal align value for the given align (value is between -1.0 and 1.0) 4053 * @since 1.18 4054 */ 4055 EAPI double 4056 edje_edit_part_item_item_align_x_get(Evas_Object *obj, const char *part, unsigned int index); 4057 4058 /** 4059 * @brief Sets the horizontal align value of a part state. 4060 * 4061 * @param obj Object being edited. 4062 * @param part Part that contain item 4063 * @param index Index of the item to set horizontal align value. 4064 * @param align_x New value of the horizontal align. 4065 * 4066 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4067 * @since 1.18 4068 */ 4069 EAPI Eina_Bool 4070 edje_edit_part_item_item_align_x_set(Evas_Object *obj, const char *part, unsigned int index, double align_x); 4071 4072 /** 4073 * @brief Gets the vertical align value of a part state. 4074 * 4075 * @param obj Object being edited. 4076 * @param part Part that contain item. 4077 * @param index Index of the item to get vertical align value. 4078 * 4079 * @return The vertical align value for the given align (value is between -1.0 and 1.0) 4080 * @since 1.18 4081 */ 4082 EAPI double 4083 edje_edit_part_item_item_align_y_get(Evas_Object *obj, const char *part, unsigned int index); 4084 4085 /** 4086 * @brief Sets the vertical align value of a part state. 4087 * 4088 * @param obj Object being edited. 4089 * @param part Part that contain item. 4090 * @param index Index of the item to set vertical align value. 4091 * @param align_y New value of the vertical align. 4092 * 4093 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4094 * @since 1.18 4095 */ 4096 EAPI Eina_Bool 4097 edje_edit_part_item_item_align_y_set(Evas_Object *obj, const char *part, unsigned int index, double align_y); 4098 4099 /** 4100 * @brief Gets the horizontal weight value of a part item. 4101 * 4102 * @param obj Object being edited. 4103 * @param part Part that contain item. 4104 * @param index Index of the item to get horizontal weight value. 4105 * 4106 * @return The horizontal weight value for the given item (value is between -1.0 and 1.0) 4107 * @since 1.18 4108 */ 4109 EAPI double 4110 edje_edit_part_item_item_weight_x_get(Evas_Object *obj, const char *part, unsigned int index); 4111 4112 /** 4113 * @brief Sets the horizontal we value of a part item. 4114 * 4115 * @param obj Object being edited. 4116 * @param part Part that contains item 4117 * @param index Index of the item to set horizontal weight value. 4118 * @param weight_x New value of the horizontal weight. 4119 * 4120 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4121 * @since 1.18 4122 */ 4123 EAPI Eina_Bool 4124 edje_edit_part_item_item_weight_x_set(Evas_Object *obj, const char *part, unsigned int index, double weight_x); 4125 4126 /** 4127 * @brief Gets the vertical weight value of a part item. 4128 * 4129 * @param obj Object being edited. 4130 * @param part Part that contain item. 4131 * @param index Index of the item to get vertical weight value. 4132 * 4133 * @return The vertical weight value for the given item (value is between -1.0 and 1.0) 4134 * @since 1.18 4135 */ 4136 EAPI double 4137 edje_edit_part_item_item_weight_y_get(Evas_Object *obj, const char *part, unsigned int index); 4138 4139 /** 4140 * @brief Sets the vertical weight value of a part item. 4141 * 4142 * @param obj Object being edited. 4143 * @param part Part that contain item. 4144 * @param index Index of the item to set vertical weight value. 4145 * @param weight_y New value of the vertical weight. 4146 * 4147 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4148 * @since 1.18 4149 */ 4150 EAPI Eina_Bool 4151 edje_edit_part_item_item_weight_y_set(Evas_Object *obj, const char *part, unsigned int index, double weight_y); 4152 4153 /** 4154 * @brief Gets column position of the part's item. 4155 * 4156 * @param obj Object being edited. 4157 * @param part Part that contain item. 4158 * @param item_name The name of the item. 4159 * 4160 * @return The item column value. 4161 * @since 1.16 4162 */ 4163 EINA_DEPRECATED 4164 EAPI unsigned short 4165 edje_edit_part_item_position_col_get(Evas_Object *obj, const char *part, const char *item_name); 4166 4167 /** 4168 * @brief Gets row position of the part's item. 4169 * 4170 * @param obj Object being edited. 4171 * @param part Part that contain item. 4172 * @param item_name The name of the item. 4173 * 4174 * @return The item row value. 4175 * @since 1.16 4176 */ 4177 EINA_DEPRECATED 4178 EAPI unsigned short 4179 edje_edit_part_item_position_row_get(Evas_Object *obj, const char *part, const char *item_name); 4180 4181 /** 4182 * @brief Gets column position of the part's item. 4183 * 4184 * @param obj Object being edited. 4185 * @param part Part that contain item. 4186 * @param index Index of the item. 4187 * 4188 * @return The item column value. 4189 * @since 1.18 4190 */ 4191 EAPI unsigned short 4192 edje_edit_part_item_index_position_col_get(Evas_Object *obj, const char *part, unsigned int index); 4193 4194 /** 4195 * @brief Gets row position of the part's item. 4196 * 4197 * @param obj Object being edited. 4198 * @param part Part that contain item. 4199 * @param index Index of the item. 4200 * 4201 * @return The item row value. 4202 * @since 1.18 4203 */ 4204 EAPI unsigned short 4205 edje_edit_part_item_index_position_row_get(Evas_Object *obj, const char *part, unsigned int index); 4206 4207 /** 4208 * @deprecated Use edje_edit_part_item_position_col_set() and 4209 * edje_edit_part_item_position_row_set() instead. 4210 * 4211 * @brief Sets column/row position of a new part's item. 4212 * 4213 * @param obj Object being edited. 4214 * @param part Part that contain item. 4215 * @param item_name The name of the item. 4216 * @param col Column item position. 4217 * @param row Row item position. 4218 * 4219 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4220 * @since 1.11 4221 */ 4222 EINA_DEPRECATED 4223 EAPI Eina_Bool edje_edit_part_item_position_set(Evas_Object *obj, const char *part, const char *item_name, unsigned short col, unsigned short row); 4224 4225 /** 4226 * @brief Sets column position of a part item. 4227 * 4228 * @param obj Object being edited. 4229 * @param part Part that contain item. 4230 * @param item_name The name of the item. 4231 * @param col Column item position. 4232 * 4233 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4234 * @since 1.16 4235 */ 4236 EINA_DEPRECATED 4237 EAPI Eina_Bool 4238 edje_edit_part_item_position_col_set(Evas_Object *obj, const char *part, const char *item_name, unsigned short col); 4239 4240 /** 4241 * @brief Sets row position of a part item. 4242 * 4243 * @param obj Object being edited. 4244 * @param part Part that contain item. 4245 * @param item_name The name of the item. 4246 * @param row Row item position. 4247 * 4248 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4249 * @since 1.16 4250 */ 4251 EINA_DEPRECATED 4252 EAPI Eina_Bool 4253 edje_edit_part_item_position_row_set(Evas_Object *obj, const char *part, const char *item_name, unsigned short row); 4254 4255 /** 4256 * @brief Sets column position of a part item. 4257 * 4258 * @param obj Object being edited. 4259 * @param part Part that contain item. 4260 * @param index Index of the item. 4261 * @param col Column item position. 4262 * 4263 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4264 * @since 1.18 4265 */ 4266 EAPI Eina_Bool 4267 edje_edit_part_item_index_position_col_set(Evas_Object *obj, const char *part, unsigned int index, unsigned short col); 4268 4269 /** 4270 * @brief Sets row position of a part item. 4271 * 4272 * @param obj Object being edited. 4273 * @param part Part that contain item. 4274 * @param index Index of the item. 4275 * @param row Row item position. 4276 * 4277 * @return @c EINA_TRUE If successful, @c EINA_FALSE otherwise. 4278 * @since 1.18 4279 */ 4280 EAPI Eina_Bool 4281 edje_edit_part_item_index_position_row_set(Evas_Object *obj, const char *part, unsigned int index, unsigned short row); 4282 4283 4284 /** 4285 * @brief Retrieves the how many columns and rows will span for use by item. 4286 * 4287 * @param obj object being edited. 4288 * @param part part that contain item. 4289 * @param item the name of the item of part. 4290 * @param col Pointer to an unsigned char in which to store the columns count. 4291 * @param row Pointer to an unsigned char in which to store the rows count. 4292 * 4293 * @deprecated Use edje_edit_part_item_span_row_get() and 4294 * edje_edit_part_item_span_col_get() instead. 4295 * 4296 * @since 1.11 4297 */ 4298 EINA_DEPRECATED 4299 EAPI void edje_edit_part_item_span_get(Evas_Object *obj, const char *part, const char *item, unsigned char *col, unsigned char *row); 4300 4301 /** 4302 * @brief Gets the number of span columns. 4303 * 4304 * @param obj Object being edited. 4305 * @param part Part that contain item. 4306 * @param item The name of the item of part. 4307 * 4308 * @return The count of span columns. 4309 * @since 1.16 4310 */ 4311 EINA_DEPRECATED 4312 EAPI unsigned short 4313 edje_edit_part_item_span_col_get(Evas_Object *obj, const char *part, const char *item); 4314 4315 /** 4316 * @brief Gets the number of span rows. 4317 * 4318 * @param obj Object being edited. 4319 * @param part Part that contain item. 4320 * @param item The name of the item of part. 4321 * 4322 * @return The count of span rows. 4323 * @since 1.16 4324 */ 4325 EINA_DEPRECATED 4326 EAPI unsigned short 4327 edje_edit_part_item_span_row_get(Evas_Object *obj, const char *part, const char *item); 4328 4329 /** 4330 * @brief Sets the count of columns and rows, which this item will spans for use. 4331 * 4332 * @param obj object being edited. 4333 * @param part part that contain item. 4334 * @param item the name of the item to set new count of columns spans. 4335 * @param col new count of the columns spans. 4336 * @param row new count of the rows spans. 4337 * 4338 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 4339 * @since 1.11 4340 */ 4341 EINA_DEPRECATED 4342 EAPI Eina_Bool edje_edit_part_item_span_set(Evas_Object *obj, const char *part, const char *item, unsigned char col, unsigned char row); 4343 4344 /** 4345 * @brief Sets the count of columns which this item will spans for use. 4346 * 4347 * @param obj Object being edited. 4348 * @param part Part that contain item. 4349 * @param item The name of the item. 4350 * @param col new count of the columns spans. 4351 * 4352 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 4353 * @since 1.16 4354 */ 4355 EINA_DEPRECATED 4356 EAPI Eina_Bool 4357 edje_edit_part_item_span_col_set(Evas_Object *obj, const char *part, const char *item, unsigned short col); 4358 4359 /** 4360 * @brief Sets the count of rows which this item will spans for use. 4361 * 4362 * @param obj Object being edited. 4363 * @param part Part that contain item. 4364 * @param item The name of the item. 4365 * @param row new count of the rows spans. 4366 * 4367 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 4368 * @since 1.16 4369 */ 4370 EINA_DEPRECATED 4371 EAPI Eina_Bool 4372 edje_edit_part_item_span_row_set(Evas_Object *obj, const char *part, const char *item, unsigned short row); 4373 4374 /** 4375 * @brief Sets the count of columns which this item will spans for use. 4376 * 4377 * @param obj Object being edited. 4378 * @param part Part that contain item. 4379 * @param index Index of the item. 4380 * @param col new count of the columns spans. 4381 * 4382 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 4383 * @since 1.18 4384 */ 4385 EAPI Eina_Bool 4386 edje_edit_part_item_index_span_col_set(Evas_Object *obj, const char *part, unsigned int index, unsigned short col); 4387 4388 /** 4389 * @brief Sets the count of rows which this item will spans for use. 4390 * 4391 * @param obj Object being edited. 4392 * @param part Part that contain item. 4393 * @param index Index of the item. 4394 * @param row new count of the rows spans. 4395 * 4396 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 4397 * @since 1.18 4398 */ 4399 EAPI Eina_Bool 4400 edje_edit_part_item_index_span_row_set(Evas_Object *obj, const char *part, unsigned int index, unsigned short row); 4401 4402 /** 4403 * @brief Gets the number of span columns. 4404 * 4405 * @param obj Object being edited. 4406 * @param part Part that contain item. 4407 * @param index Index of the item of part. 4408 * 4409 * @return The count of span columns. 4410 * @since 1.18 4411 */ 4412 EAPI unsigned short 4413 edje_edit_part_item_index_span_col_get(Evas_Object *obj, const char *part, unsigned int index); 4414 4415 /** 4416 * @brief Gets the number of span rows. 4417 * 4418 * @param obj Object being edited. 4419 * @param part Part that contain item. 4420 * @param index Index of the item of part. 4421 * 4422 * @return The count of span rows. 4423 * @since 1.18 4424 */ 4425 EAPI unsigned short 4426 edje_edit_part_item_index_span_row_get(Evas_Object *obj, const char *part, unsigned int index); 4427 4428 //@} 4429 /******************************************************************************/ 4430 /************************** STATES API ************************************/ 4431 /******************************************************************************/ 4432 /** 4433 * @name States API 4434 * Functions to deal with part states (see @ref edcref). 4435 */ //@{ 4436 4437 /** 4438 * @brief Gets the list of all the states in the given part. 4439 * 4440 * @param obj Object being edited. 4441 * @param part Part to get the states names list. 4442 * 4443 * @return An Eina_List* of string (char *)containing all the states names found 4444 * in part, including the float value (ex: "default 0.00"). 4445 * 4446 * Use edje_edit_string_list_free() when you don't need it anymore. 4447 */ 4448 EAPI Eina_List * edje_edit_part_states_list_get(Evas_Object *obj, const char *part); 4449 4450 /** 4451 * @brief Sets a new name for the given state in the given part. 4452 * 4453 * @param obj Object being edited. 4454 * @param part Part that contain state. 4455 * @param state Name of the state to rename. 4456 * @param value Value of the state to rename. 4457 * @param new_name The new name for the state. 4458 * @param new_value The new value for the state. 4459 * 4460 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4461 */ 4462 EAPI Eina_Bool edje_edit_state_name_set(Evas_Object *obj, const char *part, const char *state, double value, const char *new_name, double new_value); 4463 4464 /** 4465 * @brief Creates a new state to the give part. 4466 * 4467 * @param obj Object being edited. 4468 * @param part Part to set the name of the new state. 4469 * @param name Name for the new state (not including the state value). 4470 * @param value The state value. 4471 * 4472 * @return @c EINA_TRUE if successfully, @c EINA_FALSE otherwise. 4473 */ 4474 EAPI Eina_Bool edje_edit_state_add(Evas_Object *obj, const char *part, const char *name, double value); 4475 4476 /** 4477 * @brief Deletes the given part state from the edje. 4478 * 4479 * @param obj Object being edited. 4480 * @param part Part that contain state. 4481 * @param state The current name of the state (not including the state value). 4482 * @param value The state value. 4483 * 4484 * @return @c EINA_TRUE if successfully, @c EINA_FALSE otherwise. 4485 */ 4486 EAPI Eina_Bool edje_edit_state_del(Evas_Object *obj, const char *part, const char *state, double value); 4487 4488 /** 4489 * @brief Checks if a part state with the given name exist. 4490 * 4491 * @param obj Object being edited. 4492 * @param part Part that contain state. 4493 * @param state The name of the state to check (not including the state value). 4494 * @param value The state value. 4495 * 4496 * @return @c EINA_TRUE if the part state exist, @c EINA_FALSE otherwise. 4497 */ 4498 EAPI Eina_Bool edje_edit_state_exist(Evas_Object *obj, const char *part, const char *state, double value); 4499 4500 /** 4501 * @brief Copies the state @p from into @p to. If @p to doesn't exist it will be created. 4502 * 4503 * @param obj Object being edited. 4504 * @param part Part that contain state. 4505 * @param from State to copy from (not including state value). 4506 * @param val_from The value of the state to copy from. 4507 * @param to State to copy into (not including state value). 4508 * @param val_to The value of the state to copy into. 4509 * 4510 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4511 */ 4512 EAPI Eina_Bool edje_edit_state_copy(Evas_Object *obj, const char *part, const char *from, double val_from, const char *to, double val_to); 4513 4514 /** 4515 * @brief Gets the 'rel1 relative X' value of state. 4516 * 4517 * @param obj Object being edited. 4518 * @param part Part that contain state. 4519 * @param state The name of the state to get 'rel1 relative X' (not including the state value). 4520 * @param value The state value. 4521 * 4522 * @return The 'rel1 relative X' value of the part state. 4523 */ 4524 EAPI double edje_edit_state_rel1_relative_x_get(Evas_Object *obj, const char *part, const char *state, double value); 4525 4526 /** 4527 * @brief Gets the 'rel1 relative Y' value of state. 4528 * 4529 * @param obj Object being edited. 4530 * @param part Part that contain state. 4531 * @param state The name of the state to get 'rel1 relative Y' (not including the state value). 4532 * @param value The state value. 4533 * 4534 * @return The 'rel1 relative Y' value of the part state. 4535 */ 4536 EAPI double edje_edit_state_rel1_relative_y_get(Evas_Object *obj, const char *part, const char *state, double value); 4537 4538 /** 4539 * @brief Gets the 'rel2 relative X' value of state. 4540 * 4541 * @param obj Object being edited. 4542 * @param part Part that contain state. 4543 * @param state The name of the state to get 'rel2 relative X' (not including the state value). 4544 * @param value The state value. 4545 * 4546 * @return The 'rel2 relative X' value of the part state. 4547 */ 4548 EAPI double edje_edit_state_rel2_relative_x_get(Evas_Object *obj, const char *part, const char *state, double value); 4549 4550 /** 4551 * @brief Gets the 'rel2 relative Y' value of state. 4552 * 4553 * @param obj Object being edited. 4554 * @param part Part that contain state. 4555 * @param state The name of the state to get 'rel2 relative Y' (not including the state value). 4556 * @param value The state value. 4557 * 4558 * @return The 'rel2 relative Y' value of the part state. 4559 */ 4560 EAPI double edje_edit_state_rel2_relative_y_get(Evas_Object *obj, const char *part, const char *state, double value); 4561 4562 /** 4563 * @brief Sets the 'rel1 relative X' value of state. 4564 * 4565 * @param obj Object being edited. 4566 * @param part Part that contain state. 4567 * @param state The name of the state to set 'rel1 relative X' (not including the state value). 4568 * @param value The state value. 4569 * @param x The new 'rel1 relative X' value to set'. 4570 * 4571 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4572 */ 4573 EAPI Eina_Bool edje_edit_state_rel1_relative_x_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 4574 4575 /** 4576 * @brief Sets the 'rel1 relative Y' value of state. 4577 * 4578 * @param obj Object being edited. 4579 * @param part Part that contain state. 4580 * @param state The name of the state to set 'rel1 relative Y' (not including the state value). 4581 * @param value The state value. 4582 * @param y The new 'rel1 relative Y' value to set'. 4583 * 4584 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4585 */ 4586 EAPI Eina_Bool edje_edit_state_rel1_relative_y_set(Evas_Object *obj, const char *part, const char *state, double value, double y); 4587 4588 /** 4589 * @brief Sets the 'rel2 relative X' value of state. 4590 * 4591 * @param obj Object being edited. 4592 * @param part Part that contain state. 4593 * @param state The name of the state to set 'rel2 relative X' (not including the state value). 4594 * @param value The state value. 4595 * @param x The new 'rel2 relative X' value to set'. 4596 * 4597 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4598 */ 4599 EAPI Eina_Bool edje_edit_state_rel2_relative_x_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 4600 4601 /** 4602 * @brief Sets the 'rel2 relative Y' value of state. 4603 * 4604 * @param obj Object being edited. 4605 * @param part Part that contain state. 4606 * @param state The name of the state to set 'rel2 relative Y' (not including the state value). 4607 * @param value The state value. 4608 * @param y The new 'rel2 relative Y' value to set'. 4609 * 4610 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4611 */ 4612 EAPI Eina_Bool edje_edit_state_rel2_relative_y_set(Evas_Object *obj, const char *part, const char *state, double value, double y); 4613 4614 /** 4615 * @brief Gets the 'rel1 offset X' value of state. 4616 * 4617 * @param obj Object being edited. 4618 * @param part Part that contain state. 4619 * @param state The name of the state to get 'rel1 offset X' (not including the state value). 4620 * @param value The state value. 4621 * 4622 * @return The 'rel1 offset X' value of the part state. 4623 */ 4624 EAPI int edje_edit_state_rel1_offset_x_get(Evas_Object *obj, const char *part, const char *state, double value); 4625 4626 /** 4627 * @brief Gets the 'rel1 offset Y' value of state. 4628 * 4629 * @param obj Object being edited. 4630 * @param part Part that contain state. 4631 * @param state The name of the state to get 'rel1 offset Y' (not including the state value). 4632 * @param value The state value. 4633 * 4634 * @return The 'rel1 offset Y' value of the part state. 4635 */ 4636 EAPI int edje_edit_state_rel1_offset_y_get(Evas_Object *obj, const char *part, const char *state, double value); 4637 4638 /** 4639 * @brief Gets the 'rel2 offset X' value of state. 4640 * 4641 * @param obj Object being edited. 4642 * @param part Part that contain state. 4643 * @param state The name of the state to get 'rel2 offset X' (not including the state value). 4644 * @param value The state value. 4645 * 4646 * @return The 'rel2 offset X' value of the part state. 4647 */ 4648 EAPI int edje_edit_state_rel2_offset_x_get(Evas_Object *obj, const char *part, const char *state, double value); 4649 4650 /** 4651 * @brief Gets the 'rel2 offset Y' value of state. 4652 * 4653 * @param obj Object being edited. 4654 * @param part Part that contain state. 4655 * @param state The name of the state to get 'rel2 offset Y' (not including the state value). 4656 * @param value The state value. 4657 * 4658 * @return The 'rel2 offset Y' value of the part state. 4659 */ 4660 EAPI int edje_edit_state_rel2_offset_y_get(Evas_Object *obj, const char *part, const char *state, double value); 4661 4662 /** 4663 * @brief Sets the 'rel1 offset X' value of state. 4664 * 4665 * @param obj Object being edited. 4666 * @param part Part that contain state. 4667 * @param state The name of the state to set 'rel1 offset X' (not including the state value). 4668 * @param value The state value. 4669 * @param x The new 'rel1 offset X' value to set'. 4670 * 4671 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4672 */ 4673 EAPI Eina_Bool edje_edit_state_rel1_offset_x_set(Evas_Object *obj, const char *part, const char *state, double value, int x); 4674 4675 /** 4676 * @brief Sets the 'rel1 offset Y' value of state. 4677 * 4678 * @param obj Object being edited. 4679 * @param part Part that contain state. 4680 * @param state The name of the state to set 'rel1 offset Y' (not including the state value). 4681 * @param value The state value. 4682 * @param y The new 'rel1 offset Y' value to set'. 4683 * 4684 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4685 */ 4686 EAPI Eina_Bool edje_edit_state_rel1_offset_y_set(Evas_Object *obj, const char *part, const char *state, double value, int y); 4687 4688 /** 4689 * @brief Sets the 'rel2 offset X' value of state. 4690 * 4691 * @param obj Object being edited. 4692 * @param part Part that contain state. 4693 * @param state The name of the state to set 'rel2 offset X' (not including the state value). 4694 * @param value The state value. 4695 * @param x The new 'rel2 offset X' value to set'. 4696 * 4697 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4698 */ 4699 EAPI Eina_Bool edje_edit_state_rel2_offset_x_set(Evas_Object *obj, const char *part, const char *state, double value, int x); 4700 4701 /** 4702 * @brief Sets the 'rel2 offset Y' value of state. 4703 * 4704 * @param obj Object being edited. 4705 * @param part Part that contain state. 4706 * @param state The name of the state to set 'rel2 offset Y' (not including the state value). 4707 * @param value The state value. 4708 * @param y The new 'rel2 offset Y' value to set'. 4709 * 4710 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4711 */ 4712 EAPI Eina_Bool edje_edit_state_rel2_offset_y_set(Evas_Object *obj, const char *part, const char *state, double value, int y); 4713 4714 /** 4715 * @brief Gets the part name rel1x is relative to. 4716 * 4717 * @param obj Object being edited. 4718 * @param part Part that contain state. 4719 * @param state The state that contain which the part name rel1x is relative to (not including the state value). 4720 * @param value The state value. 4721 * 4722 * @return The part name rel1x is relative to, or NULL if the part is relative to the whole interface. 4723 */ 4724 EAPI const char * edje_edit_state_rel1_to_x_get(Evas_Object *obj, const char *part, const char *state, double value); 4725 4726 /** 4727 * @brief Gets the part name rel1y is relative to. 4728 * 4729 * @param obj Object being edited. 4730 * @param part Part that contain state. 4731 * @param state The state that contain which the part name rel1y is relative to (not including the state value). 4732 * @param value The state value. 4733 * 4734 * @return The part name rel1y is relative to, or NULL if the part is relative to the whole interface. 4735 */ 4736 EAPI const char * edje_edit_state_rel1_to_y_get(Evas_Object *obj, const char *part, const char *state, double value); 4737 4738 /** 4739 * @brief Gets the part name rel2x is relative to. 4740 * 4741 * @param obj Object being edited. 4742 * @param part Part that contain state. 4743 * @param state The state that contain which the part name rel2x is relative to (not including the state value). 4744 * @param value The state value. 4745 * 4746 * @return The part name rel2x is relative to, or NULL if the part is relative to the whole interface. 4747 */ 4748 EAPI const char * edje_edit_state_rel2_to_x_get(Evas_Object *obj, const char *part, const char *state, double value); 4749 4750 /** 4751 * @brief Gets the part name rel2y is relative to. 4752 * 4753 * @param obj Object being edited. 4754 * @param part Part that contain state. 4755 * @param state The state that contain which the part name rel2y is relative to (not including the state value). 4756 * @param value The state value. 4757 * 4758 * @return The part name rel2y is relative to, or NULL if the part is relative to the whole interface. 4759 */ 4760 EAPI const char * edje_edit_state_rel2_to_y_get(Evas_Object *obj, const char *part, const char *state, double value); 4761 4762 /** 4763 * @brief Sets the part rel1x is relative to. 4764 * 4765 * @param obj Object being edited. 4766 * @param part Part that contain state. 4767 * @param state The name of the state to set rel1x is relative to (not including the state value). 4768 * @param value The state value. 4769 * @param rel_to The name of the part that is used as container/parent (NULL make the part relative to the whole interface). 4770 * 4771 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4772 */ 4773 EAPI Eina_Bool edje_edit_state_rel1_to_x_set(Evas_Object *obj, const char *part, const char *state, double value, const char *rel_to); 4774 4775 /** 4776 * @brief Sets the part rel1y is relative to. 4777 * 4778 * @param obj Object being edited. 4779 * @param part Part that contain state. 4780 * @param state The name of the state to set rel1y is relative to (not including the state value). 4781 * @param value The state value. 4782 * @param rel_to The name of the part that is used as container/parent (NULL make the part relative to the whole interface). 4783 * 4784 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4785 */ 4786 EAPI Eina_Bool edje_edit_state_rel1_to_y_set(Evas_Object *obj, const char *part, const char *state, double value, const char *rel_to); 4787 4788 /** 4789 * @brief Sets the part rel2x is relative to. 4790 * 4791 * @param obj Object being edited. 4792 * @param part Part that contain state. 4793 * @param state The name of the state to set rel2x is relative to (not including the state value). 4794 * @param value The state value. 4795 * @param rel_to The name of the part that is used as container/parent (NULL make the part relative to the whole interface). 4796 * 4797 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4798 */ 4799 EAPI Eina_Bool edje_edit_state_rel2_to_x_set(Evas_Object *obj, const char *part, const char *state, double value, const char *rel_to); 4800 4801 /** 4802 * @brief Sets the part rel2y is relative to. 4803 * 4804 * @param obj Object being edited. 4805 * @param part Part that contain state. 4806 * @param state The name of the state to set rel2y is relative to (not including the state value). 4807 * @param value The state value. 4808 * @param rel_to The name of the part that is used as container/parent (NULL make the part relative to the whole interface). 4809 * 4810 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4811 */ 4812 EAPI Eina_Bool edje_edit_state_rel2_to_y_set(Evas_Object *obj, const char *part, const char *state, double value, const char *rel_to); 4813 4814 /** 4815 * @brief Gets the color of a part state. 4816 * 4817 * @param obj Object being edited. 4818 * @param part Part that contain state. 4819 * @param state The name of the state to get color (not including the state value). 4820 * @param value The state value. 4821 * @param r A pointer to store the red value. 4822 * @param g A pointer to store the green value. 4823 * @param b A pointer to store the blue value. 4824 * @param a A pointer to store the alpha value. 4825 */ 4826 EAPI void edje_edit_state_color_get(Evas_Object *obj, const char *part, const char *state, double value, int *r, int *g, int *b, int *a); 4827 4828 /** 4829 * @brief Gets the color2 of a part state. 4830 * 4831 * @param obj Object being edited. 4832 * @param part Part that contain state. 4833 * @param state The name of the state to get color (not including the state value). 4834 * @param value The state value. 4835 * @param r A pointer to store the red value. 4836 * @param g A pointer to store the green value. 4837 * @param b A pointer to store the blue value. 4838 * @param a A pointer to store the alpha value. 4839 */ 4840 EAPI void edje_edit_state_color2_get(Evas_Object *obj, const char *part, const char *state, double value, int *r, int *g, int *b, int *a); 4841 4842 /** 4843 * @brief Gets the color3 of a part state. 4844 * 4845 * @param obj Object being edited. 4846 * @param part Part that contain state. 4847 * @param state The name of the state to get color (not including the state value). 4848 * @param value The state value. 4849 * @param r A pointer to store the red value. 4850 * @param g A pointer to store the green value. 4851 * @param b A pointer to store the blue value. 4852 * @param a A pointer to store the alpha value. 4853 */ 4854 EAPI void edje_edit_state_color3_get(Evas_Object *obj, const char *part, const char *state, double value, int *r, int *g, int *b, int *a); 4855 4856 /** 4857 * @brief Sets the color of a part state. 4858 * 4859 * @param obj Object being edited. 4860 * @param part Part that contain state. 4861 * @param state The name of the state to set color (not including the state value). 4862 * @param value The state value. 4863 * @param r The red value of the color. 4864 * @param g The green value of the color. 4865 * @param b The blue value of the color. 4866 * @param a The alpha value of the color. 4867 * 4868 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4869 */ 4870 EAPI Eina_Bool edje_edit_state_color_set(Evas_Object *obj, const char *part, const char *state, double value, int r, int g, int b, int a); 4871 4872 /** 4873 * @brief Sets the color2 of a part state. 4874 * 4875 * @param obj Object being edited. 4876 * @param part Part that contain state. 4877 * @param state The name of the state to set color (not including the state value). 4878 * @param value The state value. 4879 * @param r The red value of the color. 4880 * @param g The green value of the color. 4881 * @param b The blue value of the color. 4882 * @param a The alpha value of the color. 4883 * 4884 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4885 */ 4886 EAPI Eina_Bool edje_edit_state_color2_set(Evas_Object *obj, const char *part, const char *state, double value, int r, int g, int b, int a); 4887 4888 /** 4889 * @brief Sets the color3 of a part state. 4890 * 4891 * @param obj Object being edited. 4892 * @param part Part that contain state. 4893 * @param state The name of the state to set color (not including the state value). 4894 * @param value The state value. 4895 * @param r The red value of the color. 4896 * @param g The green value of the color. 4897 * @param b The blue value of the color. 4898 * @param a The alpha value of the color. 4899 * 4900 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4901 */ 4902 EAPI Eina_Bool edje_edit_state_color3_set(Evas_Object *obj, const char *part, const char *state, double value, int r, int g, int b, int a); 4903 4904 /** 4905 * @brief Gets the horizontal align value of a part state. 4906 * 4907 * @param obj Object being edited. 4908 * @param part Part that contain state. 4909 * @param state The name of the state to get horizontal align (not including the state value). 4910 * @param value The state value. 4911 * 4912 * @return The horizontal align value for the given state 4913 */ 4914 EAPI double edje_edit_state_align_x_get(Evas_Object *obj, const char *part, const char *state, double value); 4915 4916 /** 4917 * @brief Gets the vertical align value of a part state. 4918 * 4919 * @param obj Object being edited. 4920 * @param part Part that contain state. 4921 * @param state The name of the state to get horizontal align (not including the state value). 4922 * @param value The state value. 4923 * 4924 * @return The vertical align value for the given state 4925 */ 4926 EAPI double edje_edit_state_align_y_get(Evas_Object *obj, const char *part, const char *state, double value); 4927 4928 /** 4929 * @brief Sets the horizontal align value of a part state. 4930 * 4931 * @param obj Object being edited. 4932 * @param part Part that contain state. 4933 * @param state The name of the state to get horizontal align (not including the state value). 4934 * @param value The state value. 4935 * @param align The new vertical align value. 4936 * 4937 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 4938 */ 4939 EAPI Eina_Bool edje_edit_state_align_x_set(Evas_Object *obj, const char *part, const char *state, double value, double align); 4940 4941 /** 4942 * @brief Sets the vertical align value of a part state. 4943 * 4944 * @param obj Object being edited. 4945 * @param part Part that contain state. 4946 * @param state The name of the state to get vertical align (not including the state value). 4947 * @param value The state value. 4948 * @param align The new vertical align value. 4949 * 4950 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 4951 */ 4952 EAPI Eina_Bool edje_edit_state_align_y_set(Evas_Object *obj, const char *part, const char *state, double value, double align); 4953 4954 /** 4955 * @brief Gets the minimum width value of a part state. 4956 * 4957 * @param obj Object being edited. 4958 * @param part Part that contain state. 4959 * @param state The name of the state to get minimum width (not including the state value). 4960 * @param value The state value. 4961 * 4962 * @return The minimum width value. 4963 */ 4964 EAPI int edje_edit_state_min_w_get(Evas_Object *obj, const char *part, const char *state, double value); 4965 4966 /** 4967 * @brief Sets the minimum width value of a part state. 4968 * The minimum width should be greater than 0. 4969 * 4970 * @param obj Object being edited. 4971 * @param part Part that contain state. 4972 * @param state The name of the state to set minimum width (not including the state value). 4973 * @param value The state value. 4974 * @param min_w Minimum width value. 4975 * 4976 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 4977 */ 4978 EAPI Eina_Bool edje_edit_state_min_w_set(Evas_Object *obj, const char *part, const char *state, double value, int min_w); 4979 4980 /** 4981 * @brief Gets the minimum height value of a part state. 4982 * 4983 * @param obj Object being edited. 4984 * @param part Part that contain state. 4985 * @param state The name of the state to get minimum height (not including the state value). 4986 * @param value The state value. 4987 * 4988 * @return The minimum height value. 4989 */ 4990 EAPI int edje_edit_state_min_h_get(Evas_Object *obj, const char *part, const char *state, double value); 4991 4992 /** 4993 * @brief Sets the minimum height value of a part state. 4994 * The minimum height should be greater than 0. 4995 * 4996 * @param obj Object being edited. 4997 * @param part Part that contain state. 4998 * @param state The name of the state to set minimum height (not including the state value). 4999 * @param value The state value. 5000 * @param min_h Minimum height value. 5001 * 5002 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5003 */ 5004 EAPI Eina_Bool edje_edit_state_min_h_set(Evas_Object *obj, const char *part, const char *state, double value, int min_h); 5005 5006 /** 5007 * @brief Gets the maximum width value of a part state. 5008 * 5009 * @param obj Object being edited. 5010 * @param part Part that contain state. 5011 * @param state The name of the state to get maximum width (not including the state value). 5012 * @param value The state value. 5013 * 5014 * @return The maximum width value. 5015 */ 5016 EAPI int edje_edit_state_max_w_get(Evas_Object *obj, const char *part, const char *state, double value); 5017 5018 /** 5019 * @brief Sets the maximum width value of a part state. 5020 * The maximum width should be greater than -1. 5021 * The value -1 means that state doesn't have any boundaries on width direction. 5022 * (it can be any size that is bigger than it's min) 5023 * 5024 * @param obj Object being edited. 5025 * @param part Part that contain state. 5026 * @param state The name of the state to set maximum width (not including the state value). 5027 * @param value The state value. 5028 * @param max_w Maximum width value. 5029 * 5030 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5031 */ 5032 EAPI Eina_Bool edje_edit_state_max_w_set(Evas_Object *obj, const char *part, const char *state, double value, int max_w); 5033 5034 /** 5035 * @brief Gets the maximum height value of a part state. 5036 * 5037 * @param obj Object being edited. 5038 * @param part Part that contain state. 5039 * @param state The name of the state to get maximum height (not including the state value). 5040 * @param value The state value. 5041 * 5042 * @return The maximum height value. 5043 */ 5044 EAPI int edje_edit_state_max_h_get(Evas_Object *obj, const char *part, const char *state, double value); 5045 5046 /** 5047 * @brief Sets the maximum height value of a part state. 5048 * The maximum height should be greater than -1. 5049 * The value -1 means that state doesn't have any boundaries on height direction. 5050 * (it can be any size that is bigger than it's min) 5051 * 5052 * @param obj Object being edited. 5053 * @param part Part that contain state. 5054 * @param state The name of the state to set maximum height (not including the state value). 5055 * @param value The state value. 5056 * @param max_h Maximum height value. 5057 * 5058 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5059 */ 5060 EAPI Eina_Bool edje_edit_state_max_h_set(Evas_Object *obj, const char *part, const char *state, double value, int max_h); 5061 5062 /** 5063 * @brief Gets the multiplier (minmul) width value of a part state. 5064 * 5065 * @param obj Object being edited. 5066 * @param part Part that contain state. 5067 * @param state The name of the state to get multiplier width (not including the state value). 5068 * @param value The state value. 5069 * 5070 * @return The maximum width value. 5071 * @since 1.11 5072 */ 5073 EAPI double edje_edit_state_minmul_w_get(Evas_Object *obj, const char *part, const char *state, double value); 5074 5075 /** 5076 * @brief Sets the multiplier (minmul) width value of a part state. 5077 * 5078 * @param obj Object being edited. 5079 * @param part Part that contain state. 5080 * @param state The name of the state to set multiplier width (not including the state value). 5081 * @param value The state value. 5082 * @param minmul_w Multiplier width value. 5083 * 5084 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5085 * @since 1.11 5086 */ 5087 EAPI Eina_Bool edje_edit_state_minmul_w_set(Evas_Object *obj, const char *part, const char *state, double value, double minmul_w); 5088 5089 /** 5090 * @brief Gets the multiplier (minmul) height value of a part state. 5091 * 5092 * @param obj Object being edited. 5093 * @param part Part that contain state. 5094 * @param state The name of the state to get multiplier height (not including the state value). 5095 * @param value The state value. 5096 * 5097 * @return The maximum height value. 5098 * @since 1.11 5099 */ 5100 EAPI double edje_edit_state_minmul_h_get(Evas_Object *obj, const char *part, const char *state, double value); 5101 5102 /** 5103 * @brief Sets the multiplier (minmul) height value of a part state. 5104 * 5105 * @param obj Object being edited. 5106 * @param part Part that contain state. 5107 * @param state The name of the state to set multiplier height (not including the state value). 5108 * @param value The state value. 5109 * @param minmul_h Multiplier height value. 5110 * 5111 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5112 * @since 1.11 5113 */ 5114 EAPI Eina_Bool edje_edit_state_minmul_h_set(Evas_Object *obj, const char *part, const char *state, double value, double minmul_h); 5115 5116 /** 5117 * @brief Gets the fixed width value of a part state. 5118 * 5119 * @param obj Object being edited. 5120 * @param part Part that contain state. 5121 * @param state The name of the state to get fixed width value (not including the state value). 5122 * @param value The state value. 5123 * 5124 * @return The fixed width value. 5125 */ 5126 EAPI Eina_Bool edje_edit_state_fixed_w_get(Evas_Object *obj, const char *part, const char *state, double value); 5127 5128 /** 5129 * @brief Sets the fixed width value of a part state. 5130 * 5131 * @param obj Object being edited. 5132 * @param part Part that contain state. 5133 * @param state The name of the state to set fixed width value (not including the state value). 5134 * @param value The state value. 5135 * @param fixed Fixed width value. 5136 * 5137 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5138 */ 5139 EAPI Eina_Bool edje_edit_state_fixed_w_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool fixed); 5140 5141 /** 5142 * @brief Gets the fixed height value of a part state. 5143 * 5144 * @param obj Object being edited. 5145 * @param part Part that contain state. 5146 * @param state The name of the state to get fixed height value (not including the state value). 5147 * @param value The state value. 5148 * 5149 * @return The fixed height value. 5150 */ 5151 EAPI Eina_Bool edje_edit_state_fixed_h_get(Evas_Object *obj, const char *part, const char *state, double value); 5152 5153 /** 5154 * @brief Sets the fixed height value of a part state. 5155 * 5156 * @param obj Object being edited. 5157 * @param part Part that contain state. 5158 * @param state The name of the state to set maximum height (not including the state value). 5159 * @param value The state value. 5160 * @param fixed Fixed height value. 5161 * 5162 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5163 */ 5164 EAPI Eina_Bool edje_edit_state_fixed_h_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool fixed); 5165 5166 /** 5167 * @brief Gets the minimum aspect value of a part state. 5168 * 5169 * @param obj Object being edited. 5170 * @param part Part that contain state. 5171 * @param state The name of the state to get minimum aspect (not including the state value). 5172 * @param value The state value. 5173 * 5174 * @return The minimum aspect 5175 */ 5176 EAPI double edje_edit_state_aspect_min_get(Evas_Object *obj, const char *part, const char *state, double value); 5177 5178 /** 5179 * @brief Gets the maximum aspect value of a part state. 5180 * 5181 * @param obj Object being edited. 5182 * @param part Part that contain state. 5183 * @param state The name of the state to get maximum aspect (not including the state value). 5184 * @param value The state value. 5185 * 5186 * @return The maximum aspect 5187 */ 5188 EAPI double edje_edit_state_aspect_max_get(Evas_Object *obj, const char *part, const char *state, double value); 5189 5190 /** 5191 * @brief Sets the minimum aspect value of a part state. 5192 * 5193 * @param obj Object being edited. 5194 * @param part Part that contain state. 5195 * @param state The name of the state to set minimum aspect (not including the state value). 5196 * @param value The state value. 5197 * @param aspect Minimum aspect value. 5198 * 5199 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5200 */ 5201 EAPI Eina_Bool edje_edit_state_aspect_min_set(Evas_Object *obj, const char *part, const char *state, double value, double aspect); 5202 5203 /** 5204 * @brief Sets the maximum aspect value of a part state. 5205 * 5206 * @param obj Object being edited. 5207 * @param part Part that contain state. 5208 * @param state The name of the state to set maximum aspect (not including the state value). 5209 * @param value The state value. 5210 * @param aspect Maximum aspect value. 5211 * 5212 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5213 */ 5214 EAPI Eina_Bool edje_edit_state_aspect_max_set(Evas_Object *obj, const char *part, const char *state, double value, double aspect); 5215 5216 /** 5217 * @brief Gets the aspect preference of a part state. 5218 * 5219 * @param obj Object being edited. 5220 * @param part Part that contain state. 5221 * @param state The name of the state to get aspect preference (not including the state value). 5222 * @param value The state value. 5223 * 5224 * @return The aspect preference (0 = None, 1 = Vertical, 2 = Horizontal, 3 = Both) 5225 */ 5226 EAPI unsigned char edje_edit_state_aspect_pref_get(Evas_Object *obj, const char *part, const char *state, double value); 5227 5228 /** 5229 * @brief Sets the aspect preference of a part state. 5230 * 5231 * The available values of aspect preference are: 5232 * <ul style="list-style-type:none"> 5233 * <li>0 - None</li> 5234 * <li>1 - Vertical</li> 5235 * <li>2 - Horizontal</li> 5236 * <li>3 - Both</li> 5237 * <li>4 - Source</li> 5238 * </ul> 5239 * 5240 * @param obj Object being edited. 5241 * @param part Part that contain state. 5242 * @param state The name of the state to set aspect preference (not 5243 * including the state value). 5244 * @param value The state value. 5245 * @param pref The aspect preference to be set 5246 * 5247 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5248 */ 5249 EAPI Eina_Bool edje_edit_state_aspect_pref_set(Evas_Object *obj, const char *part, const char *state, double value, unsigned char pref); 5250 5251 /** 5252 * @brief Gets the smooth property for given part state. 5253 * 5254 * @param obj Object being edited. 5255 * @param part Part that contain state. 5256 * @param state The name of the state to get the fill horizontal origin relative to area (not including the state value). 5257 * @param value The state value. 5258 * 5259 * @return The smooth value. 5260 */ 5261 EAPI Eina_Bool edje_edit_state_fill_smooth_get(Evas_Object *obj, const char *part, const char *state, double value); 5262 5263 /** 5264 * @brief Sets the smooth property for given part state. 5265 * 5266 * @param obj Object being edited. 5267 * @param part Part that contain state. 5268 * @param state The name of the state to set fill horizontal origin relative to area (not including the state value). 5269 * @param value The state value. 5270 * @param smooth The smooth value. 5271 * 5272 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5273 */ 5274 EAPI Eina_Bool edje_edit_state_fill_smooth_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool smooth); 5275 5276 /** 5277 * @brief Gets the fill type property for given part state. 5278 * 5279 * @param obj Object being edited. 5280 * @param part Part that contain state. 5281 * @param state The name of the state. 5282 * @param value The state value. 5283 * 5284 * @return The value that represents fill type: 0 for SCALE or 1 for TILE. In case of error (for example, if part type does not match) returns 2. 5285 * @see edje_edit_state_fill_type_set() 5286 * @since 1.11 5287 */ 5288 EAPI unsigned char edje_edit_state_fill_type_get(Evas_Object *obj, const char *part, const char *state, double value); 5289 5290 /** 5291 * @brief Sets the fill type property for given part state. 5292 * 5293 * Sets the image fill type. The available types are: 5294 * <dl> 5295 * <dt>SCALE</dt> 5296 * <dd>image will be scaled accordingly to the 'relative' and 'offset' params values from 'origin' and 'size' blocks.</dd> 5297 * <dt>TILE</dt> 5298 * <dd>image will be tiled accordingly to the 'relative' and 'offset' params values from 'origin' and 'size' blocks.</dd> 5299 * </dl> 5300 * <b>Important</b>: the part parameter 'min' must be set, it's size of tiled image. 5301 * If parameter 'max' is set tiled area will be resized accordingly to the 'max' values of part. 5302 * The default value of fill type is SCALE. 5303 * 5304 * @param obj Object being edited. 5305 * @param part Part that contain state. 5306 * @param state The name of the state. 5307 * @param value The state value. 5308 * @param fill_type The value that represents fill type: 0 for SCALE or 1 for TILE. 5309 * 5310 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5311 * @see edje_edit_state_fill_type_get() 5312 * @since 1.11 5313 */ 5314 EAPI Eina_Bool edje_edit_state_fill_type_set(Evas_Object *obj, const char *part, const char *state, double value, unsigned char fill_type); 5315 5316 /** 5317 * @brief Gets the fill horizontal origin relative value of a part state. 5318 * 5319 * @param obj Object being edited. 5320 * @param part Part that contain state. 5321 * @param state The name of the state to get the fill horizontal origin relative to area (not including the state value). 5322 * @param value The state value. 5323 * 5324 * @return The fill horizontal origin relative to area. 5325 */ 5326 EAPI double edje_edit_state_fill_origin_relative_x_get(Evas_Object *obj, const char *part, const char *state, double value); 5327 5328 /** 5329 * @brief Gets the fill vertical origin relative value of a part state. 5330 * 5331 * @param obj Object being edited. 5332 * @param part Part that contain state. 5333 * @param state The name of the state to get fill vertical origin relative to area (not including the state value). 5334 * @param value The state value. 5335 * 5336 * @return The fill vertical origin relative to area. 5337 */ 5338 EAPI double edje_edit_state_fill_origin_relative_y_get(Evas_Object *obj, const char *part, const char *state, double value); 5339 5340 /** 5341 * @brief Gets the fill horizontal origin offset value of a part state. 5342 * 5343 * @param obj Object being edited. 5344 * @param part Part that contain state. 5345 * @param state The name of the state to get fill horizontal origin offset relative to area (not including the state value). 5346 * @param value The state value. 5347 * 5348 * @return The fill horizontal origin offset relative to area. 5349 */ 5350 EAPI int edje_edit_state_fill_origin_offset_x_get(Evas_Object *obj, const char *part, const char *state, double value); 5351 5352 /** 5353 * @brief Gets the fill vertical origin offset value of a part state. 5354 * 5355 * @param obj Object being edited. 5356 * @param part Part that contain state. 5357 * @param state The name of the state to get fill vertical origin offset relative to area (not including the state value). 5358 * @param value The state value. 5359 * 5360 * @return The fill vertical origin offset value. 5361 */ 5362 EAPI int edje_edit_state_fill_origin_offset_y_get(Evas_Object *obj, const char *part, const char *state, double value); 5363 5364 /** 5365 * @brief Sets the fill horizontal origin relative value of a part state. 5366 * 5367 * @param obj Object being edited. 5368 * @param part Part that contain state. 5369 * @param state The name of the state to set fill horizontal origin relative to area (not including the state value). 5370 * @param value The state value. 5371 * @param x The fill horizontal origin value. 5372 * 5373 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5374 */ 5375 EAPI Eina_Bool edje_edit_state_fill_origin_relative_x_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 5376 5377 /** 5378 * @brief Sets the fill horizontal origin relative value of a part state. 5379 * 5380 * @param obj Object being edited. 5381 * @param part Part that contain state. 5382 * @param state The name of the state to set fill vertical origin relative to area (not including the state value). 5383 * @param value The state value. 5384 * @param y The fill vertical origin value. 5385 * 5386 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5387 */ 5388 EAPI Eina_Bool edje_edit_state_fill_origin_relative_y_set(Evas_Object *obj, const char *part, const char *state, double value, double y); 5389 5390 /** 5391 * @brief Sets the fill horizontal origin offset value of a part state. 5392 * 5393 * @param obj Object being edited. 5394 * @param part Part that contain state. 5395 * @param state The name of the state to set fill horizontal origin offset relative to area (not including the state value). 5396 * @param value The state value. 5397 * @param x The fill horizontal origin offset value. 5398 * 5399 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5400 */ 5401 EAPI Eina_Bool edje_edit_state_fill_origin_offset_x_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 5402 5403 /** 5404 * @brief Sets the fill vertical origin offset value of a part state. 5405 * 5406 * @param obj Object being edited. 5407 * @param part Part that contain state. 5408 * @param state The name of the state to set fill vertical origin offset relative to area (not including the state value). 5409 * @param value The state value. 5410 * @param y The fill vertical origin offset value. 5411 * 5412 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5413 */ 5414 EAPI Eina_Bool edje_edit_state_fill_origin_offset_y_set(Evas_Object *obj, const char *part, const char *state, double value, double y); 5415 5416 /** 5417 * @brief Gets the fill horizontal size relative value of a part state. 5418 * 5419 * @param obj Object being edited. 5420 * @param part Part that contain state. 5421 * @param state The name of the state to get fill horizontal size relative to area (not including the state value). 5422 * @param value The state value. 5423 * 5424 * @return The fill horizontal size relative to area. 5425 */ 5426 EAPI double edje_edit_state_fill_size_relative_x_get(Evas_Object *obj, const char *part, const char *state, double value); 5427 5428 /** 5429 * @brief Gets the fill vertical size relative value of a part state. 5430 * 5431 * @param obj Object being edited. 5432 * @param part Part that contain state. 5433 * @param state The name of the state to get fill vertical size relative to area (not including the state value). 5434 * @param value The state value. 5435 * 5436 * @return The fill vertical size relative to area. 5437 */ 5438 EAPI double edje_edit_state_fill_size_relative_y_get(Evas_Object *obj, const char *part, const char *state, double value); 5439 5440 /** 5441 * @brief Gets the fill horizontal size offset value of a part state. 5442 * 5443 * @param obj Object being edited. 5444 * @param part Part that contain state. 5445 * @param state The name of the state to get fill horizontal size 5446 * offset relative to area (not including the state value). 5447 * @param value The state value. 5448 * 5449 * @return The fill horizontal size offset relative to area. 5450 */ 5451 EAPI int edje_edit_state_fill_size_offset_x_get(Evas_Object *obj, const char *part, const char *state, double value); 5452 5453 /** 5454 * @brief Gets the fill vertical size offset value of a part state. 5455 * 5456 * @param obj Object being edited. 5457 * @param part Part that contain state. 5458 * @param state The name of the state to get fill vertical size offset 5459 * relative to area (not including the state value). 5460 * @param value The state value. 5461 * 5462 * @return The fill vertical size offset relative to area. 5463 */ 5464 EAPI int edje_edit_state_fill_size_offset_y_get(Evas_Object *obj, const char *part, const char *state, double value); 5465 5466 /** 5467 * @brief Sets the fill horizontal size relative value of a part state. 5468 * 5469 * @param obj Object being edited. 5470 * @param part Part that contain state. 5471 * @param state The name of the state to set fill horizontal size 5472 * relative value (not including the state value). 5473 * @param value The state value. 5474 * @param x The horizontal size relative value. 5475 * 5476 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5477 */ 5478 EAPI Eina_Bool edje_edit_state_fill_size_relative_x_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 5479 5480 /** 5481 * @brief Sets the fill vertical size relative value of a part state. 5482 * 5483 * @param obj Object being edited. 5484 * @param part Part that contain state. 5485 * @param state The name of the state to set fill vertical size 5486 * relative value (not including the state value). 5487 * @param value The state value. 5488 * @param x The vertical size relative value. 5489 * 5490 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5491 */ 5492 EAPI Eina_Bool edje_edit_state_fill_size_relative_y_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 5493 5494 /** 5495 * @brief Sets the fill horizontal size offset value of a part state. 5496 * 5497 * @param obj Object being edited. 5498 * @param part Part that contain state. 5499 * @param state The name of the state to set fill horizontal size 5500 * offset relative value (not including the state value). 5501 * @param value The state value. 5502 * @param x The horizontal size offset value. 5503 * 5504 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5505 */ 5506 EAPI Eina_Bool edje_edit_state_fill_size_offset_x_set(Evas_Object *obj, const char *part, const char *state, double value, double x); 5507 5508 /** 5509 * @brief Sets the fill vertical size offset value of a part state. 5510 * 5511 * @param obj Object being edited. 5512 * @param part Part that contain state. 5513 * @param state The name of the state to set fill vertical size offset 5514 * relative value (not including the state value). 5515 * @param value The state value. 5516 * @param y The vertical size offset value. 5517 * 5518 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5519 */ 5520 EAPI Eina_Bool edje_edit_state_fill_size_offset_y_set(Evas_Object *obj, const char *part, const char *state, double value, double y); 5521 5522 /** 5523 * @brief Gets the visibility of a part state. 5524 * 5525 * @param obj Object being edited. 5526 * @param part Part that contain state. 5527 * @param state The name of the state to get visibility (not including the state value). 5528 * @param value The state value. 5529 * 5530 * @return @c EINA_TRUE if the state is visible, @c EINA_FALSE otherwise. 5531 */ 5532 EAPI Eina_Bool edje_edit_state_visible_get(Evas_Object *obj, const char *part, const char *state, double value); 5533 5534 /** 5535 * @brief Sets the visibility of a part state. 5536 * 5537 * @param obj Object being edited. 5538 * @param part Part that contain state. 5539 * @param state The name of the state to set visibility (not including the state value). 5540 * @param value The state value. 5541 * @param visible To set state visible (EINA_TRUE if the state is visible, @c EINA_FALSE otherwise) 5542 * 5543 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5544 */ 5545 EAPI Eina_Bool edje_edit_state_visible_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool visible); 5546 5547 /** 5548 * @brief Gets the color class of the given part state. 5549 * 5550 * Remember to free the string with edje_edit_string_free() 5551 * 5552 * @param obj Object being edited. 5553 * @param part Part that contain state. 5554 * @param state The name of the state to get color class (not including the state value). 5555 * @param value The state value. 5556 * 5557 * @return The current color class. 5558 */ 5559 EAPI const char *edje_edit_state_color_class_get(Evas_Object *obj, const char *part, const char *state, double value); 5560 5561 /** 5562 * @brief Sets the color class of the given part state. 5563 * 5564 * @param obj Object being edited. 5565 * @param part Part that contain state. 5566 * @param state The name of the state to set color class (not including the state value). 5567 * @param value The state value. 5568 * @param color_class The color class to assign. 5569 * 5570 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5571 */ 5572 EAPI Eina_Bool edje_edit_state_color_class_set(Evas_Object *obj, const char *part, const char *state, double value, const char *color_class); 5573 5574 /** 5575 * @brief Gets the list of parameters for an external part. 5576 * 5577 * DO NOT FREE THE LIST! 5578 * 5579 * @param obj Object being edited. 5580 * @param part Part that contain state. 5581 * @param state The name of the state to get list of Edje_External_Param (not including the state value). 5582 * @param value The state value. 5583 * 5584 * @return The list of Edje_External_Param. 5585 */ 5586 EAPI const Eina_List * edje_edit_state_external_params_list_get(Evas_Object *obj, const char *part, const char *state, double value); 5587 5588 /** 5589 * @brief Gets the external parameter type and value. 5590 * 5591 * @param obj Object being edited. 5592 * @param part Part that contain state. 5593 * @param state The name of the state to get external parameter (not including the state value). 5594 * @param value The state value. 5595 * @param param The name of the parameter to look for. 5596 * @param type The type of the parameter will be stored here. 5597 * @param val Pointer to value will be stored here - DO NOT FREE IT! 5598 * 5599 * @return @c EINA_TRUE if the parameter was found, @c EINA_FALSE otherwise. 5600 */ 5601 EAPI Eina_Bool edje_edit_state_external_param_get(Evas_Object *obj, const char *part, const char *state, double value, const char *param, Edje_External_Param_Type *type, void **val); 5602 5603 /** 5604 * @brief Gets external parameter of type INT. 5605 * 5606 * @param obj Object being edited. 5607 * @param part Part that contain state. 5608 * @param state The name of the state to get external parameter of type INT (not including the state value). 5609 * @param value The state value. 5610 * @param param The name of the parameter. 5611 * @param val The value of the parameter. 5612 * 5613 * @return @c EINA_TRUE if successful. @c EINA_FALSE if not found or is of different type. 5614 */ 5615 EAPI Eina_Bool edje_edit_state_external_param_int_get(Evas_Object *obj, const char *part, const char *state, double value, const char *param, int *val); 5616 5617 /** 5618 * @brief Gets external parameter of type BOOL. 5619 * 5620 * @param obj Object being edited. 5621 * @param part Part that contain state. 5622 * @param state The name of the state to get external parameter of type BOOL (not including the state value). 5623 * @param value The state value. 5624 * @param param The name of the parameter. 5625 * @param val The value of the parameter. 5626 * 5627 * @return @c EINA_TRUE if successful. @c EINA_FALSE if not found or is of different type. 5628 */ 5629 EAPI Eina_Bool edje_edit_state_external_param_bool_get(Evas_Object *obj, const char *part, const char *state, double value, const char *param, Eina_Bool *val); 5630 5631 /** 5632 * @brief Gets external parameter of type DOUBLE. 5633 * 5634 * @param obj Object being edited. 5635 * @param part Part that contain state. 5636 * @param state The name of the state to get external parameter of type DOUBLE (not including the state value). 5637 * @param value The state value. 5638 * @param param The name of the parameter. 5639 * @param val The value of the parameter. 5640 * 5641 * @return @c EINA_TRUE if successful. @c EINA_FALSE if not found or is of different type. 5642 */ 5643 EAPI Eina_Bool edje_edit_state_external_param_double_get(Evas_Object *obj, const char *part, const char *state, double value, const char *param, double *val); 5644 5645 /** 5646 * @brief Gets external parameter of type STRING. 5647 * 5648 * @param obj Object being edited. 5649 * @param part Part that contain state. 5650 * @param state The name of the state to get external parameter of 5651 * type STRING (not including the state value). 5652 * @param value The state value. 5653 * @param param The name of the parameter. 5654 * @param val The value of the parameter. 5655 * 5656 * @return @c EINA_TRUE if successful. @c EINA_FALSE if not found or is of 5657 * different type. 5658 */ 5659 EAPI Eina_Bool edje_edit_state_external_param_string_get(Evas_Object *obj, const char *part, const char *state, double value, const char *param, const char **val); 5660 5661 /** 5662 * @brief Gets external parameter of type CHOICE. 5663 * 5664 * @param obj Object being edited. 5665 * @param part Part that contain state. 5666 * @param state The name of the state to get external parameter of 5667 * type CHOICE (not including the state value). 5668 * @param value The state value. 5669 * @param param The name of the parameter. 5670 * @param val The value of the parameter. 5671 * 5672 * @return @c EINA_TRUE if successful. @c EINA_FALSE if not found or is of 5673 * different type. 5674 */ 5675 EAPI Eina_Bool edje_edit_state_external_param_choice_get(Evas_Object *obj, const char *part, const char *state, double value, const char *param, const char **val); 5676 5677 /** 5678 * @brief Sets the external parameter type and value, adding it if it didn't 5679 * exist before. 5680 * 5681 * @param obj Object being edited. 5682 * @param part Part that contain state. 5683 * @param state The name of the state to get external parameter (not 5684 * including the state value). 5685 * @param value The state value. 5686 * @param param The name of the parameter set. 5687 * @param type The type of the parameter. 5688 * 5689 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5690 */ 5691 5692 /** 5693 * Arguments should have proper sized values matching their types: 5694 * - EDJE_EXTERNAL_PARAM_TYPE_INT: int 5695 * - EDJE_EXTERNAL_PARAM_TYPE_BOOL: int 5696 * - EDJE_EXTERNAL_PARAM_TYPE_DOUBLE: double 5697 * - EDJE_EXTERNAL_PARAM_TYPE_STRING: char* 5698 * - EDJE_EXTERNAL_PARAM_TYPE_CHOICE: char* 5699 * 5700 * @note: The validation of the parameter will occur only if the part 5701 * is in the same state as the one being modified. 5702 */ 5703 EAPI Eina_Bool edje_edit_state_external_param_set(Evas_Object *obj, const char *part, const char *state, double value, const char *param, Edje_External_Param_Type type, ...); 5704 5705 /** 5706 * @brief Sets external parameter of type INT. 5707 * 5708 * @param obj Object being edited. 5709 * @param part Part that contain state. 5710 * @param state The name of the state to get external parameter of 5711 * type INT (not including the state value). 5712 * @param value The state value. 5713 * @param param The name of the parameter. 5714 * @param val Value will be stored here. 5715 * 5716 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5717 */ 5718 EAPI Eina_Bool edje_edit_state_external_param_int_set(Evas_Object *obj, const char *part, const char *state, double value, const char *param, int val); 5719 5720 /** 5721 * @brief Sets external parameter of type BOOL. 5722 * 5723 * @param obj Object being edited. 5724 * @param part Part that contain state. 5725 * @param state The name of the state to get external parameter of type BOOL (not including the state value). 5726 * @param value The state value. 5727 * @param param The name of the parameter. 5728 * @param val Value will be stored here. 5729 * 5730 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5731 */ 5732 EAPI Eina_Bool edje_edit_state_external_param_bool_set(Evas_Object *obj, const char *part, const char *state, double value, const char *param, Eina_Bool val); 5733 5734 /** 5735 * @brief Sets external parameter of type DOUBLE. 5736 * 5737 * @param obj Object being edited. 5738 * @param part Part that contain state. 5739 * @param state The name of the state to get external parameter of type DOUBLE (not including the state value). 5740 * @param value The state value. 5741 * @param param The name of the parameter. 5742 * @param val Value will be stored here. 5743 * 5744 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5745 */ 5746 EAPI Eina_Bool edje_edit_state_external_param_double_set(Evas_Object *obj, const char *part, const char *state, double value, const char *param, double val); 5747 5748 /** 5749 * @brief Sets external parameter of type STRING. 5750 * 5751 * @param obj Object being edited. 5752 * @param part Part that contain state. 5753 * @param state The name of the state to get external parameter of type STRING (not including the state value). 5754 * @param value The state value. 5755 * @param param The name of the parameter. 5756 * @param val Value will be stored here. 5757 * 5758 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5759 */ 5760 EAPI Eina_Bool edje_edit_state_external_param_string_set(Evas_Object *obj, const char *part, const char *state, double value, const char *param, const char *val); 5761 5762 /** 5763 * @brief Sets external parameter of type CHOICE. 5764 * 5765 * @param obj Object being edited. 5766 * @param part Part that contain state. 5767 * @param state The name of the state to get external parameter of type CHOICE (not including the state value). 5768 * @param value The state value. 5769 * @param param The name of the parameter. 5770 * @param val Value will be stored here. 5771 * 5772 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5773 */ 5774 EAPI Eina_Bool edje_edit_state_external_param_choice_set(Evas_Object *obj, const char *part, const char *state, double value, const char *param, const char *val); 5775 5776 /** 5777 * @brief Sets the states step parameter values. 5778 * 5779 * Step parameter restricts resizing of each dimension to values divisible by 5780 * its value. This causes the part to jump from value to value while resizing. 5781 * The default value is "0 0" disabling stepping. 5782 * 5783 * @param obj Object being edited. 5784 * @param part Part that contain state. 5785 * @param state The name of the state to set fill horizontal size 5786 * relative value (not including the state value). 5787 * @param value The state value. 5788 * @param step_x The horizontal step value. 5789 * @param step_y The vertical step value. 5790 * 5791 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5792 * @see edje_edit_state_step_get() 5793 * @since 1.11 5794 */ 5795 EAPI Eina_Bool edje_edit_state_step_set(Evas_Object *obj, const char *part, const char *state, double value, int step_x, int step_y); 5796 5797 /** 5798 * @brief Gets the states step values. 5799 * 5800 * @param obj Object being edited. 5801 * @param part Part that contain state. 5802 * @param state The name of the state to set fill horizontal size 5803 * relative value (not including the state value). 5804 * @param value The state value. 5805 * @param step_x The pointer to the variable where horizontal step value should be written. 5806 * @param step_y The pointer to the variable where vertical step value should be written. 5807 * 5808 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5809 * @see edje_edit_state_step_set() 5810 * @since 1.11 5811 */ 5812 EAPI Eina_Bool edje_edit_state_step_get(Evas_Object *obj, const char *part, const char *state, double value, int *step_x, int *step_y); 5813 5814 /** 5815 * @brief Sets the states limit parameter value. 5816 * 5817 * Set limit causes the emission of signals when the size of part changes 5818 * from zero or to a zero size in corresponding to the limit value. 5819 * For example, the signals emitted on width changing are <i>'limit,width,over'</i> 5820 * and <i>'limit,width,zero'</i> 5821 * The available values are: 5822 * <ul> 5823 * <li>NONE - 0 (the default value)</li> 5824 * <li>WIDTH - 1</li> 5825 * <li>HEIGHT - 2</li> 5826 * <li>BOTH - 3</li> 5827 * </ul> 5828 * 5829 * @param obj Object being edited. 5830 * @param part Part that contain state. 5831 * @param state The name of the state. 5832 * @param value The state value. 5833 * @param limit The value that represents the states limit value in case of success. 5834 * 5835 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5836 * @see edje_edit_state_limit_get() 5837 * @since 1.11 5838 */ 5839 EAPI Eina_Bool edje_edit_state_limit_set(Evas_Object *obj, const char *part, const char *state, double value, unsigned char limit); 5840 5841 /** 5842 * @brief Gets the states limit value. 5843 * 5844 * Returns value that represents the states limit value: 5845 * <ul> 5846 * <li>NONE - 0 (the default value)</li> 5847 * <li>WIDTH - 1</li> 5848 * <li>HEIGHT - 2</li> 5849 * <li>BOTH - 3</li> 5850 * </ul> 5851 * 5852 * @param obj Object being edited. 5853 * @param part Part that contain state. 5854 * @param state The name of the state. 5855 * @param value The state value. 5856 * 5857 * @return The value that represents the states limit value in case of success, otherwise returns 4. 5858 * @see edje_edit_state_limit_set() 5859 * @since 1.11 5860 */ 5861 EAPI unsigned char edje_edit_state_limit_get(Evas_Object *obj, const char *part, const char *state, double value); 5862 5863 //@} 5864 /******************************************************************************/ 5865 /************************** MAP API ************************************/ 5866 /******************************************************************************/ 5867 /** 5868 * @name Map API 5869 * Functions to deal with objects with rotation properties (see @ref edcref). 5870 */ //@{ 5871 5872 /** 5873 * @brief Gets the flag which enables mapping for the part. 5874 * 5875 * @param obj Object being edited. 5876 * @param part The name of the part. 5877 * @param state The name of the state (not including the state value). 5878 * @param value The state value. 5879 * 5880 * @return @c EINA_TRUE in case if mapping allowed or @c EINA_FALSE otherwise. 5881 * @since 1.11 5882 **/ 5883 EAPI Eina_Bool edje_edit_state_map_on_get(Evas_Object *obj, const char *part, const char *state, double value); 5884 5885 /** 5886 * @brief Enables mapping for the part. Default is 0. 5887 * 5888 * @param obj Object being edited. 5889 * @param part The name of the part. 5890 * @param state The name of the state (not including the state value). 5891 * @param value The state value. 5892 * @param on The flag which allow mapping for the part. 5893 * 5894 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5895 * @since 1.11 5896 **/ 5897 EAPI Eina_Bool edje_edit_state_map_on_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool on); 5898 5899 /** 5900 * @brief Gets the part's name that is used as the 'perspective point'. 5901 * 5902 * @param obj Object being edited. 5903 * @param part The name of the part. 5904 * @param state The name of the state to get perspective (not including the state value). 5905 * @param value The state value. 5906 * 5907 * @return The name of the source part that is used as 'perspective point'. 5908 * @since 1.11 5909 */ 5910 EAPI const char * edje_edit_state_map_perspective_get(Evas_Object *obj, const char *part, const char *state, double value); 5911 5912 /** 5913 * @brief Sets the part's name that is used as the 'perspective point'. 5914 * 5915 * @param obj Object being edited. 5916 * @param part The name of the part. 5917 * @param state The name of the state to get perspective (not including the state value). 5918 * @param value The state value. 5919 * @param source_part The source part's name. 5920 * 5921 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5922 * @since 1.11 5923 */ 5924 EAPI Eina_Bool edje_edit_state_map_perspective_set(Evas_Object *obj, const char *part, const char *state, double value, const char *source_part); 5925 5926 /** 5927 * @brief Gets the part's name that is used as the 'light' for calculating the brightness. 5928 * 5929 * @param obj Object being edited. 5930 * @param part The name of the part. 5931 * @param state The name of the state (not including the state value). 5932 * @param value The state value. 5933 * 5934 * @return The name of the source part that is used as 'light'. 5935 * @since 1.11 5936 **/ 5937 EAPI const char * edje_edit_state_map_light_get(Evas_Object *obj, const char *part, const char *state, double value); 5938 5939 /** 5940 * @brief Sets the part that is used as the 'light'. 5941 * 5942 * @param obj Object being edited. 5943 * @param part The name of the part. 5944 * @param state The name of the state (not including the state value). 5945 * @param value The state value. 5946 * @param source_part The source part's name. 5947 * 5948 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5949 * @since 1.11 5950 **/ 5951 EAPI Eina_Bool edje_edit_state_map_light_set(Evas_Object *obj, const char *part, const char *state, double value, const char *source_part); 5952 5953 /** 5954 * @brief Gets backface_cull value of given part state. 5955 * 5956 * @param obj Object being edited. 5957 * @param part The name of the part. 5958 * @param state The name of the state (not including the state value). 5959 * @param value The state value. 5960 * 5961 * @return backface_cull value of given part state. 5962 * @since 1.11 5963 **/ 5964 EAPI Eina_Bool edje_edit_state_map_backface_cull_get(Evas_Object *obj, const char *part, const char *state, double value); 5965 5966 /** 5967 * @brief Sets backface_cull value of given part state. 5968 * 5969 * @param obj Object being edited. 5970 * @param part The name of the part. 5971 * @param state The name of the state (not including the state value). 5972 * @param value The state value. 5973 * @param backface_cull New backface_cull value. 5974 * 5975 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 5976 * @since 1.11 5977 **/ 5978 EAPI Eina_Bool edje_edit_state_map_backface_cull_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool backface_cull); 5979 5980 /** 5981 * @brief Gets perspective_on value of given part state. 5982 * 5983 * @param obj Object being edited. 5984 * @param part The name of the part. 5985 * @param state The name of the state (not including the state value). 5986 * @param value The state value. 5987 * 5988 * @return perspective_on value of given part state. 5989 * @since 1.11 5990 **/ 5991 EAPI Eina_Bool edje_edit_state_map_perspective_on_get(Evas_Object *obj, const char *part, const char *state, double value); 5992 5993 /** 5994 * @brief Sets perspective_on value of given part state. 5995 * 5996 * @param obj Object being edited. 5997 * @param part The name of the part. 5998 * @param state The name of the state (not including the state value). 5999 * @param value The state value. 6000 * @param perspective_on New perspective_on value. 6001 * 6002 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6003 * @since 1.11 6004 **/ 6005 EAPI Eina_Bool edje_edit_state_map_perspective_on_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool perspective_on); 6006 6007 /** 6008 * @brief Gets map.alpha value of given part state. 6009 * 6010 * @param obj Object being edited. 6011 * @param part The name of the part. 6012 * @param state The name of the state (not including the state value). 6013 * @param value The state value. 6014 * 6015 * @return map.alpha value of given part state. 6016 * @since 1.11 6017 **/ 6018 EAPI Eina_Bool edje_edit_state_map_alpha_get(Evas_Object *obj, const char *part, const char *state, double value); 6019 6020 /** 6021 * @brief Sets map.alpha value of given part state. 6022 * 6023 * @param obj Object being edited. 6024 * @param part The name of the part. 6025 * @param state The name of the state (not including the state value). 6026 * @param value The state value. 6027 * @param alpha New map.alpha value. 6028 * 6029 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6030 * @since 1.11 6031 **/ 6032 EAPI Eina_Bool edje_edit_state_map_alpha_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool alpha); 6033 6034 /** 6035 * @brief Gets map.smooth value of given part state. 6036 * 6037 * @param obj Object being edited. 6038 * @param part The name of the part. 6039 * @param state The name of the state (not including the state value). 6040 * @param value The state value. 6041 * 6042 * @return map.smooth value of given part state. 6043 * @since 1.11 6044 **/ 6045 EAPI Eina_Bool edje_edit_state_map_smooth_get(Evas_Object *obj, const char *part, const char *state, double value); 6046 6047 /** 6048 * @brief Sets map.smooth value of given part state. 6049 * 6050 * @param obj Object being edited. 6051 * @param part The name of the part. 6052 * @param state The name of the state (not including the state value). 6053 * @param value The state value. 6054 * @param smooth New map.smooth value. 6055 * 6056 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6057 * @since 1.11 6058 **/ 6059 EAPI Eina_Bool edje_edit_state_map_smooth_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool smooth); 6060 6061 /** 6062 * @brief Gets map.rotation of given part state. 6063 * 6064 * @param obj Object being edited. 6065 * @param part The name of the part. 6066 * @param state The name of the state (not including the state value). 6067 * @param value The state value. 6068 * @param x x-rotation. 6069 * @param y x-rotation. 6070 * @param z z-rotation. 6071 * 6072 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6073 * @since 1.11 6074 **/ 6075 EAPI Eina_Bool edje_edit_state_map_rotation_get(Evas_Object *obj, const char *part, const char *state, double value, double *x, double *y, double *z); 6076 6077 /** 6078 * @brief Sets map.rotation of given part state. 6079 * 6080 * @param obj Object being edited. 6081 * @param part The name of the part. 6082 * @param state The name of the state (not including the state value). 6083 * @param value The state value. 6084 * @param x x-rotation. 6085 * @param y x-rotation. 6086 * @param z z-rotation. 6087 * 6088 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6089 * @since 1.11 6090 **/ 6091 EAPI Eina_Bool edje_edit_state_map_rotation_set(Evas_Object *obj, const char *part, const char *state, double value, double x, double y, double z); 6092 6093 /** 6094 * @brief Gets map.perspective.focal value of given part state. 6095 * 6096 * @param obj Object being edited. 6097 * @param part The name of the part. 6098 * @param state The name of the state (not including the state value). 6099 * @param value The state value. 6100 * 6101 * @return map.perspective.focal value of given part state. 6102 * @since 1.11 6103 **/ 6104 EAPI int edje_edit_state_map_perspective_focal_get(Evas_Object *obj, const char *part, const char *state, double value); 6105 6106 /** 6107 * @brief Sets map.perspective.focal value of given part state. 6108 * 6109 * @param obj Object being edited. 6110 * @param part The name of the part. 6111 * @param state The name of the state (not including the state value). 6112 * @param value The state value. 6113 * @param focal New map.perspective.focal value. 6114 * 6115 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6116 * @since 1.11 6117 **/ 6118 EAPI Eina_Bool edje_edit_state_map_perspective_focal_set(Evas_Object *obj, const char *part, const char *state, double value, int focal); 6119 6120 /** 6121 * @brief Gets map.perspective.zplane value of given part state. 6122 * 6123 * @param obj Object being edited. 6124 * @param part The name of the part. 6125 * @param state The name of the state (not including the state value). 6126 * @param value The state value. 6127 * 6128 * @return map.perspective.zplane value of given part state. 6129 * @since 1.11 6130 **/ 6131 EAPI int edje_edit_state_map_perspective_zplane_get(Evas_Object *obj, const char *part, const char *state, double value); 6132 6133 /** 6134 * @brief Sets map.perspective.zplane value of given part state. 6135 * 6136 * @param obj Object being edited. 6137 * @param part The name of the part. 6138 * @param state The name of the state (not including the state value). 6139 * @param value The state value. 6140 * @param zplane New map.perspective.zplane value. 6141 * 6142 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6143 * @since 1.11 6144 **/ 6145 EAPI Eina_Bool edje_edit_state_map_perspective_zplane_set(Evas_Object *obj, const char *part, const char *state, double value, int zplane); 6146 6147 /** 6148 * @brief Gets the part's name that is used as the center rotation. 6149 * 6150 * @param obj Object being edited. 6151 * @param part The name of the part. 6152 * @param state The name of the state (not including the state value). 6153 * @param value The state value. 6154 * 6155 * @return The name of the source part that is used as center rotation. 6156 * @since 1.11 6157 **/ 6158 EAPI const char * edje_edit_state_map_rotation_center_get(Evas_Object *obj, const char *part, const char *state, double value); 6159 6160 /** 6161 * @brief Sets map.zoom (x and y) values of given part state. 6162 * 6163 * @param obj Object being edited. 6164 * @param part The name of the part. 6165 * @param state The name of the state (not including the state value). 6166 * @param value The state value. 6167 * @param x value of x 6168 * @param y value of y 6169 * 6170 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6171 * @since 1.19 6172 **/ 6173 EAPI Eina_Bool 6174 edje_edit_state_map_zoom_set(Evas_Object *obj, const char *part, const char *state, double value, double x, double y); 6175 6176 /** 6177 * @brief Gets map.zoom (x and y) values of given part state. 6178 * 6179 * @param obj Object being edited. 6180 * @param part The name of the part. 6181 * @param state The name of the state (not including the state value). 6182 * @param value The state value. 6183 * @param x variable to store value of x 6184 * @param y variable to store value of y 6185 * 6186 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6187 * @since 1.19 6188 **/ 6189 EAPI Eina_Bool 6190 edje_edit_state_map_zoom_get(Evas_Object *obj, const char *part, const char *state, double value, double *x, double *y); 6191 6192 /** 6193 * @brief Sets the part that is used as the center of rotation when rotating the part with this description. If no center is given, the parts original center itself is used for the rotation center. 6194 * 6195 * @param obj Object being edited. 6196 * @param part The name of the part. 6197 * @param state The name of the state (not including the state value). 6198 * @param value The state value. 6199 * @param source_part The source part's name. 6200 * 6201 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6202 * @since 1.11 6203 **/ 6204 EAPI Eina_Bool edje_edit_state_map_rotation_center_set(Evas_Object *obj, const char *part, const char *state, double value, const char *source_part); 6205 6206 /** 6207 * @brief Sets the color for vertex/point of the current part. 6208 * For more detailed information please @see evas_map_point_color_set(). 6209 * 6210 * In edje there is (currently) only 4 main point: 6211 * - Top-Left (0), Top-Right (1), Bottom-Right (2), Bottom-Left (3). 6212 * 6213 * Default value is 255 255 255 255 for every point. 6214 * 6215 * @param obj Object being edited. 6216 * @param part The name of the part. 6217 * @param state The name of the state (not including the state value). 6218 * @param value The state value. 6219 * @param idx The index of point. 6220 * @param r The red value to set. 6221 * @param g The green color value to set. 6222 * @param b The blue color value to set. 6223 * @param a The alpha color value to set. 6224 * 6225 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6226 * @since 1.11 6227 **/ 6228 EAPI Eina_Bool edje_edit_state_map_point_color_set(Evas_Object *obj, const char *part, const char *state, double value, int idx, int r, int g, int b, int a); 6229 6230 /** 6231 * @brief Gets the color of given vertex/point of the current part. 6232 * For more detailed information please @see evas_map_point_color_set(). 6233 * 6234 * In edje there is (currently) only 4 main point: 6235 * - Top-Left (0), Top-Right (1), Bottom-Right (2), Bottom-Left (3). 6236 * 6237 * Default value is 255 255 255 255 for every point. 6238 * 6239 * @param obj Object being edited. 6240 * @param part The name of the part. 6241 * @param state The name of the state (not including the state value). 6242 * @param value The state value. 6243 * @param idx The index of point. 6244 * @param r The red value to get. 6245 * @param g The green color value to get. 6246 * @param b The blue color value to get. 6247 * @param a The alpha color value to get. 6248 * 6249 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6250 * @since 1.11 6251 **/ 6252 EAPI Eina_Bool edje_edit_state_map_point_color_get(Evas_Object *obj, const char *part, const char *state, double value, int idx, int *r, int *g, int *b, int *a); 6253 6254 /** 6255 * @brief Sets the source part for given part state. 6256 * 6257 * Set another part content as the content of this part. 6258 * 6259 * @param obj Object being edited. 6260 * @param part Part that contain state. 6261 * @param state The name of the state. 6262 * @param value The state value. 6263 * @param source_name The name of part to be set as source. If NULL is passed, the source will be unset. 6264 * 6265 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6266 * @see edje_edit_state_proxy_source_get() 6267 * @since 1.11 6268 */ 6269 EAPI Eina_Bool edje_edit_state_proxy_source_set(Evas_Object *obj, const char *part, const char *state, double value, const char *source_name); 6270 6271 /** 6272 * @brief Gets the source name for given state of part. 6273 * 6274 * @note The returned string should be freed with @c eina_stringshare_del(). 6275 * @param obj Object being edited. 6276 * @param part Part that contain state. 6277 * @param state The name of the state. 6278 * @param value The state value. 6279 * 6280 * @return The name of the source part in case of success. Otherwise returns NULL. 6281 * @see edje_edit_state_proxy_source_set() 6282 * @since 1.11 6283 */ 6284 EAPI Eina_Stringshare * edje_edit_state_proxy_source_get(Evas_Object *obj, const char *part, const char *state, double value); 6285 6286 /** 6287 * @brief Sets the source clip for given PROXY part state. 6288 * 6289 * The source clipper is ignored or used when rendering the proxy part. 6290 * 6291 * @param obj Object being edited. 6292 * @param part Part that contain state. 6293 * @param state The name of the state. 6294 * @param value The state value. 6295 * @param clip Value to set if ignore or use source cliper. 6296 * 6297 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6298 * @since 1.18 6299 */ 6300 EAPI Eina_Bool 6301 edje_edit_state_proxy_source_clip_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool clip); 6302 6303 /** 6304 * @brief Gets the source clip for given PROXY part state. 6305 * 6306 * The source clipper is ignored or used when rendering the proxy part. 6307 * 6308 * @param obj Object being edited. 6309 * @param part Part that contain state. 6310 * @param state The name of the state. 6311 * @param value The state value. 6312 * 6313 * @return @c EINA_TRUE in case if source clipper is used, @c EINA_FALSE otherwise. 6314 * @since 1.18 6315 */ 6316 EAPI Eina_Bool 6317 edje_edit_state_proxy_source_clip_get(Evas_Object *obj, const char *part, const char *state, double value); 6318 6319 /** 6320 * @brief Sets the source visibility for given PROXY part state. 6321 * 6322 * Defines if both the proxy and its source object will be visible or not. 6323 * In case of false flag, the source object will not be visible at all while 6324 * proxy will still show source object. 6325 * 6326 * @param obj Object being edited. 6327 * @param part Part that contain state. 6328 * @param state The name of the state. 6329 * @param value The state value. 6330 * @param visibility Value to set if source object is visible or not. 6331 * 6332 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6333 * @since 1.18 6334 */ 6335 EAPI Eina_Bool 6336 edje_edit_state_proxy_source_visible_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool visibility); 6337 6338 /** 6339 * @brief Gets the source visibility for given PROXY part state. 6340 * 6341 * Defines if both the proxy and its source object will be visible or not. 6342 * In case of false flag, the source object will not be visible at all while 6343 * proxy will still show source object. 6344 * 6345 * @param obj Object being edited. 6346 * @param part Part that contain state. 6347 * @param state The name of the state. 6348 * @param value The state value. 6349 * 6350 * @return @c EINA_TRUE in case when source object visibility is set to true, @c EINA_FALSE otherwise. 6351 * @since 1.18 6352 */ 6353 EAPI Eina_Bool 6354 edje_edit_state_proxy_source_visible_get(Evas_Object *obj, const char *part, const char *state, double value); 6355 6356 //@} 6357 /******************************************************************************/ 6358 /************************** TEXT API ************************************/ 6359 /******************************************************************************/ 6360 /** 6361 * @name Text API 6362 * Functions to deal with text objects (see @ref edcref). 6363 */ //@{ 6364 6365 /** 6366 * @brief Gets the text of a part state. 6367 * 6368 * Remember to free the returned string with edje_edit_string_free(). 6369 * 6370 * @param obj Object being edited. 6371 * @param part Part that contain state. 6372 * @param state The name of the state to get text (not including the state value). 6373 * @param value The state value. 6374 * 6375 * @return A newly allocated string containing the text for the given state. 6376 */ 6377 EAPI const char * edje_edit_state_text_get(Evas_Object *obj, const char *part, const char *state, double value); 6378 6379 /** 6380 * @brief Sets the text of a part state. 6381 * 6382 * @param obj Object being edited. 6383 * @param part Part that contain state. 6384 * @param state The name of the state to set text (not including the state value). 6385 * @param value The state value. 6386 * @param text The new text to assign. 6387 * 6388 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6389 */ 6390 EAPI Eina_Bool edje_edit_state_text_set(Evas_Object *obj, const char *part, const char *state, double value,const char *text); 6391 6392 /** 6393 * @brief Gets font name for a given part state. 6394 * 6395 * Remember to free the returned string using edje_edit_string_free(). 6396 * 6397 * @param obj Object being edited. 6398 * @param part The name of the part to get the font of. 6399 * @param state The state of the part to get the font of. 6400 * @param value Value of the state. 6401 * 6402 * @return Font used by the part or NULL if error or nothing is set. 6403 */ 6404 EAPI const char * edje_edit_state_font_get(Evas_Object *obj, const char *part, const char *state, double value); 6405 6406 /** 6407 * @brief Sets font name for a given part state. 6408 * 6409 * Font name can be any alias of an internal font in the Edje file and, 6410 * if it doesn't match any, Edje will look for a font with the given name 6411 * in the system fonts. 6412 * 6413 * @param obj Object being edited. 6414 * @param part Part to set the font of. 6415 * @param state State in which the font is set. 6416 * @param value Value of the state. 6417 * @param font The font name to use. 6418 * 6419 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6420 */ 6421 EAPI Eina_Bool edje_edit_state_font_set(Evas_Object *obj, const char *part, const char *state, double value, const char *font); 6422 6423 /** 6424 * @brief Gets the text size of a part state. 6425 * 6426 * @param obj Object being edited. 6427 * @param part Part that contain state. 6428 * @param state The name of the state to get text size (not including the state value). 6429 * @param value The state value. 6430 * 6431 * @return The text size or @c -1 on errors. 6432 */ 6433 EAPI int edje_edit_state_text_size_get(Evas_Object *obj, const char *part, const char *state, double value); 6434 6435 /** 6436 * @brief Sets the text size of a part state. 6437 * 6438 * @param obj Object being edited. 6439 * @param part Part that contain state. 6440 * @param state The name of the state to set text size (not including the state value). 6441 * @param value The state value. 6442 * @param size The new font size to set (in pixel) 6443 * 6444 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6445 */ 6446 EAPI Eina_Bool edje_edit_state_text_size_set(Evas_Object *obj, const char *part, const char *state, double value, int size); 6447 6448 /** 6449 * @brief Gets the text horizontal align of a part state. 6450 * 6451 * The value range is from 0.0(right) to 1.0(left) 6452 * If the value is between -1.0 and 0.0 then it uses align automatically. 6453 * 6454 * @param obj Object being edited. 6455 * @param part Part that contain state. 6456 * @param state The name of the state to get the text horizontal align (not including the state value). 6457 * @param value The state value. 6458 * 6459 * @return The text horizontal align value 6460 */ 6461 EAPI double edje_edit_state_text_align_x_get(Evas_Object *obj, const char *part, const char *state, double value); 6462 6463 /** 6464 * @brief Gets the text vertical align of a part state. 6465 * 6466 * The value range is from 0.0(top) to 1.0(bottom) 6467 * 6468 * @param obj Object being edited. 6469 * @param part Part that contain state. 6470 * @param state The name of the state to get the text vertical align (not including the state value). 6471 * @param value The state value. 6472 * 6473 * @return The text horizontal align value 6474 */ 6475 EAPI double edje_edit_state_text_align_y_get(Evas_Object *obj, const char *part, const char *state, double value); 6476 6477 /** 6478 * @brief Sets the text horizontal align of a part state. 6479 * 6480 * The value range is from 0.0(right) to 1.0(left) 6481 * If the value is between -1.0 and 0.0 then it uses align automatically. 6482 * 6483 * @param obj Object being edited. 6484 * @param part Part that contain state. 6485 * @param state The name of the state to set the text horizontal align (not including the state value). 6486 * @param value The state value. 6487 * @param align The new text horizontal align value 6488 * 6489 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6490 */ 6491 EAPI Eina_Bool edje_edit_state_text_align_x_set(Evas_Object *obj, const char *part, const char *state, double value, double align); 6492 6493 /** 6494 * @brief Sets the text vertical align of a part state. 6495 * 6496 * The value range is from 0.0(top) to 1.0(bottom) 6497 * 6498 * @param obj Object being edited. 6499 * @param part Part that contain state. 6500 * @param state The name of the state to set the text vertical align (not including the state value). 6501 * @param value The state value. 6502 * @param align The new text vertical align value 6503 * 6504 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6505 */ 6506 EAPI Eina_Bool edje_edit_state_text_align_y_set(Evas_Object *obj, const char *part, const char *state, double value, double align); 6507 6508 /** 6509 * @brief Gets the text elipsis of a part state. 6510 * 6511 * The value range is from 0.0(right) to 1.0(left), and -1.0 (if disabled) 6512 * 6513 * @param obj Object being edited. 6514 * @param part Part that contain state. 6515 * @param state The name of the state to get the text elipsis value (not including the state value). 6516 * @param value The state value. 6517 * 6518 * @return The text elipsis value 6519 */ 6520 EAPI double edje_edit_state_text_elipsis_get(Evas_Object *obj, const char *part, const char *state, double value); 6521 6522 /** 6523 * @brief Sets the text vertical align of a part state. 6524 * 6525 * The value range is from 0.0(right) to 1.0(left) 6526 * If the value is in range from -1.0 to 0.0 then ellipsis is disabled. 6527 * 6528 * @param obj Object being edited. 6529 * @param part Part that contain state. 6530 * @param state The name of the state to set the text elipsis value (not including the state value). 6531 * @param value The state value. 6532 * @param balance The position where to cut the string 6533 * 6534 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6535 */ 6536 EAPI Eina_Bool edje_edit_state_text_elipsis_set(Evas_Object *obj, const char *part, const char *state, double value, double balance); 6537 6538 /** 6539 * @brief Gets if the text part fit it's container horizontally. 6540 * 6541 * @param obj Object being edited. 6542 * @param part Part that contain state. 6543 * @param state The name of the state to get the if the text part fit it's container horizontally (not including the state value). 6544 * @param value The state value. 6545 * 6546 * @return @c EINA_TRUE If the part fit it's container horizontally, @c EINA_FALSE otherwise. 6547 */ 6548 EAPI Eina_Bool edje_edit_state_text_fit_x_get(Evas_Object *obj, const char *part, const char *state, double value); 6549 6550 /** 6551 * @brief Sets if the text part should fit it's container horizontally. 6552 * 6553 * @param obj Object being edited. 6554 * @param part Part that contain state. 6555 * @param state The name of the state to set the if the text part fit it's container horizontally (not including the state value). 6556 * @param value The state value. 6557 * @param fit @c EINA_TRUE to make the text fit it's container horizontally, @c EINA_FALSE otherwise. 6558 * 6559 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6560 */ 6561 EAPI Eina_Bool edje_edit_state_text_fit_x_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool fit); 6562 6563 /** 6564 * @brief Gets if the text part fit it's container vertically. 6565 * 6566 * @param obj Object being edited. 6567 * @param part Part that contain state. 6568 * @param state The name of the state to get the if the text part fit it's container vertically (not including the state value). 6569 * @param value The state value. 6570 * 6571 * @return @c EINA_TRUE If the part fit it's container vertically, @c EINA_FALSE otherwise. 6572 */ 6573 EAPI Eina_Bool edje_edit_state_text_fit_y_get(Evas_Object *obj, const char *part, const char *state, double value); 6574 6575 /** 6576 * @brief Sets if the text part should fit it's container vertically. 6577 * 6578 * @param obj Object being edited. 6579 * @param part Part that contain state. 6580 * @param state The name of the state to set the if the text part fit it's container vertically (not including the state value). 6581 * @param value The state value. 6582 * @param fit @c EINA_TRUE to make the text fit it's container vertically, @c EINA_FALSE otherwise. 6583 * 6584 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6585 */ 6586 EAPI Eina_Bool edje_edit_state_text_fit_y_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool fit); 6587 6588 /** 6589 * @brief Gets if the text part forces the minimum horizontal size of the container to be equal to the minimum horizontal size of the text part 6590 * 6591 * @param obj Object being edited. 6592 * @param part Part that contain state. 6593 * @param state The name of the state to get the minimum horizontal size of the container to be equal (not including the state value). 6594 * @param value The state value. 6595 * 6596 * @return @c EINA_TRUE If the part forces container's minimum horizontal size, @c EINA_FALSE otherwise. 6597 */ 6598 EAPI Eina_Bool edje_edit_state_text_min_x_get(Evas_Object *obj, const char *part, const char *state, double value); 6599 6600 /** 6601 * @brief Gets if the text part forces the maximum horizontal size of the container to be equal to the maximum horizontal size of the text part 6602 * 6603 * @param obj Object being edited. 6604 * @param part Part that contain state. 6605 * @param state The name of the state to get the minimum horizontal size of the container to be equal (not including the state value). 6606 * @param value The state value. 6607 * 6608 * @return @c EINA_TRUE If the part forces container's maximum horizontal size, @c EINA_FALSE otherwise. 6609 */ 6610 EAPI Eina_Bool edje_edit_state_text_max_x_get(Evas_Object *obj, const char *part, const char *state, double value); 6611 6612 /** 6613 * @brief Gets if the text part forces the minimum vertical size of the container to be equal to the minimum vertical size of the text part 6614 * 6615 * @param obj Object being edited. 6616 * @param part Part that contain state. 6617 * @param state The name of the state to get the minimum vertical size of the container to be equal (not including the state value). 6618 * @param value The state value. 6619 * 6620 * @return @c EINA_TRUE If the part forces container's minimum vertical size, @c EINA_FALSE otherwise. 6621 */ 6622 EAPI Eina_Bool edje_edit_state_text_min_y_get(Evas_Object *obj, const char *part, const char *state, double value); 6623 6624 /** 6625 * @brief Gets if the text part forces the maximum vertical size of the container to be equal to the maximum vertical size of the text part 6626 * 6627 * @param obj Object being edited. 6628 * @param part Part that contain state. 6629 * @param state The name of the state to get the maximum vertical size of the container to be equal (not including the state value). 6630 * @param value The state value. 6631 * 6632 * @return @c EINA_TRUE If the part forces container's maximum vertical size, @c EINA_FALSE otherwise. 6633 */ 6634 EAPI Eina_Bool edje_edit_state_text_max_y_get(Evas_Object *obj, const char *part, const char *state, double value); 6635 6636 /** 6637 * @brief Sets if the text part forces the minimum horizontal size of the container to be equal to the minimum horizontal size of the text part 6638 * 6639 * @param obj Object being edited. 6640 * @param part Part that contain state. 6641 * @param state The name of the state to set the minimum horizontal size of the container to be equal (not including the state value). 6642 * @param value The state value. 6643 * @param v @c EINA_TRUE to make the text force it's forces container's minimum horizontal size, @c EINA_FALSE otherwise. 6644 * 6645 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6646 */ 6647 EAPI Eina_Bool edje_edit_state_text_min_x_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool v); 6648 6649 /** 6650 * @brief Sets if the text part forces the maximum horizontal size of the container to be equal to the maximum horizontal size of the text part 6651 * 6652 * @param obj Object being edited. 6653 * @param part Part that contain state. 6654 * @param state The name of the state to set the maximum horizontal size of the container to be equal (not including the state value). 6655 * @param value The state value. 6656 * @param v @c EINA_TRUE to make the text force it's forces container's maximum horizontal size, @c EINA_FALSE otherwise. 6657 * 6658 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6659 */ 6660 EAPI Eina_Bool edje_edit_state_text_max_x_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool v); 6661 6662 /** 6663 * @brief Sets if the text part forces the minimum vertical size of the container to be equal to the minimum vertical size of the text part 6664 * 6665 * @param obj Object being edited. 6666 * @param part Part that contain state. 6667 * @param state The name of the state to set the minimum vertical size of the container to be equal (not including the state value). 6668 * @param value The state value. 6669 * @param v @c EINA_TRUE to make the text force it's forces container's minimum vertical size, @c EINA_FALSE otherwise. 6670 * 6671 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6672 */ 6673 EAPI Eina_Bool edje_edit_state_text_min_y_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool v); 6674 6675 /** 6676 * @brief Sets if the text part forces the maximum vertical size of the container to be equal to the maximum vertical size of the text part 6677 * 6678 * @param obj Object being edited. 6679 * @param part Part that contain state. 6680 * @param state The name of the state to set the maximum vertical size of the container to be equal (not including the state value). 6681 * @param value The state value. 6682 * @param v @c EINA_TRUE to make the text force it's forces container's maximum vertical size, @c EINA_FALSE otherwise. 6683 * 6684 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6685 */ 6686 EAPI Eina_Bool edje_edit_state_text_max_y_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool v); 6687 6688 /** 6689 * @brief Gets style name for a given part state. 6690 * 6691 * @param obj Object being edited. 6692 * @param part The name of the part to get the style of. 6693 * @param state The state of the part to get the style of. 6694 * @param value Value of the state. 6695 * 6696 * @return Style used by the part, or NULL if error or nothing is set. 6697 */ 6698 EAPI const char * edje_edit_state_text_style_get(Evas_Object *obj, const char *part, const char *state, double value); 6699 6700 /** 6701 * @brief Sets style name for a given part state. 6702 * 6703 * Causes the part to use the default style and tags defined in the "style" block with the specified name. 6704 * 6705 * @param obj Object being edited. 6706 * @param part Part to set the style of. 6707 * @param state State in which the style is set. 6708 * @param value Value of the state. 6709 * @param style The style name to use. In case when NULL style will removed from textblock part description. 6710 * 6711 * 6712 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6713 */ 6714 EAPI Eina_Bool edje_edit_state_text_style_set(Evas_Object *obj, const char *part, const char *state, double value, const char *style); 6715 6716 /** 6717 * @brief Gets part name, which used as text source. 6718 * 6719 * @param obj Object being edited. 6720 * @param part Part that contain state. 6721 * @param state The name of the state to set the maximum vertical size of 6722 * the container to be equal (not including the state value). 6723 * @param value Value of the state. 6724 * 6725 * @return The name of part or NULL, if text_source param not a setted. 6726 */ 6727 EAPI const char * edje_edit_state_text_text_source_get(Evas_Object *obj, const char *part, const char *state, double value); 6728 6729 /** 6730 * @brief Sets the source text part for a given part. 6731 * Causes the part to display the content text of another part and update 6732 * them as they change. 6733 * 6734 * @param obj Object being edited. 6735 * @param part Part that contain state. 6736 * @param state The name of the state to set the maximum vertical size of 6737 * the container to be equal (not including the state value). 6738 * @param value Value of the state. 6739 * @param source The text source part name. 6740 * 6741 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6742 */ 6743 EAPI Eina_Bool edje_edit_state_text_text_source_set(Evas_Object *obj, const char *part, const char *state, double value, const char *source); 6744 6745 /** 6746 * @brief Gets part name, which used as style text source. 6747 * 6748 * @param obj Object being edited. 6749 * @param part Part that contain state. 6750 * @param state The name of the state to set the maximum vertical size of 6751 * @param value Value of the state. 6752 * The container to be equal (not including the state value). 6753 * 6754 * @return The name of part or NULL, if text_source param not a setted. 6755 */ 6756 EAPI const char * edje_edit_state_text_source_get(Evas_Object *obj, const char *part, const char *state, double value); 6757 6758 /** 6759 * @brief Sets the source part which would be used as style for text for a given part. 6760 * Causes the part to use the text properties (like font and size) of another 6761 * part and update them as they change. 6762 * 6763 * @param obj Object being edited. 6764 * @param part Part that contain state. 6765 * @param state The name of the state to set the maximum vertical size of 6766 * the container to be equal (not including the state value). 6767 * @param value Value of the state. 6768 * @param source The text source part name. 6769 * 6770 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6771 */ 6772 EAPI Eina_Bool edje_edit_state_text_source_set(Evas_Object *obj, const char *part, const char *state, double value, const char *source); 6773 6774 /** 6775 * @brief Gets the text class of the given part state. 6776 * 6777 * @param obj Object being edited. 6778 * @param part Part that contain state. 6779 * @param state The name of the state to get text class (not including the state value). 6780 * @param value The state value. 6781 * 6782 * @return The current text class. 6783 */ 6784 EAPI const char * edje_edit_state_text_class_get(Evas_Object *obj, const char *part, const char *state, double value); 6785 6786 /** 6787 * @brief Sets the text class of the given part state. 6788 * 6789 * @param obj Object being edited. 6790 * @param part Part that contain state. 6791 * @param state The name of the state to set text class (not including the state value). 6792 * @param value The state value. 6793 * @param text_class The text class to assign. 6794 * 6795 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6796 */ 6797 EAPI Eina_Bool edje_edit_state_text_class_set(Evas_Object *obj, const char *part, const char *state, double value, const char *text_class); 6798 6799 /** 6800 * @brief Gets the replacement character string of the given part state. 6801 * 6802 * @param obj Object being edited. 6803 * @param part Part that contain state. 6804 * @param state The name of the state to get replacement character 6805 * (not including the state value). 6806 * @param value The state value. 6807 * 6808 * @return The current replacement character. 6809 */ 6810 EAPI const char * edje_edit_state_text_repch_get(Evas_Object *obj, const char *part, const char *state, double value); 6811 6812 /** 6813 * @brief Sets the replacement character string of the given part state. 6814 * 6815 * @param obj Object being edited. 6816 * @param part Part that contain state. 6817 * @param state The name of the state to get replacement character 6818 * (not including the state value). 6819 * @param value The state value. 6820 * @param repch The replacement character string to assign. 6821 * 6822 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6823 */ 6824 EAPI Eina_Bool edje_edit_state_text_repch_set(Evas_Object *obj, const char *part, const char *state, double value, const char *repch); 6825 6826 /** 6827 * @brief Gets the min and max font size allowed for the text part. 6828 * 6829 * @param obj Object being edited. 6830 * @param part Part that contain state. 6831 * @param state State in which the part is set. 6832 * @param value Value of the state. 6833 * @param min Minimal value of the font size in points (pt). 6834 * @param max Maximum value of the font size in points (pt). 6835 * 6836 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6837 */ 6838 EAPI Eina_Bool edje_edit_state_text_size_range_min_max_get(Evas_Object *obj, const char *part, const char *state, double value, int *min, int *max); 6839 6840 /** 6841 * @brief Sets the min and max font size allowed for the text part. 6842 * 6843 * @param obj Object being edited. 6844 * @param part Part that contain state. 6845 * @param state State in which the part is set. 6846 * @param value Value of the state. 6847 * @param min Minimal value of the font size in points (pt). 6848 * @param max Maximum value of the font size in points (pt). 6849 * 6850 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 6851 */ 6852 EAPI Eina_Bool edje_edit_state_text_size_range_min_max_set(Evas_Object *obj, const char *part, const char *state, double value, int min, int max); 6853 6854 /** 6855 * @brief Gets the list of all the fonts in the given edje. 6856 * 6857 * Use edje_edit_string_list_free() when you don't need the list anymore. 6858 * 6859 * @param obj Object being edited. 6860 * 6861 * @return A list containing all the fonts names found in the edje file. 6862 */ 6863 EAPI Eina_List * edje_edit_fonts_list_get(Evas_Object *obj); 6864 6865 /** 6866 * @brief Adds a new font to the edje file. 6867 * 6868 * The newly created font will be available to all the groups in the edje, not only the current one. 6869 * 6870 * @param obj Object being edited. 6871 * @param path The file path to load the font from. 6872 * @param alias The alias for file, or NULL to use filename 6873 * 6874 * @return @c EINA_TRUE if font cat be loaded, @c EINA_FALSE otherwise. 6875 */ 6876 EAPI Eina_Bool edje_edit_font_add(Evas_Object *obj, const char *path, const char* alias); 6877 6878 /** 6879 * @brief Deletes font from the edje file. 6880 * 6881 * The font will be removed from all the groups in the edje, not only the current one. 6882 * 6883 * @param obj Object being edited. 6884 * @param alias The font alias 6885 * 6886 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise.(including the 6887 * case when the alias is not valid). 6888 */ 6889 EAPI Eina_Bool edje_edit_font_del(Evas_Object *obj, const char* alias); 6890 6891 /** 6892 * @brief Gets font path for a given font alias. 6893 * 6894 * Remember to free the string with edje_edit_string_free() 6895 * 6896 * @param obj Object being edited. 6897 * @param alias The font alias. 6898 * 6899 * @return The path of the given font alias. 6900 */ 6901 EAPI const char *edje_edit_font_path_get(Evas_Object *obj, const char *alias); 6902 6903 //@} 6904 /******************************************************************************/ 6905 /************************ IMAGE SET API ***********************************/ 6906 /******************************************************************************/ 6907 /** 6908 * @name Image Set API 6909 * Functions to deal with image objects (see @ref edcref). 6910 */ //@{ 6911 6912 /** 6913 * @brief Checks if given image name is set of images or not. 6914 * 6915 * @param obj Object being edited. 6916 * @param image a name to check if it is set or not. 6917 * 6918 * @return @c EINA_TRUE in case when given name is set, @c EINA_FALSE otherwise. 6919 * 6920 * @since 1.18 6921 */ 6922 EAPI Eina_Bool 6923 edje_edit_image_set_exists(Evas_Object *obj, const char *image); 6924 6925 /** 6926 * @brief Gets id of image set. 6927 * 6928 * @param obj Object being edited. 6929 * @param name image set's name. 6930 * 6931 * @return The id of the given image name. 6932 * 6933 * @since 1.18 6934 */ 6935 EAPI int 6936 edje_edit_image_set_id_get(Evas_Object *obj, const char *name); 6937 6938 /** 6939 * @brief Renames image set. 6940 * 6941 * @param obj Object being edited. 6942 * @param set image set's name. 6943 * @param new_set new name of image set. 6944 * 6945 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 6946 * 6947 * @since 1.18 6948 */ 6949 EAPI Eina_Bool 6950 edje_edit_image_set_rename(Evas_Object *obj, const char *set, const char *new_set); 6951 6952 /** 6953 * @brief Gets the list of all the image sets in the given edje. 6954 * Use edje_edit_string_list_free() when you don't need the list anymore. 6955 * 6956 * @param obj Object being edited. 6957 * 6958 * @return A List containing all image sets names found in the edje file. 6959 * 6960 * @since 1.18 6961 */ 6962 EAPI Eina_List * 6963 edje_edit_image_set_list_get(Evas_Object *obj); 6964 6965 /** 6966 * @brief Gets list of (Edje_Part_Image_Use *) - group-part-state triplets where given 6967 * set is used 6968 * 6969 * Use edje_edit_image_usage_list_free() when you don't need it anymore. 6970 * 6971 * @param obj Object being edited. 6972 * @param name The name of the image. 6973 * @param first_only If @c EINA_TRUE, return only one triplet. 6974 * 6975 * @return Eina_List containing Edje_Part_Image_Use if successful, NULL otherwise 6976 */ 6977 EAPI Eina_List* 6978 edje_edit_set_usage_list_get(Evas_Object *obj, const char *name, Eina_Bool first_only); 6979 6980 /** 6981 * @brief Adds new image set. 6982 * 6983 * @param obj Object being edited. 6984 * @param name image set's name. 6985 * 6986 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 6987 * 6988 * @since 1.18 6989 */ 6990 EAPI Eina_Bool 6991 edje_edit_image_set_add(Evas_Object *obj, const char *name); 6992 6993 /** 6994 * @brief Deletes image set. 6995 * 6996 * Can't delete set if it is used by any part. 6997 * 6998 * @param obj Object being edited. 6999 * @param name image set's name. 7000 * 7001 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7002 * 7003 * @since 1.18 7004 */ 7005 EAPI Eina_Bool 7006 edje_edit_image_set_del(Evas_Object *obj, const char *name); 7007 7008 /** 7009 * @brief Gets the list of all images inside of given set in the given edje. 7010 * Use edje_edit_string_list_free() when you don't need the list anymore. 7011 * 7012 * @param obj Object being edited. 7013 * @param name name of image set. 7014 * 7015 * @return A List containing all images found inside of given set in the edje file. 7016 * 7017 * @since 1.18 7018 */ 7019 EAPI Eina_List * 7020 edje_edit_image_set_images_list_get(Evas_Object *obj, const char *name); 7021 7022 /** 7023 * @brief Adds image to set. 7024 * 7025 * Add image to given set. If image is not exist inside of edje 7026 * collection then function @see edje_edit_image_add should be 7027 * used to get image added to edje collection. 7028 * This function uses only already added functions 7029 * 7030 * @param obj Object being edited. 7031 * @param set_name name of image set. 7032 * @param name image set's name. 7033 * 7034 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise (and when image is not exist). 7035 * 7036 * @since 1.18 7037 */ 7038 EAPI Eina_Bool 7039 edje_edit_image_set_image_add(Evas_Object *obj, const char *set_name, const char *name); 7040 7041 /** 7042 * @brief Deletes image on current position from set. 7043 * 7044 * Remove image from given set. To be sure what kind of image will be 7045 * deleted, firstly check it's position via 7046 * @see edje_edit_image_set_images_list_get function. 7047 * 7048 * @param obj Object being edited. 7049 * @param set_name name of image set. 7050 * @param place position of image to be deleted. 7051 * 7052 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7053 * 7054 * @since 1.18 7055 */ 7056 EAPI Eina_Bool 7057 edje_edit_image_set_image_del(Evas_Object *obj, const char *set_name, unsigned int place); 7058 7059 /** 7060 * @brief Gets min size of set's image. 7061 * 7062 * @param obj Object being edited. 7063 * @param set_name name of image set. 7064 * @param place position of image. 7065 * @param w Where to store the width min value. 7066 * @param h Where to store the height min value. 7067 * 7068 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7069 * 7070 * @since 1.18 7071 */ 7072 EAPI Eina_Bool 7073 edje_edit_image_set_image_min_get(Evas_Object *obj, const char *set_name, unsigned int place, int *w, int *h); 7074 7075 /** 7076 * @brief Sets min size of set's image. 7077 * 7078 * @param obj Object being edited. 7079 * @param set_name name of image set. 7080 * @param place position of image. 7081 * @param w New value of picture's min width. 7082 * @param h New value of picture's min height. 7083 * 7084 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7085 * 7086 * @since 1.18 7087 */ 7088 EAPI Eina_Bool 7089 edje_edit_image_set_image_min_set(Evas_Object *obj, const char *set_name, unsigned int place, int w, int h); 7090 7091 /** 7092 * @brief Gets max size of set's image. 7093 * 7094 * @param obj Object being edited. 7095 * @param set_name name of image set. 7096 * @param place position of image. 7097 * @param w Where to store the width max value. 7098 * @param h Where to store the height max value. 7099 * 7100 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7101 * 7102 * @since 1.18 7103 */ 7104 EAPI Eina_Bool 7105 edje_edit_image_set_image_max_get(Evas_Object *obj, const char *set_name, unsigned int place, int *w, int *h); 7106 7107 /** 7108 * @brief Sets max size of set's image. 7109 * 7110 * @param obj Object being edited. 7111 * @param set_name name of image set. 7112 * @param place position of image. 7113 * @param w New value of picture's max width. 7114 * @param h New value of picture's max height. 7115 * 7116 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7117 * 7118 * @since 1.18 7119 */ 7120 EAPI Eina_Bool 7121 edje_edit_image_set_image_max_set(Evas_Object *obj, const char *set_name, unsigned int place, int w, int h); 7122 7123 /** 7124 * @brief Gets border of set's image. 7125 * 7126 * @param obj Object being edited. 7127 * @param set_name name of image set. 7128 * @param place position of image. 7129 * @param l Where to store the left border value. 7130 * @param r Where to store the right border value. 7131 * @param b Where to store the bottom border value. 7132 * @param t Where to store the top border value. 7133 * 7134 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7135 * 7136 * @since 1.18 7137 */ 7138 EAPI Eina_Bool 7139 edje_edit_image_set_image_border_get(Evas_Object *obj, const char *set_name, unsigned int place, int *l, int *r, int *b, int *t); 7140 7141 /** 7142 * @brief Sets border of set's image. 7143 * 7144 * @param obj Object being edited. 7145 * @param set_name name of image set. 7146 * @param place position of image. 7147 * @param l New value of left border value. 7148 * @param r New value of right border value. 7149 * @param b New value of bottom border value. 7150 * @param t New value of top border value. 7151 * 7152 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7153 * 7154 * @since 1.18 7155 */ 7156 EAPI Eina_Bool 7157 edje_edit_image_set_image_border_set(Evas_Object *obj, const char *set_name, unsigned int place, int l, int r, int b, int t); 7158 7159 /** 7160 * @brief Gets border scale of set's image. 7161 * 7162 * @param obj Object being edited. 7163 * @param set_name name of image set. 7164 * @param place position of image. 7165 * 7166 * @return @c border scale value on success, @c -1 otherwise. 7167 * 7168 * @since 1.18 7169 */ 7170 EAPI double 7171 edje_edit_image_set_image_border_scale_get(Evas_Object *obj, const char *set_name, unsigned int place); 7172 7173 /** 7174 * @brief Sets border scale of set's image. 7175 * 7176 * @param obj Object being edited. 7177 * @param set_name name of image set. 7178 * @param place position of image. 7179 * @param scale_by New border scale. 7180 * 7181 * @return @c EINA_TRUE on success, @c EINA_FALSE otherwise. 7182 * 7183 * @since 1.18 7184 */ 7185 EAPI Eina_Bool 7186 edje_edit_image_set_image_border_scale_set(Evas_Object *obj, const char *set_name, unsigned int place, double scale_by); 7187 7188 //@} 7189 /******************************************************************************/ 7190 /************************** IMAGES API ************************************/ 7191 /******************************************************************************/ 7192 /** 7193 * @name Images API 7194 * Functions to deal with image objects (see @ref edcref). 7195 */ //@{ 7196 7197 /** 7198 * @brief Gets the list of all the images in the given edje. 7199 * Use edje_edit_string_list_free() when you don't need the list anymore. 7200 * 7201 * @param obj Object being edited. 7202 * 7203 * @return A List containing all images names found in the edje file. 7204 */ 7205 EAPI Eina_List * edje_edit_images_list_get(Evas_Object *obj); 7206 7207 /** 7208 * @brief Adds an new image to the image collection 7209 * 7210 * This function add the given image inside the edje. Don't add a new image part 7211 * but only put the image inside the edje file. It actually write directly to 7212 * the file so you don't have to save. 7213 * After you have to create a new image_part that use this image. Note that all 7214 * the parts in the edje share the same image collection, thus you can/must use 7215 * the same image for different part. 7216 * 7217 * The format of the image files that can be loaded depend on the evas engine on your system 7218 * 7219 * @param obj Object being edited. 7220 * @param path The name of the image file to include in the edje. 7221 * 7222 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7223 */ 7224 EAPI Eina_Bool edje_edit_image_add(Evas_Object *obj, const char *path); 7225 7226 /** 7227 * @brief Deletes an image from the image collection 7228 * 7229 * It actually write directly to the file so you don't have to save. 7230 * Can't delete image if it is used by any part. 7231 * 7232 * @param obj Object being edited. 7233 * @param name The name of the image file to include in the edje. 7234 * 7235 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise.(including the 7236 * case when the name is not valid or image is in use). 7237 */ 7238 EAPI Eina_Bool edje_edit_image_del(Evas_Object *obj, const char *name); 7239 7240 /** 7241 * @brief Replaces one image in all descriptions. 7242 * 7243 * @param obj Object being edited. 7244 * @param name The name of the image to replace. 7245 * @param new_name The new_name of the image to replace with. 7246 * 7247 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise.(including the 7248 * case when one of the names is not valid) 7249 */ 7250 EAPI Eina_Bool edje_edit_image_replace(Evas_Object *obj, const char *name, const char *new_name); 7251 7252 /** 7253 * @brief Renames image. 7254 * 7255 * @param obj Object being edited. 7256 * @param name The name of the image to be renamed. 7257 * @param new_name The new_name of the image. 7258 * 7259 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise.(including the 7260 * case when one of the names is not valid) 7261 * 7262 * @since 1.13 7263 */ 7264 EAPI Eina_Bool edje_edit_image_rename(Evas_Object *obj, const char *name, const char *new_name); 7265 7266 /** 7267 * @brief Gets list of (Edje_Part_Image_Use *) - group-part-state triplets where given 7268 * image is used. 7269 * 7270 * Important! Image can also be used inside of set and plenty of times, so for each use 7271 * inside of set triplet would set "set's" name into group name, and it's state 7272 * value would be -1. Every other fields will be 0. 7273 * 7274 * Use edje_edit_image_usage_list_free() when you don't need it anymore. 7275 * 7276 * @param obj Object being edited. 7277 * @param name The name of the image. 7278 * @param first_only If @c EINA_TRUE, return only one triplet. 7279 * 7280 * @return Eina_List containing Edje_Part_Image_Use if successful, NULL otherwise 7281 */ 7282 EAPI Eina_List* edje_edit_image_usage_list_get(Evas_Object *obj, const char *name, Eina_Bool first_only); 7283 7284 /** 7285 * @brief Frees an Eina_List of (Edje_Part_Image_Use *) allocated by an edje_edit_image_usage_list_get() or 7286 * an edje_edit_vector_usage_list_get() function. 7287 * 7288 * @param lst List of strings to free. 7289 */ 7290 EAPI void edje_edit_image_usage_list_free(Eina_List *lst); 7291 7292 /** 7293 * @brief Adds an image entry to the image collection. 7294 * 7295 * This function adds the given image entry to the edje image collection. The 7296 * image needs to be inside the eet already, with key name "images/id". After 7297 * you have to create a new image_part that use this image, referring to it as 7298 * "name". Note that all the parts in the edje share the same image collection, 7299 * thus you can/must use the same image for different part. 7300 * 7301 * @param obj Object being edited. 7302 * @param name The image entry name. 7303 * @param id The image id. 7304 * 7305 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7306 */ 7307 EAPI Eina_Bool edje_edit_image_data_add(Evas_Object *obj, const char *name, int id); 7308 7309 /** 7310 * @brief Gets normal image name for a given part state. 7311 * 7312 * @param obj Object being edited. 7313 * @param part Part that contain state. 7314 * @param state The name of the state to get the name that is being used (not including the state value). 7315 * @param value The state value. 7316 * 7317 * @return The name of the image used by state. 7318 */ 7319 EAPI const char * edje_edit_state_image_get(Evas_Object *obj, const char *part, const char *state, double value); 7320 7321 /** 7322 * @brief Sets normal image for a given part state. 7323 * 7324 * @param obj Object being edited. 7325 * @param part Part that contain state. 7326 * @param state The name of the state to set the image that will be used (not including the state value). 7327 * @param value The state value. 7328 * @param image The name of the image (must be an image contained in the edje file). 7329 * 7330 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7331 */ 7332 EAPI Eina_Bool edje_edit_state_image_set(Evas_Object *obj, const char *part, const char *state, double value, const char *image); 7333 7334 /** 7335 * @brief Gets normal vector name for a given part state. 7336 * Part should be of type VECTOR 7337 * 7338 * @param obj Object being edited. 7339 * @param part Part that contain state. 7340 * @param state The name of the state to get the name that is being used (not including the state value). 7341 * @param value The state value. 7342 * 7343 * @return The name of the vector used by state. 7344 * @since 1.19 7345 */ 7346 EAPI const char * edje_edit_state_vector_get(Evas_Object *obj, const char *part, const char *state, double value); 7347 7348 /** 7349 * @brief Sets normal vector name for a given part state. 7350 * Part should be of type VECTOR 7351 * 7352 * @param obj Object being edited. 7353 * @param part Part that contain state. 7354 * @param state The name of the state to set the vector that will be used (not including the state value). 7355 * @param value The state value. 7356 * @param image The name of the vector (must be contained in the edje file). 7357 * 7358 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7359 * @since 1.19 7360 */ 7361 EAPI Eina_Bool edje_edit_state_vector_set(Evas_Object *obj, const char *part, const char *state, double value, const char *image); 7362 7363 /** 7364 * @brief Gets image id for a given image name. 7365 * 7366 * @param obj Object being edited. 7367 * @param image_name The image name. 7368 * 7369 * @return The id of the given image name. 7370 */ 7371 EAPI int edje_edit_image_id_get(Evas_Object *obj, const char *image_name); 7372 7373 /** 7374 * @brief Gets compression type for the given image. 7375 * 7376 * @param obj Object being edited. 7377 * @param image The name of the image. 7378 * 7379 * @return One of Image Compression types. 7380 * (EDJE_EDIT_IMAGE_COMP_RAW, EDJE_EDIT_IMAGE_COMP_USER, EDJE_EDIT_IMAGE_COMP_COMP, EDJE_EDIT_IMAGE_COMP_LOSSY[_ETC1]). 7381 */ 7382 EAPI Edje_Edit_Image_Comp edje_edit_image_compression_type_get(Evas_Object *obj, const char *image); 7383 7384 /** 7385 * @brief Sets compression type for the given image. 7386 * 7387 * @param obj Object being edited. 7388 * @param image The name of the image. 7389 * @param ic Edje_Edit_Image_Comp. 7390 * (EDJE_EDIT_IMAGE_COMP_RAW, EDJE_EDIT_IMAGE_COMP_USER, EDJE_EDIT_IMAGE_COMP_COMP, EDJE_EDIT_IMAGE_COMP_LOSSY[_ETC1]). 7391 * 7392 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7393 */ 7394 EAPI Eina_Bool edje_edit_image_compression_type_set(Evas_Object *obj, const char *image, Edje_Edit_Image_Comp ic); 7395 7396 /** 7397 * @brief Gets compression rate for the given image. 7398 * 7399 * @param obj Object being edited. 7400 * @param image The name of the image. 7401 * 7402 * @return The compression rate (if the image is @c 7403 * EDJE_EDIT_IMAGE_COMP_LOSSY[_ETC1]) or < 0, on errors. 7404 */ 7405 EAPI int edje_edit_image_compression_rate_get(Evas_Object *obj, const char *image); 7406 7407 /** 7408 * @brief Gets the image border of a part state. 7409 * 7410 * Pass NULL to any of [r,g,b,a] to get only the others. 7411 * 7412 * @param obj Object being edited. 7413 * @param part Part that contain state. 7414 * @param state The name of the state to get the image border (not 7415 * including the state value). 7416 * @param value The state value. 7417 * @param l A pointer to store the left value 7418 * @param r A pointer to store the right value 7419 * @param t A pointer to store the top value 7420 * @param b A pointer to store the bottom value 7421 */ 7422 EAPI void edje_edit_state_image_border_get(Evas_Object *obj, const char *part, const char *state, double value, int *l, int *r, int *t, int *b); 7423 7424 /** 7425 * @brief Sets the image border of a part state. 7426 * 7427 * Pass -1 to any of [l,r,t,b] to leave the value untouched. 7428 * 7429 * @param obj Object being edited. 7430 * @param part Part that contain state. 7431 * @param state The name of the state to set the image border (not 7432 * including the state value). 7433 * @param value The state value. 7434 * @param l Left border value (or -1). 7435 * @param r Right border value (or -1). 7436 * @param t Top border value (or -1). 7437 * @param b Bottom border value (or -1). 7438 * 7439 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7440 */ 7441 EAPI Eina_Bool edje_edit_state_image_border_set(Evas_Object *obj, const char *part, const char *state, double value, int l, int r, int t, int b); 7442 7443 /** 7444 * @brief Gets the border scale value of a part state. 7445 * 7446 * This value tells Edje if the border should be scaled by 7447 * the object/global edje scale factors 7448 * 7449 * @param obj Object being edited. 7450 * @param part Part that contain state. 7451 * @param state The name of the state to get the image border scale (not 7452 * including the state value). 7453 * @param value The state value. 7454 * 7455 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7456 * 7457 * @since 1.18 7458 */ 7459 EAPI Eina_Bool 7460 edje_edit_state_image_border_scale_get(Evas_Object *obj, const char *part, const char *state, double value); 7461 7462 /** 7463 * @brief Sets the border scale value of a part state. 7464 * 7465 * This value tells Edje if the border should be scaled by 7466 * the object/global edje scale factors 7467 * 7468 * @param obj Object being edited. 7469 * @param part Part that contain state. 7470 * @param state The name of the state to set the image border scale (not 7471 * including the state value). 7472 * @param value The state value. 7473 * @param scale New image border scale value. 7474 * 7475 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7476 * 7477 * @since 1.18 7478 */ 7479 EAPI Eina_Bool 7480 edje_edit_state_image_border_scale_set(Evas_Object *obj, const char *part, const char *state, double value, Eina_Bool scale); 7481 7482 /** 7483 * @brief Gets the border scale by value of a part state. 7484 * 7485 * Valid values are: 0.0 or bigger (0.0 or 1.0 to turn it off) 7486 * 7487 * @param obj Object being edited. 7488 * @param part Part that contain state. 7489 * @param state The name of the state to get the image border scale by (not 7490 * including the state value). 7491 * @param value The state value. 7492 * 7493 * @return border scaling value. 7494 * 7495 * @since 1.18 7496 */ 7497 EAPI double 7498 edje_edit_state_image_border_scale_by_get(Evas_Object *obj, const char *part, const char *state, double value); 7499 7500 /** 7501 * @brief Sets the border scale by value of a part state. 7502 * 7503 * Valid values are: 0.0 or bigger (0.0 or 1.0 to turn it off) 7504 * 7505 * @param obj Object being edited. 7506 * @param part Part that contain state. 7507 * @param state The name of the state to set the image border scale by (not 7508 * including the state value). 7509 * @param value The state value. 7510 * @param scale New image border scale value. 7511 * 7512 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7513 * 7514 * @since 1.18 7515 */ 7516 EAPI Eina_Bool 7517 edje_edit_state_image_border_scale_by_set(Evas_Object *obj, const char *part, const char *state, double value, double scale); 7518 7519 /** 7520 * @brief Gets if the image center should be draw. 7521 * 7522 * 1 or 2 means to draw the center, 0 to don't draw it. 7523 * If 1 - then the center will apply alpha channel. 7524 * If 2 (SOLID mode) - then the center of an image wont have alpha channel (Just black color). 7525 * 7526 * @param obj Object being edited. 7527 * @param part Part that contain state. 7528 * @param state The name of the state to get the image border fill (not including the state value). 7529 * @param value The state value. 7530 * 7531 * @return @c 2 if the center of the bordered image is draw without alpha, @c 1 drawing with alpha and @c 0 not drawing the center. 7532 */ 7533 EAPI unsigned char edje_edit_state_image_border_fill_get(Evas_Object *obj, const char *part, const char *state, double value); 7534 7535 /** 7536 * @brief Sets if the image center should be draw. 7537 * 7538 * 1 or 2 means to draw the center, 0 to don't draw it. 7539 * If 1 - then the center will apply alpha channel. 7540 * If 2 (SOLID mode) - then the center of an image wont have alpha channel (Just black color). 7541 * 7542 * @param obj Object being edited. 7543 * @param part Part that contain state. 7544 * @param state The name of the state to set the image border fill (not including the state value). 7545 * @param value The state value. 7546 * @param fill Fill to be set. 1 or 2 if the center of the bordered image is draw, 0 otherwise. 7547 * 7548 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7549 */ 7550 EAPI Eina_Bool edje_edit_state_image_border_fill_set(Evas_Object *obj, const char *part, const char *state, double value, unsigned char fill); 7551 7552 /** 7553 * @brief Gets the list of all the tweens images in the given part state. 7554 * 7555 * Use edje_edit_string_list_free() when you don't need it anymore. 7556 * 7557 * @param obj Object being edited. 7558 * @param part Part that contain state. 7559 * @param state The name of the state to get the list of all the tweens images (not including the state value). 7560 * @param value The state value. 7561 * 7562 * @return A string list containing all the image name that form a tween animation in the given part state. 7563 */ 7564 EAPI Eina_List * edje_edit_state_tweens_list_get(Evas_Object *obj, const char *part, const char *state, double value); 7565 7566 /** 7567 * @brief Adds a new tween frame to the given part state. 7568 * 7569 * The tween param must be the name of an existing image. 7570 * 7571 * @param obj Object being edited. 7572 * @param part Part that contain state. 7573 * @param state The name of the state to add a new tween frame (not including the state value). 7574 * @param value The state value. 7575 * @param tween The name of the image to add. 7576 * 7577 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7578 */ 7579 EAPI Eina_Bool edje_edit_state_tween_add(Evas_Object *obj, const char *part, const char *state, double value, const char *tween); 7580 7581 /** 7582 * @brief Inserts a new tween frame to the given part state into a specific place. 7583 * 7584 * The tween param must be the name of an existing image. 7585 * 7586 * @param obj Object being edited. 7587 * @param part Part that contain state. 7588 * @param state The name of the state to add a new tween frame (not including the state value). 7589 * @param value The state value. 7590 * @param tween The name of the image to add. 7591 * @param place Place to be added. It can't be less than 0 or more than current size of tweens. 7592 * 7593 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7594 */ 7595 EAPI Eina_Bool 7596 edje_edit_state_tween_insert_at(Evas_Object *obj, const char *part, const char *state, double value, const char *tween, int place); 7597 7598 /** 7599 * @brief Removes the first tween with the given name. 7600 * 7601 * The image is not removed from the edje. 7602 * 7603 * @param obj Object being edited. 7604 * @param part Part that contain state. 7605 * @param state The name of the state to delete the tween (not including the state value). 7606 * @param value The state value. 7607 * @param tween The name of the image to delete. 7608 * 7609 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7610 */ 7611 EAPI Eina_Bool edje_edit_state_tween_del(Evas_Object *obj, const char *part, const char *state, double value, const char *tween); 7612 7613 //@} 7614 /******************************************************************************/ 7615 /************************** VECTORS API ************************************/ 7616 /******************************************************************************/ 7617 7618 /** 7619 * @brief Gets vector id for a given vector name. 7620 * 7621 * @param obj Object being edited. 7622 * @param vector_name The vector name. 7623 * 7624 * @return The id of the given vector name. 7625 * @since 1.19 7626 */ 7627 EAPI int edje_edit_vector_id_get(Evas_Object *obj, const char *vector_name); 7628 7629 /** 7630 * @name Vectors API 7631 * Functions to deal with vector objects of images (see @ref edcref). 7632 */ //@{ 7633 7634 /** 7635 * @brief Gets the list of all the vectors in the given edje. 7636 * Use edje_edit_string_list_free() when you don't need the list anymore. 7637 * 7638 * @param obj Object being edited. 7639 * 7640 * @return A List containing all vector names found in the edje file. 7641 * @since 1.19 7642 */ 7643 EAPI Eina_List * edje_edit_vectors_list_get(Evas_Object *obj); 7644 7645 /** 7646 * @brief Deletes vector from the vector collection 7647 * 7648 * It actually write directly to the file so you don't have to save. 7649 * Can't delete vector if it is used by any part. 7650 * 7651 * @param obj Object being edited. 7652 * @param name The name of the vector file. 7653 * 7654 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise (including the 7655 * case when the name is not valid or vector is in use). 7656 * @since 1.19 7657 */ 7658 EAPI Eina_Bool edje_edit_vector_del(Evas_Object *obj, const char *name); 7659 7660 /** 7661 * @brief Gets list of (Edje_Part_Image_Use *) - group-part-state triplets where given 7662 * vector is used. 7663 * 7664 * Use edje_edit_image_usage_list_free() when you don't need it anymore. 7665 * 7666 * @param obj Object being edited. 7667 * @param name The name of the vector. 7668 * @param first_only If EINA_TRUE, return only one triplet. 7669 * 7670 * @return Eina_List containing Edje_Part_Image_Use if successful, NULL otherwise 7671 * @since 1.19 7672 */ 7673 EAPI Eina_List* edje_edit_vector_usage_list_get(Evas_Object *obj, const char *name, Eina_Bool first_only); 7674 7675 //@} 7676 /******************************************************************************/ 7677 /************************** SOUNDS API ************************************/ 7678 /******************************************************************************/ 7679 /** 7680 * @name Sounds API 7681 * Functions to deal with sound objects (see @ref edcref). 7682 */ //@{ 7683 7684 /** 7685 * @brief Gets the list of all the sounds samples in the given edje. 7686 * Use edje_edit_string_list_free() when you don't need the list anymore. 7687 * 7688 * @param obj Object being edited. 7689 * 7690 * @return A List containing all sounds samples names found in the edje file. 7691 * @since 1.11 7692 */ 7693 EAPI Eina_List * edje_edit_sound_samples_list_get(Evas_Object *obj); 7694 7695 /** 7696 * @brief Gets the list of all the sounds tones in the given edje. 7697 * Use edje_edit_string_list_free() when you don't need the list anymore. 7698 * 7699 * @param obj Object being edited. 7700 * 7701 * @return A List containing all sounds tones names found in the edje file. 7702 * @since 1.11 7703 */ 7704 EAPI Eina_List * edje_edit_sound_tones_list_get(Evas_Object *obj); 7705 7706 /** 7707 * @brief Adds new sound sample to samples collection. 7708 * 7709 * This function adds the given sound file to the edje collection. 7710 * The added sound sample could be used by PLAY_SAMPLE action in any program 7711 * of any group that is in the current collection. 7712 * The quality of added sound by default is uncompressed (RAW). 7713 * 7714 * The available formats list of the sound files that can be loaded depends 7715 * on the evas engine on your system. 7716 * 7717 * @param obj Object being edited. 7718 * @param name The name that will identify sample. 7719 * @param snd_src The name of the sound file to add. 7720 * 7721 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7722 * @see edje_edit_sound_sample_del() 7723 * @since 1.11 7724 */ 7725 EAPI Eina_Bool edje_edit_sound_sample_add(Evas_Object *obj, const char* name, const char* snd_src); 7726 7727 /** 7728 * @brief Deletes sound sample from the collection. 7729 * 7730 * Deletes sound sample from collection by its name. After successful deletion 7731 * all PLAY_SAMPLE actions in all programs of all groups of current collection 7732 * that use deleted sound will be deleted. 7733 * 7734 * @param obj Object being edited. 7735 * @param name The name of the sound to be deleted from the edje. 7736 * 7737 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7738 * @see edje_edit_sound_sample_add() 7739 * @since 1.11 7740 */ 7741 EAPI Eina_Bool edje_edit_sound_sample_del(Evas_Object *obj, const char *name); 7742 7743 /** 7744 * @brief Adds new tone to the collection. 7745 * 7746 * This function adds new tone with given frequency to the edje collection. 7747 * The added sound sample could be used by PLAY_TONE action in any program 7748 * of any group that is in the current collection. 7749 * 7750 * @param obj Object being edited. 7751 * @param name The name that will identify tone. 7752 * @param frequency Frequency of added tone. This value should be in range of 20 to 20000 inclusive. 7753 * 7754 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 7755 * @see edje_edit_sound_tone_del() 7756 * @since 1.11 7757 */ 7758 EAPI Eina_Bool edje_edit_sound_tone_add(Evas_Object *obj, const char* name, int frequency); 7759 7760 /** 7761 * @brief Deletes tone from the collection. 7762 * 7763 * Deletes tone from collection by its name. After successful deletion 7764 * all PLAY_TONE actions in all programs of all groups of current collection 7765 * that use deleted sound will be deleted. 7766 * 7767 * @param obj Object being edited. 7768 * @param name The name of the tone to be deleted from the edje. 7769 * 7770 * @return @c EINA_TRUE if successful, @c EINA_FALSE otherwise. 7771 * @see edje_edit_sound_tone_add() 7772 * @since 1.11 7773 */ 7774 EAPI Eina_Bool edje_edit_sound_tone_del(Evas_Object *obj, const char* name); 7775 7776 /** 7777 * @brief Gets the sound quality compression. 7778 * 7779 * @param obj Object being edited. 7780 * @param sound The name of the sample. 7781 * 7782 * @return Quality of the compression of the sample sound. 7783 * @since 1.11 7784 */ 7785 EAPI double edje_edit_sound_compression_rate_get(Evas_Object *obj, const char* sound); 7786 7787 /** 7788 * @brief Sets the sound quality compression. 7789 * 7790 * @param obj Object being edited. 7791 * @param sound The name of the sample. 7792 * @param rate Quality of the compression. 7793 * 7794 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7795 * @since 1.11 7796 */ 7797 EAPI Eina_Bool edje_edit_sound_compression_rate_set(Evas_Object *obj, const char* sound, double rate); 7798 7799 /** 7800 * @brief Sets the frequency of tone. 7801 * 7802 * @param obj Object being edited. 7803 * @param name The name of the tone. 7804 * @param frequency The value of frequency of tone. This value has to be in range of 20 to 20000 inclusive. 7805 * 7806 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7807 * @see edje_edit_sound_tone_frequency_get() 7808 * @since 1.11 7809 */ 7810 EAPI Eina_Bool edje_edit_sound_tone_frequency_set(Evas_Object *obj, const char *name, int frequency); 7811 7812 /** 7813 * @brief Gets the frequency of tone. 7814 * 7815 * @param obj Object being edited. 7816 * @param name The name of the tone. 7817 * 7818 * @return The frequency of tone if successful, otherwise returns -1. 7819 * @see edje_edit_sound_tone_frequency_set() 7820 * @since 1.11 7821 */ 7822 EAPI int edje_edit_sound_tone_frequency_get(Evas_Object *obj, const char *name); 7823 7824 /** 7825 * @brief Gets the sound type compression. 7826 * 7827 * @param obj Object being edited. 7828 * @param name The name of the sample. 7829 * 7830 * @return Compression type of the sample sound. 7831 * @since 1.11 7832 */ 7833 EAPI Edje_Edit_Sound_Comp edje_edit_sound_compression_type_get(Evas_Object *obj, const char* name); 7834 7835 /** 7836 * @brief Sets the sound type compression. 7837 * 7838 * @param obj Object being edited. 7839 * @param name The name of the sample. 7840 * @param sc Edje_Edit_Sound_Comp 7841 * (@c EDJE_EDIT_SOUND_COMP_RAW, @c EDJE_EDIT_SOUND_COMP_COMP, @c EDJE_EDIT_SOUND_COMP_LOSSY, @c EDJE_EDIT_SOUND_COMP_AS_IS). 7842 * 7843 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7844 * @since 1.11 7845 */ 7846 EAPI Eina_Bool edje_edit_sound_compression_type_set(Evas_Object *obj, const char* name, Edje_Edit_Sound_Comp sc); 7847 7848 /** 7849 * @brief Gets the certain sound data from the edje object. 7850 * 7851 * @param obj Object being edited. 7852 * @param sample_name The name of the sound. 7853 * 7854 * @return buf The buffer that contains data of the sound. To free the resources use eina_binbuf_free(). 7855 * @since 1.11 7856 */ 7857 EAPI Eina_Binbuf *edje_edit_sound_samplebuffer_get(Evas_Object *obj, const char *sample_name); 7858 7859 /** 7860 * @brief Gets the name of sample source. 7861 * 7862 * @param obj Object being edited. 7863 * @param sample_name The name of the sample. 7864 * 7865 * @return snd_src The sample source name. 7866 * @since 1.11 7867 */ 7868 EAPI const char *edje_edit_sound_samplesource_get(Evas_Object *obj, const char *sample_name); 7869 7870 //@} 7871 /******************************************************************************/ 7872 /************************* SPECTRUM API ***********************************/ 7873 /******************************************************************************/ 7874 /** 7875 * @name Spectrum API 7876 * Functions to manage spectrum (see @ref edcref). 7877 */ //@{ 7878 7879 /** 7880 * @brief Gets the list of all the spectrum in the given edje object. 7881 * 7882 * Use edje_edit_string_list_free() when you don't need it anymore. 7883 * 7884 * @param obj Object being edited. 7885 * 7886 * @return A list containing all the spectra names. 7887 */ 7888 EAPI Eina_List * edje_edit_spectrum_list_get(Evas_Object *obj); 7889 7890 /** 7891 * @brief Adds a new spectra in the given edje object. 7892 * 7893 * @param obj Object being edited. 7894 * @param name The name of the spectra to include in the edje. 7895 * 7896 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7897 */ 7898 EAPI Eina_Bool edje_edit_spectra_add(Evas_Object *obj, const char *name); 7899 7900 /** 7901 * @brief Deletes the given spectra from the edje object. 7902 * 7903 * @param obj Object being edited. 7904 * @param spectra The name of the spectra to delete. 7905 * 7906 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7907 */ 7908 EAPI Eina_Bool edje_edit_spectra_del(Evas_Object *obj, const char *spectra); 7909 7910 /** 7911 * @brief Changes the name of the given spectra. 7912 * 7913 * @param obj Object being edited. 7914 * @param spectra The name of the current spectra. 7915 * @param name The new name to assign. 7916 * 7917 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7918 */ 7919 EAPI Eina_Bool edje_edit_spectra_name_set(Evas_Object *obj, const char *spectra, const char *name); 7920 7921 /** 7922 * @brief Gets the number of stops in the given spectra. 7923 * 7924 * @param obj Object being edited. 7925 * @param spectra The name of the spectra. 7926 * 7927 * @return The number of stops (or 0 on errors). 7928 */ 7929 EAPI int edje_edit_spectra_stop_num_get(Evas_Object *obj, const char *spectra); 7930 7931 /** 7932 * @brief Sets the number of stops in the given spectra. 7933 * 7934 * @param obj Object being edited. 7935 * @param spectra The name of the spectra. 7936 * @param num The number of stops you want 7937 * 7938 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7939 */ 7940 EAPI Eina_Bool edje_edit_spectra_stop_num_set(Evas_Object *obj, const char *spectra, int num); 7941 7942 /** 7943 * @brief Gets the colors of the given stop. 7944 * 7945 * @param obj Object being edited. 7946 * @param spectra The name of the spectra. 7947 * @param stop_number The number of the stop, 7948 * @param r Where to store the red color value, 7949 * @param g Where to store the green color value, 7950 * @param b Where to store the blue color value, 7951 * @param a Where to store the alpha color value, 7952 * @param d Where to store the delta stop value, 7953 * 7954 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7955 */ 7956 EAPI Eina_Bool edje_edit_spectra_stop_color_get(Evas_Object *obj, const char *spectra, int stop_number, int *r, int *g, int *b, int *a, int *d); 7957 7958 /** 7959 * @brief Sets the colors of the given stop. 7960 * 7961 * @param obj Object being edited. 7962 * @param spectra The name of the spectra. 7963 * @param stop_number The number of the stops, 7964 * @param r The red color value to set, 7965 * @param g The green color value to set, 7966 * @param b The blue color value to set, 7967 * @param a The alpha color value to set, 7968 * @param d The delta stop value to set, 7969 * 7970 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 7971 */ 7972 EAPI Eina_Bool edje_edit_spectra_stop_color_set(Evas_Object *obj, const char *spectra, int stop_number, int r, int g, int b, int a, int d); 7973 7974 //@} 7975 /******************************************************************************/ 7976 /************************* PROGRAMS API ***********************************/ 7977 /******************************************************************************/ 7978 /** 7979 * @name Programs API 7980 * Functions to deal with programs (see @ref edcref). 7981 */ //@{ 7982 7983 /** 7984 * @brief Gets the list of all the programs in the given edje object. 7985 * 7986 * Use edje_edit_string_list_free() when you don't need it anymore. 7987 * 7988 * @param obj Object being edited. 7989 * 7990 * @return A list containing all the program names. 7991 */ 7992 EAPI Eina_List * edje_edit_programs_list_get(Evas_Object *obj); 7993 7994 /** 7995 * @brief Adds a new program to the edje file 7996 * 7997 * If a program with the same name just exist the function will fail. 7998 * 7999 * @param obj Object being edited. 8000 * @param name The name of the new program. 8001 * 8002 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8003 */ 8004 EAPI Eina_Bool edje_edit_program_add(Evas_Object *obj, const char *name); 8005 8006 /** 8007 * @brief Removes the given program from the edje file. 8008 * 8009 * @param obj Object being edited. 8010 * @param prog The name of the program to remove. 8011 * 8012 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8013 */ 8014 EAPI Eina_Bool edje_edit_program_del(Evas_Object *obj, const char *prog); 8015 8016 /** 8017 * @brief Checks if a program with the given name exist in the edje object. 8018 * 8019 * @param obj Object being edited. 8020 * @param prog The prog of the program that will be searched. 8021 * 8022 * @return @c EINA_TRUE if the program exist, @c EINA_FALSE otherwise. 8023 */ 8024 EAPI Eina_Bool edje_edit_program_exist(Evas_Object *obj, const char *prog); 8025 8026 /** 8027 * @brief Runs the given program. 8028 * 8029 * @param obj Object being edited. 8030 * @param prog The name of the program to execute. 8031 * 8032 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8033 */ 8034 EAPI Eina_Bool edje_edit_program_run(Evas_Object *obj, const char *prog); 8035 8036 /** 8037 * @brief Stops all running programs. 8038 * 8039 * @param obj Object being edited. 8040 * 8041 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8042 */ 8043 EAPI Eina_Bool edje_edit_program_stop_all(Evas_Object *obj); 8044 8045 /** 8046 * @brief Sets parts into intermediate state of programs transition. 8047 * 8048 * @param obj Object being edited. 8049 * @param prog The name of the program to use. Program should have action STATE_SET. 8050 * @param pos State of transition to be setted. Value from 0.0 to 1.0. 8051 * 0.0 represents the start state, 1.0 - the final state. Other values will set 8052 * parts to an intermediate state taking into account programs transition type. 8053 * 8054 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8055 */ 8056 EAPI Eina_Bool edje_edit_program_transition_state_set(Evas_Object *obj, const char *prog, double pos); 8057 8058 /** 8059 * @brief Sets a new name for the given program. 8060 * 8061 * @param obj Object being edited. 8062 * @param prog The current program name. 8063 * @param new_name The new name to assign. 8064 * 8065 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8066 */ 8067 EAPI Eina_Bool edje_edit_program_name_set(Evas_Object *obj, const char *prog, const char *new_name); 8068 8069 /** 8070 * @brief Gets source of a given program. 8071 * 8072 * Remember to free the returned string using edje_edit_string_free(). 8073 * 8074 * @param obj Object being edited. 8075 * @param prog The name of the program to get source. 8076 * 8077 * @return The source value per program. 8078 */ 8079 EAPI const char * edje_edit_program_source_get(Evas_Object *obj, const char *prog); 8080 8081 /** 8082 * @brief Sets source of the given program. 8083 * 8084 * @param obj Object being edited. 8085 * @param prog The name of the program to set source. 8086 * @param source The new source value. 8087 * 8088 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8089 */ 8090 EAPI Eina_Bool edje_edit_program_source_set(Evas_Object *obj, const char *prog, const char *source); 8091 8092 /** 8093 * @brief Gets signal of a given program. 8094 * 8095 * Remember to free the returned string using edje_edit_string_free(). 8096 * 8097 * @param obj Object being edited. 8098 * @param prog The name of the program to get the signal. 8099 * 8100 * @return The signal value for program. 8101 */ 8102 EAPI const char * edje_edit_program_signal_get(Evas_Object *obj, const char *prog); 8103 8104 /** 8105 * @brief Sets signal of the given program. 8106 * 8107 * @param obj Object being edited. 8108 * @param prog The name of the program to set the signal. 8109 * @param signal The new signal value. 8110 * 8111 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8112 */ 8113 EAPI Eina_Bool edje_edit_program_signal_set(Evas_Object *obj, const char *prog, const char *signal); 8114 8115 /** 8116 * @brief Gets in.from of a given program. 8117 * 8118 * @param obj Object being edited. 8119 * @param prog The name of the program to get the delay. 8120 * 8121 * @return The delay. 8122 */ 8123 EAPI double edje_edit_program_in_from_get(Evas_Object *obj, const char *prog); 8124 8125 /** 8126 * @brief Sets in.from of a given program. 8127 * 8128 * @param obj Object being edited. 8129 * @param prog The name of the program to set the delay. 8130 * @param seconds Number of seconds to delay the program execution 8131 * 8132 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8133 */ 8134 EAPI Eina_Bool edje_edit_program_in_from_set(Evas_Object *obj, const char *prog, double seconds); 8135 8136 /** 8137 * @brief Gets in.range of a given program. 8138 * 8139 * @param obj Object being edited. 8140 * @param prog The name of the program to get random delay. 8141 * 8142 * @return The delay random. 8143 */ 8144 EAPI double edje_edit_program_in_range_get(Evas_Object *obj, const char *prog); 8145 8146 /** 8147 * @brief Sets in.range of a given program. 8148 * 8149 * @param obj Object being edited. 8150 * @param prog The name of the program to set random delay. 8151 * @param seconds Max random number of seconds to delay. 8152 * 8153 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8154 */ 8155 EAPI Eina_Bool edje_edit_program_in_range_set(Evas_Object *obj, const char *prog, double seconds); 8156 8157 /** 8158 * @brief Gets the action of a given program. 8159 * 8160 * @param obj Object being edited. 8161 * @param prog The name of the program to get the action. 8162 * 8163 * @return The action type, or @c -1 on errors. 8164 * Action can be one of EDJE_ACTION_TYPE_NONE, _STATE_SET, ACTION_STOP, SIGNAL_EMIT, DRAG_VAL_SET, _DRAG_VAL_STEP, _DRAG_VAL_PAGE, _SCRIPT 8165 */ 8166 EAPI Edje_Action_Type edje_edit_program_action_get(Evas_Object *obj, const char *prog); 8167 8168 /** 8169 * @brief Sets the action of a given program. 8170 * 8171 * Action can be one of EDJE_ACTION_TYPE_NONE, _STATE_SET, ACTION_STOP, SIGNAL_EMIT, DRAG_VAL_SET, _DRAG_VAL_STEP, _DRAG_VAL_PAGE, _SCRIPT 8172 * 8173 * @param obj Object being edited. 8174 * @param prog The name of the program to set the action. 8175 * @param action The new action type. 8176 * 8177 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8178 */ 8179 EAPI Eina_Bool edje_edit_program_action_set(Evas_Object *obj, const char *prog, Edje_Action_Type action); 8180 8181 /** 8182 * @brief Gets the list of the targets for the given program. 8183 * 8184 * Use edje_edit_string_list_free() when you don't need it anymore. 8185 * 8186 * @param obj Object being edited. 8187 * @param prog The name of the program to get the list of the targets. 8188 * 8189 * @return A list with all the targets names, or NULL on error. 8190 */ 8191 EAPI Eina_List * edje_edit_program_targets_get(Evas_Object *obj, const char *prog); 8192 8193 /** 8194 * @brief Adds a new target program to the list of 'targets' in the given program. 8195 * 8196 * If program action is @c EDJE_ACTION_TYPE_ACTION_STOP, then 'target' 8197 * must be an existing program name. If it's @c 8198 * EDJE_ACTION_TYPE_STATE_SET, then 'target' must be an existing part 8199 * name. 8200 * 8201 * @param obj Object being edited. 8202 * @param prog The name of the program to add a new target. 8203 * @param target The name of the new target itself. 8204 * 8205 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8206 */ 8207 EAPI Eina_Bool edje_edit_program_target_add(Evas_Object *obj, const char *prog, const char *target); 8208 8209 /** 8210 * @brief Adds a new target program to certain place in list of 'targets' in the given program. 8211 * 8212 * If program action is @c EDJE_ACTION_TYPE_ACTION_STOP, then 'target' 8213 * must be an existing program name. If it's @c 8214 * EDJE_ACTION_TYPE_STATE_SET, then 'target' must be an existing part 8215 * name. 8216 * 8217 * @param obj Object being edited. 8218 * @param prog The name of the program to add a new target. 8219 * @param target The name of the new target itself. 8220 * @param place Specific play for target to be inserted into. 8221 * 8222 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8223 * 8224 * @since 1.18 8225 */ 8226 EAPI Eina_Bool 8227 edje_edit_program_target_insert_at(Evas_Object *obj, const char *prog, const char *target, int place); 8228 8229 /** 8230 * @brief Deletes a target from the list of 'targets' in the given program. 8231 * 8232 * If program action is EDJE_ACTION_TYPE_ACTION_STOP then 'target' must be an existing program name. 8233 * If action is EDJE_ACTION_TYPE_STATE_SET then 'target' must be an existing part name. 8234 * 8235 * @param obj Object being edited. 8236 * @param prog The name of the program to del a target from the list of targets. 8237 * @param target The name of another program or another part. 8238 * 8239 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8240 */ 8241 EAPI Eina_Bool edje_edit_program_target_del(Evas_Object *obj, const char *prog, const char *target); 8242 8243 /** 8244 * @brief Clears the 'targets' list of the given program 8245 * 8246 * @param obj Object being edited. 8247 * @param prog The name of the program to clear the 'targets' list. 8248 * 8249 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8250 */ 8251 EAPI Eina_Bool edje_edit_program_targets_clear(Evas_Object *obj, const char *prog); 8252 8253 /** 8254 * @brief Gets the list of action that will be run after the give program. 8255 * 8256 * Use edje_edit_string_list_free() when you don't need it anymore. 8257 * 8258 * @param obj Object being edited. 8259 * @param prog The name of the program to get the list of actions 8260 * 8261 * @return A list with all program names, or NULL on error. 8262 */ 8263 EAPI Eina_List * edje_edit_program_afters_get(Evas_Object *obj, const char *prog); 8264 8265 /** 8266 * @brief Adds a new program name to the list of 'afters' in the given program. 8267 * 8268 * All the programs listed in 'afters' will be executed after program execution. 8269 * 8270 * @param obj Object being edited. 8271 * @param prog The name of the program that contains the list of afters 8272 * @param after The name of another program to add to the afters list 8273 * 8274 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8275 */ 8276 EAPI Eina_Bool edje_edit_program_after_add(Evas_Object *obj, const char *prog, const char *after); 8277 8278 /** 8279 * @brief Adds a new program name into specific place in list of 'afters' in the given program. 8280 * 8281 * All the programs listed in 'afters' will be executed after program execution. 8282 * 8283 * @param obj Object being edited. 8284 * @param prog The name of the program that contains the list of afters 8285 * @param after The name of another program to add to the afters list 8286 * @param place Specific place for after to be inserted into. Note that if place is greater than total number of afters then it would append to the end of list 8287 * 8288 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8289 * 8290 * @since 1.18 8291 */ 8292 EAPI Eina_Bool 8293 edje_edit_program_after_insert_at(Evas_Object *obj, const char *prog, const char *after, int place); 8294 8295 /** 8296 * @brief Deletes the given program from the list of 'afters' of the program. 8297 * 8298 * @param obj Object being edited. 8299 * @param prog The name of the program from where to remove the after. 8300 * @param after The name of the program to remove from the list of afters. 8301 * 8302 * @return @c EINA_TRUE is successful or not in the list, @c EINA_FALSE otherwise. 8303 */ 8304 EAPI Eina_Bool edje_edit_program_after_del(Evas_Object *obj, const char *prog, const char *after); 8305 8306 /** 8307 * @brief Clears the 'afters' list of the given program. 8308 * 8309 * @param obj Object being edited. 8310 * @param prog The name of the program to clear the 'afters' list. 8311 * 8312 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8313 */ 8314 EAPI Eina_Bool edje_edit_program_afters_clear(Evas_Object *obj, const char *prog); 8315 8316 /** 8317 * @brief Get the state for the given program. 8318 * 8319 * In a STATE_SET action this is the name of state to set. 8320 * In a SIGNAL_EMIT action is the name of the signal to emit. 8321 * 8322 * @param obj Object being edited. 8323 * @param prog The name of the program to get the state. 8324 * 8325 * @return The name of the state. 8326 */ 8327 EAPI const char * edje_edit_program_state_get(Evas_Object *obj, const char *prog); 8328 8329 /** 8330 * @brief Gets api's name of a program. 8331 * 8332 * @param obj Object being edited. 8333 * @param prog Name of program. 8334 * 8335 * @return Name of the api if successful, NULL otherwise. 8336 */ 8337 EAPI const char * edje_edit_program_api_name_get(Evas_Object *obj, const char *prog); 8338 8339 /** 8340 * @brief Gets api's description of a program. 8341 * 8342 * @param obj Object being edited. 8343 * @param prog Name of program. 8344 * 8345 * @return Description of the api if successful, NULL otherwise. 8346 */ 8347 EAPI const char * edje_edit_program_api_description_get(Evas_Object *obj, const char *prog); 8348 8349 /** 8350 * @brief Sets api's name of a program. 8351 * 8352 * @param obj Object being edited. 8353 * @param prog Name of the part. 8354 * @param name New name for the api property. 8355 * 8356 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8357 */ 8358 EAPI Eina_Bool edje_edit_program_api_name_set(Evas_Object *obj, const char *prog, const char *name); 8359 8360 /** 8361 * @brief Sets api's description of a program. 8362 * 8363 * @param obj Object being edited. 8364 * @param prog Name of the program. 8365 * @param description New description for the api property. 8366 * 8367 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8368 */ 8369 EAPI Eina_Bool edje_edit_program_api_description_set(Evas_Object *obj, const char *prog, const char *description); 8370 8371 /** 8372 * @brief Sets the state for the given program. 8373 * 8374 * In a STATE_SET action this is the name of state to set. 8375 * In a SIGNAL_EMIT action is the name of the signal to emit. 8376 * 8377 * @param obj Object being edited. 8378 * @param prog The name of the program to set a state. 8379 * @param state The name of the state to set (not including the state value) 8380 * 8381 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8382 */ 8383 EAPI Eina_Bool edje_edit_program_state_set(Evas_Object *obj, const char *prog, const char *state); 8384 8385 /** 8386 * @brief Gets the value of state for the given program. 8387 * 8388 * In a STATE_SET action this is the value of state to set. 8389 * Not used on SIGNAL_EMIT action. 8390 * 8391 * @param obj Object being edited. 8392 * @param prog The name of the program to get the value of state. 8393 * 8394 * @return The value of state for the program. 8395 */ 8396 EAPI double edje_edit_program_value_get(Evas_Object *obj, const char *prog); 8397 8398 /** 8399 * @brief Sets the value of state for the given program. 8400 * 8401 * In a STATE_SET action this is the value of state to set. 8402 * Not used on SIGNAL_EMIT action. 8403 * 8404 * @param obj Object being edited. 8405 * @param prog The name of the program to set the value of state. 8406 * @param value The vale to set. 8407 * 8408 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8409 */ 8410 EAPI Eina_Bool edje_edit_program_value_set(Evas_Object *obj, const char *prog, double value); 8411 8412 /** 8413 * @brief Gets the state2 for the given program 8414 * 8415 * In a STATE_SET action is not used 8416 * In a SIGNAL_EMIT action is the source of the emitted signal. 8417 * 8418 * @param obj Object being edited. 8419 * @param prog The name of the program to get the state2. 8420 * 8421 * @return The source to emit for the program. 8422 */ 8423 EAPI const char * edje_edit_program_state2_get(Evas_Object *obj, const char *prog); 8424 8425 /** 8426 * @brief Sets the state2 for the given program 8427 * 8428 * In a STATE_SET action is not used 8429 * In a SIGNAL_EMIT action is the source of the emitted signal. 8430 * 8431 * @param obj Object being edited. 8432 * @param prog The name of the program to set the state2. 8433 * @param state2 The name of the state to set. 8434 * 8435 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8436 */ 8437 EAPI Eina_Bool edje_edit_program_state2_set(Evas_Object *obj, const char *prog, const char *state2); 8438 8439 /** 8440 * @brief Gets the value of state2 for the given program. 8441 * 8442 * @param obj Object being edited. 8443 * @param prog The name of the program to get the state2 value. 8444 * 8445 * @return The vale of the state2 for the program. 8446 */ 8447 EAPI double edje_edit_program_value2_get(Evas_Object *obj, const char *prog); 8448 8449 /** 8450 * @brief Sets the value2 of state for the given program. 8451 * 8452 * This is used in DRAG_ACTION 8453 * 8454 * @param obj Object being edited. 8455 * @param prog The name of the program to set the state2 value. 8456 * @param value The value of the state2 to set. 8457 * 8458 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8459 */ 8460 EAPI Eina_Bool edje_edit_program_value2_set(Evas_Object *obj, const char *prog, double value); 8461 8462 /** 8463 * @brief Gets the type of transition to use when apply animations. 8464 * 8465 * Can be one of: EDJE_TWEEN_MODE_NONE, EDJE_TWEEN_MODE_LINEAR, EDJE_TWEEN_MODE_SINUSOIDAL, EDJE_TWEEN_MODE_ACCELERATE or EDJE_TWEEN_MODE_DECELERATE. 8466 * 8467 * @param obj Object being edited. 8468 * @param prog The name of the program to get the transition. 8469 * 8470 * @return The type of transition used by program. 8471 */ 8472 EAPI Edje_Tween_Mode edje_edit_program_transition_get(Evas_Object *obj, const char *prog); 8473 8474 /** 8475 * @brief Sets the type of transition to use when apply animations. 8476 * 8477 * Can be one of: EDJE_TWEEN_MODE_NONE, EDJE_TWEEN_MODE_LINEAR, EDJE_TWEEN_MODE_SINUSOIDAL, EDJE_TWEEN_MODE_ACCELERATE or EDJE_TWEEN_MODE_DECELERATE. 8478 * 8479 * @param obj Object being edited. 8480 * @param prog The name of the program to set the transition. 8481 * @param transition The transition type to set 8482 * 8483 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8484 */ 8485 EAPI Eina_Bool edje_edit_program_transition_set(Evas_Object *obj, const char *prog, Edje_Tween_Mode transition); 8486 8487 /** 8488 * @brief Gets the interpolation value 1 of the transition. 8489 * Can be used with one of transition type: EDJE_TWEEN_MODE_ACCELERATE_FACTOR, EDJE_TWEEN_MODE_DECELERATE_FACTOR, EDJE_TWEEN_MODE_SINUSOIDAL_FACTOR, EDJE_TWEEN_MODE_DIVISOR_INTERP, EDJE_TWEEN_MODE_BOUNCE or EDJE_TWEEN_MODE_SPRING. 8490 * 8491 * @param obj Object being edited. 8492 * @param prog The name of the program to get the interpolation value 1. 8493 * 8494 * @return Interpolation value 1. 8495 */ 8496 EAPI double edje_edit_program_transition_value1_get(Evas_Object *obj, const char *prog); 8497 8498 /** 8499 * @brief Sets the interpolation value 1 of the transition. 8500 * Can be used with one of transition type: EDJE_TWEEN_MODE_ACCELERATE_FACTOR, EDJE_TWEEN_MODE_DECELERATE_FACTOR, EDJE_TWEEN_MODE_SINUSOIDAL_FACTOR, EDJE_TWEEN_MODE_DIVISOR_INTERP, EDJE_TWEEN_MODE_BOUNCE or EDJE_TWEEN_MODE_SPRING. 8501 * 8502 * @param obj Object being edited. 8503 * @param prog The name of the program to get the interpolation value 1. 8504 * @param value The interpolation value 1 for the transition. 8505 * 8506 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8507 */ 8508 EAPI Eina_Bool edje_edit_program_transition_value1_set(Evas_Object *obj, const char *prog, double value); 8509 8510 /** 8511 * @brief Gets the interpolation value 2 of the transition. 8512 * Can be used with one of transition type: EDJE_TWEEN_MODE_DIVISOR_INTERP, EDJE_TWEEN_MODE_BOUNCE or EDJE_TWEEN_MODE_SPRING. 8513 * @param obj Object being edited. 8514 * @param prog The name of the program to get the interpolation value 2. 8515 * 8516 * @return Interpolation value 2. 8517 */ 8518 EAPI double edje_edit_program_transition_value2_get(Evas_Object *obj, const char *prog); 8519 8520 /** 8521 * @brief Sets the interpolation value 2 of the transition. 8522 * Can be used with one of transition type: EDJE_TWEEN_MODE_DIVISOR_INTERP, EDJE_TWEEN_MODE_BOUNCE or EDJE_TWEEN_MODE_SPRING. 8523 * 8524 * @param obj Object being edited. 8525 * @param prog The name of the program to get the interpolation value 2. 8526 * @param value The interpolation value 2 for the transition. 8527 * 8528 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8529 */ 8530 EAPI Eina_Bool edje_edit_program_transition_value2_set(Evas_Object *obj, const char *prog, double value); 8531 8532 /** 8533 * @brief Gets the interpolation value 3 of the transition. 8534 * Can be used with one of transition type: EDJE_TWEEN_MODE_CUBIC_BEZIER. 8535 * 8536 * @param obj Object being edited. 8537 * @param prog The name of the program to get the interpolation value 3. 8538 * 8539 * @return Interpolation value 3. 8540 */ 8541 EAPI double edje_edit_program_transition_value3_get(Evas_Object *obj, const char *prog); 8542 8543 /** 8544 * @brief Sets the interpolation value 3 of the transition. 8545 * Can be used with one of transition type: EDJE_TWEEN_MODE_CUBIC_BEZIER. 8546 * 8547 * @param obj Object being edited. 8548 * @param prog The name of the program to get the interpolation value 3. 8549 * @param value The interpolation value 3 for the transition. 8550 * 8551 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8552 */ 8553 EAPI Eina_Bool edje_edit_program_transition_value3_set(Evas_Object *obj, const char *prog, double value); 8554 8555 /** 8556 * @brief Gets the interpolation value 4 of the transition. 8557 * Can be used with one of transition type: EDJE_TWEEN_MODE_CUBIC_BEZIER. 8558 * 8559 * @param obj Object being edited. 8560 * @param prog The name of the program to get the interpolation value 4. 8561 * 8562 * @return Interpolation value 4. 8563 */ 8564 EAPI double edje_edit_program_transition_value4_get(Evas_Object *obj, const char *prog); 8565 8566 /** 8567 * @brief Sets the interpolation value 4 of the transition. 8568 * Can be used with one of transition type: EDJE_TWEEN_MODE_CUBIC_BEZIER. 8569 * 8570 * @param obj Object being edited. 8571 * @param prog The name of the program to get the interpolation value 4. 8572 * @param value The interpolation value 4 for the transition. 8573 * 8574 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8575 */ 8576 EAPI Eina_Bool edje_edit_program_transition_value4_set(Evas_Object *obj, const char *prog, double value); 8577 8578 /** 8579 * @brief Gets the duration of the transition in seconds. 8580 * 8581 * @param obj Object being edited. 8582 * @param prog The name of the program to get the transition time. 8583 * 8584 * @return The duration of the transition. 8585 */ 8586 EAPI double edje_edit_program_transition_time_get(Evas_Object *obj, const char *prog); 8587 8588 /** 8589 * @brief Sets the duration of the transition in seconds. 8590 * 8591 * @param obj Object being edited. 8592 * @param prog The name of the program to set the transition time. 8593 * @param seconds The duration of the transition (in seconds). 8594 * 8595 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8596 */ 8597 EAPI Eina_Bool edje_edit_program_transition_time_set(Evas_Object *obj, const char *prog, double seconds); 8598 8599 /** 8600 * @brief Gets sample name of the program. 8601 * 8602 * @param obj Object being edited. 8603 * @param prog The name of the program. 8604 * 8605 * @return const char* sample_name on success, NULL otherwise. 8606 */ 8607 EAPI const char * edje_edit_program_sample_name_get(Evas_Object *obj, const char *prog); 8608 8609 /** 8610 * @brief Sets sample name of the program. 8611 * 8612 * @param obj Object being edited. 8613 * @param prog The name of the program. 8614 * @param name The name of the sample. 8615 * 8616 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8617 */ 8618 EAPI Eina_Bool edje_edit_program_sample_name_set(Evas_Object *obj, const char *prog, const char *name); 8619 8620 /** 8621 * @brief Gets tone name of the program. 8622 * 8623 * @param obj Object being edited. 8624 * @param prog The name of the program. 8625 * 8626 * @return const char* tone_name on success, NULL otherwise. 8627 */ 8628 EAPI const char * edje_edit_program_tone_name_get(Evas_Object *obj, const char *prog); 8629 8630 /** 8631 * @brief Sets tone name of the program. 8632 * 8633 * @param obj Object being edited. 8634 * @param prog The name of the program. 8635 * @param name The name of the tone. 8636 * 8637 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8638 */ 8639 EAPI Eina_Bool edje_edit_program_tone_name_set(Evas_Object *obj, const char *prog, const char *name); 8640 8641 /** 8642 * @brief Gets sample speed of the program. 8643 * 8644 * @param obj Object being edited. 8645 * @param prog The name of the program. 8646 * 8647 * @return Double speed on success, @c -1 otherwise. 8648 */ 8649 EAPI double edje_edit_program_sample_speed_get(Evas_Object *obj, const char *prog); 8650 8651 /** 8652 * @brief Sets sample speed of the program. 8653 * 8654 * @param obj Object being edited. 8655 * @param prog The name of the program. 8656 * @param speed New speed value. 8657 * 8658 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8659 */ 8660 EAPI Eina_Bool edje_edit_program_sample_speed_set(Evas_Object *obj, const char *prog, double speed); 8661 8662 /** 8663 * @brief Gets tone duration of the program. 8664 * 8665 * @param obj Object being edited. 8666 * @param prog The name of the program. 8667 * 8668 * @return Double duration on success, @c -1 otherwise. 8669 */ 8670 EAPI double edje_edit_program_tone_duration_get(Evas_Object *obj, const char *prog); 8671 8672 /** 8673 * @brief Sets tone duration of the program. 8674 * 8675 * @param obj Object being edited. 8676 * @param prog The name of the program. 8677 * @param duration New duration value. 8678 * 8679 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8680 */ 8681 EAPI Eina_Bool edje_edit_program_tone_duration_set(Evas_Object *obj, const char *prog, double duration); 8682 8683 /** 8684 * @brief Gets sample channel of the program. 8685 * 8686 * @param obj Object being edited. 8687 * @param prog The name of the program. 8688 * 8689 * @return Channel on success, @c 0 otherwise. 8690 */ 8691 EAPI unsigned char edje_edit_program_channel_get(Evas_Object *obj, const char *prog); 8692 8693 /** 8694 * @brief Sets sample channel of the program. 8695 * 8696 * @param obj Object being edited. 8697 * @param prog The name of the program. 8698 * @param channel New channel value. 8699 * 8700 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8701 */ 8702 EAPI Eina_Bool edje_edit_program_channel_set(Evas_Object *obj, const char *prog, Edje_Channel channel); 8703 8704 /** 8705 * @brief Gets filter part name of the program. 8706 * 8707 * @param obj Object being edited. 8708 * @param prog The name of the program. 8709 * 8710 * @return const char* part_name on success, NULL otherwise. 8711 */ 8712 EAPI const char * edje_edit_program_filter_part_get(Evas_Object *obj, const char *prog); 8713 8714 /** 8715 * @brief Sets filter part name of the program. 8716 * 8717 * @param obj Object being edited. 8718 * @param prog The name of the program. 8719 * @param filter_part The name of the part to be set as filter. 8720 * 8721 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8722 */ 8723 EAPI Eina_Bool edje_edit_program_filter_part_set(Evas_Object *obj, const char *prog, const char *filter_part); 8724 8725 /** 8726 * @brief Gets filter state of the program. 8727 * 8728 * @param obj Object being edited. 8729 * @param prog The name of the program. 8730 * 8731 * @return const char* state_name on success, NULL otherwise. 8732 */ 8733 EAPI const char * edje_edit_program_filter_state_get(Evas_Object *obj, const char *prog); 8734 8735 /** 8736 * @brief Sets filter state of the program. 8737 * 8738 * @param obj Object being edited. 8739 * @param prog The name of the program. 8740 * @param filter_state New filter state value. 8741 * 8742 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8743 */ 8744 EAPI Eina_Bool edje_edit_program_filter_state_set(Evas_Object *obj, const char *prog, const char *filter_state); 8745 8746 //@} 8747 /******************************************************************************/ 8748 /************************** SCRIPTS API ***********************************/ 8749 /******************************************************************************/ 8750 /** 8751 * @name Scripts API 8752 * Functions to deal with embryo scripts (see @ref edcref). 8753 */ //@{ 8754 8755 /** 8756 * @brief Gets the Embryo script for the group of the given object. 8757 * 8758 * Get the shared script for the group under edition. Shared script means 8759 * the script {} block for the group, not counting what's in each program. 8760 * It returns a malloc'd duplicate of the code, so users are free to modify 8761 * the contents directly and they should remember to free() it when done. 8762 * NULL will be returned if there's no script or an error occurred. 8763 * 8764 * @param obj Object being edited. 8765 * 8766 * @return The shared script code for this group. 8767 */ 8768 EAPI char *edje_edit_script_get(Evas_Object *obj); 8769 8770 /** 8771 * @brief Sets the code for the group script. 8772 * 8773 * Set the Embryo source code for the shared script of the edited group. 8774 * Note that changing the code itself will not update the running VM, you 8775 * need to call @see edje_edit_script_compile() for it to get updated. 8776 * 8777 * @param obj The object being edited 8778 * @param code The Embryo source 8779 * 8780 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8781 */ 8782 EAPI Eina_Bool edje_edit_script_set(Evas_Object *obj, const char *code); 8783 8784 /** 8785 * @brief Gets the Embryo script for the given program. 8786 * 8787 * Get the script code for the given program. Like the group script, this 8788 * function returns a duplicate of the code that the user can modify at will 8789 * and must free when done using it. 8790 * NULL will be returned if the program doesn't exist, doesn't have any 8791 * script or is not of type script. 8792 * 8793 * @param obj Object being edited 8794 * @param prog Program name 8795 * 8796 * @return The program script code 8797 */ 8798 EAPI char *edje_edit_script_program_get(Evas_Object *obj, const char *prog); 8799 8800 /** 8801 * @brief Sets the Embryo script for the given program. 8802 * 8803 * Set the Embryo source code for the program @p prog. It must be an 8804 * existing program of type EDJE_ACTION_TYPE_SCRIPT, or the function 8805 * will fail and do nothing. 8806 * Note that changing the code itself will not update the running VM, you 8807 * need to call @see edje_edit_script_compile() for it to get updated. 8808 * 8809 * @param obj The object being edited 8810 * @param prog The program name 8811 * @param code The Embryo source 8812 * 8813 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8814 */ 8815 EAPI Eina_Bool edje_edit_script_program_set(Evas_Object *obj, const char *prog, const char *code); 8816 8817 /** 8818 * @brief Compiles the Embryo script for the given object. 8819 * 8820 * If required, this function will process all script code for the group and 8821 * build the bytecode, updating the running Embryo VM Program if the build 8822 * is successful. 8823 * 8824 * @param obj The object being edited 8825 * 8826 * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. 8827 */ 8828 EAPI Eina_Bool edje_edit_script_compile(Evas_Object *obj); 8829 8830 /** 8831 * @brief Gets the list of errors resulting from the last script build. 8832 * 8833 * Get the list of errors that resulted from the last attempt to rebuild 8834 * the Embryo script for the edited group. This will be a standard Eina_List 8835 * with Edje_Edit_Script_Error pointers as its data. 8836 * The user should not do anything else but read the contents of this list. 8837 * These errors can be the output of the embryo compiler, or internal errors 8838 * generated by Edje_Edit if the preprocessing of the scripts failed. 8839 * 8840 * @param obj The object being edited 8841 * 8842 * @return A constant list of Edje_Edit_Script_Error, or NULL if there are none 8843 */ 8844 EAPI const Eina_List *edje_edit_script_error_list_get(Evas_Object *obj); 8845 8846 //@} 8847 /******************************************************************************/ 8848 /************************ SOURCE CODE API *********************************/ 8849 /******************************************************************************/ 8850 /** 8851 * @name Scripts API 8852 * Functions to deal with embryo scripts (see @ref edcref). 8853 */ //@{ 8854 8855 /** 8856 * @brief Returns source code of the current edje edit object. 8857 * 8858 * Remember to free the string with edje_edit_string_free(). 8859 * 8860 * This function will return source code of the whole group, loaded previously. 8861 * This function also will collect all possible resources that is required and 8862 * mentioned in description blocks. For example: all images, fonts, data, styles, 8863 * and color_classes. 8864 * 8865 * @param obj The object being edited 8866 * 8867 * @return Source code containing all resources required by the object. 8868 */ 8869 8870 EAPI const char *edje_edit_source_generate(Evas_Object *obj); 8871 8872 /** 8873 * @brief Returns source code of the current edje edit object. 8874 * 8875 * Remember to free the string with edje_edit_string_free(). 8876 * 8877 * This function will return source code of the whole group, loaded previously. 8878 * This function also will collect all possible resources that is required and 8879 * mentioned in description blocks. For example: all images, fonts, styles and 8880 * color_classes. 8881 * 8882 * @note A source code will be top block 'collection'. 8883 * 8884 * @param obj The object being edited 8885 * 8886 * @return Source code containing all resources required by the object. 8887 */ 8888 8889 EAPI const char * edje_edit_object_source_generate(Evas_Object *obj); 8890 /** 8891 * @brief Returns source code of all collections. 8892 * 8893 * Remember to free the string with free(). 8894 * 8895 * This function will generate and return source code of all collections and 8896 * other top level blocks. 8897 * 8898 * @param obj The object being edited 8899 * 8900 * @return Source code as char *. 8901 */ 8902 8903 EAPI char *edje_edit_full_source_generate(Evas_Object *obj); 8904 8905 /** 8906 * @brief Returns source code of global block data. 8907 * 8908 * Remember to free the string with edje_edit_string_free(). 8909 * 8910 * @param obj The object being edited 8911 * 8912 * @return Source code of global block data. 8913 */ 8914 EAPI const char * edje_edit_data_source_generate(Evas_Object *obj); 8915 8916 /** 8917 * @brief Gets a list of color classes which given object use. 8918 * 8919 * @param obj The object being edited 8920 * 8921 * @return The color classes list 8922 */ 8923 EAPI Eina_List * 8924 edje_edit_object_color_class_list_get(Evas_Object *obj); 8925 8926 /** 8927 * @brief Gets the source code for given color classes. 8928 * 8929 * @param obj The object being edited 8930 * @param color_classes The list of color classes for generate code 8931 * 8932 * @return The color classes source code 8933 */ 8934 EAPI const char * 8935 edje_edit_color_classes_source_generate(Evas_Object *obj, Eina_List *color_classes); 8936 8937 //@} 8938 /******************************************************************************/ 8939 /************************** ERROR API ***********************************/ 8940 /******************************************************************************/ 8941 /** 8942 * @name Error API 8943 * Functions to deal with error messages (see @ref edcref). 8944 */ //@{ 8945 8946 EAPI extern Eina_Error EDJE_EDIT_ERROR_GROUP_CURRENTLY_USED; 8947 EAPI extern Eina_Error EDJE_EDIT_ERROR_GROUP_REFERENCED; 8948 EAPI extern Eina_Error EDJE_EDIT_ERROR_GROUP_DOES_NOT_EXIST; 8949 8950 8951 #ifdef __cplusplus 8952 } 8953 #endif 8954 8955 #undef EAPI 8956 #define EAPI 8957 8958 #endif 8959