summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2020-04-14 02:43:52 +0200
committerMarcel Hollerbach <mail@marcel-hollerbach.de>2020-04-19 22:01:52 +0200
commitb14a85fd6c4e291752b8b53aa871e207f972eea3 (patch)
tree991a62616f20141906a6aa2f97ef0a17332e6f96
parente0ce78e170caa267fef7206b56e009688e9d1565 (diff)
downloadefl-devs/bu5hm4n/eo_file_updates.tar.gz
HACK: remove broken APIdevs/bu5hm4n/eo_file_updates
cannot correctly work
-rw-r--r--src/lib/ector/software/ector_renderer_software_shape.c8
-rw-r--r--src/lib/efl/Efl.h25
-rw-r--r--src/lib/efl/interfaces/efl_gfx_path.c10
-rw-r--r--src/lib/efl/interfaces/efl_gfx_path.eo18
-rw-r--r--src/lib/evas/canvas/efl_canvas_vg_node.eo1
5 files changed, 41 insertions, 21 deletions
diff --git a/src/lib/ector/software/ector_renderer_software_shape.c b/src/lib/ector/software/ector_renderer_software_shape.c
index d8d804db22..b63fc69216 100644
--- a/src/lib/ector/software/ector_renderer_software_shape.c
+++ b/src/lib/ector/software/ector_renderer_software_shape.c
@@ -271,7 +271,7 @@ typedef struct _Line
double y2;
}Line;
-static void
+static void
_line_value_set(Line *l, double x1, double y1, double x2, double y2)
{
l->x1 = x1;
@@ -281,7 +281,7 @@ _line_value_set(Line *l, double x1, double y1, double x2, double y2)
}
// approximate sqrt(x*x + y*y) using alpha max plus beta min algorithm.
-// With alpha = 1, beta = 3/8, giving results with the largest error less
+// With alpha = 1, beta = 3/8, giving results with the largest error less
// than 7% compared to the exact value.
static double
_line_length(Line *l)
@@ -339,7 +339,7 @@ _dasher_line_to(Dash_Stroker *dasher, double x, double y)
_outline_line_to(dasher->outline, x, y);
}
}
- else
+ else
{
while (line_len > dasher->cur_dash_length)
{
@@ -404,7 +404,7 @@ _dasher_cubic_to(Dash_Stroker *dasher, double cx1 , double cy1, double cx2, doub
_outline_cubic_to(dasher->outline, cx1, cy1, cx2, cy2, x, y);
}
}
- else
+ else
{
while (bez_len > dasher->cur_dash_length)
{
diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
index 021bc5eb37..5edb18ebe3 100644
--- a/src/lib/efl/Efl.h
+++ b/src/lib/efl/Efl.h
@@ -163,6 +163,31 @@ typedef Efl_Gfx_Path_Command_Type Efl_Gfx_Path_Command;
#include "interfaces/efl_gfx_stack.eo.h"
#include "interfaces/efl_gfx_fill.eo.h"
#include "interfaces/efl_gfx_view.eo.h"
+
+/**
+ * @brief Set the list of commands and points to be used to create the content
+ * of path.
+ *
+ * @param[in] obj The object.
+ * @param[in] op Command list
+ * @param[in] points Point list
+ *
+ * @ingroup Efl_Gfx_Path
+ */
+EOAPI void efl_gfx_path_set(Eo *obj, const Efl_Gfx_Path_Command_Type *op, const double *points);
+
+/**
+ * @brief Set the list of commands and points to be used to create the content
+ * of path.
+ *
+ * @param[in] obj The object.
+ * @param[out] op Command list
+ * @param[out] points Point list
+ *
+ * @ingroup Efl_Gfx_Path
+ */
+EOAPI void efl_gfx_path_get(const Eo *obj, const Efl_Gfx_Path_Command_Type **op, const double **points);
+
#include "interfaces/efl_gfx_path.eo.h"
#include "interfaces/efl_gfx_shape.eo.h"
#include "interfaces/efl_gfx_gradient.eo.h"
diff --git a/src/lib/efl/interfaces/efl_gfx_path.c b/src/lib/efl/interfaces/efl_gfx_path.c
index 9852de1498..9458cfe3bb 100644
--- a/src/lib/efl/interfaces/efl_gfx_path.c
+++ b/src/lib/efl/interfaces/efl_gfx_path.c
@@ -1375,7 +1375,7 @@ _next_command(char *path, char *cmd, double *arr, int *count)
path++;
*count = _number_count(*cmd);
}
- else
+ else
{
if (*cmd == 'm')
*cmd = 'l';
@@ -1542,4 +1542,12 @@ _efl_gfx_path_efl_object_destructor(Eo *obj, Efl_Gfx_Path_Data *pd)
efl_destructor(efl_super(obj, EFL_GFX_PATH_MIXIN));
}
+
+EOAPI EFL_VOID_FUNC_BODYV(efl_gfx_path_set, EFL_FUNC_CALL(op, points), const Efl_Gfx_Path_Command_Type *op, const double *points);
+EOAPI EFL_VOID_FUNC_BODYV_CONST(efl_gfx_path_get, EFL_FUNC_CALL(op, points), const Efl_Gfx_Path_Command_Type **op, const double **points);
+
+#define EFL_GFX_PATH_EXTRA_OPS \
+ EFL_OBJECT_OP_FUNC(efl_gfx_path_set, _efl_gfx_path_path_set), \
+ EFL_OBJECT_OP_FUNC(efl_gfx_path_get, _efl_gfx_path_path_get),
+
#include "interfaces/efl_gfx_path.eo.c"
diff --git a/src/lib/efl/interfaces/efl_gfx_path.eo b/src/lib/efl/interfaces/efl_gfx_path.eo
index 42a44607ac..ffcdc15503 100644
--- a/src/lib/efl/interfaces/efl_gfx_path.eo
+++ b/src/lib/efl/interfaces/efl_gfx_path.eo
@@ -1,23 +1,9 @@
import eina_types;
-import efl_gfx_types;
mixin @beta Efl.Gfx.Path requires Efl.Object
{
[[EFL graphics path object interface]]
methods {
- @property path {
- [[Set the list of commands and points to be used to create the
- content of path.
- ]]
- set {
- }
- get {
- }
- values {
- op: ptr(const(Efl.Gfx.Path_Command_Type)); [[Command list]]
- points: ptr(const(double)); [[Point list]]
- }
- }
@property length {
[[Path length property]]
get {
@@ -65,7 +51,7 @@ mixin @beta Efl.Gfx.Path requires Efl.Object
]]
}
append_move_to {
- [[Moves the current point to the given point,
+ [[Moves the current point to the given point,
implicitly starting a new subpath and closing the previous one.
See also @.append_close.
@@ -140,7 +126,7 @@ mixin @beta Efl.Gfx.Path requires Efl.Object
}
append_arc_to {
[[Append an arc that connects from the current point int the point list
- to the given point (x,y). The arc is defined by the given radius in
+ to the given point (x,y). The arc is defined by the given radius in
x-direction (rx) and radius in y direction (ry).
Use this api if you know the end point's of the arc otherwise use
diff --git a/src/lib/evas/canvas/efl_canvas_vg_node.eo b/src/lib/evas/canvas/efl_canvas_vg_node.eo
index 69d36483df..aaf5c36696 100644
--- a/src/lib/evas/canvas/efl_canvas_vg_node.eo
+++ b/src/lib/evas/canvas/efl_canvas_vg_node.eo
@@ -1,4 +1,5 @@
import eina_types;
+import efl_gfx_types;
abstract @beta Efl.Canvas.Vg.Node extends Efl.Object
implements Efl.Gfx.Entity, Efl.Gfx.Color, Efl.Gfx.Stack, Efl.Duplicate, Efl.Gfx.Path