/* PSPP - a program for statistical analysis.
- Copyright (C) 2009 Free Software Foundation, Inc.
+ Copyright (C) 2009, 2011 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
#ifndef OUTPUT_CHART_H
#define OUTPUT_CHART_H 1
-#include <cairo/cairo.h>
+/* Charts.
-struct chart;
+ A chart is abstract. Every actual chart is a subclass of chart. */
+
+#include <stdbool.h>
+
+/* A chart.
+
+ The members of struct chart should not be accessed directly. Use one
+ of the accessor functions defined below. */
+struct chart
+ {
+ int ref_cnt;
+ const struct chart_class *class; /* Subclass. */
+ char *title; /* May be null if there is no title. */
+ };
struct chart *chart_ref (const struct chart *);
void chart_unref (struct chart *);
+bool chart_is_shared (const struct chart *);
+
+const char *chart_get_title (const struct chart *);
+void chart_set_title (struct chart *, const char *);
void chart_submit (struct chart *);