]> granicus.if.org Git - graphviz/commitdiff
Modify the round_corner function so that it draws a boundary only if penc != NULL
authorerg <devnull@localhost>
Wed, 20 Jul 2011 21:10:50 +0000 (21:10 +0000)
committererg <devnull@localhost>
Wed, 20 Jul 2011 21:10:50 +0000 (21:10 +0000)
lib/common/shapes.c

index c5c5a37e224d92a60f80ff7b04146a49fe8c347a..260c7ca05a8150d58393cd4d38782f91a423b801 100644 (file)
@@ -441,11 +441,12 @@ void round_corners(GVJ_t * job, char *fillc, char *penc, pointf * AF,
                                     TRUE);
            }
        }
-       gvrender_set_pencolor(job, penc);
-       for (seg = 0; seg < sides; seg++) {
-           gvrender_polyline(job, B + 4 * seg + 1, 2);
-           gvrender_beziercurve(job, B + 4 * seg + 2, 4, FALSE, FALSE,
-                                FALSE);
+       if (penc) {
+           gvrender_set_pencolor(job, penc);
+           for (seg = 0; seg < sides; seg++) {
+               gvrender_polyline(job, B + 4 * seg + 1, 2);
+               gvrender_beziercurve(job, B + 4 * seg + 2, 4, FALSE, FALSE, FALSE);
+           }
        }
        break;
     case DIAGONALS: