X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=src%2Foutput%2Fchart.c;h=a70862982b888e30e9c10955da06d34b6295f4d6;hb=02c766f3f1ff964f0d4fa4849f1a55e193afa48d;hp=8649feb8f75adecc6762148df462b1d8fe8c2c19;hpb=164d1274fcb70c54897f2a03fc7c27152ed4821a;p=pspp
diff --git a/src/output/chart.c b/src/output/chart.c
index 8649feb8f7..a70862982b 100644
--- a/src/output/chart.c
+++ b/src/output/chart.c
@@ -1,20 +1,18 @@
-/* PSPP - computes sample statistics.
+/* PSPP - a program for statistical analysis.
Copyright (C) 2004 Free Software Foundation, Inc.
- This program is free software; you can redistribute it and/or
- modify it under the terms of the GNU General Public License as
- published by the Free Software Foundation; either version 2 of the
- License, or (at your option) any later version.
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
- This program is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
- 02110-1301, USA. */
+ along with this program. If not, see . */
#include
#include
@@ -43,21 +41,21 @@ chart_create(void)
d = outp_drivers (NULL);
if (d == NULL)
return NULL;
-
+
chart = xmalloc (sizeof *chart);
d->class->initialise_chart(d, chart);
- if (!chart->lp)
+ if (!chart->lp)
{
free (chart);
- return NULL;
+ return NULL;
}
if (pl_openpl_r (chart->lp) < 0) /* open Plotter */
return NULL;
-
+
pl_fspace_r (chart->lp, 0.0, 0.0, 1000.0, 1000.0); /* set coordinate system */
pl_flinewidth_r (chart->lp, 0.25); /* set line thickness */
- pl_pencolorname_r (chart->lp, "black");
+ pl_pencolorname_r (chart->lp, "black");
pl_erase_r (chart->lp); /* erase graphics display */
pl_filltype_r(chart->lp,0);
@@ -78,12 +76,12 @@ chart_create(void)
strcpy(chart->fill_colour,"red");
/* Get default font size */
- if ( !chart->font_size)
+ if ( !chart->font_size)
chart->font_size = pl_fontsize_r(chart->lp, -1);
/* Draw the data area */
- pl_box_r(chart->lp,
- chart->data_left, chart->data_bottom,
+ pl_box_r(chart->lp,
+ chart->data_left, chart->data_bottom,
chart->data_right, chart->data_top);
return chart;
@@ -95,7 +93,7 @@ chart_submit(struct chart *chart)
struct som_entity s;
struct outp_driver *d;
- if ( ! chart )
+ if ( ! chart )
return ;
pl_restorestate_r(chart->lp);
@@ -104,7 +102,7 @@ chart_submit(struct chart *chart)
s.ext = chart;
s.type = SOM_CHART;
som_submit (&s);
-
+
if (pl_closepl_r (chart->lp) < 0) /* close Plotter */
{
fprintf (stderr, "Couldn't close Plotter\n");