summaryrefslogtreecommitdiff
path: root/src/lib/edje
Commit message (Collapse)AuthorAgeFilesLines
* edje_entry: fix a potential error of null derefJaehyun Cho2021-02-041-0/+2
| | | | | | | | | | | | | | | | Summary: This is a patch to fix a potential error of null dereferencing. This patch is based on D12087. Reviewers: Hermet, jsuya Reviewed By: jsuya Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12241
* edje_data: Add missing descriptor for image.max(min).limitJunsuChoi2020-12-171-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Edje_Part_Description_Image uses EDJE_DATA_DESCRIPTOR_DESCRIPTION_COMMON_SUB, EDJE_DATA_DESCRIPTOR_DESCRIPTION_COMMON_SUB is missing max.limit and min.limit descriptors. Therefore, max:SOURCE and min:SOURCE did not work in EDC. Adds a descriptor to it. https://www.enlightenment.org/_legacy_embed/edcref.html#sec_toplevel_images max [width] [height] or SOURCE The maximum size of the state. A size of -1 means that it will be ignored in one direction. When max is set to SOURCE, edje will enforce the part to be not more than the original image size. The part must be an IMAGE part. Test Plan: {F4230539} edje_cc test.edc && gcc -o test test.c `pkg-config --libs --cflags evas ecore ecore-evas edje` ./test Reviewers: Hermet, Jaehyun_Cho, cedric, raster Reviewed By: Hermet Subscribers: #reviewers, #committers, kimcinoo, herb Tags: #efl Differential Revision: https://phab.enlightenment.org/D12215
* edje_util: Fix memory leakWoochanlee2020-12-081-0/+1
| | | | | | | | | | | | | | | | Summary: evas_object_data_set call callc for internal node. It's not free before call evas_object_data_del or evas_object_data_set(obj, NULL) Reviewers: raster, cedric, Hermet Reviewed By: raster Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12205
* singularize srand in eina_init - only once in one placeCarsten Haitzler (Rasterman)2020-10-031-2/+0
| | | | | | simplify down to having a single srand() in eina_init and use urandom if it works and is there - if not, time(NULL) will do. it's the best we can...
* edje - calc - handle swallow disappearing mid-calc due to callabcksCarsten Haitzler (Rasterman)2020-09-031-6/+11
| | | | | | | callbacks attached to move/resize etc. can change a swallow and .. well.. i hit a crash where it happens. so handle this case. @fix
* edje - fix enum cast warnings - checked valuesCarsten Haitzler (Rasterman)2020-08-252-2/+2
|
* ecore evas, edje - fix use of evas seat device enumCarsten Haitzler (Rasterman)2020-08-252-3/+3
|
* edje - calce - really respect max image size for img setsCarsten Haitzler (Rasterman)2020-08-131-33/+28
| | | | | | | when you have an image set for an image it wouldnt actually respect image max size and not select something bigger than it.. now it will @fix
* edje_entry: fix a potentional error of null derefWonki Kim2020-08-061-62/+65
| | | | | | | this is a patch to fix a potentional error by null dereferencing. Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de> Differential Revision: https://phab.enlightenment.org/D12087
* edje: fix a potentional error of null derefWonki Kim2020-08-051-1/+1
| | | | | | | | | | | | | | Summary: this is a patch to fix a potentional error by null dereferencing. Reviewers: jsuya, bu5hm4n, Hermet Reviewed By: jsuya Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12086
* edje_edit: fix a potentional error of null derefWonki Kim2020-08-051-6/+4
| | | | | | | | | | | | | | Summary: this is a patch to fix a potentional error by null dereferencing. Reviewers: jsuya, bu5hm4n, cedric, Hermet Reviewed By: jsuya Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12090
* edje_edit: add null check for return of eina_hash_findBowon Ryu2020-08-051-0/+1
| | | | | | | | | | | | | | | | Summary: to prevent null pointer dereference Test Plan: N/A Reviewers: cedric, jsuya Reviewed By: jsuya Subscribers: #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12094
* elm_entry/efl.ui.textbox: use common key shortcutsAli2020-08-051-19/+12
| | | | | | | | | | | | | | | | | | | | | Summary: **key** value comes from keyboard down callbacks are common, regardless of language/layout but **keyname** is dependent on layout(in X11, in Wayland Can not be produced). This common fix for both. For example if keyboard layout in arabic then: Ctrl+A will not work (in X11) This one enhances D11606 Reviewers: woohyun, bu5hm4n, zmike Reviewed By: woohyun Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11695
* edje_embryo: fix memory leak in ALLOC_COPY_DESCJaehyun Cho2020-08-041-7/+8
| | | | | | | | | | | | | | | | | | Summary: If memory allocation fails in ALLOC_COPY_DESC, then the allocated memory is not free. To fix this memory leak, memory allocation of Edje_Real_Part_State is done prior to ALLOC_COPY_DESC. Reviewers: Hermet Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12082
* edje_embryo: fix null pointer dereference in ALLOC_COPY_DESCJaehyun Cho2020-08-031-0/+1
| | | | | To fix null pointer dereference in ALLOC_COPY_DESC, allocated variable "new" is checked.
* edje_embryo: fix to use parameter of macro ALLOC_COPY_DESCJaehyun Cho2020-08-031-1/+1
| | | | | The parameter "To" of macro ALLOC_COPY_DESC is not used. To use the parameter "To", "d" is replaced to "To".
* edje_textblock: remove duplicated textblock style propertiesBowon Ryu2020-07-221-8/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: When there is "font" and "font_size" in textblock style (already defined), If "font" and "font_size" are set using edje_text_class_set(), then "font" and "font_size" are defined duplicated in texblock style through eina_strbuf_append. Duplicate properties use memory unnecessarily, and also it is possible to cause confusion at debbuging. This patch replaces duplicate properties "font", "font_size" using eina_strbuf_replace. Test Plan: * textblock style in edc "font=Sans font_size=20 wrap=mixed text_class=TEXT_CLASS"; * edje_text_class_set in c edje_text_class_set("TEXT_CLASS", "font=DejavuSans", 40); * textblock style at runtime (BEFORE) DEFAULT='font=Sans font_size=20 wrap=mixed font_size=40.0 font=DejavuSans' * textblock style at runtime (AFTER) DEFAULT='font=DejavuSans font_size=40 wrap=mixed' Reviewers: subodh6129, woohyun, ali.alzyod Reviewed By: ali.alzyod Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11962
* efl: make all _class_get() functions constMarcel Hollerbach2020-07-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | please note, not the return type, but the function. When appending __attribute__((const)) to a function, the compiler is told that its enough to call this function once in a function. This is quite often happening when we are efl_data_scope_get and efl_super in a function that is different from a implemented function. The compiler now starts to remove the calls that aggressivly that we need to ensure that these calls are not removed, which means, the static function calls, and the eo init are now checking the return value of these functions, to ensure that they are called. Please note that you now have to be carefull when your app calls eo_shutdown, if it does so, you *must* call it at the end of a function, or never call class_get after that anymore. Overall this improves elm test runs 0.1s which is fair i guess, the main thing that is faster is textrendering, where is also the point where this is the most beneficial. Please note, this replaces 42 occurences of double _class_get() ... THAT is a sign! Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Reviewed-by: Daniel Kolesa <daniel@octaforge.org> Differential Revision: https://phab.enlightenment.org/D12057
* Revert "edje: Avoid string duplication when possible."Carsten Haitzler (Rasterman)2020-07-171-14/+8
| | | | | | This reverts commit 8941514b467ce3e5d02c9b936d35a9d393989260. found that this breaks e's systray icon layout... :(
* edje: Avoid string duplication when possible.Woochanlee2020-07-161-8/+14
| | | | | | | | | | | | | | | | | | | Summary: Most use case the part name dosen't contain the recursive name so we don't have to go through expensive eina_string_split operation. Test Plan: edje-suite (34/37 edje-suite OK 0.67 s) elementary-test app launching on enlightenment Reviewers: raster, smohanty, Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12055
* Revert "edje: Avoid string duplication when possible."Carsten Haitzler (Rasterman)2020-07-071-14/+8
| | | | | | This reverts commit 704d58d658ed4424a886c127f3bbe83afde1f2a1. gee. it looked innocent enough... it broke tests and everything in e
* edje: Avoid string duplication when possible.Woochanlee2020-07-071-8/+14
| | | | | | | | | | | | | | Summary: Most use case the part name dosen't contain the recursive name so we don't have to go through expensive eina_string_split operation. Reviewers: smohanty, cedric, Hermet, raster Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12045
* docs: Correct the wrong group name in Edje and ElementaryMyoungwoon Roy, Kim2020-07-061-141/+177
| | | | | | | I had found wrong group name in edje and box, ctxpopup, entry, gengrid, genlist, gesture and fixed them. Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Differential Revision: https://phab.enlightenment.org/D12036
* Fix typos - (Part #2)Elyes HAOUAS2020-07-061-2/+2
| | | | | | | Fix some typos Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Differential Revision: https://phab.enlightenment.org/D12016
* Fix typos - (Part #5)Elyes HAOUAS2020-06-251-1/+1
| | | | | | | Fix some typos Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Differential Revision: https://phab.enlightenment.org/D12019
* Fix typosElyes HAOUAS2020-06-251-1/+1
| | | | | | | Fix some typos Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Differential Revision: https://phab.enlightenment.org/D12015
* Get rid of trailing whitespaces (6 / 14)Elyes HAOUAS2020-06-234-4/+4
| | | | | Remove whitespaces Differential Revision: https://phab.enlightenment.org/D12004
* edje: markup flag should be TRUE in legacy edje_object_part_text_setBowon Ryu2020-06-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Through some APIs (elm_entry_editable_set, elm_entry_single_line_set, etc.) located after edje_object_part_text_set(legacy) If efl_ui_widget_theme_apply is called, In edje_object_part_text_raw_generic_set, the legacy flag becomes FALSE. And in this case, the logic works in the unintended direction because the set_markup flag is FALSE. Test Plan: /* gcc -o entry_example entry.c `pkg-config --cflags --libs elementary` */ #include <Elementary.h> EAPI_MAIN int elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED) { Evas_Object *win, *en; elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED); win = elm_win_util_standard_add("entry-example", "test"); elm_win_autodel_set(win, EINA_TRUE); en = elm_entry_add(win); evas_object_size_hint_weight_set(en, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); elm_object_part_text_set(en, "elm.guide", "<font_size=32 color=#FFF>TEST</font_size>"); elm_entry_editable_set(en, EINA_FALSE); evas_object_show(en); elm_object_content_set(win, en); evas_object_resize(win, 300, 200); evas_object_show(win); elm_run(); return 0; } ELM_MAIN() Reviewers: woohyun, ali.alzyod Subscribers: zmike, cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11868
* Efl.Canvas.Vg.Object: Optimize Ector Surface SizeJunsuChoi2020-06-031-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The ector surface size was determined by the size of the vg object. vg object is usually sized by the size of the container. So, the ector surface is set unnecessarily large. This patch sets the ector surface size to the path boundary. And the path boundary refers to the stroke width and miterlimit. Test Plan: vector sample {F3887634} {F3887632} [grey area is ector surface size] {F3887633} Reviewers: Hermet, kimcinoo, smohanty, herb Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11865
* edje: fix memory leak in edje part recalculation.Myoungwoon Roy, Kim2020-05-271-1/+2
| | | | | | | | Allocated part_array is only freed when _circular_dependency_find() is successful. It is not freed in other cases. Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Reviewed-by: woochan lee <wc0917.lee@samsung.com> Differential Revision: https://phab.enlightenment.org/D11886
* refactor buildMarcel Hollerbach2020-05-271-6/+7
| | | | | | | | | | libraries are split into deps, external deps, and pub deps. Evas engines are refactored to use the predefined engine deps. this is preparation work for efl-one. Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org> Differential Revision: https://phab.enlightenment.org/D11806
* edje: fix memory leak by freeing the limits pointer.Subhransu Mohanty2020-05-271-0/+2
| | | | | | | | | | | | | | | | Summary: This limit parts are only used in naviframe edc thats why it is only showing up in naviframe test app. Reviewers: Jaehyun_Cho, Hermet Reviewed By: Jaehyun_Cho Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11887
* edje_load : clean up vector resource when edje file freed.Woochanlee2020-05-271-0/+4
| | | | | | | | | | | | Summary: Fix memory leak. Reviewers: cedric, Hermet, smohanty, bu5hm4n Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11859
* edje: Fix memory leak by freeing the filter data.Subhransu Mohanty2020-05-271-0/+16
| | | | | | | | | | | | Reviewers: Hermet, CHAN Reviewed By: CHAN Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11879
* canvas vg: fix dangling vector containers.Hermet Park2020-05-261-3/+4
| | | | | | | | | These duplicated containers are not going removed since its refernece is always more than 0. We need to unref explicity when they have to @fix
* edje: fix animation memory leak.Hermet Park2020-05-261-9/+12
| | | | | | | | | if object is destructed on canvas animation, its internal resource is leaked. Here simple fix brings stopping animation before deleting obj. @fix
* Revert "Fix EAPI definition by defining EFL_BUILD for each built DLL"Carsten Haitzler (Rasterman)2020-05-181-3/+1
| | | | This reverts commit 3ade45cbc82bea1772c7ad1afb7e1ba5dd67d930.
* Fix EAPI definition by defining EFL_BUILD for each built DLLVincent Torri2020-05-181-1/+3
| | | | | | | | | | | | | | Summary: EAPI must be defined to dllexport when building DLL, and to dllimport when using these DLL. To achieve this, define EFL_BUILD for each library and module, and set DLL_EXPORT unconditionally. Static library are and will be not supported Test Plan: compilation Reviewers: zmike, raster, jptiz Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11834
* edje_calc: Add unload file for already loaded vector lottie file.JunsuChoi2020-05-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: Users can use multiple jsons per description in one part in edc. At that time, multiple files are loaded, if a file is already loaded, it must be unloaded. Test Plan: edje_cc -beta -id ./ json_edc.edc make ./test Push Change button -> shutdown application {F3882716} Reviewers: Hermet, herb, kimcinoo Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11820
* edje: resolve float compare warningsMike Blumenkrantz2020-05-121-2/+2
| | | | | | | | | | Summary: Depends on D11797 Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11798
* Use __func__ C99 identifier instead of __FUNCTION__ compiler extensionVincent Torri2020-05-071-2/+2
| | | | | | | | | | | | | | Summary: see http://www.open-std.org/JTC1/SC22/wg14/www/docs/n1124.pdf section 6.4.2.2 page 52 Test Plan: compilation Reviewers: raster, devilhorns Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11785
* edje_textblock: content_fit size_range updateAli Alzyod2020-05-061-5/+8
| | | | | | | | | | | | | | Summary: update size range will skip empty font_sizes Reviewers: woohyun, bowonryu Reviewed By: woohyun Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11507
* edje_textblock: optimize priority handling for content_fit optionsAli2020-05-061-3/+5
| | | | | | | | | | | | | | Summary: this patch will reduce amount of unnessesary calculations, if user set both font_size_array and size_range for content fit. Reviewers: woohyun, bowonryu Reviewed By: woohyun Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11498
* edje - don't set font sizes less than 1Carsten Haitzler (Rasterman)2020-05-011-6/+7
| | | | | | this makes evas unhappy and results in noise. @fix
* doxygen docs: Fix all invalid @param namesXavi Artigas2020-04-201-1/+1
| | | | There were quite a few of these...
* remove unused imports in eo/eot filesDaniel Kolesa2020-04-191-2/+0
|
* edje: fix cursor scrollingBowon Ryu2020-04-171-2/+6
| | | | | | | | | | If there is a string larger than the size of entry and when the entry is auto scrolling, cursor is not visible. Using _edje_entry_cursor_geometry_get guarantees the minimum size of the cursor, and guarantee the size from edje. (min_restricted_calc) Reviewed-by: Ali Alzyod <ali198724@gmail.com> Differential Revision: https://phab.enlightenment.org/D11649
* doxygen docs: Fix missing docs in EdjeXavi Artigas2020-04-142-6/+10
|
* doxygen docs: Proper usage of @ingroup and @addtogroupXavi Artigas2020-04-141-12/+12
| | | | | | | | | | | | | | This patch brings in a lot of docs which were missing before. Unfortunately, this brings along their warnings so this ends up adding more warnings than it fixes. Still, a step in the right direction. @ingroup puts the current block into the specified group, but IT DOES NOT allow opening groups with @{. This was used in lots of places, resulting in misplaced or ignored documentation. @ingroup should be used only in individual docs. For groups we use @defgroup and @addtogroup. Also,this patch adds some small missing docs.
* edje_calc: add null check after eet_readWooHyun Jung2020-04-131-10/+13
|