..
tween: "filenameN.ext";
border: left right top bottom;
- middle: 0-1;
+ middle: 0/1/NONE/DEFAULT/SOLID;
}
..
}
@property
middle
@parameters
- [0 or 1]
+ 0, 1, NONE, DEFAULT, SOLID
@effect
- If border is set, this boolean value tells Edje if the rest of the
- image (not covered by the defined border) will be displayed or not.
- The default value is 1.
+ If border is set, this value tells Edje if the rest of the
+ image (not covered by the defined border) will be displayed or not
+ or be assumed to be solid (without alpha). The default is 1/DEFAULT.
@endproperty
*/
static void
ed = ep->default_desc;
if (ep->other_desc) ed = eina_list_data_get(eina_list_last(ep->other_desc));
- ed->border.no_fill = !parse_bool(0);
+ ed->border.no_fill = parse_enum(0,
+ "1", 0,
+ "DEFAULT", 0,
+ "0", 1,
+ "NONE", 1,
+ "SOLID", 2,
+ NULL);
}
/**
evas_object_image_border_set(ep->object, p3->border.l, p3->border.r,
p3->border.t, p3->border.b);
- evas_object_image_border_center_fill_set(ep->object,
- !(chosen_desc->border.no_fill));
+ if (chosen_desc->border.no_fill == 0)
+ evas_object_image_border_center_fill_set(ep->object, EVAS_BORDER_FILL_DEFAULT);
+ else if (chosen_desc->border.no_fill == 1)
+ evas_object_image_border_center_fill_set(ep->object, EVAS_BORDER_FILL_NONE);
+ else if (chosen_desc->border.no_fill == 2)
+ evas_object_image_border_center_fill_set(ep->object, EVAS_BORDER_FILL_SOLID);
image_id = ep->param1.description->image.id;
if (image_id < 0)
{
edje_edit_state_image_border_fill_get(Evas_Object *obj, const char *part, const char *state)
{
GET_PD_OR_RETURN(0);
- return pd->border.no_fill ? 0 : 1;
+ if (pd->border.no_fill == 0) return 1;
+ else if (pd->border.no_fill == 1) return 0;
+ else if (pd->border.no_fill == 2) return 2;
+ return 0;
}
EAPI void
edje_edit_state_image_border_fill_set(Evas_Object *obj, const char *part, const char *state, unsigned char fill)
{
GET_PD_OR_RETURN();
- pd->border.no_fill = fill ? 0 : 1;
+ if (fill == 0) pd->border.no_fill = 1;
+ else if (fill == 1) pd->border.no_fill = 0;
+ else if (fill == 2) pd->border.no_fill = 2;
edje_object_calc_force(obj);
}
if (pd->border.l || pd->border.r || pd->border.t || pd->border.b)
fprintf(f, I6"border: %d %d %d %d;\n", pd->border.l, pd->border.r, pd->border.t, pd->border.b);
- if (pd->border.no_fill)
- fprintf(f, I6"middle: 0;\n");
+ if (pd->border.no_fill == 1)
+ fprintf(f, I6"middle: NONE;\n");
+ else if (pd->border.no_fill == 0)
+ fprintf(f, I6"middle: DEFAULT;\n");
+ else if (pd->border.no_fill == 2)
+ fprintf(f, I6"middle: SOLID;\n");
fprintf(f, I5"}\n");//image
}