From: Emden R. Gansner Date: Thu, 5 Dec 2013 19:04:36 +0000 (-0500) Subject: Fix bug 2393 X-Git-Tag: 2.38.0~139 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=45957b09a5fce20e36bfa9216de542fdd5b2f32d;p=graphviz Fix bug 2393 --- diff --git a/lib/common/emit.c b/lib/common/emit.c index 3eb61564e..7a241dd2b 100644 --- a/lib/common/emit.c +++ b/lib/common/emit.c @@ -3138,6 +3138,8 @@ static void init_job_viewport(GVJ_t * job, graph_t * g) Z = 1.0; if (GD_drawing(g)->size.x > 0.001 && GD_drawing(g)->size.y > 0.001) { /* graph size was given by user... */ size = GD_drawing(g)->size; + if (sz.x == 0) sz.x = size.x; + if (sz.y == 0) sz.y = size.y; if ((size.x < sz.x) || (size.y < sz.y) /* drawing is too big (in either axis) ... */ || ((GD_drawing(g)->filled) /* or ratio=filled requested and ... */ && (size.x > sz.x) && (size.y > sz.y))) /* drawing is too small (in both axes) ... */