table: Avoid initializer warnings with GCC 4.9.
[pspp] / src / output / charts / barchart.h
index d47ce165bb24d641f67ced9f2dcf9ea0e260f903..d43e379b9f64f5e3d52f30c7c03cb78fca84ae13 100644 (file)
@@ -37,6 +37,9 @@ struct barchart
   {
     struct chart_item chart_item;
 
+    /* Should the chart be displayed as percentages */
+    bool percent;
+
     /* The categories */
     struct freq **cats;
 
@@ -49,6 +52,9 @@ struct barchart
     /* The largest count of all the categories */
     double largest;
 
+    /* The sum of all the counts */
+    double total_count;
+
     /* The label for the ordinate (vertical axis) */
     char *ylabel;
 
@@ -65,7 +71,7 @@ struct barchart
     struct hmap secondaries;
 
 
-    /* A array of pointers to the members of the above hmap, 
+    /* A array of pointers to the members of the above hmap,
        sorted by VAL */
     struct category **ss;
   };
@@ -75,7 +81,7 @@ struct variable;
 struct freq;
 
 struct chart_item *barchart_create (const struct variable **, int n_vars,
-                                   const char *ylabel,
+                                   const char *ylabel, bool percent,
                                     struct freq *const *, int n_cats);
 \f
 /* This boilerplate for barchart, a subclass of chart_item, was