diff options
Diffstat (limited to 'src/Type1/paths.c')
-rw-r--r-- | src/Type1/paths.c | 106 |
1 files changed, 1 insertions, 105 deletions
diff --git a/src/Type1/paths.c b/src/Type1/paths.c index 6291d68..3fec84e 100644 --- a/src/Type1/paths.c +++ b/src/Type1/paths.c @@ -26,7 +26,7 @@ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF * THIS SOFTWARE. */ -/* $XFree86: xc/lib/font/Type1/paths.c,v 1.7 2002/02/18 20:51:57 herrb Exp $ */ +/* $XFree86: xc/lib/font/Type1/paths.c,v 1.8 2003/05/27 22:26:46 tsi Exp $ */ /* PATHS CWEB V0021 ******** */ /* @@ -211,8 +211,6 @@ t1_Loc(struct XYspace *S, /* coordinate space to interpret X,Y */ register struct segment *r; - IfTrace3((MustTraceCalls),"..Loc(S=%z, x=%f, y=%f)\n", S, &x, &y); - r = (struct segment *)Allocate(sizeof(struct segment), &movetemplate, 0); TYPECHECK("Loc", S, SPACETYPE, r, (0), struct segment *); @@ -232,8 +230,6 @@ ILoc(struct XYspace *S, /* coordinate space to interpret X,Y */ { register struct segment *r; - IfTrace3((MustTraceCalls),"..ILoc(S=%z, x=%d, y=%d)\n", - S, (long) x, (long) y); r = (struct segment *)Allocate(sizeof(struct segment), &movetemplate, 0); TYPECHECK("Loc", S, SPACETYPE, r, (0), struct segment *); @@ -257,8 +253,6 @@ so it is not provided. struct segment * SubLoc(struct segment *p1, struct segment *p2) { - IfTrace2((MustTraceCalls),"SubLoc(%z, %z)\n", p1, p2); - ARGCHECK(!ISLOCATION(p1), "SubLoc: bad first arg", p1, NULL, (0), struct segment *); ARGCHECK(!ISLOCATION(p2), "SubLoc: bad second arg", p2, NULL, (0), struct segment *); p1 = UniquePath(p1); @@ -301,8 +295,6 @@ This involves just creating and filling out a segment structure: struct segment * Line(struct segment *P) /* relevant coordinate space */ { - - IfTrace1((MustTraceCalls),"..Line(%z)\n", P); ARGCHECK(!ISLOCATION(P), "Line: arg not a location", P, NULL, (0), struct segment *); P = UniquePath(P); @@ -345,7 +337,6 @@ Bezier(struct segment *B, /* second control point */ register struct beziersegment *r; /* output segment */ - IfTrace3((MustTraceCalls),"..Bezier(%z, %z, %z)\n", B, C, D); ARGCHECK(!ISLOCATION(B), "Bezier: bad B", B, NULL, (2,C,D), struct beziersegment *); ARGCHECK(!ISLOCATION(C), "Bezier: bad C", C, NULL, (2,B,D), struct beziersegment *); ARGCHECK(!ISLOCATION(D), "Bezier: bad D", D, NULL, (2,B,C), struct beziersegment *); @@ -447,8 +438,6 @@ rules. struct segment * Join(struct segment *p1, struct segment *p2) { - IfTrace2((MustTraceCalls && PathDebug > 1),"..Join(%z, %z)\n", p1, p2); - IfTrace2((MustTraceCalls && PathDebug <=1),"..Join(%x, %x)\n", p1, p2); /* We start with a whole bunch of very straightforward argument tests: */ @@ -603,7 +592,6 @@ t1_ClosePath(struct segment *p0, /* path to close */ register fractpel firstx = 0,firsty = 0; /* start position of sub path */ register struct segment *lastnonhint = NULL; /* last non-hint segment in path */ - IfTrace1((MustTraceCalls),"ClosePath(%z)\n", p0); if (p0 != NULL && p0->type == TEXTTYPE) return(UniquePath(p0)); if (p0->type == STROKEPATHTYPE) @@ -650,9 +638,6 @@ At each break, we insert a close segment. if (r->dest.x != 0 || r->dest.y != 0) { if (r->dest.x <= CLOSEFUDGE && r->dest.x >= -CLOSEFUDGE && r->dest.y <= CLOSEFUDGE && r->dest.y >= -CLOSEFUDGE) { - IfTrace2((PathDebug), - "ClosePath forced closed by (%p,%p)\n", - r->dest.x, r->dest.y); lastnonhint->dest.x += r->dest.x; lastnonhint->dest.y += r->dest.y; r->dest.x = r->dest.y = 0; @@ -707,8 +692,6 @@ Reverse(struct segment *p) /* full path to reverse */ register struct segment *r; /* output path built here */ register struct segment *nextp; /* contains next sub-path */ - IfTrace1((MustTraceCalls),"Reverse(%z)\n", p); - if (p == NULL) return(NULL); @@ -883,8 +866,6 @@ ReverseSubPaths(struct segment *p) /* input path */ register struct segment *nomove; /* the part of sub-path without move segment */ struct fractpoint delta; - IfTrace1((MustTraceCalls),"ReverseSubPaths(%z)\n", p); - if (p == NULL) return(NULL); @@ -1024,7 +1005,6 @@ PathTransform(struct segment *p0, /* path to transform */ } default: - IfTrace1(TRUE,"path = %z\n", p); Abort("PathTransform: invalid segment"); } oldx += savex; @@ -1091,8 +1071,6 @@ QueryLoc(struct segment *P, /* location to query, not consumed */ struct XYspace *S, /* XY space to return coordinates in */ double *xP, double *yP) /* coordinates returned here */ { - IfTrace4((MustTraceCalls),"QueryLoc(P=%z, S=%z, (%x, %x))\n", - P, S, xP, yP); if (!ISLOCATION(P)) { ArgErr("QueryLoc: first arg not a location", P, NULL); return; @@ -1124,8 +1102,6 @@ QueryPath(struct segment *path, /* path to check */ { register int coerced = FALSE; /* did I coerce a text path? */ - IfTrace3((MustTraceCalls), "QueryPath(%z, %x, %x, ...)\n", - path, typeP, Bp); if (path == NULL) { *typeP = -1; return; @@ -1204,9 +1180,6 @@ QueryBounds(struct segment *p0, /* object to check for bound */ int coerced = FALSE; /* we have coerced the path from another object */ double x1,y1,x2,y2,x3,y3,x4,y4; /* corners of rectangle in space X */ - IfTrace2((MustTraceCalls), "QueryBounds(%z, %z,", p0, S); - IfTrace4((MustTraceCalls), " %x, %x, %x, %x)\n", - xminP, yminP, xmaxP, ymaxP); if (S->type != SPACETYPE) { ArgErr("QueryBounds: bad XYspace", S, NULL); return; @@ -1379,7 +1352,6 @@ to ask about an entire path. struct segment * DropSegment(struct segment *path) { - IfTrace1((MustTraceCalls),"DropSegment(%z)\n", path); if (path != NULL && path->type == STROKEPATHTYPE) path = CoercePath(path); ARGCHECK((path == NULL || !ISPATHANCHOR(path)), @@ -1401,7 +1373,6 @@ first segment only. struct segment * HeadSegment(struct segment *path) /* input path */ { - IfTrace1((MustTraceCalls),"HeadSegment(%z)\n", path); if (path == NULL) return(NULL); if (path->type == STROKEPATHTYPE) @@ -1427,79 +1398,4 @@ HeadSegment(struct segment *path) /* input path */ void DumpPath(struct segment *p) { - register fractpel x,y; - register fractpel lastx,lasty; - double roundness; - - IfTrace1(TRUE,"Dumping path, anchor=%x:\n", p); - lastx = lasty = 0; - - for (;p != NULL; p=p->link) { - - IfTrace0(TRUE,". "); - x = p->dest.x; - y = p->dest.y; - switch (p->type) { - - case LINETYPE: - IfTrace1(TRUE,". line<%x> to", (long) p->flag); - IfTrace4(TRUE," (%p,%p), delta=(%p,%p)", - x + lastx, y + lasty, x, y); - break; - - case MOVETYPE: - IfTrace1(TRUE,"MOVE<%x> to", (long) p->flag); - IfTrace4(TRUE,"(%p,%p), delta=(%p,%p)", - x + lastx, y + lasty, x, y); - break; - - case CONICTYPE: - { - register struct conicsegment *cp = (struct conicsegment *) p; - - roundness = cp->roundness; - IfTrace2(TRUE, ". conic to (%p,%p),", - x + lastx, y + lasty); - IfTrace3(TRUE," M=(%p,%p), r=%f", cp->M.x + lastx, - cp->M.y + lasty, &roundness); - } - break; - - case BEZIERTYPE: - { - IfTrace4(TRUE,". bezier to (%p,%p), B=(%p,%p)", - x + lastx, y + lasty, - bp->B.x + lastx, bp->B.y + lasty); - IfTrace2(TRUE, ", C=(%p,%p)", - bp->C.x + lastx, bp->C.y + lasty); - } - break; - - case HINTTYPE: - { - IfTrace4(TRUE,". hint ref=(%p,%p), width=(%p,%p)", - hp->ref.x + lastx, hp->ref.y + lasty, - hp->width.x, hp->width.y); - IfTrace4(TRUE, ", %c %c %c %c", - hp->orientation, hp->hinttype, - hp->adjusttype, hp->direction); - IfTrace1(TRUE, ", %ld", (long) hp->label); - } - break; - - case TEXTTYPE: -#ifdef notyet - DumpText(p); -#endif - break; - - default: - IfTrace0(TRUE, "bad path segment?"); - } - IfTrace1(TRUE," at %x\n", p); - lastx += x; - lasty += y; - } } - - |