2013-09-13 23:25:46 +00:00
|
|
|
#ifndef __AG_CHART_H__
|
|
|
|
#define __AG_CHART_H__
|
|
|
|
|
|
|
|
#include <glib-object.h>
|
|
|
|
#include <swe-glib.h>
|
|
|
|
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
|
2013-09-18 08:02:23 +00:00
|
|
|
typedef enum {
|
|
|
|
AG_CHART_ERROR_LIBXML,
|
|
|
|
AG_CHART_ERROR_CORRUPT_FILE,
|
|
|
|
} AgChartError;
|
|
|
|
|
2013-09-13 23:25:46 +00:00
|
|
|
#define AG_TYPE_CHART (ag_chart_get_type())
|
|
|
|
#define AG_CHART(o) (G_TYPE_CHECK_INSTANCE_CAST((o), AG_TYPE_CHART, AgChart))
|
|
|
|
#define AG_CHART_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), AG_TYPE_CHART, AgChartClass))
|
|
|
|
#define AG_IS_CHART(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), AG_TYPE_CHART))
|
|
|
|
#define AG_IS_CHART_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE((k), AG_TYPE_CHART))
|
|
|
|
#define AG_CHART_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS((o), AG_TYPE_CHART, AgChartClass))
|
|
|
|
|
|
|
|
typedef struct _AgChart AgChart;
|
|
|
|
typedef struct _AgChartClass AgChartClass;
|
|
|
|
typedef struct _AgChartPrivate AgChartPrivate;
|
|
|
|
|
|
|
|
struct _AgChart {
|
|
|
|
GsweMoment parent_instance;
|
|
|
|
AgChartPrivate *priv;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct _AgChartClass {
|
|
|
|
GsweMomentClass parent_class;
|
|
|
|
};
|
|
|
|
|
|
|
|
GType ag_chart_get_type(void) G_GNUC_CONST;
|
2013-09-14 15:37:33 +00:00
|
|
|
AgChart *ag_chart_new_full(GsweTimestamp *timestamp, gdouble longitude, gdouble latitude, gdouble altitude, GsweHouseSystem house_system);
|
2013-09-18 08:05:24 +00:00
|
|
|
AgChart *ag_chart_load_from_file(GFile *file, GError **err);
|
2013-09-18 08:06:12 +00:00
|
|
|
void ag_chart_save_to_file(AgChart *chart, GFile *file, GError **err);
|
2013-09-13 23:25:46 +00:00
|
|
|
|
2013-09-17 20:18:24 +00:00
|
|
|
void ag_chart_set_name(AgChart *chart, const gchar *name);
|
|
|
|
gchar *ag_chart_get_name(AgChart *chart);
|
|
|
|
void ag_chart_set_country(AgChart *chart, const gchar *country);
|
|
|
|
gchar *ag_chart_get_country(AgChart *chart);
|
|
|
|
void ag_chart_set_city(AgChart *chart, const gchar *city);
|
|
|
|
gchar *ag_chart_get_city(AgChart *chart);
|
|
|
|
|
2013-09-18 08:02:23 +00:00
|
|
|
#define AG_CHART_ERROR (ag_chart_error_quark())
|
|
|
|
GQuark ag_chart_error_quark(void);
|
|
|
|
|
2013-09-13 23:25:46 +00:00
|
|
|
G_END_DECLS
|
|
|
|
|
|
|
|
#endif /* __AG_CHART_H__ */
|
|
|
|
|