A few classes allow their objects to be duplicated, so they should all
use the same interface.
Also, rename VG's dup to copy_from as it's not conforming to the
definition of dup.
This removes the internal function pointer for scale_update. This makes
all relevant classes implement the scale API in EO.
This removes the duplicate function in Efl.Canvas.Object and only uses
the one from Efl.Ui.Base interface.
This *seems* to be working as expected. Fingers crossed!
PS: I don't like the name Efl.Ui.Base. It's an interface for a few
common API's between Gfx, Canvas and UI levels... Maybe scale simply
doesn't belong there.
Summary:
Enable value change using wheel.
(Up, Down key value change will be supported after D4933 dicussing.)
Test Plan: elementary_test efl_ui_spin test sample.
Reviewers: Jaehyun_Cho, jpeg, woohyun
Reviewed By: Jaehyun_Cho
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5546
Summary: make Efl.Ui.Popup sample codes simpler
Test Plan:
1. run elementary_test -to efluipopup
2. test various options of efluipopup by clicking each button
Reviewers: Jaehyun_Cho, Blackmole, jpeg, cedric, woohyun
Reviewed By: Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D5366
Summary: Replace Efl.Ui.Popup.Alert's title set method to using efl_text_set with efl_part
Test Plan: elementary_test -to efluipopupalert
Reviewers: jpeg, Jaehyun_Cho, woohyun, herb
Reviewed By: Jaehyun_Cho
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D5359
Summary:
Add initial code for Efl.Ui.Popup.Alert class.
It supports setting title and buttons.
Test Plan: 1. run elementary_test -to efluipopupalert
Reviewers: Jaehyun_Cho, jpeg, cedric, thiepha, Blackmole, woohyun
Differential Revision: https://phab.enlightenment.org/D5108
Summary:
add align feature and position properties (center, left, right, top, bottom)
efl_ui_popup_position_set should be seperated from evas_object_move
since evas_object_move can be called internally.
Test Plan: 1. run elementary_test -to efluipopup
Reviewers: Jaehyun_Cho, jpeg, cedric, thiepha, Blackmole, woohyun
Reviewed By: Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D5105
Summary:
https://phab.enlightenment.org/T5900
Creating base class(efl_ui_spin) to support various shape of spinner.
Added button interaction widget efl_ui_spin_button inherited from efl_ui_spin.
Test Plan: Add tests in elementary_test.
Reviewers: Jaehyun_Cho, woohyun, jpeg, singh.amitesh
Subscribers: jenkins, id213sin, cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5424
Summary:
since legacy elm_bg_color_set/get is changed to efl_gfx_color_set/get,
efl_gfx_color_get also should get color of inner rect.
@fix
Test Plan:
1) run elementary test.
2) run Bg EO API(Efl.Ui.Bg)
3) set/unset "Bg color" check.
4) observe printed color values.
Reviewers: jpeg, woohyun, cedric
Differential Revision: https://phab.enlightenment.org/D5429
See previous commit :)
Note: right now the background part has a small 3d indent which comes
from the legacy theme being used. This will be fixed soon.
If group inherits after setting "inherit_script: 1;", inherit_script
is overwritten by the value of parent group. However, inherit_script
indicates user wants to inherit script in this context, it should not
be initialized as false.
If checked, it will list only the EO test cases.
Also add some stupid icons, and try to make the test case names more
uniform.
Test cases marked as EO are not necessarily 100% EO code, but it would
be good to make them so.
If you want to have EFL application behave in a more efficient way. Like dropping
memory usage or stopping unecessary network operation, this option should be on
and the application should listen on PAUSE/RESUME event on the main loop.
When using reusable content, genlist preserves old object's state and is
expecting reusable_content_get callback to change all needed properties.
But there was an inconsistency: it was silently re-enabling the old content.
@fix
Summary:
When ctxpopup's content is removed,
ctxpopup doesn't recalculate its size, so empty space is remaind.
To fix this problem, ctxpopup recalculate its size when content is removed.
This patch is about T6327
@fix
Test Plan:
1. run elementary_test -to ctxpopup
2. select 10st item
3. click button in ctxpopup
Reviewers: jpeg, Jaehyun_Cho, zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D5462
This commit add the event "circular,dependency" for edje object. Given
event is called when edje found the circular dependency between parts
in object. This event will be usefull and informative paired with
Edje_Edit API.
There are use cases where you would want to align by a value.
The wordy alignment values are thus removed.
This commit also separates auto-modes (none, normal, locale) for
horizontal alignment to its own API.
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Previously the output base name used to include extension, now
you don't need to specify an extension and it's determined from
the input file name instead.
Also, implementation boilerplate used to merge with .eo.c before,
which made no sense. Now it's merged with .c instead when it
exists or makes a new .c file when it doesn't.
indicator_format_set/get & indicator_format_function_set are
now legacy APIs.
indicator format can be set by using generic Ui.Format function
e.g.
efl_ui_format_string_set(efl_part(sliderObj, "indicator"), "1.0%f");
elm_colorselector is legacy only (for now, unfortunately).
This means that elm_colorselector_class_get() crashes with weak linking.
Strong linking would make the compilation fail.
Apparently this isn't well supported by dash, which will print an
error and return a 2, where zsh and bash will return 255.
Explicitly returning 255 seems least surprising.
see https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=772322
#IHaveNoIdeaWhatThisScriptDoes
This prevents legacy EO classes from being exposed through .eo.h headers
or .eo in share/eolian/includes. Also removes a slew of useless xxx_eo.h
intermediate headers.
Notes:
- elm_systray has no proper API: it's not clear if the EO API should be
released (in which case it needs to be renamed to efl_something) and
there is no legacy API to create a systray object.
- Some files have been placed in a "FIXME" section, as I believe they
are necessary within EO land, but at the same time still don't
conform to the interfaces (eg. name starts with elm_).
- elm_interface_scrollable is required by photocam. This means photocam
needs to be adapted to fit the EO scroller API (still to be
completed, I believe).
Bugs:
- This breaks most C++ examples. I KNOW. And I'm working on it.
Ref T5301
Summary:
**@feature** T6241
This feature enables genlist to pin an item to viewport which will
be available always for user to view/select.
**Use Case**:
In a big list of music, most times when user finds a song which they
like, before playing that they may want to go through the entire list
to check whether there is some other good songs, but
after seeing the entire list user have to again scroll back to the
position of item which they liked to play it then.
In this case item pinning can be used, so that the item
which they want to keep for future selection can be pinned
and then it will remain in viewport, finally when user want to do
operation on item, it will be readily available in viewport.
Signed-off-by: Godly T.Alias <godlytalias@yahoo.co.in>
Test Plan: Elementary Test -> Genlist -> Double click on items to enable/disable pinning
Reviewers: raster, cedric, prince.dubey, SanghyeonLee
Subscribers: rajeshps, jpeg, shilpasingh
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D5340
If you have undefined color_class, edje will use solid white for its
colors. If you define color_class name without colors edje_cc now has
same defaults instead of 0 0 0 0.
@fix
there already was this flag but only set implicitly with anchor stuff.
allow to be able to set this flag explicitly to allow offsets to be
scaled if part is marked to scale
@feature
Summary:
When inherit_script is set to 1, script of current group contains
variables and funtions from script of parent groups. If there is same
name variable or function, newly defined one will replace that of
parents.
Reviewers: cedric, jpeg
Subscribers: taxi2se
Differential Revision: https://phab.enlightenment.org/D5062
Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
This is the result of a really quick review of the new VG code. Most of
it was moved around, but this merge includes the following:
- Move logic from edje to evas
- Create static lib for common VG handling
- Add file_set() API
- Add a basic VG cache in evas side
- Add savers modules, implement loaders and savers.
Most of the time you need to retrieve the class from the string
anyway, so remove this relic of old Eolian and gain some small
performance benefits and extra convenience.
Subtly breaks API but everything should be updated.
Summary:
This calendar widget will support basic functionality of calendar.
I've separated this widget from elm_calendar since elm_calendar had
lots of unuseful things inside.
Reviewers: jpeg, singh.amitesh, cedric, CHAN, Jaehyun_Cho
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5346
Summary: @ref T5358
Reviewers: woohyun, jpeg, cedric, Jaehyun_Cho
Reviewed By: Jaehyun_Cho
Subscribers: Jaehyun, bu5hm4n, cedric, jpeg
Maniphest Tasks: T5358
Differential Revision: https://phab.enlightenment.org/D5169
JP's note:
MBE currently has quite a few issues, probably related to focus
handling. This needs to be fixed.
Some things have clearly not been tested. Some APIs have not been
modified after repeated review comments. C++ failed to build due to
"long" being used as a namespace.
Remaining issues:
- The original finger_list API was broken by design. I didn't try to
replace it yet.
- Long tap is also broken by design: if no move happens the recognizer
gets no event, and doesn't trigger anything when the timeout is
reached. An API or event is lacking here.
- Only 2 very basic gestures have been implemented. All the gestures
from elm_gesture_layer need to be covered. None of the multi touch
support has been really implemented, except for a single bool flag.
- The configuration must be loaded from elm_config, passed on to the
recognizers.
- Some micro optimization may be required, especially if the input
device is high frequency (eg. 1KHz gaming mouse).
Because of a typo in generator source (and overlooked error in
tests) we were previously generating incorrect code for setters
with the @auto qualifier. This was brought up in D5306 and is
now fixed.
Summary:
If there is no given pathes for image files as parameter of edje_cc,
"img_dirs" will be NULL. Then, a local variable "load_err" is always
EVAS_LOAD_ERROR_NONE. Because of this, the "if" condition just after
EINA_LIST_FOREACH() will fail. It causes memory leak from "iw".
@fix
Test Plan: N/A
Reviewers: raster, cedric, jpeg, woohyun
Differential Revision: https://phab.enlightenment.org/D5285
Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
Efl.Animation.Group.Sequential is a class for animations started in
sequence.
Efl.Animation.Object.Group.Sequential is a class which provides
methods for an object of Efl.Animation.Group.Sequential.
The objects added into the sequential group animation object start
in sequence.
Efl.Animation.Group.Parallel is a class for animations started in
parallel.
Efl.Animation.Object.Group.Parallel is a class which provides methods
for an object of Efl.Animation.Group.Parallel.
The objects added into the parallel group animation object start in
parallel.
Coverity reports that the eina_strbuf 'param_call' leaks when it goes
out of scope here, so fix the leak by freeing the strbuf
Fixes CID1381502
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
efl_del() is valid but bindings such as C++ should be using efl_unref()
and not efl_del() in this situation: a reference was given, so it should
be released.
After the previous patch, the caller of efl_input_dup() clearly owns the
reference on the returned object, which means she must absolutely delete
or unref if manually.
Note that the previous patch changed the bug from use of invalid eo
pointer to leaking of objects. But the only way to support bindings with
something like dup() is to ensure we give a ref to the caller, and thus
the parent should be null.
Note: eo_debug was used extensively to reach this point.
Summary:
elm_bg was supposed to be used only in legacy,
but since we need a common object to be used as a background of widgets,
it is now renamed as efl_ui_bg and supports EO APIs.
Reviewers: cedric, jpeg, woohyun
Differential Revision: https://phab.enlightenment.org/D5147
These types are of questionable value and the API was not entirely
thought out - remove for now, and if a legitimate use is found
later, they may be readded (with a better API), but typically it
seems best to redesign the bad APIs around safe containers...
Reasons:
- This API has been confused with the min size of the widget, resulting
in badly laid out applications.
- The EO API was not very nice (Range is about numbers, the Gfx size
hint in a part is really ugly).
While I understand the value of this API and how it can be used in
scalable applications, it is in fact not absolutely necessary.
Alternatively to that span size, the widget min size can already be
defined from the application side, or the widget can simply be expanded
to fill in its parent.
This can obviously be reinstated later if the need arises for EO. For
now, keep this feature as legacy-only.
Adds "Efl.Ui.Text_Async" object.
This new widget uses the "async_layout" functionality of the underlying
Efl.Canvas.Text object.
Currently, if "editable" mode is enabled, there is no asynchronous
layout, as interactive operations (e.g. typing) should get processed
immediately. Thus, only "non-editable" instructs the text object to do
asynchronous layout.
@feature
Summary:
Tile is common type which can be used eg: background.
This is added to scale type which can be set/get by
efl_ui_image_scale_type_set/get()
@feature
Test Plan:
Run elementary test
Run Image Scale Type
Check radio "Tile".
Reviewers: jpeg, cedric, woohyun
Differential Revision: https://phab.enlightenment.org/D5119
Summary:
If user call tooltip_orient_set or tooltip_style_set or tooltip_window_mode_set
before tooltip_test_set or tooltip_content_cb_set, those functions doesn't work.
Because elm_tooltip will be created when tooltip_content_cb_set is called.
I fixed logic to use some functions before tooltip_test_set or tooltip_content_cb_set.
Test Plan: elementary_test -> Popups -> Tooltip
Reviewers: jpeg, Jaehyun
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5183
Summary:
In elm_map_overlay_show and elm_map_overlays_show,
it frees overlays list members. This lists are used
in elm_map_overlay functions, so should remain.
Test Plan:
1. Run elementary_test -> Geographic -> Map
2. Click group overlay (whose text is "3") -> bubble appears
3. Click "Show" button -> observe no more Eina Magic Check Failure appear.
Reviewers: jpeg, cedric, woohyun
Differential Revision: https://phab.enlightenment.org/D5191
For this patch I decided to add a pseudo legacy wrapper as the function
is called in a very large number of places. Fixing all those calls to
use the size2d form is a lot of work and a greater risk of b0rking
something.
It's a complex struct but defined in EO as a simple struct. ABI-wise
it's equivalent to Eina_Rectangle. Some macros that use Eina_Rectangle
also work on Eina_Rect out of the box, most of the code dealing with
x,y,w,h will require no modifications either.
But Eina_Rect provides direct access to a size or position 2d component,
as well as the usual x,y,w,h. The field "rect" is provided as a
convenience for code dealing with both Eina_Rectangle and Eina_Rect. We
may or may not require it.
Note: Size2D could use unsigned values but I have spotted a few places
in the code that actually use -1 to indicate invalid size (as opposed to
0x0).
@feature
We could just pass Efl_Time value as copy by value to set time in setter APIs
and return Efl_Time value in getter APIs.
Thanks to @JackDanielZ for the report.
Fixes T6008
In Edje and Elementary, we have part objects, which are what is returned
by the interface efl_part(). Those objects can't be of an opaque type as
this doesn't work nicely with strongly typed languages such as C++ or
C#. In JS, Lua, C the types are weak and mostly runtime-based so it
doesn't matter much.
As a consequence, the documentation and the types need to look nice in
this EO API. Thus, we remove the abusive term "internal" and explicitly
call all those classes "part" something.
Eventually we want the types to be declared in the EO file so bindings
(C#, C++, ...) can generate the proper access methods, returning the
best possible types.
Note that right now a few of those part types are used in the legacy API
but don't actually need to be exposed externally.
This is kind of a mega commit that does all the renaming at once, but
it's really just a big sed operation. The power of good IDEs :)
Ref T5315
Ref T5306
This reverts commit 9836116cab.
This is based on discussion today i had.
There would be a separate minimal spinner class instead
which facilates ways to extend it.
This makes the icon test actually work. Otherwise the icon data is too
big and basically seems ignored by the compositor or X.
Note: In E (X11) it seems that the window icon remains unchanged? xprop
shows the proper data, though. Ping @zmike.
Note: elm_test "Focus Style" can be used to test this API. The test case
is a bit broken (overly complex EDC?) but if you're patient you can see
the difference between "glow" and "glow_effect".
Ref T5363
Ref T5322
Text on path (textpath) allows application to make text follow a path.
The path can be a efl_gfx_path or a circle.
Thank hermet for initializing this work.
@feature
Wherever the EO API is used, i.e. efl_add() is used to create evas
objects, we can skip the calls to set fill/expand.
This new set of defaults indeed saves ~60 loc in the tests (out of 115
objects created). I found only 3 cases where the align had to be set
manually (to the old default of 0.5).
See 1a1b8bc451
And e8b7f5f255
Ref T5301
Summary: In state_changed_cb2 callback function, obj is used. so it should not be EINA_UNUSED
Reviewers: Jaehyun_Cho, cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5122
Summary:
When text set NULL, size is not changed even text is removed.
So, fix that case logic
1. send text,hidden signal
2. remove text
3. call sizing eval to resize layout
Test Plan:
1. run elementary_test -to check
2. change value last check object
3. compare before and after
Reviewers: Jaehyun_Cho, cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5086
It was discussed a while ago that Zoomable was a poor name in some
languages, like python.
This changes, in Efl.Ui, to use underscores:
- Image.Zoomable
- Grid.Static
- Box.Flow
- Box.Stack
This makes sure that
elementary_test -to "Window Plug"
exits nicely (with the exit policy on all window close) instead of
hanging forever with an invisible window.
@fix
This name makes more sense and one api does the job of two.
We never needed two apis at first place though.
Mark left/right_size_set as legacy apis too.
This patch also implements min_split_ratio on parts.
@feature
refer T5359
This allows user to set size hints to be respected and
request panes to ignore combined min size.
If this flag is set, the minimum size set by efl_gfx_size_hint_min_set()
is respected forcefully.
@feature
refer T5359
Summary:
ctxpopup item have elm_list item internally.
item_part_content_unset need to pass on content part to elm_list item.
Test Plan:
1. launch elementary_test - ctxpopup
2. click Ctxpopup with part text & content function
3. press "Icon Set" and press "Icon Unset"
Reviewers: jpeg, woohyun, herb, Blackmole
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5018
Summary:
There were only 2 APIs (item_append, item_prepend) for ctxpopup item add.
Added more item add APIs (item_insert_before and item_insert_after) for convenience.
Test Plan:
1. launch elementary_test - ctxpopup
2. click Ctxpopup with callback function sample
3. check whether there are 3 items on ctxpopup
Reviewers: woohyun, Jaehyun, jpeg, cedric
Reviewed By: jpeg
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5004
Summary:
ctxpopup item have elm_list item internally.
But when elm_ctxpopup item was deleted, elm_list item was not deleted.
elm_list item in elm_ctxpopup item should be deleted in del_pre
when elm_ctxpopup item is deleted by elm_wdg_item_del()
Test Plan:
1. launch elementary_test - ctxpopup
2. click Ctxpopup with label only
3. "Never Show" item should not shown in ctxpopup
Reviewers: jpeg, cedric, woohyun
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5044
Revert "Separtor: use orientation APIs"
This reverts commit f043c3be61.
Separator is not part of EO API so no need to use Orientation or
Direction API here.
Ref T5870
Some names have not been changed, hopefully making a distinction
between legacy APIs and internal code (elm_layout_blah) and valid EO
usages.
This means many internal functions are still elm_layout_ as their
sole purpose is to support the legacy API.
Ref T5315
For programs without specific names edje_cc generated default names in
the form of program_$MEMORY_ADDRESS. That worked well enough for keeping
the names unique, but it causes problems if one wants to have these files
being binary reproducible due to different memory layouts, compilers,
etc. Simply using a counter as unique part should work well enough for
our use case and help people who want to verify builds.
Thanks a lot to Bernhard M. Wiedemann for review and testing.
Fixes T5113
Ref T5495
in code we importend that doesnt use eina we have warnings of
fallthroughs. all o them are commented to be fallthrough so add the
attribute there too to have fewer warnings.
This amends 8e311db414 as the logic
was badly broken. A "shadow" variable warning
clearly showed that "tmp" was not used properly.
This fixes the "IBM" logo in svg-test (the only one
using polygon/polyline, it seems).
analysers like PVS studio dont know the eina_list_free returning NULL
design pattern for consistency and so dislike the var being set twice
in a row. this will make them happy without any skin off our backs.
not a bug at all.
found by PVS studio
if files size was 0... which would basically make a lot fail before...
it could be a divide by zero. fix and just assume minimum size of 1.
fix CID 1371127
fname would have been leaked if we failed to get a file_handler.
Also make sure we always create a new fname strbuf even without
a output_dir present to fix a potential unbalance between creating
and freeing.
CID: 1378112
Summary:
Actual slider value is not changed.
So when user release mouse or touch, slider value is returned
to the value by user set.
This is a partial revert of f41e276160
Fixes T5745
Test Plan: elementary_test -> slider
Reviewers: jpeg
Subscribers: cedric
Maniphest Tasks: T5745
Differential Revision: https://phab.enlightenment.org/D5031
This exposes an elm_win sizing bug. To test (under X):
ELM_DISABLE_EXTERNAL_MENU=1 elementary_test -to "Main Menu"
The layout is not completely wrong 100% of the time, but it is
exactly correct 0% of the time. Window sizing is our flying
spaghetti monster.
Changes cursor handle name from 'Efl.Text.Cursor.Cursor_Data' to
'Efl.Text.Cursor.Cursor'.
Also, replace all usages of Efl_Canvas_Text_Cursor
with Efl_Text_Cursor_Cursor as the handle for the cursor.
Because there might be hidden C implements defined, we need to
always generate the appropriate class initializer. This does not
hurt anything as the contents would have been called automatically
by Eo anyway.
@fix T5736
Summary:
Although user use "inherit" in a state of proxy part,
the inherit function does not copy the source_visible and
the source_clip value of parent to the state.
Test Plan: {F1751132}sample
Reviewers: jpeg, cedric
Differential Revision: https://phab.enlightenment.org/D5017
@fix
Summary:
When user drags slider, slider value cannot be changed by API.
However the necessity of above behavior has emerged.
Because sometimes applications want limitation of slider value.
Test Plan: elementary_test -> slider -> Limited
Reviewers: woohyun, cedric, SanghyeonLee, singh.amitesh, jpeg
Reviewed By: jpeg
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D4883
Summary:
When scrollable set TRUE,
scroller must be calculated its size except using item.
If content is removed, scroller doesn't calculate its size, so it has previous size.
So there is a empty space in this case.
@fix
Test Plan:
1. elementary_test -to popup
2. open "popup-center-title + list content + 2 button (with delete content)"
3. click "Delete" button
4. compare between scrollable set true and false
Reviewers: herb, singh.amitesh, jpeg, cedric, conr2d
Differential Revision: https://phab.enlightenment.org/D5010