diff options
Diffstat (limited to 'generic/Text.c')
-rw-r--r-- | generic/Text.c | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/generic/Text.c b/generic/Text.c index b01348b..187a228 100644 --- a/generic/Text.c +++ b/generic/Text.c @@ -845,14 +845,15 @@ GetAnchor(Item item, */ static ZnBool GetClipVertices(Item item, - ZnPoint **points, - int *num_points) + ZnPoly *poly) { + ZnPoint *points; + ZnListAssertSize(item->wi->work_pts, 2); - *points = (ZnPoint *) ZnListArray(item->wi->work_pts); - *num_points = 2; - (*points)[0] = item->item_bounding_box.orig; - (*points)[1] = item->item_bounding_box.corner; + points = (ZnPoint *) ZnListArray(item->wi->work_pts); + POLY_CONTOUR1(poly, points, 2); + points[0] = item->item_bounding_box.orig; + points[1] = item->item_bounding_box.corner; return True; } @@ -870,6 +871,7 @@ GetClipVertices(Item item, */ static int Coords(Item item, + int contour, int index, int cmd, ZnPoint **pts, @@ -908,9 +910,9 @@ Coords(Item item, */ static ItemClassStruct TEXT_ITEM_CLASS = { sizeof(TextItemStruct), - False, - False, - True, + False, /* has_fields */ + False, /* has_parts */ + True, /* has_anchors */ "text", text_attrs, Init, @@ -918,15 +920,17 @@ static ItemClassStruct TEXT_ITEM_CLASS = { Destroy, Configure, Query, - NULL, + NULL, /* GetFieldSet */ GetAnchor, GetClipVertices, Coords, + NULL, /* Contour */ ComputeCoordinates, ToArea, Draw, IsSensitive, Pick, + NULL, /* PickVertex */ PostScript }; |