efl: add Efl.Gfx.Base and fix inheritance for Evas_Object. 55/43255/1
authorCedric BAIL <cedric@osg.samsung.com>
Tue, 3 Feb 2015 21:51:42 +0000 (22:51 +0100)
committerSubhransu Mohanty <sub.mohanty@samsung.com>
Wed, 8 Jul 2015 02:09:33 +0000 (11:09 +0900)
Change-Id: I1715f2f5bcc48769421098758b81fcbb1bdca768

13 files changed:
src/Makefile_Efl.am
src/Makefile_Efl_Cxx.am
src/lib/edje/edje_calc.c
src/lib/edje/edje_text.c
src/lib/efl/Efl.h
src/lib/efl/interfaces/efl_gfx_base.eo [new file with mode: 0644]
src/lib/efl/interfaces/efl_interfaces_main.c
src/lib/evas/Evas_Legacy.h
src/lib/evas/canvas/evas_object.eo
src/lib/evas/canvas/evas_object_main.c
src/lib/evas/canvas/evas_object_text.c
src/lib/evas/canvas/evas_text.eo
src/tests/evas/evas_test_filters.c

index 38f7ba81778ff5e3d4d73c065570915f9c2c4546..25250201567d7a5b3cae9636be8b85edf155cfdc 100644 (file)
@@ -5,6 +5,7 @@ efl_eolian_files = \
       lib/efl/interfaces/efl_player.eo \
       lib/efl/interfaces/efl_text.eo \
       lib/efl/interfaces/efl_text_properties.eo \
+      lib/efl/interfaces/efl_gfx_base.eo \
       lib/efl/interfaces/efl_gfx_shape.eo \
       lib/efl/interfaces/efl_gfx_gradient.eo \
       lib/efl/interfaces/efl_gfx_gradient_linear.eo \
index 1ddd25dc4995b0f7d20058f2e9b6a7ea18f0ee04..6d28e97420f05d7084b9736c6f6ea27c1dc4c007 100644 (file)
@@ -8,7 +8,8 @@ generated_efl_cxx_bindings = \
                  lib/efl/interfaces/efl_image.eo.hh \
                  lib/efl/interfaces/efl_player.eo.hh \
                  lib/efl/interfaces/efl_text.eo.hh \
-                 lib/efl/interfaces/efl_text_properties.eo.hh
+                 lib/efl/interfaces/efl_text_properties.eo.hh \
+                lib/efl/interfaces/efl_gfx_base.eo.hh
 
 lib/efl/Efl.hh: $(generated_efl_cxx_bindings)
        @echo @ECHO_E@ "#ifndef EFL_CXX_EDJE_HH\n#define EFL_CXX_EDJE_HH\n" > $(top_builddir)/src/lib/efl/Efl.hh
index eab8ab1b88bbb2112e5bdc03b0ad8dd747390ab5..558c23202eb2511eeceb50facd64e399ffe2abfc 100644 (file)
@@ -1397,7 +1397,7 @@ _edje_part_recalc_single_textblock(FLOAT_T sc,
                   if (!chosen_desc->text.min_x)
                     {
                       eo_do(ep->object,
-                            evas_obj_size_set(TO_INT(params->eval.w), TO_INT(params->eval.h)),
+                            efl_gfx_size_set(TO_INT(params->eval.w), TO_INT(params->eval.h)),
                             evas_obj_textblock_size_formatted_get(&tw, &th));
                     }
                   else
@@ -1425,7 +1425,7 @@ _edje_part_recalc_single_textblock(FLOAT_T sc,
              if (!chosen_desc->text.max_x)
                {
                  eo_do(ep->object,
-                       evas_obj_size_set(TO_INT(params->eval.w), TO_INT(params->eval.h)),
+                       efl_gfx_size_set(TO_INT(params->eval.w), TO_INT(params->eval.h)),
                        evas_obj_textblock_size_formatted_get(&tw, &th));
                }
              else
@@ -1513,7 +1513,7 @@ _edje_part_recalc_single_text(FLOAT_T sc EINA_UNUSED,
      return;
 
    // Note: No need to add padding to that, it's already in the geometry
-   eo_do(ep->object, evas_obj_size_get(&mw, &mh));
+   eo_do(ep->object, efl_gfx_size_get(&mw, &mh));
 
    if (chosen_desc->text.max_x)
      {
@@ -1673,7 +1673,7 @@ _edje_part_recalc_single_text(FLOAT_T sc EINA_UNUSED,
             eo_do(ep->object,
                   evas_obj_text_style_set(style),
                   evas_obj_text_set(text),
-                  evas_obj_size_get(&tw, &th));
+                  efl_gfx_size_get(&tw, &th));
              if (chosen_desc->text.max_x)
                {
                   int l, r;
@@ -3874,7 +3874,7 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int flags, Edje_Calc_Params *sta
               /* visibility and color have no meaning on SWALLOW and GROUP part. */
 #ifdef HAVE_EPHYSICS
               eo_do(ep->object,
-                    evas_obj_size_set(pf->final.w, pf->final.h));
+                    efl_gfx_size_set(pf->final.w, pf->final.h));
               if ((ep->part->physics_body) && (!ep->body))
                 {
                    if (_edje_physics_world_geometry_check(ed->world))
@@ -3892,19 +3892,19 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int flags, Edje_Calc_Params *sta
                 }
               else
                 eo_do(ep->object,
-                      evas_obj_position_set(ed->x + pf->final.x, ed->y + pf->final.y));
+                      efl_gfx_position_set(ed->x + pf->final.x, ed->y + pf->final.y));
 #else
              eo_do(ep->object,
-                    evas_obj_position_set(ed->x + pf->final.x, ed->y + pf->final.y),
-                   evas_obj_size_set(pf->final.w, pf->final.h));
+                    efl_gfx_position_set(ed->x + pf->final.x, ed->y + pf->final.y),
+                   efl_gfx_size_set(pf->final.w, pf->final.h));
 #endif
 
               if (ep->nested_smart)
                 {  /* Move, Resize all nested parts */
                    /* Not really needed but will improve the bounding box evaluation done by Evas */
                   eo_do(ep->nested_smart,
-                        evas_obj_position_set(ed->x + pf->final.x, ed->y + pf->final.y),
-                        evas_obj_size_set(pf->final.w, pf->final.h));
+                        efl_gfx_position_set(ed->x + pf->final.x, ed->y + pf->final.y),
+                        efl_gfx_size_set(pf->final.w, pf->final.h));
                 }
               if (ep->part->entry_mode > EDJE_ENTRY_EDIT_MODE_NONE)
                 _edje_entry_real_part_configure(ed, ep);
@@ -3968,9 +3968,9 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int flags, Edje_Calc_Params *sta
                   if (ep->part->type == EDJE_PART_TYPE_GROUP)
                     vis = evas_object_visible_get(ed->obj);
                   eo_do(ep->typedata.swallow->swallowed_object,
-                        evas_obj_position_set(ed->x + pf->final.x, ed->y + pf->final.y),
-                        evas_obj_size_set(pf->final.w, pf->final.h),
-                        evas_obj_visibility_set(vis));
+                        efl_gfx_position_set(ed->x + pf->final.x, ed->y + pf->final.y),
+                        efl_gfx_size_set(pf->final.w, pf->final.h),
+                        efl_gfx_visibility_set(vis));
                }
              else evas_object_hide(ep->typedata.swallow->swallowed_object);
              mo = ep->typedata.swallow->swallowed_object;
index 05c2a6805f855ebdf8dcd3e4b32210d51c2fc6fb..dfc0db6554c2faa067a5aeb75c86c37852f9cc6b 100644 (file)
@@ -18,7 +18,7 @@ static inline void
 part_get_geometry(Edje_Real_Part *rp, Evas_Coord *w, Evas_Coord *h)
 {
    if (!rp->part->use_alternate_font_metrics)
-     eo_do(rp->object, evas_obj_size_get(w, h));
+     eo_do(rp->object, efl_gfx_size_get(w, h));
    else
      {
         if (w) *w = evas_object_text_horiz_advance_get(rp->object);
@@ -101,7 +101,7 @@ _edje_text_fit_x(Edje *ed, Edje_Real_Part *ep,
          evas_obj_text_ellipsis_set(chosen_desc->text.min_x ? -1 : params->type.text.ellipsis),
          efl_text_properties_font_set(font, size),
          efl_text_set(text),
-         evas_obj_size_set(sw, sh));
+         efl_gfx_size_set(sw, sh));
 
    return text;
 }
@@ -520,10 +520,10 @@ arrange_text:
    if (!calc_only)
      {
         eo_do(ep->object,
-              evas_obj_position_set(ed->x + TO_INT(params->eval.x) + ep->typedata.text->offset.x,
-                               ed->y + TO_INT(params->eval.y) + ep->typedata.text->offset.y);
+              efl_gfx_position_set(ed->x + TO_INT(params->eval.x) + ep->typedata.text->offset.x,
+                                   ed->y + TO_INT(params->eval.y) + ep->typedata.text->offset.y);
 
-              evas_obj_visibility_set(params->visible));
+              efl_gfx_visibility_set(params->visible));
      }
 
 
index a1155bbb73b55cd5b140bfe5934610d215404239..23f06816f7dd7790e39a9cc6f99048ef777560fd 100644 (file)
@@ -124,6 +124,7 @@ typedef enum _Efl_Gfx_Gradient_Spread
 
 #include "interfaces/efl_gfx_utils.h"
 
+#include "interfaces/efl_gfx_base.eo.h"
 #include "interfaces/efl_gfx_shape.eo.h"
 #include "interfaces/efl_gfx_gradient.eo.h"
 #include "interfaces/efl_gfx_gradient_linear.eo.h"
diff --git a/src/lib/efl/interfaces/efl_gfx_base.eo b/src/lib/efl/interfaces/efl_gfx_base.eo
new file mode 100644 (file)
index 0000000..ea175b4
--- /dev/null
@@ -0,0 +1,89 @@
+interface Efl.Gfx.Base {
+   legacy_prefix: null;
+   eo_prefix: efl_gfx;
+   properties {
+      position {
+         set {
+            /*@ Move the given Evas object to the given location inside its canvas' viewport. */
+         }
+         get {
+            /*@ Retrieves the position of the given Evas object. */
+         }
+         values {
+            int x; /*@ in */
+            int y; /*@ in */
+         }
+      }
+      size {
+         set {
+            /*@ Changes the size of the given Evas object. */
+         }
+         get {
+            /*@ Retrieves the (rectangular) size of the given Evas object. */
+         }
+         values {
+            int w; /*@ in */
+            int h; /*@ in */
+         }
+      }
+      color {
+         set {
+            /*@
+            Sets the general/main color of the given Evas object to the given
+            one.
+
+            @see evas_object_color_get() (for an example)
+            @note These color values are expected to be premultiplied by @p a.
+
+            @ingroup Evas_Object_Group_Basic */
+         }
+         get {
+            /*@
+            Retrieves the general/main color of the given Evas object.
+
+            Retrieves the “main” color's RGB component (and alpha channel)
+            values, <b>which range from 0 to 255</b>. For the alpha channel,
+            which defines the object's transparency level, 0 means totally
+            transparent, while 255 means opaque. These color values are
+            premultiplied by the alpha value.
+
+            Usually you’ll use this attribute for text and rectangle objects,
+            where the “main” color is their unique one. If set for objects
+            which themselves have colors, like the images one, those colors get
+            modulated by this one.
+
+            @note All newly created Evas rectangles get the default color
+            values of <code>255 255 255 255</code> (opaque white).
+
+            @note Use @c NULL pointers on the components you're not interested
+            in: they'll be ignored by the function.
+
+            Example:
+            @dontinclude evas-object-manipulation.c
+            @skip int alpha, r, g, b;
+            @until return
+
+            See the full @ref Example_Evas_Object_Manipulation "example".
+
+            @ingroup Evas_Object_Group_Basic */
+         }
+         values {
+            int r; /*@ The red component of the given color. */
+            int g; /*@ The green component of the given color. */
+            int b; /*@ The blue component of the given color. */
+            int a; /*@ The alpha component of the given color. */
+         }
+      }
+      visibility {
+         set {
+            /*@ Makes the given Evas object visible or invisible. */
+         }
+         get {
+            /*@ Retrieves whether or not the given Evas object is visible. */
+         }
+         values {
+            bool v; /*@ @c EINA_TRUE if to make the object visible, @c EINA_FALSE otherwise */
+         }
+      }
+   }
+}
index 9ede0fe7d293083a25bd1776e0e7c708f0fb32df..3aecd653d5a8d03474bba84bc2f4403bd07823d0 100644 (file)
@@ -11,6 +11,7 @@
 #include "interfaces/efl_text.eo.c"
 #include "interfaces/efl_text_properties.eo.c"
 
+#include "interfaces/efl_gfx_base.eo.c"
 #include "interfaces/efl_gfx_shape.eo.c"
 #include "interfaces/efl_gfx_gradient.eo.c"
 #include "interfaces/efl_gfx_gradient_linear.eo.c"
index d3c9e154ef6a61096f34fec76074bbc95a467f66..c2f0abf47b92834ce28372eed3dfe2aeedf16646 100644 (file)
@@ -568,6 +568,86 @@ EAPI void             evas_object_show(Evas_Object *obj) EINA_ARG_NONNULL(1);
 EAPI void             evas_object_hide(Evas_Object *obj) EINA_ARG_NONNULL(1);
 
 
+/**
+ *
+ * Sets the general/main color of the given Evas object to the given
+ * one.
+ *
+ * @see evas_object_color_get() (for an example)
+ * @note These color values are expected to be premultiplied by @p a.
+ *
+ * @ingroup Evas_Object_Group_Basic
+ *
+ * @param[in] r The red component of the given color.
+ * @param[in] g The green component of the given color.
+ * @param[in] b The blue component of the given color.
+ * @param[in] a The alpha component of the given color.
+ */
+EAPI void evas_object_color_set(Evas_Object *obj, int r, int g, int b, int a);
+
+/**
+ *
+ * Retrieves the general/main color of the given Evas object.
+ *
+ * Retrieves the “main” color's RGB component (and alpha channel)
+ * values, <b>which range from 0 to 255</b>. For the alpha channel,
+ * which defines the object's transparency level, 0 means totally
+ * transparent, while 255 means opaque. These color values are
+ * premultiplied by the alpha value.
+ *
+ * Usually you’ll use this attribute for text and rectangle objects,
+ * where the “main” color is their unique one. If set for objects
+ * which themselves have colors, like the images one, those colors get
+ * modulated by this one.
+ *
+ * @note All newly created Evas rectangles get the default color
+ * values of <code>255 255 255 255</code> (opaque white).
+ *
+ * @note Use @c NULL pointers on the components you're not interested
+ * in: they'll be ignored by the function.
+ *
+ * Example:
+ * @dontinclude evas-object-manipulation.c
+ * @skip int alpha, r, g, b;
+ * @until return
+ *
+ * See the full @ref Example_Evas_Object_Manipulation "example".
+ *
+ * @ingroup Evas_Object_Group_Basic
+ *
+ * @param[out] r The red component of the given color.
+ * @param[out] g The green component of the given color.
+ * @param[out] b The blue component of the given color.
+ * @param[out] a The alpha component of the given color.
+ */
+EAPI void evas_object_color_get(const Evas_Object *obj, int *r, int *g, int *b, int *a);
+
+/**
+ *
+ * Move the given Evas object to the given location inside its canvas' viewport.
+ *
+ * @param[in] x in
+ * @param[in] y in
+ */
+EAPI void evas_object_move(Evas_Object *obj, Evas_Coord x, Evas_Coord y);
+
+/**
+ *
+ * Changes the size of the given Evas object.
+ *
+ * @param[in] w in
+ * @param[in] h in
+ */
+EAPI void evas_object_resize(Evas_Object *obj, Evas_Coord w, Evas_Coord h);
+
+/**
+ *
+ * Retrieves whether or not the given Evas object is visible.
+ *
+ */
+EAPI Eina_Bool evas_object_visible_get(const Evas_Object *obj);
+
+
 #include "canvas/evas_common_interface.eo.legacy.h"
 #include "canvas/evas_object.eo.legacy.h"
 
index 27472c524546f88e0dce1b46a7f97daccbb3f0eb..435ab9cde74c1797f0f1c2c218c0e296a5393b69 100644 (file)
@@ -1,4 +1,4 @@
-abstract Evas.Object (Eo.Base, Evas.Common_Interface)
+abstract Evas.Object (Eo.Base, Evas.Common_Interface, Efl.Gfx.Base)
 {
    eo_prefix: evas_obj;
    data: Evas_Object_Protected_Data;
@@ -74,19 +74,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface)
             Evas_Coord h; /*@ Integer to use as the preferred height hint. */
          }
       }
-      visibility {
-         set {
-            /*@ Makes the given Evas object visible or invisible. */
-            legacy: null;
-         }
-         get {
-            /*@ Retrieves whether or not the given Evas object is visible. */
-            legacy: evas_object_visible_get;
-         }
-         values {
-            bool v; /*@ @c EINA_TRUE if to make the object visible, @c EINA_FALSE otherwise */
-         }
-      }
       type {
          set {
             /*@ Sets the type of the given Evas object. */
@@ -730,20 +717,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface)
             clipper, @c EINA_FALSE otherwise. */
          }
       }
-      size {
-         set {
-            /*@ Changes the size of the given Evas object. */
-            legacy: evas_object_resize;
-         }
-         get {
-            /*@ Retrieves the (rectangular) size of the given Evas object. */
-            legacy: null;
-         }
-         values {
-            Evas_Coord w; /*@ in */
-            Evas_Coord h; /*@ in */
-         }
-      }
       focus {
          set {
             /*@
@@ -1016,20 +989,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface)
             (@c EINA_FALSE) */
          }
       }
-      position {
-         set {
-            /*@ Move the given Evas object to the given location inside its canvas' viewport. */
-            legacy: evas_object_move;
-         }
-         get {
-            /*@ Retrieves the position of the given Evas object. */
-            legacy: null;
-         }
-         values {
-            Evas_Coord x; /*@ in */
-            Evas_Coord y; /*@ in */
-         }
-      }
       anti_alias {
          set {
             /*@
@@ -1047,54 +1006,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface)
             bool anti_alias; /*@ (@c EINA_TRUE) if the object is to be anti_aliased, (@c EINA_FALSE) otherwise. */
          }
       }
-      color {
-         set {
-            /*@
-            Sets the general/main color of the given Evas object to the given
-            one.
-
-            @see evas_object_color_get() (for an example)
-            @note These color values are expected to be premultiplied by @p a.
-
-            @ingroup Evas_Object_Group_Basic */
-         }
-         get {
-            /*@
-            Retrieves the general/main color of the given Evas object.
-
-            Retrieves the “main” color's RGB component (and alpha channel)
-            values, <b>which range from 0 to 255</b>. For the alpha channel,
-            which defines the object's transparency level, 0 means totally
-            transparent, while 255 means opaque. These color values are
-            premultiplied by the alpha value.
-
-            Usually you’ll use this attribute for text and rectangle objects,
-            where the “main” color is their unique one. If set for objects
-            which themselves have colors, like the images one, those colors get
-            modulated by this one.
-
-            @note All newly created Evas rectangles get the default color
-            values of <code>255 255 255 255</code> (opaque white).
-
-            @note Use @c NULL pointers on the components you're not interested
-            in: they'll be ignored by the function.
-
-            Example:
-            @dontinclude evas-object-manipulation.c
-            @skip int alpha, r, g, b;
-            @until return
-
-            See the full @ref Example_Evas_Object_Manipulation "example".
-
-            @ingroup Evas_Object_Group_Basic */
-         }
-         values {
-            int r; /*@ The red component of the given color. */
-            int g; /*@ The green component of the given color. */
-            int b; /*@ The blue component of the given color. */
-            int a; /*@ The alpha component of the given color. */
-         }
-      }
       smart_data {
          get {
             /*@
@@ -1507,6 +1418,14 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface)
       Eo.Base.destructor;
       Eo.Base.dbg_info_get;
       Evas.Common_Interface.evas.get;
+      Efl.Gfx.Base.visibility.set;
+      Efl.Gfx.Base.visibility.get;
+      Efl.Gfx.Base.position.set;
+      Efl.Gfx.Base.position.get;
+      Efl.Gfx.Base.color.set;
+      Efl.Gfx.Base.color.get;
+      Efl.Gfx.Base.size.set;
+      Efl.Gfx.Base.size.get;
    }
    events {
        mouse,in; /*@ Mouse In Event */
index 1b3fe4b81c21884150842c946fa7b3101cc22678..e000dff5c7776229037ff4f9cdb40bf76eaba1a1 100644 (file)
@@ -753,12 +753,19 @@ evas_object_geometry_set(Evas_Object *eo_obj, Evas_Coord x, Evas_Coord y, Evas_C
    return;
    MAGIC_CHECK_END();
    eo_do(eo_obj,
-         evas_obj_position_set(x, y),
-         evas_obj_size_set(w, h));
+         efl_gfx_position_set(x, y),
+         efl_gfx_size_set(w, h));
+}
+
+EAPI void
+evas_object_move(Evas_Object *obj, Evas_Coord x, Evas_Coord y)
+{
+   eo_do((Evas_Object *)obj, efl_gfx_position_set(x, y));
 }
 
 EOLIAN static void
-_evas_object_position_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Evas_Coord x, Evas_Coord y)
+_evas_object_efl_gfx_base_position_set(Eo *eo_obj, Evas_Object_Protected_Data *obj,
+                                       Evas_Coord x, Evas_Coord y)
 {
 
    Eina_Bool is, was = EINA_FALSE;
@@ -839,8 +846,15 @@ _evas_object_position_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Evas_Coor
    evas_object_inform_call_move(eo_obj, obj);
 }
 
+EAPI void
+evas_object_resize(Evas_Object *obj, Evas_Coord w, Evas_Coord h)
+{
+   eo_do((Evas_Object *)obj, efl_gfx_size_set(w, h));
+}
+
 EOLIAN static void
-_evas_object_size_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Evas_Coord w, Evas_Coord h)
+_evas_object_efl_gfx_base_size_set(Eo *eo_obj, Evas_Object_Protected_Data *obj,
+                                   Evas_Coord w, Evas_Coord h)
 {
    Eina_Bool is, was = EINA_FALSE;
    Eina_Bool pass = EINA_FALSE, freeze = EINA_FALSE;
@@ -923,33 +937,37 @@ evas_object_geometry_get(const Evas_Object *eo_obj, Evas_Coord *x, Evas_Coord *y
    if (x) *x = 0; if (y) *y = 0; if (w) *w = 0; if (h) *h = 0;
    return;
    MAGIC_CHECK_END();
-   eo_do((Eo *)eo_obj, evas_obj_position_get(x, y), evas_obj_size_get(w, h));
+   eo_do((Eo *)eo_obj, efl_gfx_position_get(x, y), efl_gfx_size_get(w, h));
 }
 
 EOLIAN static void
-_evas_object_position_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj, Evas_Coord *x, Evas_Coord *y)
+_evas_object_efl_gfx_base_position_get(Eo *obj EINA_UNUSED,
+                                       Evas_Object_Protected_Data *pd,
+                                       Evas_Coord *x, Evas_Coord *y)
 {
-   if ((obj->delete_me) || (!obj->layer))
+   if ((pd->delete_me) || (!pd->layer))
      {
         if (x) *x = 0; if (y) *y = 0;
         return;
      }
 
-   if (x) *x = obj->cur->geometry.x;
-   if (y) *y = obj->cur->geometry.y;
+   if (x) *x = pd->cur->geometry.x;
+   if (y) *y = pd->cur->geometry.y;
 }
 
 EOLIAN static void
-_evas_object_size_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj, Evas_Coord *w, Evas_Coord *h)
+_evas_object_efl_gfx_base_size_get(Eo *obj EINA_UNUSED,
+                                   Evas_Object_Protected_Data *pd,
+                                   Evas_Coord *w, Evas_Coord *h)
 {
-   if (obj->delete_me)
+   if (pd->delete_me)
      {
         if (w) *w = 0; if (h) *h = 0;
         return;
      }
 
-   if (w) *w = obj->cur->geometry.w;
-   if (h) *h = obj->cur->geometry.h;
+   if (w) *w = pd->cur->geometry.w;
+   if (h) *h = pd->cur->geometry.h;
 }
 
 static void
@@ -1178,18 +1196,26 @@ evas_object_show(Evas_Object *eo_obj)
    MAGIC_CHECK(eo_obj, Evas_Object, MAGIC_OBJ);
    return;
    MAGIC_CHECK_END();
-   eo_do(eo_obj, evas_obj_visibility_set(EINA_TRUE));
+   eo_do(eo_obj, efl_gfx_visibility_set(EINA_TRUE));
 }
 
 EAPI void
 evas_object_hide(Evas_Object *eo_obj)
 {
    if (!eo_obj) return;
-   eo_do(eo_obj, evas_obj_visibility_set(EINA_FALSE));
+   eo_do(eo_obj, efl_gfx_visibility_set(EINA_FALSE));
+}
+
+EAPI Eina_Bool
+evas_object_visible_get(const Evas_Object *obj)
+{
+   return eo_do((Evas_Object *)obj, efl_gfx_visibility_get());
 }
 
 static void
-_evas_object_visibility_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Eina_Bool visible)
+_evas_object_efl_gfx_base_visibility_set(Eo *eo_obj,
+                                         Evas_Object_Protected_Data *obj,
+                                         Eina_Bool visible)
 {
    if (visible) _show(eo_obj, obj);
    else _hide(eo_obj, obj);
@@ -1364,14 +1390,22 @@ _hide(Evas_Object *eo_obj, Evas_Object_Protected_Data *obj)
 }
 
 static Eina_Bool
-_evas_object_visibility_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj)
+_evas_object_efl_gfx_base_visibility_get(Eo *eo_obj EINA_UNUSED,
+                                         Evas_Object_Protected_Data *obj)
 {
    if (obj->delete_me) return EINA_FALSE;
    return obj->cur->visible;
 }
 
+EAPI void
+evas_object_color_set(Evas_Object *obj, int r, int g, int b, int a)
+{
+   eo_do((Evas_Object *)obj, efl_gfx_color_set(r, g, b, a));
+}
+
 EOLIAN static void
-_evas_object_color_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, int r, int g, int b, int a)
+_evas_object_efl_gfx_base_color_set(Eo *eo_obj, Evas_Object_Protected_Data *obj,
+                                    int r, int g, int b, int a)
 {
    if (obj->delete_me) return;
    if (r > 255) r = 255; if (r < 0) r = 0;
@@ -1425,8 +1459,16 @@ _evas_object_color_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, int r, int g
    evas_object_change(eo_obj, obj);
 }
 
+EAPI void
+evas_object_color_get(const Evas_Object *obj, int *r, int *g, int *b, int *a)
+{
+   eo_do((Evas_Object *)obj, efl_gfx_color_get(r, g, b, a));
+}
+
 EOLIAN static void
-_evas_object_color_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj, int *r, int *g, int *b, int *a)
+_evas_object_efl_gfx_base_color_get(Eo *eo_obj EINA_UNUSED,
+                                    Evas_Object_Protected_Data *obj,
+                                    int *r, int *g, int *b, int *a)
 {
    if (obj->delete_me)
      {
@@ -1533,18 +1575,18 @@ _evas_object_eo_base_dbg_info_get(Eo *eo_obj, Evas_Object_Protected_Data *obj EI
    Eina_Bool clipees_has;
 
    eo_do(eo_obj,
-         visible = evas_obj_visibility_get(),
+         visible = efl_gfx_visibility_get(),
          layer = evas_obj_layer_get(),
          name = evas_obj_name_get(),
-         evas_obj_position_get(&x, &y),
-         evas_obj_size_get(&w, &h),
+         efl_gfx_position_get(&x, &y),
+         efl_gfx_size_get(&w, &h),
          scale = evas_obj_scale_get(),
          evas_obj_size_hint_min_get(&minw, &minh),
          evas_obj_size_hint_max_get(&maxw, &maxh),
          evas_obj_size_hint_request_get(&requestw, &requesth),
          evas_obj_size_hint_align_get(&dblx, &dbly),
          evas_obj_size_hint_weight_get(&dblw, &dblh),
-         evas_obj_color_get(&r, &g, &b, &a),
+         efl_gfx_color_get(&r, &g, &b, &a),
          focus = evas_obj_focus_get(),
          m = evas_obj_pointer_mode_get(),
          pass_event = evas_obj_pass_events_get(),
index 8eadf07f1791c54a5fe17e3ba7566c4c7610e7b1..83bb6445a0204ab86bbb28c28defd926e402fbf6 100644 (file)
@@ -923,7 +923,7 @@ _evas_object_text_layout(Evas_Object *eo_obj, Evas_Text_Data *o, Eina_Unicode *t
 }
 
 EOLIAN static void
-_evas_text_evas_object_size_set(Eo *eo_obj, Evas_Text_Data *o, Evas_Coord w, Evas_Coord h)
+_evas_text_efl_gfx_base_size_set(Eo *eo_obj, Evas_Text_Data *o, int w, int h)
 {
    Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
 
@@ -1226,7 +1226,7 @@ _evas_text_style_set(Eo *eo_obj, Evas_Text_Data *o, Evas_Text_Style_Type style)
    h = obj->cur->geometry.h + (t - pt) + (b - pb);
 
    eo_do_super(eo_obj, MY_CLASS,
-               evas_obj_size_set(w, h));
+               efl_gfx_size_set(w, h));
    evas_object_change(eo_obj, obj);
 }
 
@@ -2326,12 +2326,12 @@ _evas_object_text_recalc(Evas_Object *eo_obj, Eina_Unicode *text)
 
              min = w + l + r < obj->cur->geometry.w || obj->cur->geometry.w == 0 ? w + l + r : obj->cur->geometry.w;
              eo_do_super(eo_obj, MY_CLASS,
-                         evas_obj_size_set(min, h + t + b));
+                         efl_gfx_size_set(min, h + t + b));
           }
         else
           {
              eo_do_super(eo_obj, MY_CLASS,
-                         evas_obj_size_set(w + l + r, h + t + b));
+                         efl_gfx_size_set(w + l + r, h + t + b));
           }
 ////        obj->cur->cache.geometry.validity = 0;
      }
@@ -2345,7 +2345,7 @@ _evas_object_text_recalc(Evas_Object *eo_obj, Eina_Unicode *text)
           evas_filter_program_padding_get(o->cur.filter->chain, &l, &r, &t, &b);
 
         eo_do_super(eo_obj, MY_CLASS,
-                    evas_obj_size_set(0, o->max_ascent + o->max_descent + t + b));
+                    efl_gfx_size_set(0, o->max_ascent + o->max_descent + t + b));
 ////        obj->cur->cache.geometry.validity = 0;
      }
    o->last_computed.w = obj->cur->geometry.w;
index 52eb07141450213a7b3a3b5879afd5f2a1e3a447..520db772860306f3861883af9fb214c36f8eb34e 100644 (file)
@@ -362,7 +362,7 @@ class Evas.Text (Evas.Object, Efl.Text, Efl.Text_Properties)
       Eo.Base.constructor;
       Eo.Base.destructor;
       Eo.Base.dbg_info_get;
-      Evas.Object.size.set;
+      Efl.Gfx.Base.size.set;
       Efl.Text.text.set;
       Efl.Text.text.get;
       Efl.Text_Properties.font.get;
index e494c8b9b11eb98b2fa737388f1b2c1d88bdaf4f..320fcf915922a2e039ffa0965d7006d0c34c469b 100644 (file)
@@ -387,14 +387,14 @@ START_TEST(evas_filter_text_render_test)
              evas_object_resize(o, 10, 10);
              evas_object_show(o);
              eo_do(to,
-                   evas_obj_color_set(255, 255, 255, 255),
+                   efl_gfx_color_set(255, 255, 255, 255),
                    evas_obj_text_filter_source_set(tc->source, o),
                    evas_obj_text_filter_program_set(tc->code));
           }
         else
           {
              eo_do(to,
-                   evas_obj_color_set(255, 255, 255, 255),
+                   efl_gfx_color_set(255, 255, 255, 255),
                    evas_obj_text_filter_program_set(tc->code));
           }