X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Foutput%2Fhtml.c;h=3a8be8eb0b0e2cbf8db200b73bf5099244f5c2c3;hb=77dc491d3b0c1429801ec839e7afab0fbef6a7fc;hp=d943f192aa3a63c93800599fc1099f71da05979c;hpb=e0c37920bb2cc46ee559e3992470572d4b4d27e6;p=pspp-builds.git diff --git a/src/output/html.c b/src/output/html.c index d943f192..3a8be8eb 100644 --- a/src/output/html.c +++ b/src/output/html.c @@ -138,14 +138,6 @@ html_close_driver (struct outp_driver *this) return ok; } -/* Link the image contained in FILE_NAME to the - HTML stream in FILE. */ -static void -link_image (FILE *file, char *file_name) -{ - fprintf (file, "", file_name); - } - /* Generic option types. */ enum { @@ -208,22 +200,10 @@ static void html_output_chart (struct outp_driver *this, const struct chart *chart) { struct html_driver_ext *x = this->ext; - struct chart_geometry geom; char *file_name; - plPlotter *lp; - - /* Draw chart in separate file. */ - if (!chart_create_file ("png", x->chart_file_name, x->chart_cnt, - NULL, &file_name, &lp)) - return; - x->chart_cnt++; - chart_geometry_init (lp, &geom, 1000.0, 1000.0); - chart_draw (chart, lp, &geom); - chart_geometry_free (lp); - pl_deletepl_r (lp); - - link_image (x->file, file_name); + file_name = chart_draw_png (chart, x->chart_file_name, x->chart_cnt++); + fprintf (x->file, "", file_name); free (file_name); }