From: Matthew Fernandez Date: Mon, 20 Dec 2021 04:01:22 +0000 (-0800) Subject: gvloadimage: [nfc] take a C99 bool parameter instead of a boolean X-Git-Tag: 3.0.0~112^2~3 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5e37d64f4153135d96b09b63929c5b926583f87a;p=graphviz gvloadimage: [nfc] take a C99 bool parameter instead of a boolean --- diff --git a/lib/gvc/gvcproc.h b/lib/gvc/gvcproc.h index 5a4a86255..eb92100bd 100644 --- a/lib/gvc/gvcproc.h +++ b/lib/gvc/gvcproc.h @@ -53,7 +53,7 @@ bool gvtextlayout(GVC_t *gvc, textspan_t *span, char **fontpath); /* loadimage */ - void gvloadimage(GVJ_t *job, usershape_t *us, boxf b, boolean filled, const char *target); + void gvloadimage(GVJ_t *job, usershape_t *us, boxf b, bool filled, const char *target); /* usershapes */ point gvusershape_size_dpi(usershape_t *us, pointf dpi); diff --git a/lib/gvc/gvloadimage.c b/lib/gvc/gvloadimage.c index aadd76215..bb8e52691 100644 --- a/lib/gvc/gvloadimage.c +++ b/lib/gvc/gvloadimage.c @@ -25,6 +25,7 @@ /* for agerr() */ #include +#include static int gvloadimage_select(GVJ_t * job, char *str) { @@ -41,7 +42,7 @@ static int gvloadimage_select(GVJ_t * job, char *str) return NO_SUPPORT; } -void gvloadimage(GVJ_t * job, usershape_t *us, boxf b, boolean filled, const char *target) +void gvloadimage(GVJ_t * job, usershape_t *us, boxf b, bool filled, const char *target) { gvloadimage_engine_t *gvli; char type[SMALLBUF]; @@ -59,5 +60,5 @@ void gvloadimage(GVJ_t * job, usershape_t *us, boxf b, boolean filled, const cha agerr (AGWARN, "No loadimage plugin for \"%s\"\n", type); if ((gvli = job->loadimage.engine) && gvli->loadimage) - gvli->loadimage(job, us, b, filled); + gvli->loadimage(job, us, b, filled ? TRUE : FALSE); } diff --git a/lib/gvc/gvrender.c b/lib/gvc/gvrender.c index ee093d4fa..77395a770 100644 --- a/lib/gvc/gvrender.c +++ b/lib/gvc/gvrender.c @@ -820,7 +820,7 @@ void gvrender_usershape(GVJ_t * job, char *name, pointf * a, int n, b.UR.y = d; } if (gvre) { - gvloadimage(job, us, b, filled, job->render.type); + gvloadimage(job, us, b, filled != FALSE, job->render.type); } }