Commit Graph

172 Commits

Author SHA1 Message Date
Cedric BAIL 018a9dad66 * edje: Use Eina_Log.
Patch from Mathieu Taillefumier.


SVN revision: 44655
2009-12-22 13:46:00 +00:00
Cedric BAIL b32c9a3eae * edje: Add Fixed Point Math support to Edje.
You can try it by passing --enable-fixed-point to the configure. It
	will produce an ABI/API compatible Edje library that use internally
	Eina_F32p32 instead of double. It will load Eina_F32p32 instead of
	double from eet file (thanks to eet ability to convert them on the
	fly), so edje file are compatible between fixed point and floating
	point version.

	This patch touch almost all internal calc of Edje, I did test it with
	elementary_test, enlightenment and all my test apps, but it could
	certainly break some of your preferred Edje file. If you see any
	unexpected behaviour please report them to me as soon as possible.

	Note: For devs, I put few macros in edje_private.h that should now
	be used when doing calc in Edje, please use them so that Fixed Point
	doesn't break in the futur.


SVN revision: 44323
2009-12-09 15:44:54 +00:00
Iván Briano 521c89df41 dont segv if theres no file
SVN revision: 43958
2009-11-24 21:08:52 +00:00
Iván Briano 9892926bdf Autoload modules for external widgets
Patch by Fabiano Fidencio


SVN revision: 43951
2009-11-24 17:55:11 +00:00
Carsten Haitzler 3b07a3d255 fix segv on obj del - didnt remove callbacks!
SVN revision: 43596
2009-11-09 23:47:42 +00:00
Iván Briano 2ba79e04af Some more stuff in externals, little api change there, may change some more later.
SVN revision: 43379
2009-10-31 18:07:08 +00:00
Iván Briano 22952844c4 and bring external back now that the file was added
SVN revision: 43306
2009-10-27 01:08:19 +00:00
Carsten Haitzler d3fd0c30cb REVERT! broke edje.
try again and dont forget to add edje_external.c! (and any others needing
adding)



SVN revision: 43304
2009-10-27 00:27:50 +00:00
Iván Briano 68756f92b2 External objects support by Brian 'rephorm' Mattern
Since we are on a freeze, the patch goes on updated to current svn, but without changing its API. After the freeze some things will be added, and some will change :)


SVN revision: 43302
2009-10-26 21:33:56 +00:00
Vincent Torri cbcf159c27 warning--
SVN revision: 43266
2009-10-25 12:17:05 +00:00
Hannes Janetzek e7d76f6392 also remove text class members on object deletion
SVN revision: 42397
2009-09-11 00:48:57 +00:00
Vincent Torri 8b2bd0c079 * remove unused parameters (except in edje_lua.c, as i don't know the current status)
* remove unused variables


SVN revision: 41957
2009-08-24 16:40:42 +00:00
Hanspeter Portner da75132793 From: "Hanspeter Portner" <ventosus@airpost.net>
This concerns Ticket #109: Add Lua support for Edje

It adds Lua as scripting facility to Edje, letting Embryo untouched.
It should be easier to use and be more flexible than Embryo, imho ;-)

---
The patch
---

Lua 5.1 is used in sandboxed mode. Lua byte code is not
platform/architecture independent, Lua code is saved as text in the Edje
container and parsed at load time, therefore.

The patch goes in two directions

1) Analogous to Embryo for scripting logic, messaging and custom states.
The same things are implemented as in Embryo:

    - messaging from and to C
        - manual creation of timers, animators, pollers for custom events /
            animations
                - manual manipulation of Edje parts by means of the public
                    edje_object_part_* and internal functions and custom states
                    
                        -> those routines are actually implemented as Lua
bindings to
    functions in Edje.h and Ecore.h
        -> the implementation is done in an object oriented way, so that the
            interface gives the feel of an object description language, pretty
                similar to EDC itself
                    -> combining custom states and custom animators allows
for fancy
    animations and transitions, e.g circular/spline translations or
        complex/conditional transitions, etc.
            -> this is just the same as Embryo does, but implemented in Lua, so
                nothing new here, actually
                
                2) Dynamic object creation and manipulation
                
                    - this interface stems from the 'script_only' objects in
Edje. Those
    objects are a kind of scriptable Edje counterparts to Evas_Smart
        objects. The infrastructure for Embryo is already there, but has
            never been used
                - I added this in Lua and added some first bindings to
experiment
    with
        - I thought it would be useful to allow for a limited dynamic
            creation of ui parts
                - We can create instances of groups from within the same Edje
                    container and use them just like the main Edje object as
stated in
    1)
        - And there are some stand-alone bindings to dynamically create
            Evas_Image, Evas_Table, Evas_Line, Evas_Polygon as examples
            
                -> this may be useful to decouple the program from the ui
even more,
    to be able to do things that have to be done in the program itself
        atm, but actually belong to the user interface, but need dynamic
            creation of objects or complex interactions
                -> those objects are manipulated manually with Lua bindings
to the
    corresponding edje_object_* and evas_object_* functions
    
    ---
    Discussion points
    ---
    
    Both stuff in 1) & 2) is functioning, but needs testing, feedback,
    improvements, ...
    
    Stuff in 1) can already fully replace Embryo scripting with Lua
    scripting. There still is space for improvements/additions, though.
    
    Of the stuff in 2), I think it may only make sense to add the dynamic
    creation of groups defined in the same Edje container.  Dynamic creation
    of other Evas_Objects makes not much sense, as most of them can already
    be used as Edje parts and be manipulated with custom states (apart from
    polygons and lines) and it would make the whole theming potentially more
    programing-like and much more susceptible for errors, etc.
    
    Would this be useful, or drop it all?
    
    The scripting should be there just for logic, conditionals, custom
    states and animations, not for a whole dynamic canvas, imho.
    
    There is a patch around with EXTERNAL Edje parts. Seems to be a better,
    faster, more secure way to extend Edje with custom objects.
    
    There would be the possibility of precompiling Lua code at compile time
    (edje_cc) for faster loading, but we would have to patch and run our own
    Lua version.
    The Lua parser is pretty fast, though, and using
    byte-converted/endianness-swapped byte-code does only pay off for Lua
    chunks of some kilo lines.
    Byte code also occupies much more space than text in the final Edje
    container, as it includes debug symbols.
    
    ---
    
    Cedric and Vincent told me, that the plan was to replace Embryo totally
    by Lua before the official release of Edje at the end of the year? So it
    would make sense to bring Lua to svn soon and look how it fits in, test,
    debug, adapt it further to the themers needs, decide on its final shape,
    GATHER SOME PEOPLE TO HELP ;-)
    
    ---
    
    The Lua enhanced Edje is in sync with svn and can be get directly here
       git clone git://repo.or.cz/edje_lua.git
          cd edje_lua
             git checkout -b lua_patch origin/lua_patch
             
             or apply the attached patch
             
             There are also some examples to show the usage of the things
mentioned
above
    - showcase.edj: shows usage of custom animators, custom states,
        messaging and the script_only object
            - test.edj: test cases of script usage and bindings (custom states,
                custom transitions, tween_states, animators, timers,
object_parts),
    but most of it are experimental script_only objects
    
    http://didgmo.sourceforge.net/showcase.edj
    http://didgmo.sourceforge.net/test.edj
    
    The source of showcase.edc is attached, too, to just have a glimpse at
    Lua inside of EDC
    
    ---
    
    So, what do you guys think?
    
    Thanks and sry for the looong mail, hehe ;-)



SVN revision: 41802
2009-08-16 02:34:02 +00:00
Cedric BAIL 7df190d264 * edje_calc: Major cleanup.
- Edje_Real_Part use less memory.
		- Edje_Real_Part and Edje_Real_Part_State now use a mempool.
		- When both param1 and param2 are the same, only recalc param1.
		- Don't compute Edje_Real_Part more than one time per edje_recalc_do.



SVN revision: 41771
2009-08-14 17:19:42 +00:00
Cedric BAIL 8170df024a * edje: Oops, fix drag.
SVN revision: 41691
2009-08-11 14:55:26 +00:00
Cedric BAIL b69abd204f * edje: Free the Edje_Real_Part_Drag.
SVN revision: 41686
2009-08-11 13:07:46 +00:00
Cedric BAIL d16bbd3953 * edje: Make Edje_Real_Part_Drag a pointer. Win 100 bytes per states.
SVN revision: 41685
2009-08-11 12:47:00 +00:00
Cedric BAIL 9807d2e4c8 * edje: More cleanup of Edje_Real_Part.
SVN revision: 41683
2009-08-11 10:32:21 +00:00
Cedric BAIL 7047c5f561 * edje: Cleanup drag part of Edje_Real_Part.
SVN revision: 41682
2009-08-11 10:17:14 +00:00
Cedric BAIL b6a228e3eb * edje_load: More cleanup.
SVN revision: 41680
2009-08-11 10:06:37 +00:00
Cedric BAIL 922939d832 * edje: Some cleanup, mainly removing dead code.
SVN revision: 41679
2009-08-11 09:45:06 +00:00
Cedric BAIL 7f9a41a824 * edje: Add a cache for _edje_part_recalc_single.
WARNING: THIS CAN CAUSE RENDERING GLITCH AND OTHER WEIRD BEHAVIOUR WITH
	YOUR EDJE FILE. PLEASE REPORT ANY ALIEN STUFF.

	Note: This patch cache the result of _edje_part_recalc_single, until
	any relative part are moved, the object is resized or some property
	are changed (like during text set or color class set).

	Note: Be carefull when you call edje_object_size_min_restricted_calc,
	it's really an inderect heavy user of _edje_part_recalc_single and
	I wasn't able to bring it down.

	Note: This patch use more RAM, around 480 bytes per Edje state, so I
	don't recommand using it on a Desktop with a lot of CPU power.


SVN revision: 41663
2009-08-10 15:16:51 +00:00
Carsten Haitzler 02fef22de9 move adding of events if entry only if entry part exists.
SVN revision: 41103
2009-06-18 14:01:26 +00:00
Andreas Volz a5af5b19d7 updated docu
SVN revision: 40808
2009-05-24 08:24:32 +00:00
Gustavo Sverzut Barbieri b1f00aa9d5 edjeL convert error code to string.
SVN revision: 38268
2008-12-21 18:39:36 +00:00
Iván Briano 7f3dfc66f2 And finally, edje table goes in
SVN revision: 38204
2008-12-18 02:43:20 +00:00
Cedric BAIL e33474c92f Move to eina_hash. Nothing should break, but if you experience any unexpected behaviour
please ping me on #edevelop.



SVN revision: 38183
2008-12-17 14:26:47 +00:00
Sebastian Dransfeld 4615291cc2 evas_hash -> eina_hash
SVN revision: 38157
2008-12-15 21:00:19 +00:00
Cedric BAIL 2c668d6747 The for loop inside _edje_file_del is accessing Edje_Real_Part that could be
destroyed by _edje_cache_coll_unref. So moving the call to _edje_cache_coll_unref
after the last use of Edje_Real_Part should be better.


SVN revision: 38020
2008-12-08 14:23:26 +00:00
Gustavo Sverzut Barbieri 2f8f874b20 Shut up a bunch of warnings and fix some real errors.
SVN revision: 37954
2008-12-06 03:08:17 +00:00
Carsten Haitzler 90d3729897 bad edje! leak! fix fix!
SVN revision: 37840
2008-11-28 13:54:21 +00:00
Iván Briano 0ee4d07727 Edje Box in. Have fun with it.
SVN revision: 37783
2008-11-24 05:15:15 +00:00
Carsten Haitzler ba0bf9010f and actually force styles to be assigned early.
SVN revision: 37695
2008-11-18 01:46:56 +00:00
Carsten Haitzler 38f06f34e8 track subobjs (used by entry only for now) and emit signals to them too
SVN revision: 37688
2008-11-17 05:54:01 +00:00
Sebastian Dransfeld b2fa64de52 Formatting
SVN revision: 37626
2008-11-14 17:35:05 +00:00
Cedric BAIL 25f4acee01 This is a quick fix for edje match memory consuption. It is not the best
solution, but the fastest to implement without breaking edje file format.

So now, when a callback or a program don't use globbing charactere (*, ?,
[] and \), the match are put in a little rbtree instead of the big automate
matrix.

This patch could potentially break edje user, if you experience anything
strange with your edje file, please report.



SVN revision: 37577
2008-11-10 16:37:52 +00:00
Vincent Torri 0d8b00fdeb * move standard header files to source files
* remove gendoc


SVN revision: 37158
2008-10-26 17:18:19 +00:00
Cedric BAIL fa66dbf40a Remove Evas list from Edje and use Eina instead.
SVN revision: 36961
2008-10-22 11:34:42 +00:00
Cedric BAIL b489e1936b Switch evas_stringshare to eina_stringshare.
SVN revision: 36672
2008-10-15 14:11:11 +00:00
Carsten Haitzler ce0d40cae7 editable textblocks... a start (definitely not there yet)
SVN revision: 36611
2008-10-13 09:19:04 +00:00
Cedric BAIL 060f30aa6e Make EDJE_PROGRAM_CACHE configurable with autotools (with small fix for make it run again).
SVN revision: 35942
2008-09-11 11:14:39 +00:00
Cedric BAIL dec2f04734 Actually call eet_init/eet_shutdown and fix another potential memory leak.
SVN revision: 35615
2008-08-22 14:32:25 +00:00
Gustavo Sverzut Barbieri d428d6ec1d Add some consts to Edje's API.
Some methods do no change object internal state and can be marked as
read only. In parallel have infamous edje_object_part_object_get() to
return a read-only object, so it's even more clear that one should not
touch this object state (either a cast or a compiler warning if you do
that!)


SVN revision: 35485
2008-08-14 18:21:27 +00:00
Gustavo Sverzut Barbieri a85c8a5f2b Fix name incoherency: rename Edje->part to group.
It is very confusing to have "part" there and in the methods call,
because we want the group name, not part.


SVN revision: 35483
2008-08-14 18:04:43 +00:00
Carsten Haitzler e84a969a69 fix string len problem
SVN revision: 35305
2008-08-02 01:33:39 +00:00
doursse c5623c01b3 reorganize header files inclusion. Fix some problems when compiling on Windows
SVN revision: 34768
2008-06-07 10:06:14 +00:00
Carsten Haitzler 1c7b215135 printf--
SVN revision: 34702
2008-05-30 14:27:56 +00:00
Carsten Haitzler 15cd1238db start some serious work on script_only edje objects - for efficiency sake i'm
having an almost parallel codepath for script_only objects - they dont get to
use the older edje api calls for part defined objects. they will have a new
set of calls specifically for them. it's partly done - very little available
now, but will expand. lots of fixme's.


SVN revision: 34699
2008-05-30 11:20:49 +00:00
Carsten Haitzler 0e4c0eb8ec cedric small speedups patches for edje back in - minus the ones that break
things. (0004).


SVN revision: 34234
2008-04-10 08:58:19 +00:00
Carsten Haitzler ff6fb2e3bf actually. these patches broke illume! aaak! revert.!
SVN revision: 34180
2008-04-03 19:27:53 +00:00