iPDC-suite/iPDC/lib/liblivechart.so.p/drawable.c

223 lines
7.1 KiB
C

/* drawable.c generated by valac 0.56.0, the Vala compiler
* generated from drawable.vala, do not modify */
#include "livechart.h"
#include <glib.h>
#include <string.h>
#include <cairo-gobject.h>
static GType live_chart_drawable_get_type_once (void);
static GType live_chart_colorable_get_type_once (void);
LiveChartBoundingBox*
live_chart_bounding_box_dup (const LiveChartBoundingBox* self)
{
LiveChartBoundingBox* dup;
#line 4 "../src/drawable.vala"
dup = g_new0 (LiveChartBoundingBox, 1);
#line 4 "../src/drawable.vala"
memcpy (dup, self, sizeof (LiveChartBoundingBox));
#line 4 "../src/drawable.vala"
return dup;
#line 23 "drawable.c"
}
void
live_chart_bounding_box_free (LiveChartBoundingBox* self)
{
#line 4 "../src/drawable.vala"
g_free (self);
#line 31 "drawable.c"
}
static GType
live_chart_bounding_box_get_type_once (void)
{
GType live_chart_bounding_box_type_id;
live_chart_bounding_box_type_id = g_boxed_type_register_static ("LiveChartBoundingBox", (GBoxedCopyFunc) live_chart_bounding_box_dup, (GBoxedFreeFunc) live_chart_bounding_box_free);
return live_chart_bounding_box_type_id;
}
GType
live_chart_bounding_box_get_type (void)
{
static volatile gsize live_chart_bounding_box_type_id__once = 0;
if (g_once_init_enter (&live_chart_bounding_box_type_id__once)) {
GType live_chart_bounding_box_type_id;
live_chart_bounding_box_type_id = live_chart_bounding_box_get_type_once ();
g_once_init_leave (&live_chart_bounding_box_type_id__once, live_chart_bounding_box_type_id);
}
return live_chart_bounding_box_type_id__once;
}
void
live_chart_drawable_draw (LiveChartDrawable* self,
cairo_t* ctx,
LiveChartConfig* config)
{
LiveChartDrawableIface* _iface_;
#line 13 "../src/drawable.vala"
g_return_if_fail (self != NULL);
#line 13 "../src/drawable.vala"
_iface_ = LIVE_CHART_DRAWABLE_GET_INTERFACE (self);
#line 13 "../src/drawable.vala"
if (_iface_->draw) {
#line 13 "../src/drawable.vala"
_iface_->draw (self, ctx, config);
#line 68 "drawable.c"
}
}
void
live_chart_drawable_get_bounding_box (LiveChartDrawable* self,
LiveChartBoundingBox* result)
{
LiveChartDrawableIface* _iface_;
#line 15 "../src/drawable.vala"
g_return_if_fail (self != NULL);
#line 15 "../src/drawable.vala"
_iface_ = LIVE_CHART_DRAWABLE_GET_INTERFACE (self);
#line 15 "../src/drawable.vala"
if (_iface_->get_bounding_box) {
#line 15 "../src/drawable.vala"
_iface_->get_bounding_box (self, result);
#line 85 "drawable.c"
}
}
gboolean
live_chart_drawable_get_visible (LiveChartDrawable* self)
{
LiveChartDrawableIface* _iface_;
#line 11 "../src/drawable.vala"
g_return_val_if_fail (self != NULL, FALSE);
#line 11 "../src/drawable.vala"
_iface_ = LIVE_CHART_DRAWABLE_GET_INTERFACE (self);
#line 11 "../src/drawable.vala"
if (_iface_->get_visible) {
#line 11 "../src/drawable.vala"
return _iface_->get_visible (self);
#line 101 "drawable.c"
}
#line 11 "../src/drawable.vala"
return FALSE;
#line 105 "drawable.c"
}
void
live_chart_drawable_set_visible (LiveChartDrawable* self,
gboolean value)
{
LiveChartDrawableIface* _iface_;
#line 11 "../src/drawable.vala"
g_return_if_fail (self != NULL);
#line 11 "../src/drawable.vala"
_iface_ = LIVE_CHART_DRAWABLE_GET_INTERFACE (self);
#line 11 "../src/drawable.vala"
if (_iface_->set_visible) {
#line 11 "../src/drawable.vala"
_iface_->set_visible (self, value);
#line 121 "drawable.c"
}
}
static void
live_chart_drawable_default_init (LiveChartDrawableIface * iface,
gpointer iface_data)
{
#line 10 "../src/drawable.vala"
g_object_interface_install_property (iface, g_param_spec_boolean ("visible", "visible", "visible", TRUE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 131 "drawable.c"
}
static GType
live_chart_drawable_get_type_once (void)
{
static const GTypeInfo g_define_type_info = { sizeof (LiveChartDrawableIface), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) live_chart_drawable_default_init, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
GType live_chart_drawable_type_id;
live_chart_drawable_type_id = g_type_register_static (G_TYPE_INTERFACE, "LiveChartDrawable", &g_define_type_info, 0);
g_type_interface_add_prerequisite (live_chart_drawable_type_id, G_TYPE_OBJECT);
return live_chart_drawable_type_id;
}
GType
live_chart_drawable_get_type (void)
{
static volatile gsize live_chart_drawable_type_id__once = 0;
if (g_once_init_enter (&live_chart_drawable_type_id__once)) {
GType live_chart_drawable_type_id;
live_chart_drawable_type_id = live_chart_drawable_get_type_once ();
g_once_init_leave (&live_chart_drawable_type_id__once, live_chart_drawable_type_id);
}
return live_chart_drawable_type_id__once;
}
void
live_chart_colorable_get_main_color (LiveChartColorable* self,
GdkRGBA * result)
{
LiveChartColorableIface* _iface_;
#line 22 "../src/drawable.vala"
g_return_if_fail (self != NULL);
#line 22 "../src/drawable.vala"
_iface_ = LIVE_CHART_COLORABLE_GET_INTERFACE (self);
#line 22 "../src/drawable.vala"
if (_iface_->get_main_color) {
#line 22 "../src/drawable.vala"
_iface_->get_main_color (self, result);
#line 169 "drawable.c"
}
#line 22 "../src/drawable.vala"
return;
#line 173 "drawable.c"
}
void
live_chart_colorable_set_main_color (LiveChartColorable* self,
GdkRGBA * value)
{
LiveChartColorableIface* _iface_;
#line 22 "../src/drawable.vala"
g_return_if_fail (self != NULL);
#line 22 "../src/drawable.vala"
_iface_ = LIVE_CHART_COLORABLE_GET_INTERFACE (self);
#line 22 "../src/drawable.vala"
if (_iface_->set_main_color) {
#line 22 "../src/drawable.vala"
_iface_->set_main_color (self, value);
#line 189 "drawable.c"
}
}
static void
live_chart_colorable_default_init (LiveChartColorableIface * iface,
gpointer iface_data)
{
#line 20 "../src/drawable.vala"
g_object_interface_install_property (iface, g_param_spec_boxed ("main-color", "main-color", "main-color", gdk_rgba_get_type (), G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_DEPRECATED));
#line 199 "drawable.c"
}
static GType
live_chart_colorable_get_type_once (void)
{
static const GTypeInfo g_define_type_info = { sizeof (LiveChartColorableIface), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) live_chart_colorable_default_init, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
GType live_chart_colorable_type_id;
live_chart_colorable_type_id = g_type_register_static (G_TYPE_INTERFACE, "LiveChartColorable", &g_define_type_info, 0);
g_type_interface_add_prerequisite (live_chart_colorable_type_id, G_TYPE_OBJECT);
return live_chart_colorable_type_id;
}
GType
live_chart_colorable_get_type (void)
{
static volatile gsize live_chart_colorable_type_id__once = 0;
if (g_once_init_enter (&live_chart_colorable_type_id__once)) {
GType live_chart_colorable_type_id;
live_chart_colorable_type_id = live_chart_colorable_get_type_once ();
g_once_init_leave (&live_chart_colorable_type_id__once, live_chart_colorable_type_id);
}
return live_chart_colorable_type_id__once;
}