forked from enlightenment/efl
efl: add an interface for Efl_Geometry_Shape.
This commit is contained in:
parent
a247ddeceb
commit
14dcad09c0
|
@ -4,7 +4,8 @@ efl_eolian_files = \
|
|||
lib/efl/interfaces/efl_image.eo \
|
||||
lib/efl/interfaces/efl_player.eo \
|
||||
lib/efl/interfaces/efl_text.eo \
|
||||
lib/efl/interfaces/efl_text_properties.eo
|
||||
lib/efl/interfaces/efl_text_properties.eo \
|
||||
lib/efl/interfaces/efl_geometry_shape.eo
|
||||
|
||||
efl_eolian_files_h = $(efl_eolian_files:%.eo=%.eo.h)
|
||||
efl_eolian_files_c = $(efl_eolian_files:%.eo=%.eo.c)
|
||||
|
|
|
@ -34,6 +34,61 @@ extern "C"
|
|||
# endif
|
||||
#endif /* ! _WIN32 */
|
||||
|
||||
/**
|
||||
* Path command enum.
|
||||
*
|
||||
* @since 1.13
|
||||
* @ingroup Efl_Geometry_Shape
|
||||
*/
|
||||
typedef enum _Efl_Geometry_Path_Command
|
||||
{
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_END = 0, /**< End of the stream of command */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_MOVE_TO, /**< A move command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_LINE_TO, /**< A line command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_QUADRATIC_TO, /**< A quadratic command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_SQUADRATIC_TO, /**< A smooth quadratic command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_CUBIC_TO, /**< A cubic command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_SCUBIC_TO, /**< A smooth cubic command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_ARC_TO, /**< An arc command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_CLOSE, /**< A close command type */
|
||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_LAST, /**< Not a valid command, but last one according to this version header */
|
||||
} Efl_Geometry_Path_Command;
|
||||
|
||||
/**
|
||||
* Type describing dash
|
||||
* @since 1.13
|
||||
*/
|
||||
typedef struct _Efl_Geometry_Dash Efl_Geometry_Dash;
|
||||
struct _Efl_Geometry_Dash
|
||||
{
|
||||
double length;
|
||||
double gap;
|
||||
};
|
||||
|
||||
/**
|
||||
* Type defining how a line end.
|
||||
* @since 1.13
|
||||
*/
|
||||
typedef enum _Efl_Geometry_Cap
|
||||
{
|
||||
EFL_GEOMETRY_CAP_BUTT,
|
||||
EFL_GEOMETRY_CAP_ROUND,
|
||||
EFL_GEOMETRY_CAP_SQUARE,
|
||||
EFL_GEOMETRY_CAP_LAST
|
||||
} Efl_Geometry_Cap;
|
||||
|
||||
/**
|
||||
* Type defining how join between path are drawn.
|
||||
* @since 1.13
|
||||
*/
|
||||
typedef enum _Efl_Geometry_Join
|
||||
{
|
||||
EFL_GEOMETRY_JOIN_MITER,
|
||||
EFL_GEOMETRY_JOIN_ROUND,
|
||||
EFL_GEOMETRY_JOIN_BEVEL,
|
||||
EFL_GEOMETRY_JOIN_LAST
|
||||
} Efl_Geometry_Join;
|
||||
|
||||
#ifdef EFL_BETA_API_SUPPORT
|
||||
|
||||
/* Interfaces */
|
||||
|
@ -44,6 +99,8 @@ extern "C"
|
|||
#include "interfaces/efl_text.eo.h"
|
||||
#include "interfaces/efl_text_properties.eo.h"
|
||||
|
||||
#include "interfaces/efl_geometry_shape.eo.h"
|
||||
|
||||
#endif
|
||||
|
||||
#if defined ( __cplusplus )
|
||||
|
|
|
@ -0,0 +1,82 @@
|
|||
interface Efl.Geometry.Shape
|
||||
{
|
||||
legacy_prefix: null;
|
||||
properties {
|
||||
stroke_scale {
|
||||
set {
|
||||
}
|
||||
get {
|
||||
}
|
||||
values {
|
||||
double s;
|
||||
}
|
||||
}
|
||||
stroke_color {
|
||||
set {
|
||||
}
|
||||
get {
|
||||
}
|
||||
values {
|
||||
int r;
|
||||
int g;
|
||||
int b;
|
||||
int a;
|
||||
}
|
||||
}
|
||||
stroke_width {
|
||||
set {
|
||||
}
|
||||
get {
|
||||
}
|
||||
values {
|
||||
double w;
|
||||
}
|
||||
}
|
||||
stroke_location {
|
||||
set {
|
||||
}
|
||||
get {
|
||||
}
|
||||
values {
|
||||
double centered;
|
||||
}
|
||||
}
|
||||
stroke_dash {
|
||||
set {
|
||||
}
|
||||
get {
|
||||
}
|
||||
values {
|
||||
const(Efl_Geometry_Dash) *dash;
|
||||
uint length;
|
||||
}
|
||||
}
|
||||
stroke_cap {
|
||||
set {
|
||||
}
|
||||
get {
|
||||
}
|
||||
values {
|
||||
Efl_Geometry_Cap c;
|
||||
}
|
||||
}
|
||||
stroke_join {
|
||||
set {
|
||||
}
|
||||
get {
|
||||
}
|
||||
values {
|
||||
Efl_Geometry_Join j;
|
||||
}
|
||||
}
|
||||
}
|
||||
methods {
|
||||
path_set {
|
||||
return: bool;
|
||||
params {
|
||||
@in const(Efl_Geometry_Path_Command) *op;
|
||||
@in const(double) *points;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -10,3 +10,5 @@
|
|||
#include "interfaces/efl_player.eo.c"
|
||||
#include "interfaces/efl_text.eo.c"
|
||||
#include "interfaces/efl_text_properties.eo.c"
|
||||
|
||||
#include "interfaces/efl_geometry_shape.eo.c"
|
||||
|
|
Loading…
Reference in New Issue