diff options
Diffstat (limited to 'Bezier.c')
-rw-r--r-- | Bezier.c | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -70,7 +70,7 @@ typedef struct _BezierItemStruct { /* Public data */ ZnList points; - unsigned int flags; + unsigned short flags; ZnLineEnd first_end; /* These two are considered only if relief is flat */ ZnLineEnd last_end; LineStyle line_style; /* This is considered only if relief is flat */ @@ -257,9 +257,13 @@ Clone(Item item) char *text; bz->dev_points = NULL; - bz->grad_geo = NULL; bz->tristrip.num_strips = 0; + if (bz->grad_geo) { + ZnPoint *grad_geo = ZnMalloc(4*sizeof(ZnPoint)); + memcpy(grad_geo, bz->grad_geo, 4*sizeof(ZnPoint)); + bz->grad_geo = grad_geo; + } if (bz->gradient) { bz->gradient = ZnGetGradientByValue(bz->gradient); } @@ -962,8 +966,7 @@ Render(Item item) ZnLineEnd last = ISSET(bz->flags, LAST_END_OK) ? bz->last_end : NULL; RenderPolyline(wi, points, num_points, - bz->line_width, False, - bz->line_style, bz->cap_style, JoinRound, + bz->line_width, bz->line_style, bz->cap_style, JoinRound, first, last, bz->line_color); } } |