From: ellson Date: Tue, 18 Oct 2005 21:10:03 +0000 (+0000) Subject: Fix for bug 784 X-Git-Tag: LAST_LIBGRAPH~32^2~7078 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ff475f8c8db377ec68ce1162ca2b2857fdd818ca;p=graphviz Fix for bug 784 --- diff --git a/lib/common/psgen.c b/lib/common/psgen.c index 0b91d9b94..7d4ca406c 100644 --- a/lib/common/psgen.c +++ b/lib/common/psgen.c @@ -541,12 +541,21 @@ static void ps_user_shape(char *name, point * A, int sides, int filled) shapeimagefile = agget(Curnode, "shapefile"); } else if (find_user_shape(name)) { + if (filled) { + ps_begin_context(); + ps_set_color(S[SP].fillcolor); + fprintf(Output_file, "[ "); + for (j = 0; j < sides; j++) + fprintf(Output_file, "%d %d ", A[j].x, A[j].y); + fprintf(Output_file, "%d %d ", A[0].x, A[0].y); + fprintf(Output_file, "] %d true %s\n", sides, name); + ps_end_context(); + } fprintf(Output_file, "[ "); for (j = 0; j < sides; j++) fprintf(Output_file, "%d %d ", A[j].x, A[j].y); fprintf(Output_file, "%d %d ", A[0].x, A[0].y); - fprintf(Output_file, "] %d %s %s\n", sides, - (filled ? "true" : "false"), name); + fprintf(Output_file, "] %d false %s\n", sides, name); return; } else