Commit Graph

28235 Commits

Author SHA1 Message Date
subhransu mohanty 10501b170f edje/optimization: keep a style hash for fast retrival of styles
As edje mostly deals with style string. to get the style data each time
it linearly search through list to find out the style which is not very
cache friendly so keep a hash to do first lookup with less impact on cache.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9547
2019-08-20 10:40:22 -07:00
subhransu mohanty 676835458f edje/style: optimize updation of styles for a given text_style
Currently we do 2 pass updation. first we scan through all the styles
and check if they have text_style which matches the test_style we need to update
then we mark them dirty. then we call style_all_update() to go through the list
again and update those styles.
By combining them both in a single function we avoid scanning through the whole
list again.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9639
2019-08-20 10:40:19 -07:00
Mike Blumenkrantz bc0bd4eb3f efl_ui/scroller: process edje signals during group calc
Summary:
scrollbars (and other parts) can have min sizes which affect sizing calcs,
so it's necessary to ensure that these signals are processed before trying
to size in order to get the correct size
Depends on D9593

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9594
2019-08-20 09:11:18 -04:00
Mike Blumenkrantz cc6669c0d2 efl_ui/popup: replace legacy image use with efl_ui_image
Summary: new widgets should not use legacy widgets internally

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9590
2019-08-20 09:11:12 -04:00
Mike Blumenkrantz 563ad2a650 tests/popup: make text alert sizing test even more strict
Summary:
ensure that the internal label size is not wider than the scroller

text alerts should never need to scroll horizontally, so ensure that this
does not break

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9589
2019-08-20 09:11:07 -04:00
WooHyun Jung ebae12f06a elm_slider: remove dependency with efl_ui_slider
Summary:
This commit includes follwoing works.

1. change parent class from EFL_UI_SLIDER_INTERVAL
  to EFL_UI_LAYOUT_BASE
2. get all necessary codes from efl_ui_slider and
   efl_ui_slider_interval to elm_slider
3. add callbacks to slider test code

ref T7893

Test Plan:
1. elementary_test
2. slider
3. operate sliders on the window

Reviewers: bu5hm4n, segfaultxavi, eagleeye, zmike

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7893

Differential Revision: https://phab.enlightenment.org/D9623
2019-08-20 09:09:14 -04:00
Yeongjong Lee 81a7b79235 efl_ui_scroll_util: set drag_step of parent edje object
Summary: Depends on D9649

Test Plan: elementary_test -to 'efl.ui.scroller'

Reviewers: eagleeye, bu5hm4n, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9650
2019-08-20 09:07:13 -04:00
Yeongjong Lee 8f32138f1f efl_ui_scroll_util: emit edc signal that fix scroll arrow visibility
Summary:
"efl,action,scroll" signal will update arrow state.

ref T8051

Test Plan: elementary_test -to 'efl.ui.scroller'

Reviewers: eagleeye, bu5hm4n, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8051

Differential Revision: https://phab.enlightenment.org/D9649
2019-08-20 09:07:13 -04:00
junsu choi e850e3e5dc evas_vg_load_svg: Support "display" attribute.
Summary:
If the display attribute is "none", VG object is not show.
The default is "inline" which means visible and "none" means invisible.

Depending on the type of node, additional functionality may be required.
refer to https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/display

Test Plan:
[SVG]
<svg viewBox="0 0 220 100" xmlns="http://www.w3.org/2000/svg">
  <!-- Here the yellow rectangle is displayed -->
  <g display="none">
    <rect x="0" y="0" width="100" height="100" fill="skyblue"></rect>
  </g>
  <rect x="20" y="20" width="60" height="60" fill="yellow"></rect>

  <!-- Here the yellow rectangle is not displayed -->
  <rect x="120" y="0" width="100" height="100" fill="skyblue"></rect>
  <rect x="140" y="20" width="60" height="60" fill="yellow" display="none"></rect>
</svg>

[C CODE]
int main(int argc, char **argv)
{
   setenv("ECTOR_BACKEND", "default", 1);
   elm_init(argc, argv);

   Evas_Object *win = elm_win_util_standard_add(NULL, "test");
   evas_object_smart_callback_add(win, "delete,request", win_del, 0);
   elm_win_autodel_set(win, 1);

   Evas *evas = evas_object_evas_get(win);

   Evas_Object *vg = evas_object_vg_add(evas);
   evas_object_show(vg);
   Evas_Object *container = evas_vg_container_add(vg);
   evas_object_vg_root_node_set(vg, container);

   Evas_Object *svg = efl_add(EFL_CANVAS_VG_OBJECT_CLASS, container);
   efl_file_simple_load(svg, "./test.svg", NULL);
   efl_gfx_entity_size_set(svg, EINA_SIZE2D(600, 600));
   efl_gfx_entity_visible_set(svg, EINA_TRUE);
   evas_object_size_hint_weight_set(svg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
   evas_object_size_hint_align_set(svg, EVAS_HINT_FILL, EVAS_HINT_FILL);

   elm_win_resize_object_add(win, vg);
   evas_object_resize(win, WIDTH, HEIGHT);
   evas_object_show(win);
   elm_run();
   elm_shutdown();
   return 0;
}

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9640
2019-08-20 20:32:15 +09:00
Hermet Park b0737c7434 Revert "ector: code refactoring."
This reverts commit dad166f84a.

Ector is not public, this breaks enlightenment compilation,
2019-08-20 20:24:27 +09:00
Hermet Park dad166f84a ector: code refactoring.
Current vector drawing requires several methods for compositing,
it's shouldnt have only masking but other blending functions
such as matte in lottie, porter&duff in android, etc.

Previously we didn't specify this method name,
just reserved the options and now we started to define the methods
with ector_renderer_composite_method() instead of mask_set().
2019-08-20 18:23:41 +09:00
Marcel Hollerbach ead8a28057 efl_ui_widget: optimize size / position setting
calling geometry set here is again calling the API in canvas object that
splits this call to size_set and position_set which means we spent quite
a bit of time in eo, just to call the same APIs we could call directly.
With this commit here, the calls are directly going to the right
objects, with the right API.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9619
2019-08-20 07:42:43 +02:00
Marcel Hollerbach cbf7d71eeb efl_ui_focus_manager_calc: use a mempool instead of calloc / free
if we are heaving a streak of showing / hiding a lot of widgets we free
and calloc the same nodes all the time. This now lowers the amount of
callocs / frees that we are doing

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9618
2019-08-20 07:42:41 +02:00
Marcel Hollerbach ef858e1bfa efl_ui_focus_manager_calc: safe if this is root in a flag
otherwise we would need to get the private data of the focus manager
which is quite a heavy operation. This is slowing down enormously the
visibility setting of widgets.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9617
2019-08-20 07:42:39 +02:00
Marcel Hollerbach c1e6197b21 efl_ui_focus_manager_calc: optimize item deletion
if there is high frequency adding and deleting of items, the deletion
here can be quite heavy, this makes freeing a little bit faster.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9616
2019-08-20 07:42:38 +02:00
subhransu mohanty 6f0730cef3 edje/style: refactor style parsing to remove temporary dynamic string creation.
Summary:
pass a buffer to reparse() function for reuse.
create fontsource once and reuse.

Reviewers: ali.alzyod, Hermet, cedric, raster

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9636
2019-08-20 14:36:22 +09:00
Hermet Park 5c39e68d2b canvas svg: fix to apply premultipled color.
fill colors should be premultiplied with fill opcaity.
2019-08-20 11:25:44 +09:00
Hermet Park 3c59e23b7d evas vg: code refactoring.
try reduce code section size,
no logical changes.
2019-08-20 10:56:01 +09:00
Lauro Moura cc49c1034b csharp: MVVM parts support
Summary:
Parts binding will follow a similar approach to regular property
binding:

`var error = factory.PartName().PropertyName().Bind(modelProperty);`

* Changed both `Bind()` overloads to return the error code from
  `efl_ui_property_bind`
* Also properties from interfaces implemented didn't have their `Bindable`
  wrapper methds available.

Depends on D9563

Reviewers: felipealmeida, cedric, SanghyeonLee, woohyun

Reviewed By: cedric

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9564
2019-08-19 21:41:29 -03:00
Shinwoo Kim 2a0eeba4e5 evas: fix png regression issue
Accidentally commit "382c580 evas: add support for .9.png file to PNG loader."
adding the 9 patch feature with small code refactoring missed a line calling
eina_file_map_all taking EINA_FILE_SEQUENTIAL for data decoding.

You can see the previous change adding the line from the following commit.

   e60baa0 evas: change mapping policy to be less agressive into loading file
           in memory.

This is a response to the request of @cedric on D9580

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9614
2019-08-19 16:47:22 -07:00
Mike Blumenkrantz 409c42e46b efl_ui/text: attempt to size more accurately in non-scroll mode
the internal text object provides a min size based on its current geometry,
so temporarily match the geometry of the overall object in order to provide
a somewhat more accurate calculation sooner for this object

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9598
2019-08-19 16:47:20 -07:00
Mike Blumenkrantz e7cc65bdeb efl_ui/popups: convert from elm_scroller to efl_ui_scroller internally
efl_ui widgets should not use legacy widgets internally

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9596
2019-08-19 16:47:18 -07:00
Mike Blumenkrantz c4e03dcea4 efl_ui/scroller: create scroll manager in constructor
this fixes setting scroller properties during construction

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9593
2019-08-19 16:47:16 -07:00
Mike Blumenkrantz 6e54c58b9c efl_ui/scroller: directly trigger group_calc if pan is resized during canvas calc
this is the time when all calculations need to be handled, so ensure that the
widget directly updates itself here instead of deferring in order to avoid
infinite recalc loops

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9592
2019-08-19 16:47:14 -07:00
Mike Blumenkrantz 617bc90f12 efl_ui/scroll_util: don't trigger group_calc again on size changes
this is already handled elsewhere and can cause infinite recalc loops

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9591
2019-08-19 16:47:12 -07:00
Mike Blumenkrantz 6316455261 tests/scroller: start unit tests for efl.ui.scroller
same layout as elm_test case, start by checking scroll events after wheel

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9634
2019-08-19 16:47:10 -07:00
Mike Blumenkrantz 1114106f09 tests/elm: add util functions for triggering wheel events
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9633
2019-08-19 16:47:08 -07:00
Mike Blumenkrantz 187425e12c elm/hoversel: manually trigger group_calc for internal objects
hoversel doesn't implement group calc or do any sane type of sizing
so just manually call these on demand to ensure the correct size is used

fix T8127

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9632
2019-08-19 16:47:06 -07:00
Mike Blumenkrantz 1948bf0d07 elm/hoversel: avoid calling api functions on null hoversel objects
the hoversel must be created before it can be shown, and its internal
hover object may be destroyed when it is hidden

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9631
2019-08-19 16:47:04 -07:00
Cedric BAIL 945447d1f8 elementary: properly refcount the key of the hash used by Efl.Ui.Layout_Factory property bind.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9578
2019-08-19 15:25:19 -07:00
Ali Alzyod e08ca17488 evas_textblock: markup text: improve handling invalide escape characters
Improve handling invalid escape characters.

(*) When '&' character founded in Markup text.
      Old Behavior   : Any text after '&' (if it is not escape), all text will be discarded
      New Behavior : Any text after '&' (if it is not escape), will be processes as normal plain text.

Example:
     Markup  Text :  Hello X & Y & Z 1 2 3
     Old     output :  Hello
     New   output :  Hello X & Y & Z 1 2 3

This is related to T8077

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9489
2019-08-19 11:33:25 -07:00
Ali Alzyod a821eb456a evas_common: parse color in rgb()/rgba() format
evas_common_format_color_parse: support rgb()/rgba() format

efl user can now specify colors in text formats and styles as rgb(0-255,0-255,0-255) &  rgba(0-255,0-255,0-255,0-255)  format.

This is related to task: T8068

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9309
2019-08-19 11:33:23 -07:00
Ali Alzyod 1d76452aa9 evas_textblock: reduce _evas_textblock_changed calls with markup_text_append
**_evas_textblock_changed** is internal function that mark that the textblock has changed.

When make call for
evas_object_textblock_text_markup_set(txtblock,"This is Line<br>THis is other Line<br>");

Old behaviour:
multible calles for _evas_textblock_changed will happend, for each text/format appended.

New behaviour:
Single call for _evas_textblock_changed will happend.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9376
2019-08-19 11:33:20 -07:00
Lauro Moura ed22ad99a3 elm: avoid clash in Collection.Focus_Manager
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9627
2019-08-19 18:21:01 +02:00
Vincent Torri 01b987df59 make mman.h private
Summary:
integrate mman.h to make Evil private to the EFL, as mman.h does not exist on Windows. After a discussion with raster, i include sys/mman.h only on non Windows platform.

One issue, though, is that src/modules/emotion/generic/Emotion_Generic_Plugin.h has inlined functions using mmap()

Test Plan: compilation on Windows

Reviewers: cedric, raster, zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9542
2019-08-19 09:55:13 -04:00
Hermet Park ce3d1ec7e7 evas svg: fix svg spec compatibility.
Minus degree value must be transformed to the signed before Radian.

It's easily tested i.e. the rotation degree is -350.

@fix
2019-08-19 21:37:45 +09:00
junsu choi 8f440cdedc vg_common_svg: Apply node opacity to stroke color
Summary:
  When an object to be converted to a stroke or
  path uses "opacity" attribute, opacity is also applied.

Test Plan:
[SVG]
<?xml version="1.0" encoding="UTF-8"?>
<svg width="40px" height="40px" viewBox="0 0 40 40" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
    <!-- Generator: Sketch 52.6 (67491) - http://www.bohemiancoding.com/sketch -->
        <rect fill="#FF0000" opacity="0" x="0" y="0" width="40" height="40"></rect>
        <path d="M12,20 L25,8 L12,20 Z M12,20 L25,32 L12,20 Z"
              id="Combined-Shape"
              stroke="#FFFFFF"
              stroke-width="2"
              opacity="0.12"
              stroke-linecap="round"
              stroke-linejoin="round" fill-rule="nonzero"></path>
</svg>

[Code]
int main(int argc, char **argv)
{
   setenv("ECTOR_BACKEND", "default", 1);
   elm_init(argc, argv);

   Evas_Object *win = elm_win_util_standard_add(NULL, "test");
   evas_object_smart_callback_add(win, "delete,request", win_del, 0);
   elm_win_autodel_set(win, 1);

   Evas *evas = evas_object_evas_get(win);
   Evas_Object *vg = evas_object_vg_add(evas);
   evas_object_show(vg);
   Evas_Object *container = evas_vg_container_add(vg);
   evas_object_vg_root_node_set(vg, container);

   Evas_Object *svg = efl_add(EFL_CANVAS_VG_OBJECT_CLASS, container);
   efl_file_simple_load(svg, "./i_arrow_l_disable.svg", NULL);
   efl_gfx_entity_size_set(svg, EINA_SIZE2D(600, 600));
   efl_gfx_entity_visible_set(svg, EINA_TRUE);
   evas_object_size_hint_weight_set(svg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
   evas_object_size_hint_align_set(svg, EVAS_HINT_FILL, EVAS_HINT_FILL);

   elm_win_resize_object_add(win, vg);
   evas_object_resize(win, 600, 600);
   evas_object_show(win);
   elm_run();
   elm_shutdown();

   return 0;
}

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9620
2019-08-19 19:46:02 +09:00
subhransu mohanty dafd3dc7b8 edje/style: refactor to avoid creating temporary strings.
Summary: param_parse() was creating unnecessary 2 temporary string and destroying it.

Reviewers: ali.alzyod, cedric, Hermet, raster

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9610
2019-08-19 19:38:35 +09:00
subhransu mohanty a880a756cd edje/styles: avoid redundant style tag addition by providing extra checks.
Summary:
we should only add font_size tag if the new size is different.
we should only add font tag if there is a new font.

Reviewers: ali.alzyod, Hermet, cedric, raster

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9613
2019-08-19 19:33:56 +09:00
subhransu mohanty 1d930427a3 edje/styles: keep an escaped string of font_set. As eina_ecaped_string() creates a new string just make it once and use when needed.
Reviewers: Hermet, ali.alzyod

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9615
2019-08-19 19:21:47 +09:00
Hermet Park f10a3c9ee3 edje: fix compatibility issue.
Obviously previous edje object file set would try reload file
even though the file is already loaded.

This brings different result if the file data has been modified or changed.
2019-08-19 18:07:04 +09:00
Marcel Hollerbach 375f22931e meson: there is no need for checking ecore here
fix T7768

Differential Revision: https://phab.enlightenment.org/D9574
2019-08-19 09:44:26 +02:00
Felipe Magno de Almeida a6e679f830 eo-cxx: Add second NULL sentinel to avoid buffer overrun by efl_check.h
efl_check.h assumes at least one element exists when checking
parallelization and accesses the second element of the array without
checking its size first. Adding a second NULL sentinel fixes the problem.

T8141
Differential Revision: https://phab.enlightenment.org/D9588
2019-08-19 09:42:05 +02:00
Carsten Haitzler ae5fbe49ef elm slider - delete timers on destruction that should be deleted
also use safe free to set to null
2019-08-18 10:28:51 +01:00
Carsten Haitzler b2ab0a7788 evas - loader - rsvg generic - install svg symlink
svg loading broke as we didnt have the right symlink installed after a
binary file name change. this fixes that.
2019-08-18 09:57:42 +01:00
Carsten Haitzler 49602f7426 elm hoversel - avoid crash when items modified while popping down
this fixes a crash i saw with asan on pop down if items change at that
time. @fix
2019-08-18 00:25:39 +01:00
Daniel Kolesa 2f147f2725 eolian: rename is_class api for functions to is_static
Still needs restriction to classes only etc to be done later.

Ref https://phab.enlightenment.org/T8118
Ref https://phab.enlightenment.org/T7675
2019-08-16 16:33:37 +02:00
Daniel Kolesa 8a8a833837 eolian: rename @class on methods to @static
Ref https://phab.enlightenment.org/T8118
Ref https://phab.enlightenment.org/T7675
2019-08-16 16:27:00 +02:00
Felipe Magno de Almeida 491a9a5bf8 eolian-mono: Use correct allocator to free with free, and not delete
T8137
Differential Revision: https://phab.enlightenment.org/D9576
2019-08-16 16:01:38 +02:00
Daniel Kolesa 9f2e2f99c6 eolian: fix function pointer leak as reported by asan
Ref T8140.
2019-08-16 13:33:45 +02:00
Shinwoo Kim f5aa672853 evas: fix png regression issue
Summary:
The evas_image_load_file_data_png had called png_set_tRNS_to_alpha
from following commit.

   6988a38 evas: fix png loader to actually produce lower resolution
           content when asked.

You could refer to following information regarding png_set_tRNS_to_alpha
which is available on page http://www.libpng.org/pub/png/libpng-manual.txt

   The following code transforms grayscale images of less than 8 to 8 bits,
   changes paletted images to RGB, and adds a full alpha channel if there is
   transparency information in a tRNS chunk.  This is most useful on
   grayscale images with bit depths of 2 or 4 or if there is a multiple-image
   viewing application that wishes to treat all images in the same way.

       if (color_type == PNG_COLOR_TYPE_PALETTE)
           png_set_palette_to_rgb(png_ptr);

       if (png_get_valid(png_ptr, info_ptr,
           PNG_INFO_tRNS)) png_set_tRNS_to_alpha(png_ptr);

       if (color_type == PNG_COLOR_TYPE_GRAY &&
           bit_depth < 8) png_set_expand_gray_1_2_4_to_8(png_ptr)

Accidentally commit "382c580 evas: add support for .9.png file to PNG loader."
adding a new feature with small code refactoring missed the line calling
png_set_tRNS_to_alpha.

So we got a rendering issue. It made around 75% size white rectangle
using a grayscale and transparent image. I'd like to attach the image
which has following type information for test purpose.

$ identify -verbose ./grayscale_transparent.png | grep type -i
  Mime type: image/png
  Type: Bilevel
    png:IHDR.color-type-orig: 0
    png:IHDR.color_type: 0 (Grayscale)

Test Plan:
This is the sample image file grayscale_transparent.png

{F3748665}

Reviewers: cedric, Hermet, jsuya

Reviewed By: Hermet

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9580
2019-08-16 16:55:12 +09:00
Felipe Magno de Almeida 289cd1f3d4 eolian-cxx: Fix use after free for base variable
T8137
Differential Revision: https://phab.enlightenment.org/D9575
2019-08-16 09:30:54 +02:00
Marcel Hollerbach f5063b8733 meson: add xkbcommon to the build deps
Summary: fix T8064

Reviewers: cedric, zmike, devilhorns

Reviewed By: devilhorns

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8064

Differential Revision: https://phab.enlightenment.org/D9573
2019-08-15 15:36:29 -04:00
Christopher Michael 10c0e37a72 tests/ecore_wl2: Add ecore_wl2_surface tests to build order
ref T8016
2019-08-15 15:36:14 -04:00
Carsten Haitzler a84cfbae72 ethumb - fix short alloc on stack not including nul char space
fix space for nul byte with alloca.
2019-08-15 19:17:35 +01:00
Carsten Haitzler c3c903b9cc elm - dnd - fix drop target del to not nuke handler all the time
this broke dnd if u have multiple drop targets in a window... keep the
functions there if we still have drop targets... especially in x11.

@fix
2019-08-15 13:27:54 +01:00
Carsten Haitzler 894c1b34b3 elm entry - respect plain text newlines on paste again...
make this work like it used to... fixes T8135
2019-08-15 00:08:57 +01:00
Lauro Moura 252f0c42a0 elementary: Avoid segfault when part is not set.
Check whether we called `efl_part_get` before.

This was happening to C# bindings (maybe a bug there?) but in any case a
failure is safer than a segfault.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9563
2019-08-14 12:08:19 -07:00
subhransu mohanty d672d55107 edje/optimization: keep a readonly flag on edje_style.
Just to check if the edje style has text_class tag we do
lot of pointer hopping by linearly scan through the tags in the
style which is not very cache efficient.

by keeping a readonly flag we can avoid those acess if the style dosen't
have any text_class tags. and if we have those tags then we can start
updating the style straight away.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9546
2019-08-14 12:08:17 -07:00
Mike Blumenkrantz 11d2202635 efl_ui/text_scroller: remove erroneous max size hint setting
this makes no sense

ref T8122

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9554
2019-08-14 12:08:15 -07:00
Mike Blumenkrantz e1fda2cbdb efl/hints: add restricted and combined max size hints
these function the same as the min size hint versions and enable
distinction between internally-set max size hints and user-set max size
hints

@feature

ref T8122

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9553
2019-08-14 12:08:13 -07:00
SangHyeon Jade Lee c3f78d8b4f efl_ui: update efl_ui_list_view example to work
seems name for the model property_name is now allowed,
so fix it to title and now it works well.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9558
2019-08-14 12:08:11 -07:00
Mike Blumenkrantz c375bbcfa7 efl/hint: add doc note about max size hint
ref T8122

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9551
2019-08-14 12:08:09 -07:00
Mike Blumenkrantz 144d086fd7 efl_ui/popup: remove 'expandable' property from popup subclasses
this is more or less just the max size hint, so just set the max size
hint

ref T7902

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9550
2019-08-14 12:08:06 -07:00
Mike Blumenkrantz 0c72d430c3 efl_ui/popup: remove popup_size property
this was more or less just a wrapper around efl_gfx_entity_size_set
and resulted in unpredictable behavior depending on when it was called

instead, simply set the min size hint on the popup object

ref T7902

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9549
2019-08-14 12:08:04 -07:00
Mike Blumenkrantz d99186c039 efl_ui/win: implement unimplemented methods
Summary:
pass through methods from inherited classes to the correct internal
object
Depends on D9562

Reviewers: q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9572
2019-08-14 19:26:14 +02:00
Mike Blumenkrantz 07e810c5cc efl_ui/layout: implement unimplemented methods
Summary:
add redirects to internal layout objects for these methods
Depends on D9561

Reviewers: q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9562
2019-08-14 19:25:53 +02:00
Mike Blumenkrantz c48903f7df efl_ui: mark localization methods with @empty for containers
Summary:
these classes cannot be localized
Depends on D9560

Reviewers: q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9561
2019-08-14 19:25:27 +02:00
Mike Blumenkrantz 304f4ce9bb efl: remove Efl.Ui.I18n from canvas object inheritance
Summary:
canvas objects do not need localization because they are not directly user-facing

this should only be inherited by objects which need to be localized
Depends on D9559

Reviewers: q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9560
2019-08-14 19:25:09 +02:00
Mike Blumenkrantz 0ca5cd82a9 efl: mark a couple internal eo files as @beta
Summary: these are not distributed apis so they should always remain beta

Reviewers: q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9559
2019-08-14 19:24:19 +02:00
Christopher Michael e533bef2bf tests/ecore_wl2: Add start of ecore_wl2_surface tests
ref T8016
2019-08-14 11:03:04 -04:00
Yeongjong Lee 51a644d966 efl_ui: remove duplicated hint_min_set code
Summary:
evas_object_size_hint_min_set call efl_gfx_hint_size_restricted_min_set
internally.

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9567
2019-08-14 09:56:42 -04:00
Yeongjong Lee c857955a4e efl_ui_layout: remove efl_gfx_hint_size_min_set in _sizing_eval
Summary:
`evas_object_size_hint_min_set` is replaced with `efl_gfx_hint_size_min_set` in
4d79efce6. it is able to have backward compatibility issue because
`evas_object_size_hint_min_set` call `efl_gfx_hint_size_restricted_min_set`
internally.
```
evas_object_main.c:2501
EAPI void
evas_object_size_hint_min_set(Evas_Object *obj, Evas_Coord w, Evas_Coord h)
{
   efl_gfx_hint_size_restricted_min_set(obj, EINA_SIZE2D(w, h));
}
```

This patch remove unnecessary min_set call.

Test Plan: elementary_test

Reviewers: zmike, Jaehyun_Cho

Reviewed By: Jaehyun_Cho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9566
2019-08-14 17:48:32 +09:00
Shinwoo Kim 85cf0ce883 evas_map: draw what map did not draw before.
Summary:
When a map property is changed, map draws it.
Before drawing, evas_object_map_update updates map->spans which is data for
actual drawing. But if changed_map is false, then evas_object_map_update does
not update map->spans.

Usually mapped object has following step.

(1) change map data (evas_map_point_coord_set)
(2) render_pre
(3) evas_object_map_update updates map->spans if changed_map is true.
(4) render
(5) render_post -> evas_object_cur_prev -> "map->prev = map->cur"

But if mapped object hides at step(1), then step(3),(4) does not happen. But
step(4) map->prev keeps changed map data. After this point, If same map data
comes, then map does not draw it. Because the new data is same with map->prev.

The issue occurs with following step.
(A) point_coord_set with point A.
(B) (2)(3)(4)(5) works.
(C) point_coord_set with point B. And hide.
(D) (2)(5) wokrs.
(E) point_coord_set with point A. still hide, so none of (2)(3)(4)(5) work.
(F) point_coord_set with point B. And show.
(G) (2)(3)(4)(5) works. BUT step(3) does not update map->spans because
changed_map is false. So you can see image of point A.

The changed_map is changed to false after updating map->spans at step(3).
So usually changed_map is false before deciding changed_map of next render.
In case of not rendering (but render_pre/post) after map data is changed, the
changed_map keeps true. So this patch was suppose to make changed_map
false if changed_map is already ture before _evas_map_calc_map_geometry
decides changed_map which occurs step(1). true changed_map indicates that
you need to draw even though new map data is same with previous map data.

Test Plan: {F3739770}

Reviewers: Hermet, jsuya

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9476
2019-08-14 12:39:58 +09:00
Jaehyun Cho b8d1747382 efl_ui_layout: fix typo in _sizing_eval 2019-08-14 10:29:49 +09:00
subhransu mohanty 7ab04abf27 edje/style: Remove redundant style tags from style text.
Summary:
Both font and font_size are already added into the style text
in _edje_format_reparse() function and there we update the tag->font_size
as well as tag->font member. so I think it is unnecessary to
add again which has memory as well as parsing performance impact.

Note :
   someone please update this cryptic comment
   /* Add font name last to save evas from multiple loads */
   how this is going to help saving multiple load.

Reviewers: ali.alzyod, Hermet, raster, cedric

Reviewed By: Hermet

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9543
2019-08-13 11:18:01 +09:00
Cedric BAIL 742b7afb40 elementary: add tests for the efl_part support of efl_ui_property_bind.
Reviewed-by: Felipe Magno de Almeida <felipe@expertisesolutions.com.br>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9529
2019-08-12 10:13:38 -07:00
Cedric BAIL a5a7c67bdf elementary: add support for efl_ui_property_bind to all efl_part inheriting from widget using reflection.
Reviewed-by: Felipe Magno de Almeida <felipe@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D9528
2019-08-12 10:13:35 -07:00
Cedric BAIL 74aff95fca elementary: add support for widget part property bind.
Reviewed-by: Felipe Magno de Almeida <felipe@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D9527
2019-08-12 10:13:33 -07:00
subhransu mohanty 9952b9bf18 textblock/optimization: refactor evas_textblock_style for memory and perfromance.
the main user of textblock_style_set() api is the edje whcih keeps its owen edje_textblock_style
tags( string_shared string) by changing the textblock to keep the string_shared string will improve
the chance of sharing the same string hence reducing memory.

By removing the Eina_StrBuf usage inside the loop in textblock_style_set() api we can avoid lot
of temporary memory allocation and deallocation hence will improve performance.

Note: I see lot of places we use Eina_Strbuf inside a loop (eina_strbuf_new() does 2 allocation)
We need to be extra carefull while reviewing when the code uses those construct to see if its really necessary.

Data: it reduces memory allocation by 7000 in elementary_test launch time.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9545
2019-08-12 10:13:30 -07:00
subhransu mohanty 384765b088 edje/textblock: Don't add text_class style tag to the final style string
Evas_TextBlock_Style has no idea about the text_class tag its a garbage value to it.
So keep the text_class tag in the edje level and update the text style property in the
final style string when necessary.

Because text_class id tends to be unique by removing from the final style string
enable it to be shared (string shared string).

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9544
2019-08-12 10:13:28 -07:00
Carsten Haitzler c4354dd38e evas test - use correct type for ptr type tracking called
callback setup uses int but thecallback uses intptr_t ... which is...
wrong.
2019-08-11 17:09:32 +01:00
Carsten Haitzler 0a06c7b568 efl check - use global not stack local buffer for srunner_set_xml
asan is most unhappy about using a priori stack frame's data for
this.. it seems check uses the char * buf directly as-is without
duplicating it... so we can't sensibvly use local stack data. that is
what asan is saying... and this makes our tests not work under asan to
begin with... nto to mention other possible issues i have yet to see
as i got to this one first.
2019-08-11 16:35:03 +01:00
Carsten Haitzler cb513df377 eldbus - fix null node last on introspection parse
this fixes CID 1402721
2019-08-11 12:47:38 +01:00
Carsten Haitzler 9e94115ab3 evas text - handle null font case for font set
coverity was unhappy wiht inconsistent checks, so we'll be consistent
and thus handle a null font.

fixes CID 1403882
2019-08-11 12:47:38 +01:00
Carsten Haitzler b0ad81d927 elm ctxpopup - be consistent with scope data checks
makes coverity happy.

CID 1403898
2019-08-11 12:47:38 +01:00
Carsten Haitzler 807c8e7357 eina file - don't double unlock a lock
thanks to coverity - found this double unlock path in case of error.

fix CID 1403899
2019-08-11 12:47:38 +01:00
Carsten Haitzler fd48be23c2 eina file - make coverity happy and lock+unlock on init
coverity doesnt like inconsistent behavior of code, so make it
consistent even  if pointless as this is during init when we wont have
threads .... yet.

CID 1403903
2019-08-11 12:47:38 +01:00
Carsten Haitzler f3c01a9a6c efl thread - use pipe array names consistently to avoid err handling bug
in the case pipes fail to create we'll close the wrong ones... this
fixes that. it also happens because i didn't use names consistently.
now it does so it's easier to keep right.

thanks coverity.

fix CID 1396994
2019-08-11 12:47:38 +01:00
Carsten Haitzler 60f549c5fb efl thread - fic pipe close to not close invalid pipe fds
if we only have stdout and no stdin we'd accidentally close junk int's
on the stack. fix this fix CID 1396963
2019-08-11 12:47:38 +01:00
Carsten Haitzler c2a33f2225 efl filter model - fix return value handling to avoid uninit mem access
coverity reported - it's right. this fixes CID 1401461 and CID 1401463
2019-08-11 12:47:38 +01:00
Carsten Haitzler d9bdf12019 edje - fix conversion of edje var from int to float to use tmp var
fix CID 1402624
2019-08-11 12:47:38 +01:00
Carsten Haitzler 8113eb74a0 eldbus - fix leak of message in error path case
fix CID 1402657
2019-08-11 12:47:38 +01:00
Carsten Haitzler 4b8a422a6d edje - fix conversion of edje var from float to int to use tmp var
this should disambiguate the conversion intended.

fix CID 1402675
2019-08-11 12:47:38 +01:00
Carsten Haitzler 05ee22cd68 efl model - fix use after free
fix CID 1402712
2019-08-11 12:47:37 +01:00
Carsten Haitzler e0f0165220 evas - png loader - fix leake in error case of pixels
fix CID 1403027

@fix
2019-08-11 12:47:37 +01:00
Carsten Haitzler 61be4f02bf eet dict+ data read - move rw lock to ourside decode for speed read
on read/decode we can avoid lots of little locks and unlocked by
having the rwlock go to the outside and a single lock+unlock (read) on
the dictionary. it blocks for longer by has less atomics/fence points
as a result and thus decodes faster where changes that we are writing
while decoding is insanely low so no point worrying here.
2019-08-11 12:47:31 +01:00
Carsten Haitzler 8531380de0 efreet - be more patient for efreet to start - up to 2 sec now
seems people have issues with efreetd starting in 0.5 sec on some
systems... even rpi's manage that, but lets be more patient and wait
up to 2 sec
2019-08-09 19:09:25 +01:00
Mike Blumenkrantz 769fa4b592 elm_test: fix crashing in efl.ui.popup when closing windows
avoid double free on pointer in callback

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9540
2019-08-09 10:25:37 -07:00
Mike Blumenkrantz 189ddd9c81 tests/popup: add (extremely) comprehensive test for anchor popups
this verifies all align settings, different anchor points, changing anchors
and aligns on-the-fly, unsetting anchors, and changing popup sizes

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9526
2019-08-09 10:25:35 -07:00
Mike Blumenkrantz 2c33744a8a tests/popup: add test units for all the text_alert popups in elm_test
this is mostly to verify that the internal label is sizing as expected

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9523
2019-08-09 10:25:33 -07:00
Mike Blumenkrantz 0a3dfe8b5c tests/popup: add unit tests for scroll_alert expandable sizing
these correspond to the cases in elm_test

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9522
2019-08-09 10:25:30 -07:00
Mike Blumenkrantz 1334514cfe efl_ui/popup: apply user min size hints during group_calc
if these hints are set, they should be used

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9539
2019-08-09 10:25:28 -07:00
Mike Blumenkrantz 3aee9a96c0 efl_ui/popup: optimize popup sizing calcs slightly
ensure that scroll-based popups don't accidentally trigger a full
recalc and (wrong) size change during group_calc by hitting the base
popup size_set() implementation and setting the needs_calc flag or
by using the base popup calc code when it should not be used

this resolves a corner case sizing issue in the text_alert 2 popup
case in elm_test which seems to have been present for a long time

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9538
2019-08-09 10:25:26 -07:00
Mike Blumenkrantz 219cb6fe9e elm/config: clear env var hash on shutdown
env vars should not be retained when this subsystem is not "active"

fixes unit test running

ref 9149767184

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9537
2019-08-09 10:25:24 -07:00
Daniel Kolesa 510d437246 eolian: add an envvar to warn about unimplemented beta funcs
This changes the behavior of the existing env var to only check
unimplemented functions in stable APIs by default. Beta checks
can be enabled with an additional environment var, so use
EOLIAN_CLASS_UNIMPLEMENTED_WARN for stable and
EOLIAN_CLASS_UNIMPLEMENTED_BETA_WARN for extra beta checks.
2019-08-09 16:10:41 +02:00
Cedric BAIL 7248812a51 edje: fix warning for returning wrong type.
Reviewers: zmike

Reviewed By: zmike

Subscribers: segfaultxavi, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9530
2019-08-09 08:48:15 -04:00
subhransu mohanty 9e3a046661 evas/textblock: optmize textblock format parsing.
Summary:
 textblock format parsing creates/delets eina_TempStr for each
 token. Eina_TempStr is even worse than malloc/free because it also
 takes a lock/unlock along with malloc/free each time we create it.
 Just use a stack bufefr and create string in it if the string is too big
 then it will fall back to heap which is anyway we are doing right now.

 Tested this in Tizen List view the number of allocation reduced by 16000.

Reviewers: Hermet, ali.alzyod, woohyun

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9534
2019-08-09 17:36:35 +09:00
subhransu mohanty 1b94d90d53 edje: optimize color_class_recursive_find_helper() function
Summary:
If the  color_class is not overridden by the object level the
hash will be empty but still we do the expensive call to _edje_hash_find_helper()
find the color_class in an empty hash. by checking if the hash is empty
and returning early we save lot of unnecessary hash computaion and lookup.

Reviewers: Hermet

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9532
2019-08-09 14:02:24 +09:00
subhransu mohanty da39f53b95 eina/hash: optimize eina_hash_find() when hash is empty.
Summary:
Check if hash is empty before computing the hash key and look inside the
hash to find data.

Note: could have called the eina_hash_population() api but didn't
      because of extra function call.

Reviewers: Hermet

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9531
2019-08-09 14:00:03 +09:00
Hermet Park 21bebe0422 efl_ui_textpath: clear up path data when it's destructed.
This fixes path data memory leak.

@fix
2019-08-09 13:43:50 +09:00
Mike Blumenkrantz cdaebfa040 evas/render: size and draw proxy render surface based on proxy clipper
if a proxy is not being proxied, it's optimal to create a surface for only
the necessary dimensions and then only draw within those dimensions.

when a proxy is clipped to a size smaller than the proxy object, the required
size for the proxy render becomes smaller as the proxy has less visible area.
this enables us to draw only the clipped region and thus gives a performance
boost

this can only be enabled if the clipper is marked as static

Reviewed-by: Hermet Park <hermetpark@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8881
2019-08-08 18:32:27 -07:00
Mike Blumenkrantz 250777a16e evas/render: clamp mask surface size to clipper size
there's no point in allocating a massive mask surface if it's going to
be clipped to a smaller size, so instead just allocate the smaller size
and position it where the clipped size would be

this can only be enabled if the clipper is known to not be changing size,
as performance would be impacted if the clipper was forcing a full mask
redraw due to regular resizing

Reviewed-by: Hermet Park <hermetpark@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8841
2019-08-08 18:32:25 -07:00
Mike Blumenkrantz 0f58547085 evas: add 'has_fixed_size' property for canvas objects
this provides a hint for rendering that the object is not going to resize
for as long as the flag is set and  allows for some optimizations to
be made during rendering based on this knowledge

@feature

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D8887
2019-08-08 18:32:23 -07:00
Carsten Haitzler 9149767184 getenv - reduce continually calling getenv for the same vars do once
do it once and remember the result from the first one. drops overhead
for sure by a chunk i actually could see in perf reports like about 1-2%
of cpu...
2019-08-08 23:57:02 +01:00
Boris Faure cdb920ab08 get rid of shadow variables
Summary: gl: add some EINA_FALLTHROUGH

Reviewers: #reviewers, zmike

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9525
2019-08-08 17:18:46 -04:00
Hermet Park 9b7d71df79 ector: ++safety.
null handling just in corner case.
2019-08-08 23:34:02 +09:00
Hermet Park 49343b628a evas vg: ++safety.
Realloc internal composite buffer if its size is invalid.
2019-08-08 23:30:20 +09:00
Marcel Hollerbach 090588f58b efl_ui_selectable: add spec test suite for this
Summary:
this brings a spec test suite for Efl.Ui.Selectable

Depends on D9517

Reviewers: zmike, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9518
2019-08-08 09:12:46 -04:00
Carsten Haitzler 5f1e44ddad eina log - we exceet 24 domains alrready out of the box, so increase
this avoids more reallocs since we already use more than 24 domains...
go up to 64.
2019-08-07 21:20:00 +01:00
Lauro Moura ccd5441b8f cxx: Fix funcptr c_args declaration.
Summary:
The internal wrapper was generating the argument types directly instead
of passing through the translation generator `grammar::c_type`.

This caused the type in the `caller` callback to be different from the
actual C type of the declared function pointer, like in `@out` parameters.

Reviewers: tasn, felipealmeida

Reviewed By: felipealmeida

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9524
2019-08-07 16:14:27 -03:00
Carsten Haitzler b6bc80d2da ecore evas drm - fix code that forgets to del an fd handler
also.. note the badness of the code design mixing a global singleton
with a "per struct" set of data like fd handlers for the same devices
initted only once but... anyway. it's messy.
2019-08-07 18:14:06 +01:00
Carsten Haitzler 064b46b7a3 evas egl - esnure we always destroy surfaces because creating new ones
be sure we dont leak them.
2019-08-07 16:59:43 +01:00
Carsten Haitzler 8e67e9d18e evas - gl_drm - delete old surfaces before creating new ones
we shouldnt go have multiple drm window surfaces per drm surface...
this is bad.

@fix
2019-08-07 16:39:10 +01:00
Marcel Hollerbach 2c0ea5b5e3 efl_ui_focus_layer: we should cleanup on invalidate
Summary:
otherwise there will be errors. Lets pray this did not break anything
else.
Depends on D9518

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9521
2019-08-07 10:24:08 -04:00
Tom Hacohen 84e06f7234 Evas: migrate Evas_BiDi_Direction -> Efl_Text_Bidirectional_Type. 2019-08-07 15:01:22 +01:00
Marcel Hollerbach d11551050d efl_ui_item: fix event emission
with this commit events are emitted correctly, even if the container is
already on the way to deletion. Additionally, the codepath that is
triggered when the item is selected via clickable is now also going
through the selected property.

ref 7905

Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D9517
2019-08-07 14:48:42 +02:00
Marcel Hollerbach 54c524f7f6 introduce efl_ui_multi_selectable and efl_ui_single_selectable
right now they are just thin wrappers from what have been in
efl_ui_collection. This is just a first effort, the interfaces have to
be equipped with more and better API, more events, and tests.

ref T8057

Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D9515
2019-08-07 14:48:41 +02:00
Mike Blumenkrantz f34f92bb29 efl_ui: use unified size hints api and be explicit about which hint is changed
unified widgets should use unified api internally and also be more explicit
about which min size hint (restricted or user) is being set in order to improve
readability of code

when unified widgets also implement legacy wrappers, legacy api should be used
for the legacy objects

no functional changes

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9495
2019-08-07 14:48:39 +02:00
Mike Blumenkrantz c5030346d4 tests/popup: add sizing test for scroll_alert popup
Differential Revision: https://phab.enlightenment.org/D9516
2019-08-07 14:48:38 +02:00
Ali Alzyod eee58425ea evas_text: backward compatibility for setting text size
Summary: This is for backward compatibility for TIZEN Test cases for legacy

Reviewers: woohyun

Reviewed By: woohyun

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9519
2019-08-07 20:39:33 +09:00
Carsten Haitzler eea0e92c2c emile - use newer lz4 api instead of deprecated one 2019-08-07 11:44:05 +01:00
Carsten Haitzler 98e80725a3 lz4 - update to 1.9.1 for static lib in src tree
this updates our static zlib to 1.9.1 releases april 23, 2019.

fixes T7983
2019-08-07 11:31:03 +01:00
Marcel Hollerbach f7035fac67 efl_ui_selectable: this should be beta
sorry, i forgot that ... :(
2019-08-07 10:38:33 +02:00
Mike Blumenkrantz 4410f8b080 tests/popup: add unit tests for alert_popup
this covers all cases from the elm_test example

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9512
2019-08-06 17:18:37 +02:00
Marcel Hollerbach 9baa96c352 efl_ui_check: migrate from own property to Efl.Ui.Selectable
this is the basic work for getting radio group as a single_selection
interface, which can be a part of mutli_selection. Which will come both
later on.

ref T8057

Differential Revision: https://phab.enlightenment.org/D9504
2019-08-06 17:09:42 +02:00
Marcel Hollerbach d347c0632a efl_input_clickable: int -> uint
Summary:
the ids of the structs here are never negative

ref T7976

Reviewers: zmike, segfaultxavi, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7976

Differential Revision: https://phab.enlightenment.org/D9497
2019-08-06 10:57:56 -04:00
Marcel Hollerbach 912dfe270e efl_ui_focus_manager_root_focus: perform focus switch delayed
Summary:
Delaying the unregistering here ensures that there is not focus set call
while a object is beeing registered in the focus manager.

ref T8081

Reviewers: zmike, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8081

Differential Revision: https://phab.enlightenment.org/D9513
2019-08-06 10:52:32 -04:00
Marcel Hollerbach 63d3af3ce9 efl_ui_collection: implement initial focus behaviour
Summary:
the behaviour here is that the next item according to the direction is
getting focused. This sounds easy but is quite complex given the fact
that the items might be hidden. This is the first draft for this, to see
how good it performes.

Reviewers: zmike, stefan_schmidt, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9496
2019-08-06 09:34:42 -04:00
Christopher Michael 49e8334024 ecore_wl2: Move ecore_wl2_buffer_fit function to be internal
The ecore_wl2_buffer_fit function is only used internally in EFL so
move it out of the public API header.

ref T8013
2019-08-06 08:51:05 -04:00
Christopher Michael 43a49007f7 ecore_wl2: Move ecore_wl2_window_false_commit to be internal
The ecore_wl2_window_false_commit function is only used internally
inside efl so there is no need for it to be a public API.

ref T8013
2019-08-06 08:49:38 -04:00
Christopher Michael b273bf7f9a ecore_wl2: Move ecore_wl2_window_rotation_change functions to be
internal

These functions are not used in efl wayland clients nor are they used
in Enlightenment. As such, there is no reason that they need to be
public API so this commit moves them to be Internal and updates
Ecore_Evas engine code to include the internal header.

ref T8013
2019-08-06 08:40:41 -04:00
Hermet Park ee25c66eff build: Seprate same svg extension loaders between image and vector.
Currently, vector and image support svg format via different rountine.
Our vector loader implemenst on its own drawing mechanism for svg,
but in case of image loader, it depends on rsvg library.

By Comparing both, our vector svg is winner at performance wise.
we can remove rsvg routine later.

For now, these two loader names are conflicted, we should separate their names
with svg and rsvg.
2019-08-06 20:57:46 +09:00
Yeongjong Lee 97510fc571 efl_input_hold: replace hold property name with input_hold
Sorry to touch stable eo classes. there is name conflict issue between class and
property when binding language is generated from eo. for example in C#, compiler
error occurs.

```
src/bindings/mono/efl_input_hold.eo.cs(166,17): error CS0542:
`Efl.Input.Hold.Hold': member names cannot be the same as their enclosing type
```

This patch changes Efl.Input.Hold.GetHold/SetHold to
Efl.Input.Hold.GetInputHold/SetInputHold and generates Efl.Input.Hold.InputHold
property.

Note that CAPI is not changed.

ref T8093

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Lauro Neto <lauromauro_>
Differential Revision: https://phab.enlightenment.org/D9484
2019-08-06 11:05:30 +02:00
Lauro Moura 51c8ff8fc8 docs: Improve Efl.Input.Key docs
People without X11 background would have a hard time understanding the difference
between key, key_name, key_code, etc.

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Reviewed-by: YeongJong Lee <yj34.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D9487
2019-08-06 11:05:29 +02:00
Vincent Torri 5536bcd90e remove useless definition of the macro HAVE_MMAN_H
use HAVE_SYS_MMAN_H when including sys/mman.h and HAVE_MMAP when using mmap()

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9494
2019-08-06 10:01:39 +02:00
Mike Blumenkrantz 660d993752 tests/efl_ui_popup: add tests for this widget
these tests cover all the cases in the elm_test efl.ui.popup example

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9509
2019-08-06 09:26:41 +02:00
Mike Blumenkrantz 15eff40820 efl_ui/popup_backwall: implement efl.file file and key get methods
these need to be proxied to the internal image object to return
correct values

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9508
2019-08-06 09:26:40 +02:00
Mike Blumenkrantz 962a777c10 efl_ui: add popup headers to Efl_Ui.h
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9507
2019-08-06 09:26:39 +02:00
Mike Blumenkrantz e9e8078cec tests/elm: add helper callback for automatically quitting main loop when triggered
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9506
2019-08-06 09:26:38 +02:00
Mike Blumenkrantz f8dcb7dc2b tests/elm: add helper function for clicking at specified coords
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9505
2019-08-06 09:26:37 +02:00
Mike Blumenkrantz 067d65361e efl_ui/text: handle disabled text
no idea what's going on here with new styling but this makes it look
like it should

ref T6649

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9502
2019-08-06 09:26:36 +02:00
Mike Blumenkrantz 8f8e19df20 efl_ui/clock: remove unused functions
these were used for clock module functionality that has since been removed

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9501
2019-08-06 09:26:36 +02:00
Mike Blumenkrantz c9299f0caa efl_ui/clock: remove legacy api/widget use internally
new widgets should use unified api internally

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9500
2019-08-06 09:26:35 +02:00
Mike Blumenkrantz 88910d6a65 efl_ui/clock: remove module interface
this was overly complex and never actually used

ref T7868

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9499
2019-08-06 09:26:34 +02:00
Vitor Sousa c1b76d3008 csharp: fix ownership of value types in arrays and lists
Summary:
`eolian_mono` now considers the implicit ownership of value types in arrays and
lists when generating ownership flags.

Also, update manual bindings for arrays and lists to no longer free elements
in the `Dispose` method when the container has ownership of the elements
but C# itself does not have ownership of the container; the elements will be
freed by whoever owns the container.
Modifying and removing elements will still free them though.

Re-enabled unit tests that required ownership of value type elements.

Reviewers: felipealmeida, q66, vitor.sousa

Reviewed By: felipealmeida

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9457
2019-08-05 19:15:35 -03:00
Vitor Sousa e6a52ef371 csharp: re-enable binbuf tests with -Dmono-beta=false
Summary:
Since the introduction of the `binbuf` keyword in eolian, `Eina_Binbuf` is no
longer a beta only type.
Hence, we enable EFL# binbuf unit tests in non-beta compilation too.

Reviewers: lauromoura, felipealmeida

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9467
2019-08-05 18:55:20 -03:00
Carsten Haitzler 21efff6d3e evas image - eina file - be paranoud about double closes
tracking some seemingly not so good asan hits on the eina file where
we're accessing an eina file already closed... so be extra paranoid
about it and set things to null after free/close...
2019-08-05 18:59:33 +01:00
Carsten Haitzler c56791180d gif loader - dup eina file as we keep our own copy of it in the loader
we didnt dup the eina file handle since  we kee our own handle. we
need ot do that. asan found this.
2019-08-05 18:59:33 +01:00
Marcel Hollerbach 1bd9a8f232 introduce a new interface efl_ui_selectable
this is meant to be implemented by entities that *can* be selectabled
(not to be confused with containers that can have selected contents)!

ref T8057

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9503
2019-08-05 19:49:13 +02:00
Marcel Hollerbach fc12e7721f efl_ui_selectable: split this up
i dont know why, but something got badly mixed up, the selection APIs
for text and item ended up in the same interface, which seems ... weird
?
This commit splits that up into container_selectable and
text_selectable, there is no future plan on my list for text_selection.
The rest of this series is working towards removing
container_selectable, replacing it with a new interface. However, the
interface will stay until list_view is replaced.

The changes in the legacy code are removing the efl.ui.selection
interface from it, item emission is not depending on the inherited
interfaces, additionally, this interface does not provide any API, so
this should not be an issue.

ref T7766

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9498
2019-08-05 19:49:12 +02:00
WooHyun Jung 53649030db efl_ui_action_connector: rename clickable_util to action_connector
efl_ui_clickable_util was only for efl_input_clickable interface,
but there can be more cases which want to connect object event
to specific action interfaces (such as scrolling) in the future.
For that extension, efl_ui_action_connector seems better.

ref: T7847

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9486
2019-08-05 17:44:32 +02:00
Carsten Haitzler d9198f10a9 edje cc - fix coverity warning for uninit local var
fix CID 1382208
2019-08-05 15:20:49 +01:00
Lauro Moura 40def3eac9 efl-mono: Add Model manual implementation to C# and MVVM factories
Summary: Depends on D9273, D9270

Test Plan: Run added testcases.

Reviewers: cedric, bu5hm4n, zmike, SanghyeonLee, felipealmeida, segfaultxavi

Reviewed By: cedric

Subscribers: cedric

Tags: #expertise_solutions, #efl_language_bindings

Differential Revision: https://phab.enlightenment.org/D8080
2019-08-05 10:18:18 -04:00
Carsten Haitzler 7c72f10153 ethumb - fix error free of static string as stringshare
in one case we try stringshare_del a static string, not stringshared,
so fix by always making it a stringshare

fix CID 1402614
2019-08-05 15:02:45 +01:00
Carsten Haitzler 4664d02fe2 epp - fix tchnical leak for coverity
its technically a leak.. but epp will give up a nd error out anyway
here so... didn't matter.

fix CID 1402655
2019-08-05 15:00:29 +01:00
Carsten Haitzler b7bc6212bc ecore drm legacy - fix dbus leaks of reply handle
fix CID 1402664
2019-08-05 15:00:29 +01:00
Daniel Kolesa 4c6a9520ef eolian: fix use after free in eolian_database
'toscan' is actually a view to 'mpath' memory, so freeing it first
would result in use-after-free. This is obviously only in the error
branch so it usually does not happen, but fix anyway.

CID1403022
2019-08-05 15:43:39 +02:00
Daniel Kolesa 4f50a9728d eolian: fix false positive use-after-free in parser
The catch here is that check_match results in a long jump under
that condition. The static analyzer doesn't know this, so declare
intent.

CID1402703
2019-08-05 15:42:24 +02:00
Daniel Kolesa 3c7e1c9767 eolian: silence return checking in lexer
Coverity CID1396970.
2019-08-05 15:39:43 +02:00
Daniel Kolesa 80fb8727b5 eolian: refactor "dead" code
This has no functional change but should stop coverity from
complaining.

CID1382214
2019-08-05 15:37:13 +02:00
Daniel Kolesa ede2db5f1b eolian: attempt to silence coverity overlapping assignment errors
While the previous code was I believe correct, coverity still
complains about it. Split it into two statements also to declare
intent.

CID 1402603..1402724
2019-08-05 15:35:15 +02:00
Carsten Haitzler ce44122f61 elm theme - fix leak in error cse in elm theme mmap set
we don't free the eina file handle on error. coverity found it. fix

fix CID 1402680
2019-08-05 14:28:40 +01:00
Carsten Haitzler 970b620f5a ethumb - make coverity happy by including null char
doesnt cost us much to memcpy the nul byte too to keep coverity happy.

fix CID 1402690
2019-08-05 14:17:33 +01:00
Carsten Haitzler 9ea4bb8fc7 ecore evas drm - fix multi-dlopening of lib into symbol space
only load libglapi once... not multiple times by storing static ptr to
lib handle.

fix CID 1402692
2019-08-05 13:55:38 +01:00
Yeongjong Lee f2b1f312a9 efl_input_key: replace key property name with key_sym
Summary:
Sorry to touch stable eo classes. there is name conflict issue between class and
property when binding language is generated from eo. for example in C#, compiler
error occurs.

```
src/bindings/mono/efl_input_key.eo.cs(272,26): error CS0542:
`Efl.Input.Key.Key': member names cannot be the same as their enclosing type
```

This patch changes Efl.Input.Key.GetKey/SetKey method to
Efl.Input.Key.GetKeySym/SetKeySym and generates Efl.Input.Key.KeySym
property.

Note that CAPI is not changed.

ref T8093

Test Plan: meson setup -Dbindings=mono,cxx -Dmono-beta=true

Reviewers: lauromoura, woohyun, zmike, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8093

Differential Revision: https://phab.enlightenment.org/D9483

zmike note: this class was not released at the point of this patch, the class
was only recently marked as stable
2019-08-05 08:51:22 -04:00
Vincent Torri fb023ee6d2 evil: add mprotect() and fix a bit mmap(). Elm_test is working
Test Plan: compilation aand elm_test working

Reviewers: raster, cedric, zmike

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9493
2019-08-05 08:47:19 -04:00
Marcel Hollerbach 94b05f15e6 efl_ui_spin/button: move from elm_ to efl_ prefixed functions
Summary:
this moves a bunch of api calls from elm_ to efl_. Those calls that are
called on the entry object are still elm, as well as access APIs, they
will have to be moved once efl_ui_text is usable.
Depends on D9475

Reviewers: segfaultxavi, cedric, zmike

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9488
2019-08-05 08:47:00 -04:00
Carsten Haitzler 034ef0badc ecore drm - legacy - fix coverity leak complaint
is real - in error case. fix it to make coverity happy.
fix CID 1402696
2019-08-05 13:44:25 +01:00
Carsten Haitzler ea48df482c ephysics - fix stringshare double del
fix CID 1402707
2019-08-05 13:33:01 +01:00
Hermet Park 8650c7d09d vg json: update missing change in 16d806ff92. 2019-08-05 21:09:14 +09:00
Hermet Park 16d806ff92 vg json: up to date internal reference.
rlottie is not officially released, still it's unstable.
2019-08-05 20:42:26 +09:00
junsu choi 949cf2750b ector_software_rasterizer: Add default value for stroke's miter_limit
Summary:
Currently the default value of miter_limit is defined as 0.
miter_limit should be specified to a value other than 0. becuase it is affected by width.
See below for an explanation of this.
https://www.freetype.org/freetype2/docs/reference/ft2-glyph_stroker.html#ft_stroker_linejoin

There is no particular reason why the default value is 0x4.
It only refers to the standard of web svg.
https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-miterlimit

Test Plan:
   setenv("ECTOR_BACKEND", "default", 1);
   elm_init(argc, argv);
   Evas_Object *win = elm_win_util_standard_add(NULL, "test");
   evas_object_smart_callback_add(win, "delete,request", win_del, 0);
   elm_win_autodel_set(win, 1);
   Evas_Object *bg = elm_bg_add(win);
   elm_bg_color_set(bg, 255,255,255);
   evas_object_size_hint_align_set(bg, EVAS_HINT_FILL, EVAS_HINT_FILL);
   evas_object_size_hint_weight_set(bg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
   evas_object_show(bg);

   Evas *evas = evas_object_evas_get(win);

   Evas_Object *vg = evas_object_vg_add(evas);
   evas_object_show(vg);
   Evas_Object *container = evas_vg_container_add(vg);

   Evas_Object *shape = evas_vg_shape_add(container); //Default is EFL_GFX_JOIN_MITER
   evas_vg_shape_append_rect(shape, 0, 0, 100 , 100, 0, 0);
   evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
   evas_vg_shape_stroke_width_set(shape, 10);
   evas_vg_node_origin_set(shape, 50, 150);

   shape = evas_vg_shape_add(container);
   evas_vg_shape_append_rect(shape, 0, 0, 100 , 100, 0, 0);
   evas_vg_shape_stroke_join_set(shape, EFL_GFX_JOIN_BEVEL);
   evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
   evas_vg_shape_stroke_width_set(shape, 10);
   evas_vg_node_origin_set(shape, 200, 150);

   shape = evas_vg_shape_add(container);
   evas_vg_shape_append_rect(shape, 0, 0, 100 , 100, 0, 0);
   evas_vg_shape_stroke_join_set(shape, EFL_GFX_JOIN_ROUND);
   evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
   evas_vg_shape_stroke_width_set(shape, 10);
   evas_vg_node_origin_set(shape, 350, 150);

   evas_object_vg_root_node_set(vg, container);
   elm_object_content_set(bg, vg);

   elm_win_resize_object_add(win, bg);
   evas_object_resize(win, WIDTH, HEIGHT);
   evas_object_show(win);
   elm_run();
   elm_shutdown();

Reviewers: smohanty, Hermet, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9492
2019-08-05 18:08:50 +09:00
Marcel Hollerbach 7869778d02 efl_ui_spin: move the step implementation to spin_button
having efl_ui_spin implementing efl.ui.range_interactive does not make
sense. Efl.Ui.Spin is a not interactive widget, so it should not
implement that interface.

ref T7897

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9475
2019-08-03 20:40:11 +02:00
Marcel Hollerbach 42bbe0e58f efl_ui_spin_button: fix initial displaying of formatting string
spin_button should also implement formatted_apply, the label has a
different part name then spin.

ref T8097

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9474
2019-08-03 20:40:10 +02:00
Marcel Hollerbach 7558620957 efl_ui_spin_button: stop calling only the parent
if the spin button is skipped the spin is called directly, the label
will display the wrong value.

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9473
2019-08-03 20:40:09 +02:00
Carsten Haitzler db18d67af9 elm toolbar - fix toolbar item separators and refactor aling/fill of item
only set this is one place and thus get it consistent/right for
separators vs other items.

@fix
2019-08-02 17:17:48 +01:00
Carsten Haitzler efd45df1c4 elm toolbar - fix packing options at start to avoid visual layout bugs
i spoetted open moving around and shrinking when it shouldnt -
packging options (fill/align) not always set right. this fixes that.

@fix
2019-08-02 16:41:12 +01:00
Carsten Haitzler d9dbd2fbea ecore evas x and e sync rendering - disable as it's unused
this has been optional and unused by e for a very long time ot try
sync front-buffered software rendering with the wm/compositor. we may
as well remove the bloat that is here that is unused... it's been
inactive for many years anyway.
2019-08-02 16:41:12 +01:00
Xavi Artigas d13c59fb89 mono-docs: Add more event args link for event handlers
There were some events missing <value> tags (see f01b113401)
2019-08-02 17:29:27 +02:00
Xavi Artigas 6764535aae mono-docs: Escape the recently added docs
This is the second time I forget...
2019-08-02 16:15:20 +02:00
Xavi Artigas e4a2e7cb55 mono-docs: Add descriptions to event args
Event args structs had fields without description (missing <value> tag).
2019-08-02 14:03:26 +02:00
Xavi Artigas 3fd5542f6d mono-docs: Proper indentation for previous commit 2019-08-02 13:53:19 +02:00
Xavi Artigas f01b113401 mono-docs: Add event args link for event handlers
For some reason DocFX does not generate links for templated event handlers:
event EventHandler<Efl.Input.IInterfacePointerOutEvt_Args> PointerOutEvt;

After unsuccessfully trying to find out why, this patch adds the link to the
event arguments in a <value> tag, so at least it shows in the documentation
and the reader has somewhere to click to find out what arguments an event
is sending.
2019-08-02 13:49:20 +02:00
Hermet Park 03cb0212ac efl_canvas_rectangle: rendering optmization.
There was a weird profiling result that rectangles drawing is much much slower than images.
Checked reason, the computation rect clip area is the overload point.

I don't think it's necesary but we can simplely improve the performance here
by replacing native function.

I tested this by drawing 400 number of rectangles,
and this patch improved up abt 10 fps(sw), 20fps(gl).

@TEST CODE

   MAX_SIZE = 400;

   for(int i=0; i< MAX_SIZE; i++)
   {
      Evas_Object *rect = evas_object_rectangle_add(layout);

      int x = rand() % WINDOW_WIDTH;
      int y = rand() % WINDOW_HEIGHT;

      evas_object_resize(rect, ELM_SCALE_SIZE(200), ELM_SCALE_SIZE(200));
      evas_object_move(rect, x, y);
      evas_object_color_set(rect, (rand() % 256), (rand() % 256), (rand() % 256), 255);
      evas_object_show(rect);

      Elm_Transit *transit = elm_transit_add();
      elm_transit_object_add(transit, rect);

      int dX = rand() % WINDOW_WIDTH;
      int dY = rand() % WINDOW_HEIGHT;

      elm_transit_effect_translation_add(transit, 0, 0, dX - x, dY - y);
      elm_transit_repeat_times_set(transit, -1);
      elm_transit_duration_set(transit, 1.0);

      elm_transit_go(transit);
   }
2019-08-02 18:27:38 +09:00
Hermet Park 9395a4c33c evas rectangle: code refactoring.
Just removed white spaces, fixed indentation.

No logical changes.
2019-08-02 18:27:27 +09:00
Jaehyun Cho b1e697df1c efl_input_clickable: increase the time interval for repeated counter
Summary:
The repeated counter in Efl.Input.Clickable_Clicked can be used to
identify double click or triple click.

Previously, the repeated counter in Efl.Input.Clickable_Clicked was
calculated within the time interval 0.1 second.

Now, the time interval for the repeated counter is increased to 0.25
second. It seems that 0.25 second is more appropriate to identify if the
two consecutive clicks should be considered together.
(e.g. considered as double click or triple click)
Moreover, in ecore_event and edje, 0.25 second is already used as a time
interval for double click.

Test Plan:
1. Run Efl.Ui.Button in elementary_test
2. Do double click or triple click the buttons

Reviewers: segfaultxavi, bu5hm4n, YOhoho

Reviewed By: segfaultxavi, YOhoho

Subscribers: YOhoho, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9485
2019-08-02 10:50:02 +02:00
Mike Blumenkrantz ded6dc9017 efl_ui/tags: set entry to fill vertically
forgot this in previous patch

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9479
2019-08-01 14:37:10 -07:00
Mike Blumenkrantz b89e7b3500 efl_ui/tags: use user size hints for internal objects
restricted min size hint should only be set by an object's own group_calc
function. all other cases should use regular min size hint

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9477
2019-08-01 14:37:07 -07:00
Mike Blumenkrantz fe849c9666 efl_ui/flow.box: fix item calc with mixed weights
if a box contains an entire row of items with weight(0), and the next
row contains items with weights set, the item count must be correctly
incremented so that the box uses the right items in its calculations

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9480
2019-08-01 14:37:05 -07:00
Vincent Torri 085de22d42 examples: cast to uintptr_t instead of long
on Windows, long is a 32 bits type

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9470
2019-08-01 14:37:02 -07:00
Marcel Hollerbach 4f45749b14 efl_ui_position_manager: add event for updating the range
the new event can be used to message back the currently visible range
from the position to the collection / collection_view.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9462
2019-08-01 14:36:59 -07:00
Marcel Hollerbach 1c916714f0 spinner_example: migrate it to efl::ui::spin_button
we should do that more often, that shows issues.
Right now there seems to be an issue with accessors in cxx, something is
freeing the accessor twice. So this feature is disabled right now.

ref T8100

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9471
2019-08-01 14:36:56 -07:00
Marcel Hollerbach fd860eb6e8 efl_ui_spin_button: rename circulate to wraparound
ref T8097

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9461
2019-08-01 14:36:53 -07:00
Marcel Hollerbach bd8fcab8b2 efl_ui_spec: add a test suite for the steady event
this checks that the steady event is correctly emitted after some time.
Right now this test does notthing for EFL_UI_SPIN_CLASS. Reason for this
is that Spin is not interactive, even if it implements the interface for
it. Maybe something we should resolve in future.

ref T7894

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9460
2019-08-01 14:36:50 -07:00
Marcel Hollerbach 45b763a2dc efl_ui_spin_button: use the newly emitted event from range_interactive
this event is not also in range_interactive, so better use this.

ref T8097

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9459
2019-08-01 14:36:48 -07:00
Marcel Hollerbach 010f813572 efl_ui_range_interactive: add a new event
the steady event from slider now moved here. A spec test suite and the
corresponding implementations will follow.

ref T7894

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D9458
2019-08-01 14:36:45 -07:00
Lauro Moura ca813f41a6 csharp: Add a documentation_string generator
Summary:
Escapes a single string, without leading `///`

Depends on D9481

Reviewers: segfaultxavi, felipealmeida

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9482
2019-08-01 21:12:36 +02:00
Lauro Moura becef7aee4 csharp: Avoid generating empty <value> tags
Depends on D9478

Reviewers: segfaultxavi, felipealmeida

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9481
2019-08-01 21:12:36 +02:00
Xavi Artigas 44e0027338 mono-docs: Add misc struct docs
Summary:
Structs have a convenience constructor which was missing parameter documentation.
Struct fields need a <value> tag or there is a hole in the generated docs.
The documentation for the type of the field has been used, when available.

Test Plan: Build docs and look at generated pages for structs.

Reviewers: lauromoura, vitor.sousa, felipealmeida

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9478
2019-08-01 21:12:36 +02:00
Daekwang Ryu cf818a84be evas_gl: implement EvasGL ES 3.2
add a wrapper function for glFramebufferTexture.
some bugs were fixed.
I tested on Ubuntu 14.04(x64) and nVidia 375 driver with VK-GL-CTS

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D4831
2019-08-01 10:42:55 -07:00
Daniel Kolesa 1c5fa59ee8 eolian: remove __builtin_free_cb
This has long been unused. If we need to replace this eventually,
it should be done correctly.
2019-08-01 16:55:31 +02:00
Daniel Kolesa 1bcca58d82 eolian: disallow ptr() in containers in stable API 2019-08-01 16:55:31 +02:00
Christopher Michael adaea4170a tests/ecore_wl2: Add test for ecore_wl2_input_name_get
ref T8016
2019-08-01 09:04:09 -04:00
Christopher Michael 2c4b26ef4e tests/ecore_wl2: Add test for ecore_wl2_input_keymap_get
ref T8016
2019-08-01 08:59:26 -04:00
Christopher Michael f15ca5e227 tests/ecore_wl2: Add test for ecore_wl2_input_display_get function
ref T8016
2019-08-01 08:56:42 -04:00
Christopher Michael f166cf3741 tests/ecore_wl2: Add test for ecore_wl2_input_seat_id_get function
ref T8016
2019-08-01 08:53:45 -04:00
Christopher Michael f481b6acf1 tests/ecore_wl2: Fix assert tests for some window functions
ref T8016
2019-08-01 08:53:21 -04:00
Christopher Michael 34514ccf58 tests/ecore_wl2: Add start of Ecore_Wl2_Input API tests
ref T8016
2019-08-01 08:41:07 -04:00
Christopher Michael a7971f409d efl_ui_collection: Mark unused parameter
double align is actually unused in this function, so mark it as such
2019-08-01 08:32:42 -04:00
Xavi Artigas 84601549e8 eolian_mono: Fix whitespace in generated cs files
Pet peeve of mine.
2019-08-01 13:28:26 +02:00
Marcel Hollerbach d671c7e42b fix warning 2019-08-01 11:41:30 +02:00
Marcel Hollerbach 7610920ed0 elementary_test: add a test to show our frame widget
it does not work yet, but we at least have the chance of seeing it.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9194
2019-08-01 11:41:30 +02:00
WooHyun Jung d02a3ecb66 efl_input_clickable: add longpress_abort
Now, a specific class which uses efl_input_clickable_util is able
to cancel ongoing longpress event by calling longpress_abort.

This commit shows how efl_ui_text uses longpress_abort to satisfy
its own longpress use case

ref T7847

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9455
2019-08-01 11:33:03 +02:00
WooHyun Jung d2f7bacc2c efl_ui_clickable_util: remove efl_input_processed_set
Summary:
efl_input_processed_set needs to be used only when specific
event marks that it is monopolizing current user interaction.
(such as scrolling).
But, press event or unpress event looks not that proper.

Reviewers: bu5hm4n, Jaehyun_Cho

Reviewed By: bu5hm4n, Jaehyun_Cho

Subscribers: AbdullehGhujeh, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9454
2019-08-01 17:19:16 +09:00
Marcel Hollerbach d98d434e56 efl_ui_position_manager: move from accessor to function callback
this commit enables access to the item structure of the collection via a
function callback. The function callback now enables batching for items,
which does not pay off right now. However, a few more optimizations can
be done in order to get the whole payoff.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9445
2019-07-31 15:51:48 -07:00
Felipe Magno de Almeida 69975fc72d eolian-cxx: Add special type tags to make function_wrapper specializations unique
Reviewers: lauromoura, bu5hm4n, woohyun

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9469
2019-07-31 18:38:59 -03:00
Felipe Magno de Almeida dccd68491c eolian-cxx: Generate eot files
Summary:
Eolian Type files were not being generated, which made some template
specialization to not be defined, for example for function_wrappers.

Reviewers: bu5hm4n, woohyun, lauromoura

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9468
2019-07-31 18:38:02 -03:00
Mike Blumenkrantz eb938f8a88 efl_ui/win: use efl_ui_image internally for non-legacy widgets
switch to using a fully non-legacy widget when this is not being created
with elm_win_add

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9466
2019-07-31 14:00:18 -07:00
Mike Blumenkrantz 02f1ce8d54 elm/colorselector: go back to using elm_box internally
legacy widgets should not use efl_ui widgets internally and vice versa

reverts b11f371703

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9465
2019-07-31 14:00:15 -07:00
Mike Blumenkrantz 407a0aa367 elm/colorselector: directly use smart callback api here
this is not a mixed legacy+unified widget, so we don't need to use
efl api here

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9464
2019-07-31 14:00:13 -07:00
Mike Blumenkrantz dd11dadfef efl_ui/tags: use flow box internally
the existing layout code here is basically just a flow box, so use that
instead to avoid mixing legacy widgets in unified ones

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9463
2019-07-31 14:00:11 -07:00
Ali Alzyod 32cffb4494 evas_textblock: change font-size/font-family only using EFL.Text.Font Interface
Currently:
User cannot change font size only, he needs to set both font and font size with (**efl_text_font_font_set**)
To change size only, you need to make two calls, one to get font (**efl_text_font_font_get**) , then pass it again with new size to (**efl_text_font_font_set**).

New Behaviour:
If user want to change size only, then he passes NULL as font argument to keep same font.
If user want to change font only, then he passes 0 as font-size argument, to keep same font-size.

Notes:
This is not best solution, but it better than current behaviour.
I think best solution to have separate function to set font size, but It might break current api or duplicate functions.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9158
2019-07-31 10:54:55 -07:00
Marcel Hollerbach 6d0f514126 efl_ui_check/radio: use clickable
Summary:
with this commit the state of the check / radio buttons are changes when
the Widget is clicked. The Widget is now using clickable and emits all
the events.

ref T7865

Reviewers: segfaultxavi, zmike, Jaehyun_Cho, woohyun

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7865

Differential Revision: https://phab.enlightenment.org/D9456
2019-07-31 09:12:07 -04:00
Carsten Haitzler 79d3748557 evas events - fix segv if pointer data is freed by cb
callback can free what is in context. avoid that problem

@fix
2019-07-31 14:05:55 +01:00
Xavi Artigas 16866e4ef2 Efl.Composite_Model: Improve docs. 2019-07-31 14:24:53 +02:00
Woochanlee 740b91c9de ecore_wl2: Changed log macro ERR->EINA_LOG_ERR.
Summary:
When the ecore_wl2_shutdown() calling without ecore_wl2_init().

It makes crash.

Reviewers: eagleeye, devilhorns

Reviewed By: devilhorns

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9452
2019-07-31 07:34:56 -04:00
Xavi Artigas 359a118cda Efl.Ui.Spin: Remove mouse wheel interaction
This widget is now meant as a base class for other widgets, with very limited
user interaction. Efl.Ui.Spin_Button already takes care of mouse wheel events.

Ref T7897

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9453
2019-07-31 12:44:31 +02:00
Jaehyun Cho b218dcbc3f efl_ui_spotlight: pop() unpacks content although there is one content
Previously, pop() does not unpack content if there is one content.

Now, pop() unpacks content without transition if there is one content.
Since there is no transition, NULL future is returned.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9450
2019-07-31 12:21:06 +02:00
Carsten Haitzler 8dbdcff3cb Revert "edje/calc: clamp part calc size to 0"
This reverts commit 895ffd93cc.

This commit broke E's widget toolbars that only had text - so many
config dialogs broke. too simple to fix - it's a wrong premise to
begin with it would seem.
2019-07-31 10:17:06 +01:00
Marcel Hollerbach 1e363538b3 slider_cxx: fix casting
this object now needs to be casted, in order to have the event
available.
2019-07-31 10:57:26 +02:00
Marcel Hollerbach f00e24de29 efl_pan: improve docs
Summary: documentation now reflects what is happening in the functions

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8863
2019-07-31 10:50:14 +02:00
Marcel Hollerbach 14ff010601 efl_ui_spec: add test suite for range_display events
Summary:
this test case ensures the correct emittation of the newly added events.

ref T7895
Depends on D9372

Reviewers: segfaultxavi, zmike, woohyun, cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7895

Differential Revision: https://phab.enlightenment.org/D9373
2019-07-31 10:18:20 +02:00
Marcel Hollerbach 8f7fa82244 efl_ui_*: add the new events to the widgets
previous commit introduced new events to range_display. This commit
ensures correct emittation of those events.

ref T7895

Differential Revision: https://phab.enlightenment.org/D9372
2019-07-31 10:18:20 +02:00
Marcel Hollerbach c0082b1c71 efl_ui_range_display: move events from spin
we concluded min,reached and max,reached should be on every widget that
implements range_display. This here is the start of that work, the
events are moved, next commit fixes all widgets, the last commits
enables tests in the spec unit test.

ref T7897
ref T7895

Differential Revision: https://phab.enlightenment.org/D9371
2019-07-31 10:18:20 +02:00
Marcel Hollerbach 911eab3420 efl_ui_item: remove sizing eval code
i do not know why this code is there. But the same code is called in
layout itself, additionally this results in way less calls for
calculating the minsize (Not sure why).

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9425
2019-07-31 08:42:09 +02:00
Jaehyun Cho 959c68ca2e efl_ui_spotlight: add scroll_block to Manager_Scroll
To support blocking of scrolling movement, @property scroll_block has
been added to Manager_Scroll.
If scroll_block is set to be true, then scrolling movement by mouse
input is blocked.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9444
2019-07-31 08:42:08 +02:00
Hermet Park e092878d11 vg json: --log level
Vector needs to try load a lottie file in a brutal force way,
If the input source is not identified.
2019-07-31 15:12:19 +09:00
Lauro Moura 119d26f43f csharp: Add EFL_BETA guards around new test
Summary:
The test method is not generated when beta is disabled as
`Eina.Value_Type` is marked @beta and eolian complains if we try to use
it.

Other `Eina.Value` methods work despite `Eina.Value` also being beta due
to its usage as stable through the keyword `any_value[_ptr]`.

Reviewers: vitor.sousa, bu5hm4n, felipealmeida

Reviewed By: vitor.sousa

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9449
2019-07-30 17:57:24 -03:00
Lauro Moura d0e10dd273 ecore: Fix download test.
Summary:
After ecore_main_loop_quit() changes, calling it from outside the main
loop does not make the next iteration of the main loop quit, causing the
original version of the test to deadlock.

Also update the function documentation about it.

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, felipealmeida, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9448
2019-07-30 15:22:03 -04:00
Mike Blumenkrantz c594c83a02 efl_ui/layout: use MAX macro for min size clamping in group calc
Summary: Depends on D9442

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9447
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz d17ec12faf efl_ui: always set restricted_min size hints internally
Summary:
regular min size hint is for users, internal calcs should use restricted

@fix

Depends on D9441

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9442
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz 872d43f0a0 elm_layout: move elm_layout_sizing_restricted_eval to layout mixin
Summary:
this function should never need to be called on new widgets

Depends on D9440

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9441
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz 4d79efce64 elm_layout: create a mixin to provide elm_layout_sizing_eval
Summary:
this removes elm_layout_sizing_eval entirely from the implementation
hierarchy of any efl_ui-based widgets, ensuring that future code will
correctly use efl_canvas_group functionality

Depends on D9439

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9440
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz 7e517e2a11 elm/efl_ui: remove elm_layout_sizing_eval implementations
Summary:
historically there have been two methods of calculating sizes in elm:
* elm_layout_sizing_eval
* evas_object_smart_calculate (now efl_canvas_group_calculate)

the former was used to set size hints on widgets, while the latter was
used to perform internal size calcs for the widget. for things to
work correctly, these functions had to be triggered in just the right
order at just the right time. many hard-to-fix bugs related to widget
sizing over the years have been the result of this split

this patch removes elm_layout_sizing_eval implementations so that all
widgets perform both internal size calcs and size hint setting all
in the same function, ensuring that these are always in sync

the result is that in the vast majority of cases, far fewer recalcs
happen for widgets, and they are quicker to achieve their final size

Depends on D9438

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9439
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz 586f41f927 efl_ui/layout_base: add subobjs_calc internal functionality
Summary:
this functionality forces group_calc on a layout's subobjects during
layout group_calc so that the layout's own group_calc will yield consistent
and correct results

currently this is only used in panel widgets

Depends on D9437

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9438
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz e583eba56b efl_ui/layout_base: add "finger_size_multiplier" property
Summary:
this feature is set on objects which inherit from layout_base in order to
allow automatically application of variable finger sizes based on a
widget's needs

an example of this would be a calendar, which is 7:8 fingers

this functionality is disabled by passing 0,0 as the property

@feature

Depends on D9436

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9437
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz 46cf288d32 efl_ui/layout: implement group_calc, add finger size for inherited layouts
Summary:
this adds a group_calc implementation for the layout object (not layout_base)
to allow differentiation between inherited layout calcs and layout object
calcs

by using this, we can automatically apply finger size to inherited layout
calcs if the implementation ever reaches this point

Depends on D9435

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9436
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz 268d06d381 efl_ui/layout: use min size hints when calculating layout size
Summary:
for legacy layouts, all min size hints should be considered when performing
size calculations

for non-legacy layouts, only "user" min size hints should be considered, as we
are calculating the restricted min size hint in this function

Depends on D9434

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9435
2019-07-30 13:12:52 -04:00
Mike Blumenkrantz adc510f9ee efl_ui: change calls to elm_layout_sizing_eval to efl_canvas_group_change
Summary:
elm_layout_sizing_eval is a legacy function which should not need to be called
on new widgets

Reviewers: segfaultxavi, bu5hm4n

Reviewed By: bu5hm4n

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9434
2019-07-30 13:12:52 -04:00
Marcel Hollerbach 6883087ac7 Revert "evas_object_textblock: add support for variation sequences"
This reverts commit f7ce771e32.
2019-07-30 19:09:12 +02:00
Lauro Moura 29d24aa409 csharp: Add marshal support for Eina.ValueType
Summary:
It uses a custom marshaler and a helper boxing class to convert between
the managed enum values and the native Eina_Value_Type pointers.

To be used by future MVVM machinery.

Reviewers: vitor.sousa, felipealmeida

Reviewed By: vitor.sousa

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9443
2019-07-30 11:47:07 -03:00
Daniel Kolesa 1530d0386c eolian_gen: generate freefuncs for strbuf/binbuf 2019-07-30 15:57:52 +02:00
Daniel Kolesa a17d3300bd eolian: make strbuf ownable 2019-07-30 15:57:52 +02:00
Xavi Artigas 25324500e4 Fix typo in Efl prefix
This annoyed me far far far more than it should.
2019-07-30 15:36:32 +02:00
Mike Blumenkrantz 895ffd93cc edje/calc: clamp part calc size to 0
this could previously have been negative

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9431
2019-07-29 11:17:51 -07:00
Mike Blumenkrantz 36ff0a012c elm/config: fix config usage with EFL_RUN_IN_TREE set
when running in tree, elm_config should not attempt to access files
outside the tree, nor should it attempt to overwrite any existing config
files

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9433
2019-07-29 11:17:49 -07:00
Mike Blumenkrantz b561e9632e elm/config: monitor MODIFIED events on config files
eio/inotify now receives these events when the config file is modified,
even though the file is copied onto that location. this fixes config
updating at runtime

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9432
2019-07-29 11:17:46 -07:00
Marcel Hollerbach 2057957d21 efl_ui_pan: emit position changed when content is resized
even if the position is not really changed here, the min / max relation
has changed. If we do not emit this event here, every user (that
calculates a relative position) would have to monitor the pan position
and the size of the content. This simplifies the given usecase, and
fixes the scroller position when new items are added to the collection.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9411
2019-07-29 11:17:44 -07:00
Marcel Hollerbach 764f35b7a3 elm_test: add a example that shows efl_ui_item instances
this is just a little showcase to show the possible items

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9430
2019-07-29 11:17:42 -07:00
Mike Blumenkrantz 7f2ce2f99a elm_test: add option for running all tests on startup
this is useful for doing quick testing when making invasive changes that
affect a large number of widgets, such as rewriting all sizing calc code

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9407
2019-07-29 11:17:40 -07:00
Mike Blumenkrantz 44ff1e73bb efl_ui/popup: unset callbacks on win object when parent is removed
these callbacks must be removed if there is no parent, otherwise they
may trigger once the widget is deleted and trigger invalid object access

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9429
2019-07-29 11:17:37 -07:00
Ali Alzyod f7ce771e32 evas_object_textblock: add support for variation sequences
update font processing to handle variation sequences unicodes to select proper glypg in respect to variation seqences

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9053
2019-07-29 11:17:35 -07:00
Lauro Moura 7927023fc7 pyolian: Fix tests
Summary: Update tests after some legacy cleanup from last release.

Reviewers: bu5hm4n, DaveMDS, segfaultxavi

Reviewed By: DaveMDS

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8817
2019-07-29 11:39:10 -03:00
Marcel Hollerbach 0ab05a8271 efl_ui_item: try to improve docs
its everything but perfect, but a start ...

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9424
2019-07-29 16:32:06 +02:00
Marcel Hollerbach 44a45e3aca efl_ui_item: migrate to Efl.Ui.Clickable
this adds the mixin to the item. With this commit every class inheriting
from Efl.Ui.Item will automatically emit all the clickable events.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D8830
2019-07-29 16:32:05 +02:00
Mike Blumenkrantz a61cef3fb2 efl_ui/popup: implement efl.file.unload for popup backwall part
this fixes unsetting images for popup backwall

@fix

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9415
2019-07-29 16:21:12 +02:00
Mike Blumenkrantz a247bd0f56 efl_ui/popup: use correct class when setting popup backwall file
MY_CLASS failure strikes again

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9416
2019-07-29 16:21:11 +02:00
Marcel Hollerbach b4f5b78550 efl_ui_item: remove self field
Summary:
there is no reason to have this field, pd of a item is always passed
with the object.

Reviewers: segfaultxavi, zmike, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9423
2019-07-29 16:09:14 +02:00
Mike Blumenkrantz d01885ec8b elm_test: add keybinds to rapidly flip between tests
when not using --test-win-only, allow opening new tests forward and
backward with alt+. and alt+,

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9406
2019-07-29 16:06:22 +02:00
Mike Blumenkrantz e1f2b9d235 elm_test: replace bespoke arg handling with a for loop
this fixes handling of --help regardless of its position in the arg array

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9405
2019-07-29 16:06:21 +02:00
Mike Blumenkrantz e0ae3a9a76 efl_ui/widget: check legacy type on correct object for scroll_hold push/pop
too much copy/paste

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9399
2019-07-29 16:06:20 +02:00
Mike Blumenkrantz 62d4d4c5b8 elm/ctxpopup: check list existence before trying to delete list items
this is kinda gross, but if the list is already deleted then the list
items are also gone and this is an invalid object access

@fix

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9402
2019-07-29 16:06:19 +02:00
Mike Blumenkrantz b1986363db tests/elm: move efl_config tests to efl_ui_suite
these invoke non-legacy codepaths which should never be triggered during
legacy unit tests

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9403
2019-07-29 16:06:18 +02:00
Mike Blumenkrantz b9648605e8 tests/elm: add test for ctxpopup sizing
verify that size hints of content are being respected

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9404
2019-07-29 16:06:17 +02:00
Mike Blumenkrantz 7827381221 elm_test/modal_win: handle case where test is not passed the main window
Summary:
this test is not runnable when it is not triggered directly from pressing
a button in the main window

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: devilhorns, bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9401
2019-07-29 09:17:20 -04:00
Ali Alzyod 0bab8be791 evas_textblock: markup: handle invalid/missing escape characters
Summary:
T8088

if escape character sequence not found for example **&123;** :
* (Old Behaviour)  : Draw nothing
* (New Behaviour)  : Draw Text like it plain text

I think this is the right behaviour since:
1- We print output as it is, so user can detect what was the problem.
   For example user write &gf; (by mistake, he wanted to write &gt;)
   == if we nothing is printed he would not know exactly where is the real problem.
      it can be font file, textblock is not visible, he may think bug in efl
   == if we printed &gf; as it is, it will direclty show that this is not valid escape char.
2- If user made mistake in text, it is better to show it instead of hide it, maybe there are new sequences that we do not know about.

This behaviour was checked on multible systems:
1- Web Browsers like chrome
2- Qt
3- Android

They all have same as our new behaviour

Example :
markup text =  "&gt;&gf;
Old              :     >
New            :     >&gf;

Test Plan:
```
#define EFL_EO_API_SUPPORT 1
#define EFL_BETA_API_SUPPORT 1

#include <Eina.h>
#include <Elementary.h>
#include <Efl_Ui.h>

static void
_gui_quit_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
{
   efl_exit(0);
}

static void
_gui_setup()
{
   Eo *win, *box;

   win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
                 efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
                 efl_text_set(efl_added, "Hello World"),
                 efl_ui_win_autodel_set(efl_added, EINA_TRUE));

   // when the user clicks "close" on a window there is a request to delete
   efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, _gui_quit_cb, NULL);

   box = efl_add(EFL_UI_BOX_CLASS, win,
                efl_content_set(win, efl_added),
                efl_gfx_hint_size_min_set(efl_added, EINA_SIZE2D(360, 240)));

   efl_add(EFL_UI_TEXT_CLASS, box,
           efl_text_markup_set(efl_added,
           "&gt;&gf;"),
           efl_text_interactive_selection_allowed_set(efl_added, EINA_FALSE),
           efl_gfx_hint_weight_set(efl_added, 1.0, 0.9),
           efl_gfx_hint_align_set(efl_added, 0.5, 0.5),
           efl_text_multiline_set(efl_added,EINA_FALSE),
           efl_pack(box, efl_added));

   efl_add(EFL_UI_BUTTON_CLASS, box,
           efl_text_set(efl_added, "Quit"),
           efl_gfx_hint_weight_set(efl_added, 1.0, 0.1),
           efl_pack(box, efl_added),
           efl_event_callback_add(efl_added, EFL_UI_EVENT_CLICKED,
                                  _gui_quit_cb, efl_added));
}

EAPI_MAIN void
efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
   _gui_setup();
}
EFL_MAIN()
```

Reviewers: woohyun, bowonryu, segfaultxavi, bu5hm4n

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9428
2019-07-29 14:09:32 +02:00
Mike Blumenkrantz 444a068c05 elm_test: fix anchor popup test
Summary:
this group name was wrongly changed by sed

ref d4526f44b8

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9419
2019-07-29 12:31:59 +02:00
Xavi Artigas ef235c43c8 Fix build break
Caused by 1c0a459293
I should have been more careful before approving, my bad.
2019-07-29 12:23:18 +02:00
Ali Alzyod 1c0a459293 efl_gfx_color: fix color_code_set
Summary:
There are two parts for this patch:
1- Fix sigmentation fault when using (efl_gfx_color_color_code_set).  // It try to modify const variable
2- Remove unnecessary code. // why would user pass slash or back slash as color code format.

Test Plan:
```
#define EFL_EO_API_SUPPORT 1
#define EFL_BETA_API_SUPPORT 1

#include <Eina.h>
#include <Elementary.h>
#include <Efl_Ui.h>

static void
_gui_quit_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
{
   efl_exit(0);
}

static void
_gui_setup()
{
   Eo *win, *rect;

   win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
                 efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
                 efl_text_set(efl_added, "Hello World"),
                 efl_ui_win_autodel_set(efl_added, EINA_TRUE));

   // when the user clicks "close" on a window there is a request to delete
   efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, _gui_quit_cb, NULL);
   rect = efl_add(EFL_CANVAS_RECTANGLE_CLASS,win);
   const char *color = "#FF0000FF";
   efl_gfx_color_code_set(rect,color);
   evas_object_resize(rect,250,250);
   evas_object_resize(win,250,250);
   evas_object_move(rect,0,0);
   evas_object_show(rect);
   evas_object_show(win);
}

EAPI_MAIN void
efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
   _gui_setup();
}
EFL_MAIN()
```

Reviewers: zmike, cedric, segfaultxavi, woohyun

Reviewed By: segfaultxavi

Subscribers: singh.amitesh, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9422
2019-07-29 12:10:25 +02:00
WooHyun Jung 77e268e6ab efl_input_clickable: rename efl_ui_clickable to efl_input_clickable
Summary:
Renamed all efl_ui_clickable_XXX to efl_input_clickable_XXX based on
the discussion in T7847

ref T7847 T7976

Reviewers: zmike, bu5hm4n, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7976, T7847

Differential Revision: https://phab.enlightenment.org/D9427
2019-07-29 11:43:01 +02:00
Carsten Haitzler 9b294d6284 eina file - stat generation inexactness support
this is a performance optimization. it brings in a "stat generation".
for now it's disabled by default so we retain previous behavior. this
stops eina file from opening and stating a file every time you open
... it only does it if stat generation is off, or, if the generation
changed since the last time it opened that file. this makes cache hits
not have a 3 syscall cost (open+fstat+close). this optimizes that
lower end of things path. but .. it comes at a cost. if the file
changes before generation ticks over (which this forces to tick over
every time the loop exits idle by default).

now here is something to ask.

1. should we have this on by default and accept the "inexactness"
since you can eina_file_statgen_next() before any call that would do
i/o to force it to look at the real file stat info...
2. should we tick over every idle enter OR every N idle enters  or
every frame we render instead? ... i want to avoid getting a timestamp
or having a timer interrupt often... so what should we do?

at least this introduces the idea, some api's and an env var to turn
this on. it definitely cuts down syscalls during things like creation
of widdgets or objects in large batches etc.
2019-07-28 11:51:15 +01:00
Carsten Haitzler 0ff42fa4e5 elm test - set var to null to avoid warning 2019-07-28 11:40:18 +01:00
Carsten Haitzler 4d27f5f63e warning - move break in switch to handle properly and addess warning 2019-07-28 11:37:23 +01:00
Carsten Haitzler 188874e289 examples - use putenv, not setenv for porting reasons
putenv is more portable than setenv, so usethat instead. this nukes
warnings on windows as evil is meant to go private and you thus have no
setenv anymore.
2019-07-28 11:17:51 +01:00
Carsten Haitzler 5fd272d038 filesel example - add locale.h include since we use setlocale 2019-07-28 10:33:07 +01:00
Carsten Haitzler 508c2954f3 ecore win32 - disable #warning because all it does is fill build logs
we see it 100's of times during build. disabling this. the comments
etc. are still there, but more value in commenting out than keeping it
so we can see the forest from the trees.
2019-07-28 10:29:52 +01:00
Vincent Torri 5b51a6bb20 Eio: enable eio_file_chown if chown is available on the platform
Test Plan: compilation on Windows

Reviewers: zmike, raster, cedric

Reviewed By: raster

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9393
2019-07-28 09:38:26 +01:00
Vincent Torri a6ade14c5e Evil: remove pwd code in Evil and fix compilation failures after the removal
Summary: remove pwd code in Evil

Test Plan: compilation

Reviewers: zmike, cedric, raster

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9420
2019-07-28 09:27:27 +01:00
Vincent Torri 04848c98f2 Eina: define EINA_HAVE_DEBUG_THREADS only if backtrace() in execinfo.h is available
Summary: fix compilation on systems where backtrace() in execinfo.h is not available

Test Plan: compilation on Windows

Reviewers: zmike, cedric, raster

Reviewed By: cedric, raster

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9392
2019-07-28 09:21:53 +01:00
Xavi Artigas bc955f35bb Rename Efl.Gfx.Image.Stretch_Region -> Efl.Gfx.Image_Stretch_Region
Otherwise we have a symbol <-> namespace clash. Again.
2019-07-26 22:35:40 +02:00
Yeongjong Lee 41aa680c85 efl_mono: update docs of CreateWrapperFor
Reviewers: lauromoura, felipealmeida, segfaultxavi, vitor.sousa

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9084
2019-07-26 20:51:46 +02:00
Vitor Sousa 8d1bd770df csharp: fix EFL# by updating it to reflect the newest changes in Eolian
Summary:
`Efl.Event` became a builtin type that is no longer declared in `efl_object.eo`,
and therefore it is no longer automatically generated in EFL#.
Given that, we define a struct manually to reflect the memory layout of the
native struct.

Containers of value types are now allowed in eolian, so tests that were disabled
because of the restriction on `ptr` were re-enabled using the plain type.

But since these containers have just arrived, handling of ownership for value
types is currently undefined in bindings.
Hence, tests that used `ptr(int) @owned` as elements were left disable.
This will be solved in a future patch.

`void_pr` is now deprecated, so we remove it from tests also.

Reviewers: q66, segfaultxavi, lauromoura, felipealmeida

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9417
2019-07-26 15:47:33 -03:00
Mike Blumenkrantz 44dbf5c22a efl_ui/datepicker: adjust datepicker minimum limits
Summary:
this whole thing seems pretty busted but at least now it won't error and
break elm_test

t.tm_mday is 0 when the function in the macro returns, so this value needs
to be clamped like the others

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9398
2019-07-26 17:00:06 +02:00
Felipe Magno de Almeida 8377ea20a0 efl-js: Remove private keys for Twitter API from example
Summary: For security concerns we removed the secret keys which could be used improperly by the wrong people.

Reviewers: woohyun, cedric, lauromoura

Reviewed By: lauromoura

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9377
2019-07-26 14:59:29 +02:00
Daniel Kolesa 1a95e87f58 eolian: fix tests after latest restrictions 2019-07-26 14:39:38 +02:00
Daniel Kolesa 1348569bfa eolian: allow value types in owning containers (list/array/etc) 2019-07-26 14:13:50 +02:00
Daniel Kolesa 0259f98472 eolian: also ban underscore prefixed builtins in stable API 2019-07-26 13:38:01 +02:00
Daniel Kolesa 635a2df7e7 eolian: ban void_ptr in stable APIs
This required some refactoring in eldbus and tests but otherwise
seems good to go.
2019-07-26 13:35:27 +02:00
Daniel Kolesa d964a04da1 eo: remove Efl_Event definition (replace with builtin) 2019-07-26 13:21:14 +02:00
Felipe Magno de Almeida f230dc9dbc eolian-cxx: Add binbuf and event keywords handling
n

Summary:
Add support in Eolian-Cxx for binbuf and event keywords and tests. It
will generate the C type while the manual binding in C++ for the types
do not exist.

Reviewers: q66, lauromoura

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9412
2019-07-26 13:02:28 +02:00
Carsten Haitzler d19e435ff9 reduce syscalls on opening files - roll CLOEXEC into open
on linux open supports() O_CLOEXEC. add test case for this in meson
build and ifdef. this rolls 3 syscalls into 1 as we were doing open,
then fnctl to get and fcntl to set flags.

less syscalls is a good thing as syscalls are not cheap on some
architectures or systems. I've seen a syscall on 1 system take 2-3x
as long as another and another syscall in the same 2 system
comparison take 10x as long. depending on the syscall you may only
have a budget of something like 5000 syscalls "per frame" (60fps)
before you spend all of your frame time just in syscalls not
doing any processing, so we should keep these down if possible
and that is what this does.
2019-07-26 11:43:17 +01:00
Hermet Park 24a49c8938 ecore_evas: prevent double free evas.
When user manually free the ecore evas,
it could delete evas internally,
then evas_invalidate would be triggered,
invalidate callback would try free evas again,
this causes double free evas.

TEST SCENARIO:
   ee = ecore_evas_new(...);
   ...
   ecore_evas_free(ee);
      -> free evas
         -> invalidated cb
            -> free evas (**double free)

This is a regression bug by 5847886a3f
2019-07-26 16:54:31 +09:00
Xavi Artigas e40f666807 Efl.Ui.Text: Minor tweaks on the documentation. 2019-07-26 09:48:16 +02:00
Taehyub Kim e1e4f90446 Efl.Gfx.Hint_Align: add define values for Efl.Gfx.Hint_Align
Summary:
Add define values for Efl.Gfx.Hint_Align
 - Efl.Gfx.Hint_Align_Left
 - Efl.Gfx.Hint_Align_Right
 - Efl.Gfx.Hint_Align_Top
 - Efl.Gfx.Hint_Align_Bottom
 - Efl.Gfx.Hint_Align_Center

Reviewers: bu5hm4n, Jaehyun_Cho, woohyun, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9413
2019-07-26 09:07:41 +02:00
junsu choi 3210fa3d69 ector: Prevent access to NULL buffer in software rasterizer
Summary:
Prevents a crash caused by a null pointer exception
when ector surface buffer is NULL.

Test Plan: N/A

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9390
2019-07-26 13:12:48 +09:00
Cedric BAIL f66844ebbf elementary: use data:null to remove unecessary structure declaration.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9389
2019-07-25 21:03:11 +02:00
Mike Blumenkrantz 880296bb7d elm_test/plug: fix error handling
Summary:
if plug connection fails, a notification can't always be created because
there may be no object passed to this function to create a notify object on

@fix

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9400
2019-07-25 14:46:58 -04:00
Mike Blumenkrantz 485d2e37d8 elm/glview: fix glview to (again) return null if context creation fails
Summary:
engine internals have changed, so it's necessary to actually check whether
the glview api is available now to determine whether the glview is viable

@fix

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9397
2019-07-25 14:46:58 -04:00
Mike Blumenkrantz 6c93461324 efl_ui/timepicker: fix range clamping on 12 hour timepickers
Summary: this errors all the time otherwise

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: devilhorns, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9396
2019-07-25 14:46:58 -04:00
Marcel Hollerbach e3557ec944 efl_ui_spotlight_manager_*: cleanup canvas state on invalidate
this is needed so we can support a empty object which is not freed.
Sounds useless, but required by bindings, this fixes the issue described
in D9300.

Differential Revision: https://phab.enlightenment.org/D9306
2019-07-25 20:42:39 +02:00
Marcel Hollerbach 2a970046bc efl_ui_spotlight_container: mirror the behavior of view_manager
setting the parent here is usefull, as we can forgot about this object
then, and do not have to free the object by hand.

Differential Revision: https://phab.enlightenment.org/D9305
2019-07-25 20:42:39 +02:00
Marcel Hollerbach 6d0b0baf9b efl_ui_spotlight_container: fix ownership behavior of view_manager
view_manager is a property that takes ownership of the view_manager
object. We are setting the parent in the setter which means, we should
actaully have one ref to the parent, and one from the caller, so we need
to unref one.

Differential Revision: https://phab.enlightenment.org/D9304
2019-07-25 20:42:38 +02:00
SangHyeon Jade Lee 670b7b4a83 efl_ui : apply item part visible signal properly.
efl_layout_signal is being overrided by efl_ui_layout,
so do not call the signal emit on resize object directly,
call the signal emit on the item widget.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9233
2019-07-25 20:27:42 +02:00
Marcel Hollerbach 18c7a90f7a rename Item_Container -> Collection
this is the last bit of renaming

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9410
2019-07-25 20:27:41 +02:00
Marcel Hollerbach 257b30f9de efl_ui_spec_suite: simplify this
when i initially added item_container to the spec test suite, there was
no plan to make Efl.Ui.List / Efl.Ui.Grid like it is now. However, now
we can simply use Efl.Ui.List and Grid instead of this helper class.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9409
2019-07-25 20:27:40 +02:00
Marcel Hollerbach a4f7baa911 rename efl_ui_item_container -> efl_ui_collection
this is the first rename of the main widget, the renames of the test
suites will follow

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9408
2019-07-25 20:27:39 +02:00
Marcel Hollerbach 167d2475e8 efl_ui_grid_item: remove this
this is not needed anymore, the grid items can also just inherit
directly from the items.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9395
2019-07-25 20:27:38 +02:00
Marcel Hollerbach 530d03dcf6 efl_ui_list_item: remove this
this has nothing usefull in it. Additionally, future commits will brings
up another design where there is a central default item style, which can
be hinted.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9394
2019-07-25 20:27:37 +02:00
Marcel Hollerbach eaf8dff2cc efl_ui_item_container: speed up item lookup
the problem with accessor is that the normal eina accessor is only for
immutable lists, by the time you change the list, the accessor has a
problem and might crash. This would mean we have to recreate the
accessors after every change to the internal list representation, which
would invalidate the cache all the time.

The usage of grid and list here is also very performant in cache using,
all the usages normally iterate forward or backward, which makes this
cache really helpfull.

With this commit the lookup of sizes is improved a lot, because
eina_list_nth is not used anymore. (Cuts of ~90ms in creation time)

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9387
2019-07-25 20:27:36 +02:00
Mike Blumenkrantz a5420ac8f3 tests/ecore: verify that quit() -> begin() does not pre-cancel main loop
Summary: ref 17f433c57b

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9375
2019-07-25 13:35:41 -04:00
Xavi Artigas 5a3d659006 mono-docs: Clearer docs for ConstructingHandle
Only *slightly* clearer.
2019-07-25 17:30:44 +02:00
SubhransuSekhar Mohanty dd484a54dc efl_canvas_vg svg: free the svg tree returned by eet_data_read()
The eet_data_read() api creates the structure by referencing the wwt data structure
and reading from eet file. So the structure should be deleted by the user of the function.
As eet_data_read() api documentation dosen't specify about the ownership I guess
we need to free this structure to avoid memory leak.
2019-07-25 15:19:41 +09:00
Shinwoo Kim 5f1f361c08 evas image: apply filter at runtime
Summary:
If you call efl_gfx_filter_program_set in a mouse event callback,
it does not work. Because render_pre removes area uisng evas_render_update_del.

Reviewers: Hermet, jpeg, jsuya, cedric

Reviewed By: Hermet, cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9301
2019-07-25 15:02:03 +09:00
Marcel Hollerbach 38c4e34533 efl_ui_grid/list: fix build
wrong header file + wrong class define. That was forgotten to be pushed
with the commits before, sorry.
2019-07-24 22:07:15 +02:00
Cedric BAIL 9419be9baf elementary: make Efl.Ui.Position_Manager a namespace.
This does the following rename as per T8058:
Efl.Ui.Item_Position_Manager -> Efl.Ui.Position_Manager.Entity
Efl.Ui.Grid_Position_Manager -> Efl.Ui.Position_Manager.Grid
Efl.Ui.List_Position_Manager -> Efl.Ui.Position_Manager.List

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9388
2019-07-24 21:26:43 +02:00
Marcel Hollerbach 59d684284b efl_ui_list: make it work with item_container
This also refactors the example a little bit.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9385
2019-07-24 12:05:08 -07:00
Marcel Hollerbach a6543fb68f efl_ui_grid: make it work with item_container
this also reformats the example, removes
comments that are misleading, removes UI elements that have no purpose.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9384
2019-07-24 12:05:06 -07:00
Carsten Haitzler 7525ab16f1 warnings remove in efl thread/exe examples 2019-07-24 19:26:09 +01:00
Marcel Hollerbach 577b82dad6 Introduce Efl.Ui.Item_Container
this is a new widget which aims to replace Efl.Ui.Grid / Efl.Ui.List.
The widget is split up in a widget and a interface for item placement.

Efl_Ui_Item_Position_Manager: The interface contains API which is used
by the Item_Container to place the items, there is also a set of common
tests which tests for the casual tripping wires, and ensures that the
events are emitted in the correct moments (the later part still can be
improved)

Efl_Ui_Item_Container: The widget itself, it contains the API for the
enduser to add Items to the widget, it handles the different modes for
selection type and emits the events for selection changes. The pack API
is conform with the spec unit test. An additional set of tests is
defined which should be able to be run on every widget with a specific
position_manager beeing set.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9285
2019-07-24 10:38:22 -07:00
Carsten Haitzler 0cd5427c3f build - cmake files - remove old seemingly unused cmake files 2019-07-24 17:53:09 +01:00
Carsten Haitzler a1421564e5 examples - add efl_thread and efl_exe to them 2019-07-24 17:51:27 +01:00
Carsten Haitzler c3807413e7 build - remove old .mk files that were for autofoo not meson 2019-07-24 17:44:05 +01:00
Hermet Park 54a8ba3d8c Revert "elm/scrollable: avoid unnecessary edje recalcs"
This reverts commit 4279f75f0b.

This totally breaks popup control in Tizen,

Need to consider necessity of this patch,
further potential side effects possibilities.
2019-07-24 21:31:07 +09:00
Hermet Park 735f05de76 Revert "Revert "efl/scroll manager: stop clearing animators on every wheel event""
This reverts commit a836c73ef6.

Sorry, I mistook the picking of commit id...
2019-07-24 21:31:07 +09:00
Xavi Artigas a45cc2d47b docs: minor nitpicks to Efl.Ui.Win docs 2019-07-24 14:13:56 +02:00
Hermet Park a836c73ef6 Revert "efl/scroll manager: stop clearing animators on every wheel event"
This reverts commit e6393393cc.

This totally break popup control in Tizen,

Please consider necessity of this patch,
further potential side effects possibilities.
2019-07-24 20:47:28 +09:00
Hermet Park ac75934d06 textpath: + null handling. 2019-07-24 14:28:29 +09:00
Xavi Artigas 7c030aa57e mono-docs: Indicate when methods and properties are BETA
Summary:
Previous commit added a <remarks> section to BETA classes.
Methods (and properties) cannot have <remarks> section so a bit
of bold text is added instead to their summary.

Depends on D9380

Test Plan: Generate docs and observe beta methods and properties have a note regarding their betaness in the summary.

Reviewers: lauromoura, vitor.sousa

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9382
2019-07-23 21:53:01 +02:00
Xavi Artigas d20b8ad42a mono-docs: Allow HTML codes in documentation
Summary:
All comments from EO files are HTML-escaped (i.e. "<" is turned into "&lt;"), and this is good.
However all text added by the mono code generator is HTML-escaped too, and that is a pity.
Circumventing the escaping in the generator involves serious code changes so it is simpler to
allow "escaping" characters to avoid escaping...
"<" is turned into "&lt;"
but
"\<" is turned into "<"

If you are giving these strings from C, remember that the backslash needs to be escaped too!
For example: "\\<b\\>Hello\\</b\\>"

This is intended for use in the generators, NOT in the EO docs.

Test Plan: Everything works as before, but now HTML codes can be added from the generators.

Reviewers: lauromoura, vitor.sousa, felipealmeida

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9380
2019-07-23 21:53:01 +02:00