Commit Graph

119 Commits

Author SHA1 Message Date
Carsten Haitzler f9e8839125 tests - let's have our own enforced master timeout of 240sec
let's not let check defaults decide. let us decide for everything with
one var. also timeout.c matches too... so 2 places i guess for now.
2024-01-09 08:14:42 +00:00
Stefan Schmidt 27cecc3afb tests: edje: check result of evas_engine_info_set()
Make sure we check the result of evas_engine_info_set and only continue
if it succeeds.

CID: 1401077

Reviewed-by: Christopher Michael <devilhorns@comcast.net>
Differential Revision: https://phab.enlightenment.org/D11978
2020-06-15 15:04:22 +02:00
Ali Alzyod d7ed1721b8 tests: edje: Fedora32 system fail resolve
This test seems to fail on Fedora32, we increase font size margin to
prevent it from happening

Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Differential Revision: https://phab.enlightenment.org/D11776
2020-05-05 14:56:53 +02:00
Ali Alzyod 208c1938bc evas_test: change START_TEST to EFL_START_TEST
Summary: evas_test: change START_TEST to EFL_START_TEST

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D11716
2020-04-16 12:03:23 -04:00
a.srour d3dc7dc86e Fix worning and tests for edje text_class
Summary: This should fix the wornings and tests logic from previouse commit, diff D10692

Reviewers: ali.alzyod, segfaultxavi, woohyun

Reviewed By: segfaultxavi

Subscribers: cedric, #committers, #reviewers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D11017
2020-01-07 14:28:46 +01:00
Ali Alzyod 36a50f4d82 efl.text_style: remame underline2 and glow2
Summary: rename underline2 into secondary_underline and glow2 into secondary_glow

Reviewers: woohyun, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7857

Differential Revision: https://phab.enlightenment.org/D11024
2020-01-07 09:32:03 +01:00
a.srour 0164162a48 Edje: edc text_class applied without font or font_size in style
Summary:
The issue with `text_class` in Edc styles has to be within a string containing `font` & `font_size` properties to effect style, if font or font_size not presented in the same string text_class will be ignored.

So in the following Edc example, `text_class` will be ignored:
```
collections {
   text_classes {
      text_class {
         name: "tc1";
         font: "Sans";
         size: 20;
      }
   }
   styles {
      style {
         name: "style1";
         base: "color=#00FF00 text_class=tc1";
         tag: "br" "\n";
      }
   }
}
```

To apply text_class `tc1`, font and font_size has to be added to `styles.style.base` value, to be as follows:
```
...
base: "font=Serif font_size=15 color=#00FF00 text_class=tc1";
...
```

NOTE: The produced font will be `Sans` and font_size equal to `20`

Test Plan:
`layout.edc`
```
// compile: edje_cc layout.edc
// play: edje_player layout.edj
collections {
    text_classes {
       text_class {
          name: "tc1";
          font: "Sans";
          size: 20;
       }
    }
    styles {
        style {
            name: "style1";
            base: "color=#FFFFFF text_class=tc1";
        }
    }
    group {
        name : "group1";
        parts {
           part {
              name : "tb1";
              type: TEXTBLOCK;
              scale: 1;
              entry_mode: NONE;
              description {
                  state: "default" 0.0;
                  rel1.relative: 0.0 0.0;
                  rel2.relative: 0.5 0.5;
                  text {
                     style: "style1";
                     align: 0.0 0.0;
                     text: "Hello EFL";
                  }
              }
           }
        }
    }
}

Reviewers: segfaultxavi, smohanty, ali.alzyod, cedric, zmike

Reviewed By: zmike

Subscribers: zmike, segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8477, T8478

Differential Revision: https://phab.enlightenment.org/D10692
2019-12-30 11:12:37 -05:00
Ali Alzyod 5cf7fa7670 efl.text.style: rename methods/properties and add text_ prefix
Summary:
efl.text.style: rename methods and properties

this change will avoid conflict in the future with other interfaces or class methods.

```
      Efl.Text_Style.text_color { set; get; }
      Efl.Text_Style.text_backing_type { set; get; }
      Efl.Text_Style.text_background_color { set; get;}  //this was backing_color
      Efl.Text_Style.text_underline_type { set; }
      Efl.Text_Style.text_underline_color { set; get; }
      Efl.Text_Style.text_underline2_color { set; get; }
      Efl.Text_Style.text_underline_dashed_color { set; get; }
      Efl.Text_Style.text_underline_height { set; }
      Efl.Text_Style.text_underline_dashed_width { set; }
      Efl.Text_Style.text_underline_dashed_gap { set; }
      Efl.Text_Style.text_strikethrough_type { set; }
      Efl.Text_Style.text_strikethrough_color { set; get; }
      Efl.Text_Style.text_effect_type { set; }
      Efl.Text_Style.text_shadow_direction { set; }
      Efl.Text_Style.text_outline_color { set; get; }
      Efl.Text_Style.text_shadow_color { set; get; }
      Efl.Text_Style.text_glow_color { set; get; }
      Efl.Text_Style.text_glow2_color { set; get; }
```

T8533

Reviewers: woohyun, segfaultxavi, bu5hm4n, zmike, cedric

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10897
2019-12-20 09:58:27 +01:00
Ali Alzyod 7bdb63d045 Polish text interface methods
Summary:
This patch is set to rename some properties of `Efl.Text_Font` & `Efl.Text_Format` interfaces.

1- efl_text_font_set/get become (efl_text_font_family_set/get, efl_text_font_size_set/get)

2- efl_text_valign/halign   become efl_text_vertical/horizontal_align

3- efl_text_halign_auto_type  become  efl_text_horizontal_align_auto_type

Reviewers: ali.alzyod, woohyun, segfaultxavi, bu5hm4n, zmike, cedric

Reviewed By: woohyun

Subscribers: zmike, #committers, #reviewers, cedric

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10716
2019-11-28 16:55:27 +09:00
Mike Blumenkrantz e55a6f6778 edje: add Efl_Layout.h for eo-based layout headers
this includes all related headers

ref T8274

Additional Authors: Lauro Moura <lauromoura@expertisesolutions.com.br>

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D10228
2019-09-30 10:33:27 +02:00
Mike Blumenkrantz cfae5ba285 tests/edje: handle file modifications properly on windows
Summary: we don't have access to utimensat and I'm too busy to figure out why

Reviewers: vtorri, bu5hm4n, devilhorns

Reviewed By: vtorri

Subscribers: cedric, #reviewers, #committers

Tags: #efl_build

Differential Revision: https://phab.enlightenment.org/D9914
2019-09-13 14:13:33 -04:00
Mike Blumenkrantz 52e39f71fa tests/edje: reduce chances of cascading test failures in non-forked mode
Summary:
move evas_free() into the global shutdown fixture to ensure that edje_shutdown
actually does call internal shutdown methods since evas_free() will not be
reached if it is at the end of a failing test

Depends on D9878

Reviewers: cedric

Reviewed By: cedric

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9879
2019-09-11 13:38:35 -04:00
Mike Blumenkrantz 599d7f80db tests/edje: add comprehensive edje reloading test
Summary:
this verifies:
* successfully loading a file
* emission of "load" signal when performing a file load
* swallowing an object
* no-op of file load operation on same file if mtime is unchanged
* successfully reloading the same file if the mtime has changed
* preserving user-defined data across file reloads

Depends on D9877

Reviewers: cedric

Reviewed By: cedric

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9878
2019-09-11 13:38:28 -04:00
Yeongjong Lee 9c52484caf efl_pack_table: rename table_position to cell_column, cell_row
Summary:
Rename ambiguous `table_position` property. it is actually related to child
column, row.

ref T7900

Reviewers: segfaultxavi, zmike

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl_api

Maniphest Tasks: T7900

Differential Revision: https://phab.enlightenment.org/D9611
2019-08-27 12:57:35 +02:00
Mike Blumenkrantz 2cd4d67109 tests/edje: disable efreetd and ecore system modules in unit tests
Summary: these cause tests to take up to 100x longer

Reviewers: bu5hm4n, cedric

Reviewed By: bu5hm4n, cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl_tests

Differential Revision: https://phab.enlightenment.org/D9702
2019-08-23 13:38:33 -04:00
Vincent Torri ba22016c4c tests: fix warnings and undef ref on Windows (using meson :-) )
Summary: we need to include evil_private.h so that some symbols are declared

Test Plan: compilation

Reviewers: raster, zmike, cedric

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9129
2019-06-20 12:50:35 +01:00
Carsten Haitzler 346e5d1324 edje src - mark with efl version so we don't get warnings 2019-05-13 14:40:08 +01:00
Marcel Hollerbach 4edf8036e0 meson: correctly use the correct dependency
Summary:
edje_cc calls epp, so we should not only add edje_cc to the depends on
target, but rather also ensure that epp is availble. Additionally, this
removes unneccessary depends on declarations when we do cross compile.
Depends on D8561

Reviewers: zmike, segfaultxavi, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8562
2019-04-05 08:15:39 -04:00
Yeongjong Lee 4628021fe5 efl_container: remove content_remove
Most of classes implements Efl.Container.content_remove are just calling "unpack"
except of "Efl.Canvas.Layout" and "Efl.Ui.Layout".
This patch remove the asymmetrical API and add content_remove API of
"Efl.Canvas.Layout" and "Efl.Ui.Layout" that child can be remove without efl_part
APIs.

ref T7576

Reviewed-by: Marcel Hollerbach <marcel-hollerbach@t-online.de>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D7913
2019-02-27 21:20:33 +01:00
Mike Blumenkrantz a5e183ad5d efl.canvas.object: clip -> clipper && clipees -> clipped_objects
Summary:
also clipees_has -> clipped_objects_count

ref T7555

Depends on D8039

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7555

Differential Revision: https://phab.enlightenment.org/D8040
2019-02-27 13:17:37 -05:00
Mike Blumenkrantz 6326e18b3f efl.file: improve api a bit
Summary:
the previous implementation/api had a number of issues:
* "file" property contained both "file" and "key" values
  - also performed file loading operation
* "load_error" property which was specific to image objects
* no methods for controlling file loading/unloading

this patch attempts the following changes:
* split "file" property into "file" and "key" properties
  - also remove "key" from existing "mmap" property
* remove "load_error"
* directly return error codes from operations
* add "load" and "unload" methods for directly controlling load state
* add implicit file loading if file/mmap is set during construction
* rewrite all efl.file implementations to move file loading into load() method
* rewrite all usage of efl.file api based on these changes
* add C extension functions to mimic previous behavior

ref T7577

Reviewers: segfaultxavi, bu5hm4n, cedric

Reviewed By: segfaultxavi

Subscribers: vitor.sousa, #reviewers, #committers

Tags: #efl_api

Maniphest Tasks: T7577

Differential Revision: https://phab.enlightenment.org/D8018
2019-02-27 13:17:10 -05:00
Mike Blumenkrantz f886941b11 api: efl.gfx.size_hints -> efl.gfx.hints
Summary:
these hints are not strictly size-related, so renaming them is more consistent
with their actual function

ref T7563

Depends on D7968

Reviewers: segfaultxavi, cedric, bu5hm4n

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7563

Differential Revision: https://phab.enlightenment.org/D7977
2019-02-21 18:43:12 +01:00
Marcel Hollerbach 1763afb391 edje: implement container api
the container api returns the number of added swallows.
the content iterator returns a iterator over all swallowed objects.

The reason this is only for swallows is that the interface explicitly
mentions UI elements at the count. Since i am believing the the result
of the count operation should mirror to the amount of elements in the
iterator, the iterator only returns swallowed objects.

ref T5719

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D7748
2019-01-26 11:41:58 +01:00
Carsten Haitzler 6dedfddda7 meson - edje_cc use -fastcomp for fast builds in mesa 2019-01-24 14:04:07 +00:00
Marcel Hollerbach 5b98ebab4a meson: abstract edje_cc exec lines
the array is calling the shell etc. this makes cross building easier.

Differential Revision: https://phab.enlightenment.org/D7413
2018-12-06 15:13:34 +01:00
Carsten Haitzler 791cd5b157 edje test - part content should be null as nothing is swallowed yet
fix test
2018-11-10 16:31:18 +00:00
Carsten Haitzler eae67c02e3 edje test - fix unused return val and actually check its value 2018-11-09 11:43:59 +00:00
Daniel Hirt e8ed36af10 Canvas layout: fix test for meson builds
Fixes T7456
2018-11-08 11:44:05 +02:00
Daniel Hirt face90632e Canvas layout: support more Efl.Text.* with efl_part
This adds many Efl.Text.* that are useful for manipulating the
underlying TEXTBLOCK object's propeties using efl_part.

This has been implemented as part of the "user-defined" properties of
the layout part, so that the changes on the part persist across load of
different groups.

Note that text styles have precedence over the TEXTBLOCK (Canvas.Text)
object's properties. if an edc provides a style, the properties it
manipulates as part of the "base:" string would not be affected by this
API.

In general, this helps reducing the amount of styles for objects (or
modes of the same objects) that share the same setup, but are different
in some properties (e.g.  ellipsis, wrap etc).

@feature

Canvas layout: add text part "expand" property

This adds "expansion modes", which are essentially the same as min/max
hints in the edje part's 'description.text' fields.

The user can then customize his widget to different modes without being
forced to create a new edje group in the theme.

Note that there is an added check in case one of the min/max text flags
are provided from the theme. In such case, all flags from this new API
will be ignored.
This fortifies misuse where the flags are set both in theme and the API.

@feature
2018-11-06 18:33:56 +02:00
Marcel Hollerbach 46d464e5bf here comes meson
a new shiny buildtool that currently completes in the total of ~ 4 min..
1 min. conf time
2:30 min. build time
Where autotools takes:
1:50 min. conf time
3:40 min. build time.

meson was taken because it went quite good for enlightenment, and is a traction gaining system that is also used by other mayor projects. Additionally, the DSL that is defined my meson makes the configuration of the builds a lot easier to read.

Further informations can be gathered from the README.meson

Right now, bindings & windows support are missing.

It is highly recommented to use meson 0.48 due to optimizations in meson
that reduced the time the meson call would need.

Co-authored-by: Mike Blumenkrantz <zmike@samsung.com>

Differential Revision: https://phab.enlightenment.org/D7012
Depends on D7011
2018-10-02 17:22:50 +02:00
Yeongjong Lee 9fc687a8c3 edje: call recalc in part_text_get if there is no available text data
Summary:
If edje_text_get is called before any edje_text_set function call, it return
null, because rp->typedata.text->text is only set by edje_text_set function.
If there is no available text data, find it from rp(edc).

ref 7bbf18a950

Test Plan: make check

Reviewers: zmike, id213sin, herdsman

Reviewed By: id213sin

Subscribers: Hermet, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6961
2018-09-28 16:14:00 +09:00
Mike Blumenkrantz 588830280f tests/edje: fix object parenting for swallow tests
Summary:
recent safety check patches exposed issues here where tests were
incorrectly written to pass evas objects as edje object parents,
resulting in new test failures after this began to be detected and
treated as an error

Reviewers: netstar

Reviewed By: netstar

Subscribers: netstar, cedric, #reviewers, #committers

Tags: #efl_tests

Differential Revision: https://phab.enlightenment.org/D6851
2018-08-16 19:47:32 +01:00
Mike Blumenkrantz 5794f6f7af tests/edje: add test to verify that swallow objects exist during DEL callback
Summary:
this mimics expected behavior by enlightenment

for 2.0, this behavior should likely be changed since the INVALIDATE event
should be the last expected point at which a parent<->child relationship
continues to exist in any form

ref D6540
Depends on D6554

Reviewers: devilhorns, Hermet

Reviewed By: Hermet

Subscribers: cedric, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6555
2018-07-12 16:29:51 +09:00
Mike Blumenkrantz b05a5cb4c7 tests/edje: split edje tests into separate files
Summary:
this will speed up tests and make it slightly less intimidating to
add new tests

Reviewers: devilhorns

Subscribers: cedric, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6554
2018-07-12 16:25:15 +09:00
Chris Michael 9a9970ae62 tests: Update edje test to wrap edje_object_part_object_get with
Summary:
freeze/thaw

@ref T6884

Depends on D6403

Reviewers: zmike, ManMower

Reviewed By: zmike

Subscribers: cedric, #committers

Tags: #efl

Maniphest Tasks: T6884

Differential Revision: https://phab.enlightenment.org/D6404
2018-06-25 11:32:33 -04:00
Youngbok Shin 69b5d67367 edje: fix text set/get issue without edje calculation
Summary:
Some changes broke really basical function behavior of text.
I couldn't get text from an edje object which I just set to the given edje object.
In the past code, edje called recalc function before trying to get text.
So, this patch bring that code to fix this issue.
@fix

Test Plan: Included. Run "make check"

Reviewers: herdsman, raster, cedric, woohyun, devilhorns

Subscribers: #committers, zmike

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6364
2018-06-22 12:30:59 +03:00
Marcel Hollerbach d1e1adf0bc edje: fix edje_part_helpers refcounting
Summary:
the reference from efl_reuse was forgotten & the parent relation was not
correctlty setted, which led to the fact that NOREF was never emitted.
This caused that thte object never really was destructed probebly, and
thus the del_interceptor_cb was not executed, and the object simply
leaked.

The test checks that those properties are correctly set, additionally a
error is printed in the efl code when a part has not the expected
reference properties. This also enforces errors when users are doing
wrong things with objects returned by efl_part.

Reviewers: ManMower, zmike

Reviewed By: zmike

Subscribers: cedric, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6254
2018-06-10 17:01:33 +02:00
Marcel Hollerbach bb2037748a edje: a new testcase for what was happening before
Summary:
this checks explicitly that the lifecycle is alive.

Depends on D6223

Reviewers: cedric, zmike, JackDanielZ

Subscribers: cedric, #committers, zmike

Tags: #efl

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

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
2018-05-28 21:50:19 -07:00
Youngbok Shin cd0bd865eb edje: fix backward compatibility issue caused by legacy cursor funcs
Summary:
edje_object_part_text_cursor_prev/next/up/down has return value.
It has to return EINA_TRUE when only it successed.
But, when these funcs moved to legacy, it changed to return EINA_TRUE
whenever it fails or success. It must return EINA_FALSE when it fails.
@fix

Test Plan:
- Run test suite
  make check

Reviewers: herdsman, raster, cedric, woohyun

Subscribers: zmike

Differential Revision: https://phab.enlightenment.org/D5972
2018-05-02 19:48:46 +03:00
Xavi Artigas 55bd097a3d Efl.Gfx.Entity (from Efl.Gfx)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:32 -07:00
Mike Blumenkrantz 624925fe6e tests: move to using checked fixtures for all test suites
individual tests should not need to explicitly call init/shutdown functions
in most cases, and many did not properly do this anyway

see followup commit which resolves some issues with eina tests

ref T6813
ref T6811

Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com>
2018-04-05 11:10:26 +02:00
Mike Blumenkrantz adc601aca2 tests: add instrumentation to existing tests to find slow tests
efl_check.h must be included and the EFL_START/END_TEST macros must be
used in place of normal START/END_TEST macros

timing is enabled when TIMING_ENABLED is set
https://phab.enlightenment.org/w/improve_tests/

Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com>
2018-04-05 11:10:25 +02:00
Carsten Haitzler e30fb6945e fix evas test suite to now init both ecore and evas.... correctly.
see c8dcc4327b803e9b8ad2a0985e756c924946c442 - basicall evas depends
on ecore these days... thus requires ecore be initted THEN evas. ...
which in theory is an abi break for those using evas and ONLY evas
long ago from when efl was separate... but it''s how we're building
these days.

@fix
2018-01-05 02:34:16 +09:00
SangHyeon Lee 0f16a06710 interface : change efl_pack_grid and efl_ui_grid to efl_pack_table and efl_ui_table
Summary:
Change name of 'grid' to 'table' for matching on common ui naming
and avoiding confusion with 'gengrid' and 'grid view'.
grid will be introduced as grid image view after.

Test Plan:
checked make & make install
checked make check - there are errors but not related with these changes.
checked make examples - there are errors in cxx but not related with these changes.
checked make discheck - failed
test in elementary_test with Efl.Ui.Table and Table_static.

Reviewers: raster, cedric, jpeg, felipealmeida

Differential Revision: https://phab.enlightenment.org/D5668
2017-12-19 14:25:08 +09:00
Amitesh Singh 54ae9cc18b edje: rename Edje.Object to Efl.Canvas.Layout 2017-12-06 13:12:29 +09:00
Amitesh Singh c7aa3b2f83 edje: rename intf Efl.Canvas.Layout_Calc to Efl.Layout.Calc 2017-12-05 16:18:32 +09:00
Amitesh Singh 7b3fde4d4b edje: rename intf Efl.Canvas.Layout.Signal to Efl.Layout.Signal 2017-12-05 16:18:32 +09:00
Youngbok Shin de9f0aff57 edje: don't return negative width and height from _parts_extends
Summary:
It should return width and height with positive values or zero.
@fix

Test Plan: make check

Reviewers: raster, jpeg, cedric

Reviewed By: raster

Subscribers: jiin.moon

Differential Revision: https://phab.enlightenment.org/D5422
2017-11-06 11:06:41 +09:00
Jean-Philippe Andre 04d3cc4eb9 edje: Fix make check
Oops. The API was tested.
See 19dff85519
2017-10-13 11:07:28 +09:00
Jean-Philippe Andre 1fb306fd3e edje: Fix make check :(
No idea how I missed that one... (except that make check is now broken
for C++, again)
2017-09-18 17:40:38 +09:00