summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-09-13 17:00:14 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-09-13 18:03:34 +0900
commit21c72948dbc926db77e355c1fb18026e13d043c3 (patch)
treeba96e80c6224965b3836a442daf5c5adf48707b8 /src
parent13da5e980eb43288b9b9f502cb6a7a000e1f26ea (diff)
efl_gfx: Remove color_part API (EO)
This API was introduced in commit: cd3f8db506379a770ef37134748a64adfae66ab3 This was since limited to EO only APIs, and totally underexploited. After that, efl_part() was introduced, which defines how all part APIs should be designed. Nothing uses this API, efl_vg had an implementation that provides no extra value over the other APIs.
Diffstat (limited to 'src')
-rw-r--r--src/lib/efl/interfaces/efl_gfx.eo42
-rw-r--r--src/lib/evas/canvas/efl_canvas_object.eo1
-rw-r--r--src/lib/evas/canvas/efl_vg.eo1
-rw-r--r--src/lib/evas/canvas/efl_vg_shape.eo1
-rw-r--r--src/lib/evas/canvas/evas_object_main.c23
-rw-r--r--src/lib/evas/canvas/evas_vg_node.c22
-rw-r--r--src/lib/evas/canvas/evas_vg_shape.c28
7 files changed, 0 insertions, 118 deletions
diff --git a/src/lib/efl/interfaces/efl_gfx.eo b/src/lib/efl/interfaces/efl_gfx.eo
index 1670ddc3c6..bea1ca652a 100644
--- a/src/lib/efl/interfaces/efl_gfx.eo
+++ b/src/lib/efl/interfaces/efl_gfx.eo
@@ -89,48 +89,6 @@ interface Efl.Gfx {
89 a: int; [[The alpha component of the given color.]] 89 a: int; [[The alpha component of the given color.]]
90 } 90 }
91 } 91 }
92 @property color_part {
93 set {
94 [[Sets a specifc color of the given Efl.Gfx object to the
95 given one.
96
97 See also @.color.get (for an example)
98
99 These color values are expected to be premultiplied by alpha.
100 ]]
101 return: bool; [[$true when color was set, $false otherwise]]
102 }
103 get {
104 [[Retrieves a specific color of the given Evas object.
105
106 Retrieves a specific color's RGB component (and alpha channel)
107 values, which range from 0 to 255. For the alpha channel,
108 which defines the object's transparency level, 0 means totally
109 transparent, while 255 means opaque. These color values are
110 premultiplied by the alpha value.
111
112 The main color being mapped to null.
113
114 Usually youll use this attribute for text and rectangle objects,
115 where the main color is their unique one. If set for objects
116 which themselves have colors, like the images one, those colors
117 get modulated by this one.
118
119 Use null pointers on the components you're not interested
120 in: they'll be ignored by the function.
121 ]]
122 return: bool; [[$true when color was retrieved, $false otherwise]]
123 }
124 keys {
125 part: string; [[The part you are interested in.]]
126 }
127 values {
128 r: int; [[The red component of the given color.]]
129 g: int; [[The green component of the given color.]]
130 b: int; [[The blue component of the given color.]]
131 a: int; [[The alpha component of the given color.]]
132 }
133 }
134 @property visible { 92 @property visible {
135 set { 93 set {
136 [[Makes the given Evas object visible or invisible.]] 94 [[Makes the given Evas object visible or invisible.]]
diff --git a/src/lib/evas/canvas/efl_canvas_object.eo b/src/lib/evas/canvas/efl_canvas_object.eo
index 6acd2218b0..61c59497dd 100644
--- a/src/lib/evas/canvas/efl_canvas_object.eo
+++ b/src/lib/evas/canvas/efl_canvas_object.eo
@@ -665,7 +665,6 @@ abstract Efl.Canvas.Object (Efl.Object, Efl.Gfx, Efl.Gfx.Stack, Efl.Animator,
665 Efl.Object.debug_name_override; 665 Efl.Object.debug_name_override;
666 Efl.Gfx.visible { get; set; } 666 Efl.Gfx.visible { get; set; }
667 Efl.Gfx.color { get; set; } 667 Efl.Gfx.color { get; set; }
668 Efl.Gfx.color_part { get; set; }
669 Efl.Gfx.geometry { get; set; } 668 Efl.Gfx.geometry { get; set; }
670 Efl.Gfx.position { get; set; } 669 Efl.Gfx.position { get; set; }
671 Efl.Gfx.size { get; set; } 670 Efl.Gfx.size { get; set; }
diff --git a/src/lib/evas/canvas/efl_vg.eo b/src/lib/evas/canvas/efl_vg.eo
index df69ae1aaf..beb132851d 100644
--- a/src/lib/evas/canvas/efl_vg.eo
+++ b/src/lib/evas/canvas/efl_vg.eo
@@ -116,7 +116,6 @@ abstract Efl.VG (Efl.Object, Efl.Gfx, Efl.Gfx.Stack)
116 Efl.Object.destructor; 116 Efl.Object.destructor;
117 Efl.Gfx.visible { get; set; } 117 Efl.Gfx.visible { get; set; }
118 Efl.Gfx.color { get; set; } 118 Efl.Gfx.color { get; set; }
119 Efl.Gfx.color_part { get; set; }
120 Efl.Gfx.size { get; } 119 Efl.Gfx.size { get; }
121 Efl.Gfx.position { get; set; } 120 Efl.Gfx.position { get; set; }
122 Efl.Gfx.geometry { get; } 121 Efl.Gfx.geometry { get; }
diff --git a/src/lib/evas/canvas/efl_vg_shape.eo b/src/lib/evas/canvas/efl_vg_shape.eo
index a3e602048c..888ea4590c 100644
--- a/src/lib/evas/canvas/efl_vg_shape.eo
+++ b/src/lib/evas/canvas/efl_vg_shape.eo
@@ -35,7 +35,6 @@ class Efl.VG.Shape (Efl.VG, Efl.Gfx.Shape)
35 } 35 }
36 } 36 }
37 implements { 37 implements {
38 Efl.Gfx.color_part { get; set; }
39 Efl.VG.bounds_get; 38 Efl.VG.bounds_get;
40 Efl.VG.interpolate; 39 Efl.VG.interpolate;
41 Efl.VG.dup; 40 Efl.VG.dup;
diff --git a/src/lib/evas/canvas/evas_object_main.c b/src/lib/evas/canvas/evas_object_main.c
index e8efe87265..8ad0e78c2a 100644
--- a/src/lib/evas/canvas/evas_object_main.c
+++ b/src/lib/evas/canvas/evas_object_main.c
@@ -1934,17 +1934,6 @@ _efl_canvas_object_efl_gfx_color_set(Eo *eo_obj, Evas_Object_Protected_Data *obj
1934 evas_object_change(eo_obj, obj); 1934 evas_object_change(eo_obj, obj);
1935} 1935}
1936 1936
1937EOLIAN static Eina_Bool
1938_efl_canvas_object_efl_gfx_color_part_set(Eo *obj, Evas_Object_Protected_Data *pd,
1939 const char *part,
1940 int r, int g, int b, int a)
1941{
1942 if (part) return EINA_FALSE;
1943
1944 _efl_canvas_object_efl_gfx_color_set(obj, pd, r, g, b, a);
1945 return EINA_TRUE;
1946}
1947
1948EAPI void 1937EAPI void
1949evas_object_color_get(const Evas_Object *obj, int *r, int *g, int *b, int *a) 1938evas_object_color_get(const Evas_Object *obj, int *r, int *g, int *b, int *a)
1950{ 1939{
@@ -1970,18 +1959,6 @@ _efl_canvas_object_efl_gfx_color_get(Eo *eo_obj EINA_UNUSED,
1970 if (a) *a = obj->cur->color.a; 1959 if (a) *a = obj->cur->color.a;
1971} 1960}
1972 1961
1973EOLIAN static Eina_Bool
1974_efl_canvas_object_efl_gfx_color_part_get(Eo *obj,
1975 Evas_Object_Protected_Data *pd,
1976 const char *part,
1977 int *r, int *g, int *b, int *a)
1978{
1979 if (part) return EINA_FALSE;
1980
1981 _efl_canvas_object_efl_gfx_color_get(obj, pd, r, g, b, a);
1982 return EINA_TRUE;
1983}
1984
1985EOLIAN static void 1962EOLIAN static void
1986_efl_canvas_object_anti_alias_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Eina_Bool anti_alias) 1963_efl_canvas_object_anti_alias_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Eina_Bool anti_alias)
1987{ 1964{
diff --git a/src/lib/evas/canvas/evas_vg_node.c b/src/lib/evas/canvas/evas_vg_node.c
index f6ce22d4eb..3267f76bc5 100644
--- a/src/lib/evas/canvas/evas_vg_node.c
+++ b/src/lib/evas/canvas/evas_vg_node.c
@@ -159,17 +159,6 @@ _efl_vg_efl_gfx_color_set(Eo *obj EINA_UNUSED,
159 _efl_vg_changed(obj); 159 _efl_vg_changed(obj);
160} 160}
161 161
162static Eina_Bool
163_efl_vg_efl_gfx_color_part_set(Eo *obj, Efl_VG_Data *pd,
164 const char *part,
165 int r, int g, int b, int a)
166{
167 if (part) return EINA_FALSE;
168
169 _efl_vg_efl_gfx_color_set(obj, pd, r, g, b, a);
170 return EINA_TRUE;
171}
172
173static void 162static void
174_efl_vg_efl_gfx_color_get(Eo *obj EINA_UNUSED, 163_efl_vg_efl_gfx_color_get(Eo *obj EINA_UNUSED,
175 Efl_VG_Data *pd, 164 Efl_VG_Data *pd,
@@ -181,17 +170,6 @@ _efl_vg_efl_gfx_color_get(Eo *obj EINA_UNUSED,
181 if (a) *a = pd->a; 170 if (a) *a = pd->a;
182} 171}
183 172
184static Eina_Bool
185_efl_vg_efl_gfx_color_part_get(Eo *obj, Efl_VG_Data *pd,
186 const char *part,
187 int *r, int *g, int *b, int *a)
188{
189 if (part) return EINA_FALSE;
190
191 _efl_vg_efl_gfx_color_get(obj, pd, r, g, b, a);
192 return EINA_TRUE;
193}
194
195static void 173static void
196_efl_vg_mask_set(Eo *obj EINA_UNUSED, 174_efl_vg_mask_set(Eo *obj EINA_UNUSED,
197 Efl_VG_Data *pd, 175 Efl_VG_Data *pd,
diff --git a/src/lib/evas/canvas/evas_vg_shape.c b/src/lib/evas/canvas/evas_vg_shape.c
index a4e441c284..a53eb98772 100644
--- a/src/lib/evas/canvas/evas_vg_shape.c
+++ b/src/lib/evas/canvas/evas_vg_shape.c
@@ -44,34 +44,6 @@ _efl_vg_shape_fill_get(Eo *obj EINA_UNUSED, Efl_VG_Shape_Data *pd)
44 return pd->fill; 44 return pd->fill;
45} 45}
46 46
47static Eina_Bool
48_efl_vg_shape_efl_gfx_color_part_set(Eo *obj, Efl_VG_Shape_Data *pd EINA_UNUSED,
49 const char * part,
50 int r, int g, int b, int a)
51{
52 if (part && !strcmp(part, "stroke"))
53 {
54 efl_gfx_shape_stroke_color_set(obj, r, g, b, a);
55 return EINA_TRUE;
56 }
57
58 return efl_gfx_color_part_set(efl_super(obj, EFL_VG_SHAPE_CLASS), part, r, g, b, a);
59}
60
61static Eina_Bool
62_efl_vg_shape_efl_gfx_color_part_get(Eo *obj, Efl_VG_Shape_Data *pd EINA_UNUSED,
63 const char * part,
64 int *r, int *g, int *b, int *a)
65{
66 if (part && !strcmp(part, "stroke"))
67 {
68 efl_gfx_shape_stroke_color_get(obj, r, g, b, a);
69 return EINA_TRUE;
70 }
71
72 return efl_gfx_color_part_get(efl_super(obj, EFL_VG_SHAPE_CLASS), part, r, g, b, a);
73}
74
75static void 47static void
76_efl_vg_shape_stroke_fill_set(Eo *obj EINA_UNUSED, 48_efl_vg_shape_stroke_fill_set(Eo *obj EINA_UNUSED,
77 Efl_VG_Shape_Data *pd, 49 Efl_VG_Shape_Data *pd,