From: ellson Date: Thu, 27 Jul 2006 00:28:50 +0000 (+0000) Subject: - move usershape images down a layer in -Tfig so that the node is drawn on top X-Git-Tag: LAST_LIBGRAPH~32^2~6047 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3f98e230f4c5fe315f16244d562fe0d11c9fa9f7;p=graphviz - move usershape images down a layer in -Tfig so that the node is drawn on top - add commentary for the strange 1.2 scaling needed to get usershapes the right size. --- diff --git a/plugin/core/gvloadimage_core.c b/plugin/core/gvloadimage_core.c index 6e006c400..9419d1eb8 100644 --- a/plugin/core/gvloadimage_core.c +++ b/plugin/core/gvloadimage_core.c @@ -77,7 +77,7 @@ static void core_loadimage_fig(GVJ_t * job, usershape_t *us, boxf bf, bool fille int thickness = 0; int pen_color = 0; int fill_color = -1; - int depth = 0; + int depth = 1; int pen_style = -1; /* not used */ int area_fill = 0; double style_val = 0.0; diff --git a/plugin/core/gvrender_core_fig.c b/plugin/core/gvrender_core_fig.c index 8b9142177..8e04df4ae 100644 --- a/plugin/core/gvrender_core_fig.c +++ b/plugin/core/gvrender_core_fig.c @@ -543,10 +543,12 @@ gvrender_features_t figgen_features = { EMIT_COLORS | GVRENDER_Y_GOES_DOWN, /* flags */ DEFAULT_EMBED_MARGIN, /* default margin - points */ - {1450.,1450.}, /* default dpi */ + {1440.,1440.}, /* default dpi */ /* FIXME - this default dpi is a very strange number!!! - * it was picked to make .png usershapes the right size on my screen - * also 1200 is hardcoded into the o/p file instead of using job->dpi + * It was picked to make .png usershapes the right size on my screen. + * It happens to be 1.2 * 1200, but I can't explain the 1.2. + * (I was expecting 1.3333 which is 96/72, but thats too big.) + * Also 1200 is hardcoded in figgen_begin_graph() instead of using job->dpi */ figgen_knowncolors, /* knowncolors */ sizeof(figgen_knowncolors) / sizeof(char *), /* sizeof knowncolors */