Commit Graph

664 Commits

Author SHA1 Message Date
Kai Huuhko 1940b51f15 Evas.SmartObject: Use calloc to allocate the array 2015-03-21 10:37:47 +02:00
Kai Huuhko 0266db28bd Eo: Add the property 'parent' 2015-03-21 10:06:45 +02:00
Kai Huuhko c547f72374 Ecore-X: Fix copy & paste error in last commit 2015-03-13 20:36:05 +02:00
Kai Huuhko 0a9ccfca74 Ecore-X: Add cursor_free, deprecate screensaver_supend 2015-03-13 20:13:31 +02:00
Kai Huuhko 6036567b41 Ecore-X: Add cursor_shape_get() 2015-03-13 19:48:15 +02:00
Kai Huuhko 4ccea0f35d Evas.SmartObject: Add smart callback introspection 2015-03-13 19:22:01 +02:00
Kai Huuhko ea2d5bd689 Evas.SmartObject: Optimize Smart calls 2015-03-13 13:10:22 +02:00
Kai Huuhko 3120e56250 Evas.SmartObject: Go back to the old cb system
Turns out the C calls are awfully slow.

Dave, good work with the tests!
2015-03-13 02:40:39 +02:00
Kai Huuhko ccc88f6650 Elementary.Object: Use Evas.Object._set_obj() 2015-03-12 21:17:25 +02:00
Kai Huuhko 4b9a44d2fc Evas.Object: Add more documentation for size hints from C headers 2015-03-12 19:39:29 +02:00
Kai Huuhko dd5b35ef8f Evas.Object: Re-order the methods into sections, cosmetic 2015-03-12 18:52:08 +02:00
Kai Huuhko 6fa1b78256 Evas.SmartObject: Keep reference to Smart in the SO object
Smart gets freed automatically when no SO or user has references to it.
2015-03-12 18:22:46 +02:00
Kai Huuhko 270ac10e09 Evas.SmartObject: Optimize python cb call 2015-03-12 16:19:35 +02:00
Kai Huuhko 179404e279 Evas.SmartObject: Change SmartCb spec into a custom object
This allows faster C access to the values, avoids casting the conv_func
pointer to an integer and back.
2015-03-12 14:27:36 +02:00
Kai Huuhko 8b594d4bd8 Evas.SmartObject: Improve Smart cb handling
Calling custom callbacks with event_info was broken, fixed.

A check was added for event_info pointer, a warning will emit
when it's non-NULL and we don't have a conv function set.

Small optimizations.
2015-03-12 02:00:04 +02:00
Kai Huuhko 247eb9e452 Evas.SmartObject: Revert SmartCb add/del mechanism partially
We need to keep a better track of the spec references so they
don't get mixed up when user adds and deletes the callbacks.
2015-03-11 22:13:00 +02:00
Kai Huuhko a407e11298 Evas: Change SmartCb event_info conversions into C functions 2015-03-11 15:37:06 +02:00
Kai Huuhko d36b61e97e Evas.SmartObject: Keep refs in a list
Using Py_INCREF/DECREF in add/del we could have dangling references when
the object is deleted without user calling callback_del.
2015-03-11 11:36:50 +02:00
Kai Huuhko 7fad9e3ff4 Evas.SmartObject: Simplify callback handler code
This should do the same as the previous approach, except heaps and tons
faster. No more dicts and lists to go through.
2015-03-11 04:13:08 +02:00
Kai Huuhko c4786f997e Evas.SmartObject: changed smart event callback add/del methods to cdef 2015-03-11 02:12:36 +02:00
Kai Huuhko 4ab927809e Move smart callback handling from elm Object to evas SO and inherit 2015-03-10 22:53:16 +02:00
Kai Huuhko a11fadc82d Evas.SmartObject: Handle object deletion in a saner way
Evas free event gets called last, we free resources there so that the
SO callbacks can call with a valid object reference.
2015-03-10 00:04:28 +02:00
Kai Huuhko d416425f51 Evas.SmartObject: Trivial changes
Removed cruft, upgraded cls == NULL log message level to ERR,
added formatter to SO example logging.
2015-03-09 21:01:55 +02:00
Kai Huuhko fbc22d850d Make Evas.SO iterator a generic Eo iterator and move to efl.eo 2015-03-09 19:36:42 +02:00
Kai Huuhko 16f04ee2ec Evas.SmartObject: Move documentation to right places 2015-03-09 17:40:34 +02:00
Kai Huuhko 9dbff82aac Evas: Copy SO methods member_add/del to Object.smart_member_add/del 2015-03-09 13:11:15 +02:00
Kai Huuhko 3dd81c4f60 Evas.SmartObject: Switch to using C implementation of ClippedSO 2015-03-08 23:48:21 +02:00
Kai Huuhko 9e86901b0d Evas.SmartObject: Add unicode/py3k safety to callback methods 2015-03-08 23:47:07 +02:00
Kai Huuhko c61e4912e7 Evas.SmartObject: Allow callback calls even when obj is NULL 2015-03-08 20:06:32 +02:00
Kai Huuhko 204aecc746 Evas.SmartObject: Use the correct function when deleting data 2015-03-08 20:04:50 +02:00
Kai Huuhko f3a5b44151 Evas.SmartObject: Add smart_get, commented out parent getter
Need to test if we can use Eo parent_get to do the same thing.
2015-03-08 19:35:47 +02:00
Kai Huuhko c1e51903fe Evas.SmartObject: Fix crash when Smart is re-used 2015-03-08 19:20:58 +02:00
Kai Huuhko 3d7b940631 Evas: Remove now redundant SmartObject metaclass 2015-03-08 18:18:01 +02:00
Kai Huuhko db5663773e Evas.SmartObject: Fix issues in the new API implementation 2015-03-08 18:15:26 +02:00
Kai Huuhko 4af81e96a7 Evas.SmartObject: rewrite because of changes in Cython 0.21.1
Unfortunately it was impossible to keep api compatibility.

Compiles but didn't test it yet, need to rewrite the tests and
examples too.
2015-03-07 21:38:08 +02:00
Kai Huuhko d3357619f7 Evas: Bring back SmartObject
Possible TODO: support per-child delete cb like in C
2015-03-05 21:07:38 +02:00
Kai Huuhko ded0c5fd06 Elementary: Documentation fixes 2015-03-05 14:19:48 +02:00
Kai Huuhko 5fdfe2e553 Elementary.scroller: Make ScrollerWidget private
We now also disallow Scrollable initialization.

Hopefully these changes clarify the intended usage of these classes.
2015-03-03 17:26:45 +02:00
Kai Huuhko 2a1a08ae40 Elementary.scroller: Documentation fixes 2015-03-03 14:11:03 +02:00
Kai Huuhko 4fedd07228 Elementary.box: Add an iterator for Box's children
Usage example:

  box = Box(parent)
  box.pack_end(mychild)

  for child in box:
      print(child)
2015-03-02 10:16:34 +02:00
Kai Huuhko 5efbb8810b Evas: Optimize rect getters class initialization 2015-03-02 09:02:51 +02:00
Kai Huuhko 65d68e7aee Evas.Rect: Optimizations
Freelist will keep Rect objects around for quick instancing,
casts to extension type will skip unnecessary type tests.
2015-03-02 07:55:16 +02:00
Kai Huuhko 460d749aef Evas.Rect: Rename intercepts to intersects, correct the algorithm
It now uses the same algorithm as eina_rectangle
2015-03-02 05:22:57 +02:00
Kai Huuhko f18ddbf87c Elementary.window: Improve documentation of Window constructor 2015-02-26 05:42:30 +02:00
Kai Huuhko 9c801a9416 Elementary.systray: Follow Eo changes 2015-02-26 05:40:56 +02:00
Kai Huuhko ff83ec4266 Evas: Rename Object.parent_get to smart_parent_get
It was clashing with Eo.parent_get and is more correct in regards
to C api naming.
2015-02-25 23:41:14 +02:00
Davide Andreoli 9afb74906b Fix code to conform to recent Eo changes. 2015-02-25 21:44:31 +01:00
Kai Huuhko 2ce228be96 Elementary: Add module systray
Test/example needs more work
2015-02-21 05:41:14 +02:00
Davide Andreoli d141a912e5 Fix Photocam.internal_image to actually work
This property/get_function was totally wrong :(
2015-02-21 00:19:50 +01:00
Davide Andreoli 9428a7418e Fix Scroller doc 2015-02-20 20:45:22 +01:00
Davide Andreoli 4b7d08e38a Fix for cython 0.22 2015-02-19 20:22:39 +01:00
Davide Andreoli 65ff1c8217 Image.memfile_set: do not raise exceptions.
The first raise (when img do not support the buffer interface) is useless,
as python yet raise the same TypeError exception.

The latter is removed to be consistent with the docs and the C api,
so return a bool and do not rise the exception. We are going to move
to autogeneration sooner or later, so we must keep the api as much
as possible close to the C one, to minimize the future effort of porting
applications.
2015-02-16 20:57:25 +01:00
Davide Andreoli b4fcee3de2 Use consistent indentation style with the rest of the code 2015-02-16 20:38:25 +01:00
Kai Huuhko 31a6f559b0 Elementary.image: Add memfile support 2015-02-16 14:54:26 +02:00
Davide Andreoli 1ccc6012d8 Fix the signature of the un/highlight List callback to include the item.
Also fixed docs for all the other item callbacks, sorry for the noise.
2015-02-15 14:31:50 +01:00
Davide Andreoli ca7b737d67 Now start the 1.14 development cycle 2015-02-09 23:24:51 +01:00
Davide Andreoli c64ca0fa1a Rollup stable 1.13.0 release 2015-02-09 20:18:06 +01:00
Davide Andreoli 8106e2b1aa fixed elm.Entry.cursor_content_get() to not crash when called
With a new test Entry Notepad
2015-02-07 20:07:55 +01:00
Davide Andreoli fb09f3dad5 Deprecate elm.Configuration.engine and preferred_engine
Also fix misnamed _accel_preference_set() (removed trailing _)

and bumped version to beta2
2015-02-07 12:12:40 +01:00
Davide Andreoli c6508c52bb Include the betaX in dist package name.
This will generate the 1.13.0-beta1 pre-release
2015-02-07 11:25:51 +01:00
Davide Andreoli 806fad39cb Prepare a first 1.13.0 pre-release 2015-02-03 20:51:35 +01:00
Davide Andreoli 7eb3217a69 Restructured Emotion docs 2015-01-31 17:21:32 +01:00
Davide Andreoli 24025e6d81 Restructured edje docs 2015-01-31 17:14:42 +01:00
Davide Andreoli 1d8ffd1ed4 Restructured eo docs 2015-01-31 17:00:18 +01:00
Davide Andreoli 588d28ab12 Restructured ecore doc 2015-01-31 16:51:54 +01:00
Davide Andreoli a4273b1095 Docs: improved evas pages 2015-01-19 23:34:28 +01:00
Davide Andreoli 660c0a7e51 Huge documentation work
Improved structure, contents and style for better readability
2015-01-18 19:07:06 +01:00
Davide Andreoli 928f802ed4 Docs: update Window texts 2015-01-18 10:27:21 +01:00
Davide Andreoli 28d1e6853e New 1.13 property elm.Table.align
And small improvements to the table test
2015-01-17 17:47:58 +01:00
Davide Andreoli f0d76df693 New 1.13 signal clicked,right for Gengrid and List 2015-01-17 17:09:14 +01:00
Davide Andreoli 77d14470c4 New 1.13 elm.Transit.tween_mode_factor_n_set
Also added some missing TRANSIT_TWEEN_MODE_*
2015-01-17 15:55:47 +01:00
Davide Andreoli 308f93a145 New 1.13 signal for elm.Win theme,changed 2015-01-17 12:18:29 +01:00
Davide Andreoli 114cfaaa00 New 1.13 property elm.Configuration.slider_indicator_visible_mode 2015-01-17 12:13:25 +01:00
Davide Andreoli 49d409db3a New 1.13 property evas.Map.util_object_move_sync 2015-01-17 11:38:26 +01:00
Davide Andreoli 64e9c9ac96 New 1.13 property Scroller.step_size 2015-01-17 10:38:08 +01:00
Davide Andreoli 852d472db8 Fix doc for theme.theme_list_item_path_get.
This function is quite of broken in py, the in_search_path param is not used
and should instead be returned along the returned path. That will result in
an api break so Im leaving it as is.
2015-01-16 22:54:31 +01:00
Davide Andreoli b18b8c0d8c Fix documentation for the Theme class 2015-01-16 22:47:18 +01:00
Davide Andreoli c1aeafd2e1 GengridItem: no more need to implement tooltip/cursor functions
They are yet implemented in ObjectItem, that is the base class for GengridItem
2015-01-14 21:49:06 +01:00
Davide Andreoli be323e24bc GenlistItem: no more need to implement tooltip/cursor functions
They are yet implemented in ObjectItem, that is the base class for GenlistItem
2015-01-14 21:37:17 +01:00
Davide Andreoli 7687adb6d9 Doc: restructure edje and emotion documentation 2015-01-09 20:54:59 +01:00
Davide Andreoli 29d1b41f44 Docs: removed some really old evas writes, they do not apply anymore 2015-01-06 21:35:36 +01:00
Davide Andreoli f91999ac49 Fix doc build errors removing refs to ecore.x and SmartObject 2015-01-06 18:10:43 +01:00
Davide Andreoli 783e2ba6c8 Evas.Object: New convenience props, size_hint_expand and size_hint_fill
Also added some docs for size hints usage
2015-01-06 17:46:18 +01:00
Davide Andreoli d368d64d3f Provide a new distutils Command: build_fdo
This will take care of installing any icons and .desktop files found
2015-01-05 19:08:49 +01:00
Davide Andreoli de01f76650 Evas: better define for EVAS_HINT_FILL/EXPAND
Also added the various tuple we always use, just for convenience.

Use the new tuples in the elm examples
2015-01-05 12:24:19 +01:00
Davide Andreoli 9be98bb979 And (finally) new style enums for elm 2015-01-05 01:16:03 +01:00
Davide Andreoli bbb747eb5e New style enums for eo 2015-01-04 22:30:19 +01:00
Davide Andreoli 728ff202e4 New style enums for emotion 2015-01-04 22:12:08 +01:00
Davide Andreoli e6d3a88349 New style enums for edje_edit 2015-01-04 22:04:36 +01:00
Davide Andreoli 3ebc6f21e9 New style enums for edje 2015-01-04 22:02:09 +01:00
Davide Andreoli 419405e456 New style enums for ecore 2015-01-04 21:29:40 +01:00
Davide Andreoli f9e8906724 Use new cython cpdef-enums in evas
cpdef enums are automatically exported to C and
to python, no more need for the enums file and
the duplicated definition for py.

This is a cython 0.21 feature so from now on you will
need at least that version.

Require some <int> cast here and there, but a totally
win in the end.
2015-01-04 20:44:45 +01:00
Davide Andreoli 7b135c2012 Small doc fixes 2015-01-04 14:39:53 +01:00
Davide Andreoli 84a09b61b6 Remove specific X code from elm
Just using unsigned int for the Ecore_X_ID type
2015-01-04 14:34:04 +01:00
Davide Andreoli 027505f45a Move ecore enums with all the other enums files 2015-01-04 13:14:06 +01:00
Davide Andreoli 8d99fc8b40 Remove old (moved) ecore.x files 2015-01-04 12:51:38 +01:00
Davide Andreoli 863efc19eb Move ecore_x out of the ecore extension
Now ecore do not more looks like an alien with his __init__
hack and his different module/package structure

This broke ecore.x users as the extension is now efl.ecore_x

Sorry to bother but I still think that ecore_x should not be
implemented in python, if this hurt you please let me know
2015-01-04 12:47:40 +01:00
Davide Andreoli 1910563604 Docs: fix some text to not show up
Pygments css for some highlightend text are the same color of our gray bg, just make them white
2015-01-03 20:25:47 +01:00
Davide Andreoli 6ff9998258 Lots of documentation fixes for ALL the classes
Mainly with regard of class __init__ params and the **keyword param
2015-01-03 20:17:24 +01:00
Davide Andreoli 64c1d33c9f Added new convenience class: DialogWindow
With a new test for both StandardWindow and DialogWindow
2015-01-03 14:51:08 +01:00
Davide Andreoli 1746a0acdd Docs for fdo icon names 2015-01-03 12:54:52 +01:00
Davide Andreoli 5c8bb29d78 New distutils command: uninstall 2015-01-02 21:36:21 +01:00
Davide Andreoli a4f2cc37cc Another year has passed... 2015-01-02 20:03:53 +01:00
Davide Andreoli e4a3616613 Provide a new distutil command: build_edc 2015-01-02 19:46:06 +01:00
Davide Andreoli 08170d1fd4 Disable evas.SmartObject to workaround Cython brakage.
SmartObject do work fully in real, thay probably need a full rewrite,
so this should not harm at all.

Also disabled tests and examples
2015-01-02 13:25:44 +01:00
Davide Andreoli 99c5e47ca5 Fix a distutils import 2015-01-01 22:27:37 +01:00
Davide Andreoli 3a3cb85634 Cython warnings-- 2015-01-01 22:08:27 +01:00
Davide Andreoli 6fe657d979 Added new efl.utils.setup pure python module
This module contain some distutils commands that can be used
by apps in the setup.py script
2015-01-01 21:19:10 +01:00
Davide Andreoli 9e2ad3382e elm.Theme: added group_base_list_get() function 2014-12-31 12:42:08 +01:00
Davide Andreoli b642c60b84 Genlist: new clicked,right signal 2014-12-26 19:30:18 +01:00
Davide Andreoli d6ab0de2dd Better docs for available Genlist item styles 2014-12-25 13:15:23 +01:00
Davide Andreoli 8fd9a0021e Fix elm.ObjectItem.part_content_set() to accept a generic EvasObject.
...not only an elm object.
2014-12-03 21:11:39 +01:00
Davide Andreoli e8c61e7690 Reopen developement for 1.13 release 2014-11-23 20:25:26 +01:00
Davide Andreoli b6ca4649a6 Roll-up the 1.12 release 2014-11-22 16:52:46 +01:00
Davide Andreoli 2582c32800 New 1.12 enums: Input panel variations 2014-11-22 16:02:29 +01:00
Davide Andreoli 60e7e94889 New 1.12 API: edje_object_base_scale_get
With proper test
2014-11-22 15:21:00 +01:00
Davide Andreoli 5e8a644f24 New 1.12 API: elm_fileselector_current_name_set/get
With proper test
2014-11-22 15:11:23 +01:00
Davide Andreoli 3be938511f New 1.12 API: elm_panel_scrollable_set/get/content_size_set
Also improved the test for panel and added a new test for scrollable panel.
2014-11-22 14:33:47 +01:00
Davide Andreoli d3f98802b0 Optimize the _set_properties_from_keyword_args() function.
We do not need to check if the attribute exist to raise an exception, setattr() yet raise a well formatted expection in case of failure.

This way we avoid a dir() call and an IN check in a hot path.

The only drawback is that this change the raised exception in the case an attr not exist, from  AssertionError to AttributeError... I hope none was using that eception explicitly.
2014-11-22 14:25:39 +01:00
Davide Andreoli da1807c379 New 1.12 API: elm_process_state_get 2014-11-18 21:42:31 +01:00
Davide Andreoli 5668d30498 New 1.12 API: elm_entry_input_hint_set/get 2014-11-18 21:12:26 +01:00
Davide Andreoli 8f05e1c177 New 1.12 api: edje_object_part_text_input_hint_set/get 2014-11-18 20:55:12 +01:00
Kai Huuhko 40cedb0e4b Elm.menu: Fix documentation for item_add parameters
icon and label are in fact reversed in our API when compared to C API.
2014-10-05 21:11:40 +03:00
Davide Andreoli 6fe9080af1 Make cython 0.21 happy
Simplify the statement so that it also compile with newer cythons
2014-09-22 18:47:42 +02:00
Kai Huuhko ffeb5aaf2c Release 1.11.0 2014-09-13 18:43:11 +03:00
Kai Huuhko 5543852d54 Examples: Add description to elm web exceptions, trivial updates to test 2014-09-13 18:16:17 +03:00
Davide Andreoli d3794d9566 No need to call ecore init/shutodown here
they are called in e_dbus_init/shutdown
2014-08-23 21:15:46 +02:00
Davide Andreoli 3544e7408f Cleanup, remove unused stuff 2014-08-23 20:42:19 +02:00
Davide Andreoli d0bea312ef dbus_mainloop: reworked how we manage the dbus watch requests.
Dbus can request (via watch_add) more than one watch on the same fd (one
for write and one for read), but ecore cannot setup more than one fd_handler
on the same fd. So we need to manage this (weired) case internally, reusing
an existing fd_handler for more than one dbus watch.

This, at the end of the story, fix the ability to connect to the (fucking) PulseAudio
dbus server, that do not use the Session or System buses, but provide its own bus.
2014-08-23 20:37:15 +02:00
Davide Andreoli bc02e43181 Cleanups: the filter are not used here
and the ecore_event is not used enywhere
2014-08-23 17:59:22 +02:00
Davide Andreoli 1de3ffccd6 Simplify: no need to keep a local copy of the watch state 2014-08-23 17:34:37 +02:00
Davide Andreoli 6d5a1d1169 use 3 spaces indentation, not 2 2014-08-23 17:06:28 +02:00
Davide Andreoli a41106348a added extra debug info (to be manually enabled) 2014-08-23 16:50:16 +02:00
Davide Andreoli e592aa9647 renamed a function to a better name 2014-08-23 16:17:18 +02:00
Davide Andreoli e5d3ea2e96 just move some functions around for readability 2014-08-23 15:56:09 +02:00
Davide Andreoli c7ae54df15 Add version info in the efl package.
Also removed the logger import in efl, not usefull and only create problems
2014-08-16 14:11:06 +02:00
Davide Andreoli 9a78c4e22d Expose object_from_instance and the inverse to other C code
This create the efl.eo_api.h file that you can copy to your source if you want to use the exported api
2014-08-16 12:33:29 +02:00
Davide Andreoli 042dc0f835 emotion: implemented missed smart signals 2014-08-11 23:30:46 +02:00
Davide Andreoli 0567c52013 Fix emotion.__repr__ function
self.type_get() is not a function, dunno what was the intention here
2014-08-04 17:24:05 +02:00
Davide Andreoli a4d321dacc Gengrid: new property reorder_type, with test for reorder mode 2014-08-01 18:14:55 +02:00
Davide Andreoli f5dd70b70f Gengrid: implemented search_by_text_item_get(), with a proper test 2014-08-01 17:31:09 +02:00
Davide Andreoli d8174aea3d Genlist: implemented search_by_text_item_get(), with a proper test 2014-08-01 16:31:24 +02:00
Davide Andreoli 401145f4fa Toolbar: new un/selected signals, with tests 2014-08-01 13:35:50 +02:00
Davide Andreoli a97e61dd4f Ctxpopup: new getters for items and the item_prepend method, with tests 2014-07-31 22:18:41 +02:00
Davide Andreoli 5aa12930a1 Implemented missed ecore.x screensaver functions 2014-07-31 21:23:35 +02:00
Davide Andreoli 1af5adb8cd Panes: new content_[left/right]_min_[relative]_size properties 2014-07-31 17:01:53 +02:00
Davide Andreoli f9247fa99f New Map function: region_zoom_bring_in 2014-07-31 16:11:26 +02:00
Kai Huuhko bb77d08ed9 Elementary: Fix object item tooltips
It would be an ABI breakage if the tooltips had ever worked in
the first place but apparently they never did.
2014-07-01 20:41:47 +03:00
Davide Andreoli 2a303f29e1 Follow recent Eo class names changes 2014-06-30 20:52:36 +02:00
Kai Huuhko a0ecc41572 Elementary.entry: Fix ref leak in filter callback handling. 2014-06-05 18:16:14 +03:00