/* def-basic-ss-display.c generated by valac 0.24.0, the Vala compiler
 * generated from def-basic-ss-display.vala, do not modify */

/* 
 * SmartSim - Digital Logic Circuit Designer and Simulator
 *   
 *   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.
 *   
 *   You should have received a copy of the GNU General Public License
 *   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *   
 *   Filename: componentdef/def-basic-ss-display.vala
 *   
 *   Copyright Ashley Newson 2013
 */

#include <glib.h>
#include <glib-object.h>
#include <cairo.h>
#include <libxml/tree.h>
#include <libxml/xmlwriter.h>
#include <stdlib.h>
#include <string.h>
#include <float.h>
#include <math.h>
#include <config.h>
#include <stdio.h>


#define TYPE_COMPONENT_DEF (component_def_get_type ())
#define COMPONENT_DEF(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_COMPONENT_DEF, ComponentDef))
#define COMPONENT_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_COMPONENT_DEF, ComponentDefClass))
#define IS_COMPONENT_DEF(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_COMPONENT_DEF))
#define IS_COMPONENT_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_COMPONENT_DEF))
#define COMPONENT_DEF_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_COMPONENT_DEF, ComponentDefClass))

typedef struct _ComponentDef ComponentDef;
typedef struct _ComponentDefClass ComponentDefClass;
typedef struct _ComponentDefPrivate ComponentDefPrivate;

#define TYPE_DIRECTION (direction_get_type ())

#define TYPE_COMPONENT_INST (component_inst_get_type ())
#define COMPONENT_INST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_COMPONENT_INST, ComponentInst))
#define COMPONENT_INST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_COMPONENT_INST, ComponentInstClass))
#define IS_COMPONENT_INST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_COMPONENT_INST))
#define IS_COMPONENT_INST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_COMPONENT_INST))
#define COMPONENT_INST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_COMPONENT_INST, ComponentInstClass))

typedef struct _ComponentInst ComponentInst;
typedef struct _ComponentInstClass ComponentInstClass;

#define TYPE_PROJECT (project_get_type ())
#define PROJECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PROJECT, Project))
#define PROJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PROJECT, ProjectClass))
#define IS_PROJECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PROJECT))
#define IS_PROJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PROJECT))
#define PROJECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PROJECT, ProjectClass))

typedef struct _Project Project;
typedef struct _ProjectClass ProjectClass;

#define TYPE_CUSTOM_COMPONENT_DEF (custom_component_def_get_type ())
#define CUSTOM_COMPONENT_DEF(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CUSTOM_COMPONENT_DEF, CustomComponentDef))
#define CUSTOM_COMPONENT_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CUSTOM_COMPONENT_DEF, CustomComponentDefClass))
#define IS_CUSTOM_COMPONENT_DEF(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CUSTOM_COMPONENT_DEF))
#define IS_CUSTOM_COMPONENT_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CUSTOM_COMPONENT_DEF))
#define CUSTOM_COMPONENT_DEF_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CUSTOM_COMPONENT_DEF, CustomComponentDefClass))

typedef struct _CustomComponentDef CustomComponentDef;
typedef struct _CustomComponentDefClass CustomComponentDefClass;

#define TYPE_PROPERTY_ITEM (property_item_get_type ())
#define PROPERTY_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PROPERTY_ITEM, PropertyItem))
#define PROPERTY_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PROPERTY_ITEM, PropertyItemClass))
#define IS_PROPERTY_ITEM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PROPERTY_ITEM))
#define IS_PROPERTY_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PROPERTY_ITEM))
#define PROPERTY_ITEM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PROPERTY_ITEM, PropertyItemClass))

typedef struct _PropertyItem PropertyItem;
typedef struct _PropertyItemClass PropertyItemClass;

#define TYPE_PROPERTY_SET (property_set_get_type ())
#define PROPERTY_SET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PROPERTY_SET, PropertySet))
#define PROPERTY_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PROPERTY_SET, PropertySetClass))
#define IS_PROPERTY_SET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PROPERTY_SET))
#define IS_PROPERTY_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PROPERTY_SET))
#define PROPERTY_SET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PROPERTY_SET, PropertySetClass))

typedef struct _PropertySet PropertySet;
typedef struct _PropertySetClass PropertySetClass;

#define TYPE_COMPILED_CIRCUIT (compiled_circuit_get_type ())
#define COMPILED_CIRCUIT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_COMPILED_CIRCUIT, CompiledCircuit))
#define COMPILED_CIRCUIT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_COMPILED_CIRCUIT, CompiledCircuitClass))
#define IS_COMPILED_CIRCUIT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_COMPILED_CIRCUIT))
#define IS_COMPILED_CIRCUIT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_COMPILED_CIRCUIT))
#define COMPILED_CIRCUIT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_COMPILED_CIRCUIT, CompiledCircuitClass))

typedef struct _CompiledCircuit CompiledCircuit;
typedef struct _CompiledCircuitClass CompiledCircuitClass;

#define TYPE_CONNECTION (connection_get_type ())
#define CONNECTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CONNECTION, Connection))
#define CONNECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CONNECTION, ConnectionClass))
#define IS_CONNECTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CONNECTION))
#define IS_CONNECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CONNECTION))
#define CONNECTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CONNECTION, ConnectionClass))

typedef struct _Connection Connection;
typedef struct _ConnectionClass ConnectionClass;

#define TYPE_CIRCUIT_INFORMATION (circuit_information_get_type ())
#define CIRCUIT_INFORMATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CIRCUIT_INFORMATION, CircuitInformation))
#define CIRCUIT_INFORMATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CIRCUIT_INFORMATION, CircuitInformationClass))
#define IS_CIRCUIT_INFORMATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CIRCUIT_INFORMATION))
#define IS_CIRCUIT_INFORMATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CIRCUIT_INFORMATION))
#define CIRCUIT_INFORMATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CIRCUIT_INFORMATION, CircuitInformationClass))

typedef struct _CircuitInformation CircuitInformation;
typedef struct _CircuitInformationClass CircuitInformationClass;

#define TYPE_GRAPHIC (graphic_get_type ())
#define GRAPHIC(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_GRAPHIC, Graphic))
#define GRAPHIC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_GRAPHIC, GraphicClass))
#define IS_GRAPHIC(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_GRAPHIC))
#define IS_GRAPHIC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_GRAPHIC))
#define GRAPHIC_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_GRAPHIC, GraphicClass))

typedef struct _Graphic Graphic;
typedef struct _GraphicClass GraphicClass;

#define TYPE_PIN_DEF (pin_def_get_type ())
#define PIN_DEF(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PIN_DEF, PinDef))
#define PIN_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PIN_DEF, PinDefClass))
#define IS_PIN_DEF(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PIN_DEF))
#define IS_PIN_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PIN_DEF))
#define PIN_DEF_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PIN_DEF, PinDefClass))

typedef struct _PinDef PinDef;
typedef struct _PinDefClass PinDefClass;

#define TYPE_BASIC_SS_DISPLAY_COMPONENT_DEF (basic_ss_display_component_def_get_type ())
#define BASIC_SS_DISPLAY_COMPONENT_DEF(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BASIC_SS_DISPLAY_COMPONENT_DEF, BasicSsDisplayComponentDef))
#define BASIC_SS_DISPLAY_COMPONENT_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BASIC_SS_DISPLAY_COMPONENT_DEF, BasicSsDisplayComponentDefClass))
#define IS_BASIC_SS_DISPLAY_COMPONENT_DEF(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BASIC_SS_DISPLAY_COMPONENT_DEF))
#define IS_BASIC_SS_DISPLAY_COMPONENT_DEF_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BASIC_SS_DISPLAY_COMPONENT_DEF))
#define BASIC_SS_DISPLAY_COMPONENT_DEF_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BASIC_SS_DISPLAY_COMPONENT_DEF, BasicSsDisplayComponentDefClass))

typedef struct _BasicSsDisplayComponentDef BasicSsDisplayComponentDef;
typedef struct _BasicSsDisplayComponentDefClass BasicSsDisplayComponentDefClass;
typedef struct _BasicSsDisplayComponentDefPrivate BasicSsDisplayComponentDefPrivate;
#define _component_def_unref0(var) ((var == NULL) ? NULL : (var = (component_def_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))

#define TYPE_PROPERTY_ITEM_SELECTION (property_item_selection_get_type ())
#define PROPERTY_ITEM_SELECTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PROPERTY_ITEM_SELECTION, PropertyItemSelection))
#define PROPERTY_ITEM_SELECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PROPERTY_ITEM_SELECTION, PropertyItemSelectionClass))
#define IS_PROPERTY_ITEM_SELECTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PROPERTY_ITEM_SELECTION))
#define IS_PROPERTY_ITEM_SELECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PROPERTY_ITEM_SELECTION))
#define PROPERTY_ITEM_SELECTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PROPERTY_ITEM_SELECTION, PropertyItemSelectionClass))

typedef struct _PropertyItemSelection PropertyItemSelection;
typedef struct _PropertyItemSelectionClass PropertyItemSelectionClass;
#define _property_item_unref0(var) ((var == NULL) ? NULL : (var = (property_item_unref (var), NULL)))

#define TYPE_WIRE_INST (wire_inst_get_type ())
#define WIRE_INST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_WIRE_INST, WireInst))
#define WIRE_INST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_WIRE_INST, WireInstClass))
#define IS_WIRE_INST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_WIRE_INST))
#define IS_WIRE_INST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_WIRE_INST))
#define WIRE_INST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_WIRE_INST, WireInstClass))

typedef struct _WireInst WireInst;
typedef struct _WireInstClass WireInstClass;
typedef struct _ComponentInstPrivate ComponentInstPrivate;

#define TYPE_PIN_INST (pin_inst_get_type ())
#define PIN_INST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PIN_INST, PinInst))
#define PIN_INST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PIN_INST, PinInstClass))
#define IS_PIN_INST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PIN_INST))
#define IS_PIN_INST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PIN_INST))
#define PIN_INST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PIN_INST, PinInstClass))

typedef struct _PinInst PinInst;
typedef struct _PinInstClass PinInstClass;
typedef struct _PinInstPrivate PinInstPrivate;
#define _connection_unref0(var) ((var == NULL) ? NULL : (var = (connection_unref (var), NULL)))

#define TYPE_COMPONENT_STATE (component_state_get_type ())
#define COMPONENT_STATE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_COMPONENT_STATE, ComponentState))
#define COMPONENT_STATE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_COMPONENT_STATE, ComponentStateClass))
#define IS_COMPONENT_STATE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_COMPONENT_STATE))
#define IS_COMPONENT_STATE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_COMPONENT_STATE))
#define COMPONENT_STATE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_COMPONENT_STATE, ComponentStateClass))

typedef struct _ComponentState ComponentState;
typedef struct _ComponentStateClass ComponentStateClass;

#define TYPE_BASIC_SS_DISPLAY_COMPONENT_STATE (basic_ss_display_component_state_get_type ())
#define BASIC_SS_DISPLAY_COMPONENT_STATE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BASIC_SS_DISPLAY_COMPONENT_STATE, BasicSsDisplayComponentState))
#define BASIC_SS_DISPLAY_COMPONENT_STATE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BASIC_SS_DISPLAY_COMPONENT_STATE, BasicSsDisplayComponentStateClass))
#define IS_BASIC_SS_DISPLAY_COMPONENT_STATE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BASIC_SS_DISPLAY_COMPONENT_STATE))
#define IS_BASIC_SS_DISPLAY_COMPONENT_STATE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BASIC_SS_DISPLAY_COMPONENT_STATE))
#define BASIC_SS_DISPLAY_COMPONENT_STATE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BASIC_SS_DISPLAY_COMPONENT_STATE, BasicSsDisplayComponentStateClass))

typedef struct _BasicSsDisplayComponentState BasicSsDisplayComponentState;
typedef struct _BasicSsDisplayComponentStateClass BasicSsDisplayComponentStateClass;
#define _component_state_unref0(var) ((var == NULL) ? NULL : (var = (component_state_unref (var), NULL)))

typedef enum  {
	DIRECTION_NONE,
	DIRECTION_RIGHT,
	DIRECTION_DOWN,
	DIRECTION_LEFT,
	DIRECTION_UP,
	DIRECTION_HORIZONTAL,
	DIRECTION_VERTICAL,
	DIRECTION_DIAGONAL
} Direction;

struct _ComponentDef {
	GTypeInstance parent_instance;
	volatile int ref_count;
	ComponentDefPrivate * priv;
	Graphic* graphic;
	gchar* graphicReferenceFilename;
	gchar* name;
	gchar* description;
	gchar* iconFilename;
	gchar* label;
	PinDef** pinDefs;
	gint pinDefs_length1;
	gint rightBound;
	gint downBound;
	gint leftBound;
	gint upBound;
	gint backgroundAlpha;
	gint backgroundRed;
	gint backgroundGreen;
	gint backgroundBlue;
	gdouble backgroundAlphaF;
	gdouble backgroundRedF;
	gdouble backgroundGreenF;
	gdouble backgroundBlueF;
	gboolean drawBox;
	gchar* filename;
};

struct _ComponentDefClass {
	GTypeClass parent_class;
	void (*finalize) (ComponentDef *self);
	void (*extra_render) (ComponentDef* self, cairo_t* context, Direction direction, gboolean flipped, ComponentInst* componentInst);
	void (*extra_validate) (ComponentDef* self, Project* project, CustomComponentDef** componentChain, int componentChain_length1, ComponentInst* componentInst);
	void (*add_properties) (ComponentDef* self, PropertySet* queryProperty, PropertySet* configurationProperty);
	void (*get_properties) (ComponentDef* self, PropertySet* queryProperty, PropertySet** configurationProperty);
	void (*load_properties) (ComponentDef* self, xmlNode* xmlnode, PropertySet** configurationProperty);
	void (*save_properties) (ComponentDef* self, xmlTextWriter* xmlWriter, PropertySet* configurationProperty);
	void (*configure_inst) (ComponentDef* self, ComponentInst* componentInst, gboolean firstLoad);
	void (*compile_component) (ComponentDef* self, CompiledCircuit* compiledCircuit, ComponentInst* componentInst, Connection** connections, int connections_length1, ComponentInst** ancestry, int ancestry_length1);
	void (*create_information) (ComponentDef* self, CircuitInformation* circuitInformation);
};

struct _BasicSsDisplayComponentDef {
	ComponentDef parent_instance;
	BasicSsDisplayComponentDefPrivate * priv;
};

struct _BasicSsDisplayComponentDefClass {
	ComponentDefClass parent_class;
};

typedef enum  {
	COMPONENT_DEF_LOAD_ERROR_NOT_COMPONENT,
	COMPONENT_DEF_LOAD_ERROR_FILE,
	COMPONENT_DEF_LOAD_ERROR_LOAD,
	COMPONENT_DEF_LOAD_ERROR_CANCEL
} ComponentDefLoadError;
#define COMPONENT_DEF_LOAD_ERROR component_def_load_error_quark ()
typedef enum  {
	CUSTOM_COMPONENT_DEF_LOAD_ERROR_NOT_CUSTOM,
	CUSTOM_COMPONENT_DEF_LOAD_ERROR_MISSING_DEPENDENCY,
	CUSTOM_COMPONENT_DEF_LOAD_ERROR_NAME_CONFLICT,
	CUSTOM_COMPONENT_DEF_LOAD_ERROR_INVALID
} CustomComponentDefLoadError;
#define CUSTOM_COMPONENT_DEF_LOAD_ERROR custom_component_def_load_error_quark ()
typedef enum  {
	PLUGIN_COMPONENT_DEF_LOAD_ERROR_NOT_PLUGIN,
	PLUGIN_COMPONENT_DEF_LOAD_ERROR_INIT_ERROR,
	PLUGIN_COMPONENT_DEF_LOAD_ERROR_LIBRARY_NOT_ACCESSIBLE,
	PLUGIN_COMPONENT_DEF_LOAD_ERROR_LIBRARY_NOT_COMPATIBLE,
	PLUGIN_COMPONENT_DEF_LOAD_ERROR_NAME_CONFLICT,
	PLUGIN_COMPONENT_DEF_LOAD_ERROR_INVALID
} PluginComponentDefLoadError;
#define PLUGIN_COMPONENT_DEF_LOAD_ERROR plugin_component_def_load_error_quark ()
typedef enum  {
	PROPERTY_ITEM_ERROR_ITEM_NOT_FOUND
} PropertyItemError;
#define PROPERTY_ITEM_ERROR property_item_error_quark ()
struct _ComponentInst {
	GTypeInstance parent_instance;
	volatile int ref_count;
	ComponentInstPrivate * priv;
	ComponentDef* componentDef;
	gint myID;
	gint xPosition;
	gint yPosition;
	Direction direction;
	gboolean flipped;
	gint rightBound;
	gint downBound;
	gint leftBound;
	gint upBound;
	PropertySet* configuration;
	gboolean selected;
	gboolean errorMark;
	PinInst** pinInsts;
	gint pinInsts_length1;
};

struct _ComponentInstClass {
	GTypeClass parent_class;
	void (*finalize) (ComponentInst *self);
};

struct _PinInst {
	GTypeInstance parent_instance;
	volatile int ref_count;
	PinInstPrivate * priv;
	gint* x;
	gint x_length1;
	gint* y;
	gint y_length1;
	gint* xConnect;
	gint xConnect_length1;
	gint* yConnect;
	gint yConnect_length1;
	gint xLabel;
	gint yLabel;
	WireInst** wireInsts;
	gint wireInsts_length1;
	gboolean* invert;
	gint invert_length1;
	PinDef* pinDef;
	gint arraySize;
	gint xMin;
	gint xMax;
	gint yMin;
	gint yMax;
	gboolean show;
};

struct _PinInstClass {
	GTypeClass parent_class;
	void (*finalize) (PinInst *self);
};


static gpointer basic_ss_display_component_def_parent_class = NULL;

gpointer component_def_ref (gpointer instance);
void component_def_unref (gpointer instance);
GParamSpec* param_spec_component_def (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_component_def (GValue* value, gpointer v_object);
void value_take_component_def (GValue* value, gpointer v_object);
gpointer value_get_component_def (const GValue* value);
GType component_def_get_type (void) G_GNUC_CONST;
GType direction_get_type (void) G_GNUC_CONST;
gpointer component_inst_ref (gpointer instance);
void component_inst_unref (gpointer instance);
GParamSpec* param_spec_component_inst (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_component_inst (GValue* value, gpointer v_object);
void value_take_component_inst (GValue* value, gpointer v_object);
gpointer value_get_component_inst (const GValue* value);
GType component_inst_get_type (void) G_GNUC_CONST;
gpointer project_ref (gpointer instance);
void project_unref (gpointer instance);
GParamSpec* param_spec_project (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_project (GValue* value, gpointer v_object);
void value_take_project (GValue* value, gpointer v_object);
gpointer value_get_project (const GValue* value);
GType project_get_type (void) G_GNUC_CONST;
GType custom_component_def_get_type (void) G_GNUC_CONST;
gpointer property_item_ref (gpointer instance);
void property_item_unref (gpointer instance);
GParamSpec* param_spec_property_item (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_property_item (GValue* value, gpointer v_object);
void value_take_property_item (GValue* value, gpointer v_object);
gpointer value_get_property_item (const GValue* value);
GType property_item_get_type (void) G_GNUC_CONST;
GType property_set_get_type (void) G_GNUC_CONST;
gpointer compiled_circuit_ref (gpointer instance);
void compiled_circuit_unref (gpointer instance);
GParamSpec* param_spec_compiled_circuit (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_compiled_circuit (GValue* value, gpointer v_object);
void value_take_compiled_circuit (GValue* value, gpointer v_object);
gpointer value_get_compiled_circuit (const GValue* value);
GType compiled_circuit_get_type (void) G_GNUC_CONST;
gpointer connection_ref (gpointer instance);
void connection_unref (gpointer instance);
GParamSpec* param_spec_connection (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_connection (GValue* value, gpointer v_object);
void value_take_connection (GValue* value, gpointer v_object);
gpointer value_get_connection (const GValue* value);
GType connection_get_type (void) G_GNUC_CONST;
gpointer circuit_information_ref (gpointer instance);
void circuit_information_unref (gpointer instance);
GParamSpec* param_spec_circuit_information (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_circuit_information (GValue* value, gpointer v_object);
void value_take_circuit_information (GValue* value, gpointer v_object);
gpointer value_get_circuit_information (const GValue* value);
GType circuit_information_get_type (void) G_GNUC_CONST;
gpointer graphic_ref (gpointer instance);
void graphic_unref (gpointer instance);
GParamSpec* param_spec_graphic (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_graphic (GValue* value, gpointer v_object);
void value_take_graphic (GValue* value, gpointer v_object);
gpointer value_get_graphic (const GValue* value);
GType graphic_get_type (void) G_GNUC_CONST;
gpointer pin_def_ref (gpointer instance);
void pin_def_unref (gpointer instance);
GParamSpec* param_spec_pin_def (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_pin_def (GValue* value, gpointer v_object);
void value_take_pin_def (GValue* value, gpointer v_object);
gpointer value_get_pin_def (const GValue* value);
GType pin_def_get_type (void) G_GNUC_CONST;
GType basic_ss_display_component_def_get_type (void) G_GNUC_CONST;
enum  {
	BASIC_SS_DISPLAY_COMPONENT_DEF_DUMMY_PROPERTY
};
#define BASIC_SS_DISPLAY_COMPONENT_DEF_infoFilename PACKAGE_DATADIR "components/info/basic-ss-display.xml"
GQuark component_def_load_error_quark (void);
BasicSsDisplayComponentDef* basic_ss_display_component_def_new (GError** error);
BasicSsDisplayComponentDef* basic_ss_display_component_def_construct (GType object_type, GError** error);
ComponentDef* component_def_construct (GType object_type);
GQuark custom_component_def_load_error_quark (void);
GQuark plugin_component_def_load_error_quark (void);
void component_def_load_from_file (ComponentDef* self, const gchar* infoFilename, GError** error);
static void basic_ss_display_component_def_real_add_properties (ComponentDef* base, PropertySet* queryProperty, PropertySet* configurationProperty);
GQuark property_item_error_quark (void);
gchar* property_item_selection_get_data_throw (PropertySet* propertySet, const gchar* name, GError** error);
GType property_item_selection_get_type (void) G_GNUC_CONST;
PropertyItemSelection* property_item_selection_new (const gchar* name, const gchar* description);
PropertyItemSelection* property_item_selection_construct (GType object_type, const gchar* name, const gchar* description);
void property_item_selection_add_option (PropertyItemSelection* self, const gchar* value, const gchar* text);
gint property_item_selection_set_option (PropertyItemSelection* self, const gchar* value);
gint property_set_add_item (PropertySet* self, PropertyItem* propertyItem);
static void basic_ss_display_component_def_real_get_properties (ComponentDef* base, PropertySet* queryProperty, PropertySet** configurationProperty);
PropertySet* property_set_new (const gchar* name, const gchar* description);
PropertySet* property_set_construct (GType object_type, const gchar* name, const gchar* description);
static void basic_ss_display_component_def_real_load_properties (ComponentDef* base, xmlNode* xmlnode, PropertySet** configurationProperty);
static void basic_ss_display_component_def_real_save_properties (ComponentDef* base, xmlTextWriter* xmlWriter, PropertySet* configurationProperty);
static void basic_ss_display_component_def_real_compile_component (ComponentDef* base, CompiledCircuit* compiledCircuit, ComponentInst* componentInst, Connection** connections, int connections_length1, ComponentInst** ancestry, int ancestry_length1);
Connection* connection_new_fake (void);
Connection* connection_construct_fake (GType object_type);
gpointer wire_inst_ref (gpointer instance);
void wire_inst_unref (gpointer instance);
GParamSpec* param_spec_wire_inst (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_wire_inst (GValue* value, gpointer v_object);
void value_take_wire_inst (GValue* value, gpointer v_object);
gpointer value_get_wire_inst (const GValue* value);
GType wire_inst_get_type (void) G_GNUC_CONST;
WireInst* connection_get_wireInst (Connection* self);
gpointer pin_inst_ref (gpointer instance);
void pin_inst_unref (gpointer instance);
GParamSpec* param_spec_pin_inst (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_pin_inst (GValue* value, gpointer v_object);
void value_take_pin_inst (GValue* value, gpointer v_object);
gpointer value_get_pin_inst (const GValue* value);
GType pin_inst_get_type (void) G_GNUC_CONST;
gpointer component_state_ref (gpointer instance);
void component_state_unref (gpointer instance);
GParamSpec* param_spec_component_state (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_component_state (GValue* value, gpointer v_object);
void value_take_component_state (GValue* value, gpointer v_object);
gpointer value_get_component_state (const GValue* value);
GType component_state_get_type (void) G_GNUC_CONST;
BasicSsDisplayComponentState* basic_ss_display_component_state_new (Connection* input1Wire, Connection* input2Wire, Connection* input4Wire, Connection* input8Wire, Connection* inputPWire, gboolean displayPoint, ComponentInst** ancestry, int ancestry_length1, ComponentInst* componentInst);
BasicSsDisplayComponentState* basic_ss_display_component_state_construct (GType object_type, Connection* input1Wire, Connection* input2Wire, Connection* input4Wire, Connection* input8Wire, Connection* inputPWire, gboolean displayPoint, ComponentInst** ancestry, int ancestry_length1, ComponentInst* componentInst);
GType basic_ss_display_component_state_get_type (void) G_GNUC_CONST;
void compiled_circuit_add_component (CompiledCircuit* self, ComponentState* componentState);
static void basic_ss_display_component_def_real_configure_inst (ComponentDef* base, ComponentInst* componentInst, gboolean firstLoad);
gboolean pin_inst_disconnect (PinInst* self, ComponentInst* componentInst);
static void basic_ss_display_component_def_real_extra_render (ComponentDef* base, cairo_t* context, Direction direction, gboolean flipped, ComponentInst* componentInst);


BasicSsDisplayComponentDef* basic_ss_display_component_def_construct (GType object_type, GError** error) {
	BasicSsDisplayComponentDef* self = NULL;
	GError * _inner_error_ = NULL;
	self = (BasicSsDisplayComponentDef*) component_def_construct (object_type);
	{
		component_def_load_from_file ((ComponentDef*) self, BASIC_SS_DISPLAY_COMPONENT_DEF_infoFilename, &_inner_error_);
		if (_inner_error_ != NULL) {
			goto __catch6_g_error;
		}
	}
	goto __finally6;
	__catch6_g_error:
	{
		FILE* _tmp0_ = NULL;
		GError* _tmp1_ = NULL;
		g_clear_error (&_inner_error_);
		_inner_error_ = NULL;
		_tmp0_ = stdout;
		fprintf (_tmp0_, "Failed to load built in component \"%s\"\n", BASIC_SS_DISPLAY_COMPONENT_DEF_infoFilename);
		_tmp1_ = g_error_new_literal (COMPONENT_DEF_LOAD_ERROR, COMPONENT_DEF_LOAD_ERROR_LOAD, "Failed to load \"" BASIC_SS_DISPLAY_COMPONENT_DEF_infoFilename "\"\n");
		_inner_error_ = _tmp1_;
		goto __finally6;
	}
	__finally6:
	if (_inner_error_ != NULL) {
		if (_inner_error_->domain == COMPONENT_DEF_LOAD_ERROR) {
			g_propagate_error (error, _inner_error_);
			_component_def_unref0 (self);
			return NULL;
		} else {
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
			g_clear_error (&_inner_error_);
			return NULL;
		}
	}
	return self;
}


BasicSsDisplayComponentDef* basic_ss_display_component_def_new (GError** error) {
	return basic_ss_display_component_def_construct (TYPE_BASIC_SS_DISPLAY_COMPONENT_DEF, error);
}


static void basic_ss_display_component_def_real_add_properties (ComponentDef* base, PropertySet* queryProperty, PropertySet* configurationProperty) {
	BasicSsDisplayComponentDef * self;
	gchar* typeString = NULL;
	PropertyItemSelection* selection = NULL;
	PropertyItemSelection* _tmp5_ = NULL;
	const gchar* _tmp6_ = NULL;
	PropertySet* _tmp7_ = NULL;
	GError * _inner_error_ = NULL;
	self = (BasicSsDisplayComponentDef*) base;
	g_return_if_fail (queryProperty != NULL);
	g_return_if_fail (configurationProperty != NULL);
	{
		gchar* _tmp0_ = NULL;
		PropertySet* _tmp1_ = NULL;
		gchar* _tmp2_ = NULL;
		gchar* _tmp3_ = NULL;
		_tmp1_ = configurationProperty;
		_tmp2_ = property_item_selection_get_data_throw (_tmp1_, "Type", &_inner_error_);
		_tmp0_ = _tmp2_;
		if (_inner_error_ != NULL) {
			goto __catch7_g_error;
		}
		_tmp3_ = _tmp0_;
		_tmp0_ = NULL;
		_g_free0 (typeString);
		typeString = _tmp3_;
		_g_free0 (_tmp0_);
	}
	goto __finally7;
	__catch7_g_error:
	{
		gchar* _tmp4_ = NULL;
		g_clear_error (&_inner_error_);
		_inner_error_ = NULL;
		_tmp4_ = g_strdup ("Hexadecimal");
		_g_free0 (typeString);
		typeString = _tmp4_;
	}
	__finally7:
	if (_inner_error_ != NULL) {
		_g_free0 (typeString);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
		g_clear_error (&_inner_error_);
		return;
	}
	_tmp5_ = property_item_selection_new ("Type", "The type of seven segment display.");
	selection = _tmp5_;
	property_item_selection_add_option (selection, "Hexadecimal", NULL);
	property_item_selection_add_option (selection, "Hexadecimal with point", NULL);
	_tmp6_ = typeString;
	property_item_selection_set_option (selection, _tmp6_);
	_tmp7_ = queryProperty;
	property_set_add_item (_tmp7_, (PropertyItem*) selection);
	_property_item_unref0 (selection);
	_g_free0 (typeString);
}


static void basic_ss_display_component_def_real_get_properties (ComponentDef* base, PropertySet* queryProperty, PropertySet** configurationProperty) {
	BasicSsDisplayComponentDef * self;
	PropertySet* _vala_configurationProperty = NULL;
	gchar* typeString = NULL;
	const gchar* _tmp5_ = NULL;
	gchar* _tmp6_ = NULL;
	gchar* _tmp7_ = NULL;
	PropertySet* _tmp8_ = NULL;
	PropertyItemSelection* selection = NULL;
	PropertyItemSelection* _tmp9_ = NULL;
	const gchar* _tmp10_ = NULL;
	GError * _inner_error_ = NULL;
	self = (BasicSsDisplayComponentDef*) base;
	g_return_if_fail (queryProperty != NULL);
	{
		gchar* _tmp0_ = NULL;
		PropertySet* _tmp1_ = NULL;
		gchar* _tmp2_ = NULL;
		gchar* _tmp3_ = NULL;
		_tmp1_ = queryProperty;
		_tmp2_ = property_item_selection_get_data_throw (_tmp1_, "Type", &_inner_error_);
		_tmp0_ = _tmp2_;
		if (_inner_error_ != NULL) {
			goto __catch8_g_error;
		}
		_tmp3_ = _tmp0_;
		_tmp0_ = NULL;
		_g_free0 (typeString);
		typeString = _tmp3_;
		_g_free0 (_tmp0_);
	}
	goto __finally8;
	__catch8_g_error:
	{
		gchar* _tmp4_ = NULL;
		g_clear_error (&_inner_error_);
		_inner_error_ = NULL;
		_tmp4_ = g_strdup ("Hexadecimal");
		_g_free0 (typeString);
		typeString = _tmp4_;
	}
	__finally8:
	if (_inner_error_ != NULL) {
		_g_free0 (typeString);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
		g_clear_error (&_inner_error_);
		return;
	}
	_tmp5_ = ((ComponentDef*) self)->name;
	_tmp6_ = g_strconcat (_tmp5_, " configuration", NULL);
	_tmp7_ = _tmp6_;
	_tmp8_ = property_set_new (_tmp7_, "");
	_property_item_unref0 (_vala_configurationProperty);
	_vala_configurationProperty = _tmp8_;
	_g_free0 (_tmp7_);
	_tmp9_ = property_item_selection_new ("Type", "");
	selection = _tmp9_;
	property_item_selection_add_option (selection, "Hexadecimal", NULL);
	property_item_selection_add_option (selection, "Hexadecimal with point", NULL);
	_tmp10_ = typeString;
	property_item_selection_set_option (selection, _tmp10_);
	property_set_add_item (_vala_configurationProperty, (PropertyItem*) selection);
	_property_item_unref0 (selection);
	_g_free0 (typeString);
	if (configurationProperty) {
		*configurationProperty = _vala_configurationProperty;
	} else {
		_property_item_unref0 (_vala_configurationProperty);
	}
}


static void basic_ss_display_component_def_real_load_properties (ComponentDef* base, xmlNode* xmlnode, PropertySet** configurationProperty) {
	BasicSsDisplayComponentDef * self;
	PropertySet* _vala_configurationProperty = NULL;
	gchar* typeString = NULL;
	gchar* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	gchar* _tmp2_ = NULL;
	gchar* _tmp3_ = NULL;
	PropertySet* _tmp4_ = NULL;
	PropertyItemSelection* selection = NULL;
	PropertyItemSelection* _tmp20_ = NULL;
	const gchar* _tmp21_ = NULL;
	PropertySet* _tmp22_ = NULL;
	self = (BasicSsDisplayComponentDef*) base;
	_tmp0_ = g_strdup ("Hexadecimal");
	typeString = _tmp0_;
	_tmp1_ = ((ComponentDef*) self)->name;
	_tmp2_ = g_strconcat (_tmp1_, " configuration", NULL);
	_tmp3_ = _tmp2_;
	_tmp4_ = property_set_new (_tmp3_, "");
	_property_item_unref0 (_vala_configurationProperty);
	_vala_configurationProperty = _tmp4_;
	_g_free0 (_tmp3_);
	{
		xmlAttr* xmlattr = NULL;
		xmlNode* _tmp5_ = NULL;
		xmlAttr* _tmp6_ = NULL;
		_tmp5_ = xmlnode;
		_tmp6_ = _tmp5_->properties;
		xmlattr = _tmp6_;
		{
			gboolean _tmp7_ = FALSE;
			_tmp7_ = TRUE;
			while (TRUE) {
				xmlAttr* _tmp10_ = NULL;
				xmlAttr* _tmp11_ = NULL;
				const gchar* _tmp12_ = NULL;
				const gchar* _tmp13_ = NULL;
				GQuark _tmp15_ = 0U;
				static GQuark _tmp14_label0 = 0;
				if (!_tmp7_) {
					xmlAttr* _tmp8_ = NULL;
					xmlAttr* _tmp9_ = NULL;
					_tmp8_ = xmlattr;
					_tmp9_ = _tmp8_->next;
					xmlattr = _tmp9_;
				}
				_tmp7_ = FALSE;
				_tmp10_ = xmlattr;
				if (!(_tmp10_ != NULL)) {
					break;
				}
				_tmp11_ = xmlattr;
				_tmp12_ = _tmp11_->name;
				_tmp13_ = _tmp12_;
				_tmp15_ = (NULL == _tmp13_) ? 0 : g_quark_from_string (_tmp13_);
				if (_tmp15_ == ((0 != _tmp14_label0) ? _tmp14_label0 : (_tmp14_label0 = g_quark_from_static_string ("type")))) {
					switch (0) {
						default:
						{
							xmlAttr* _tmp16_ = NULL;
							xmlNode* _tmp17_ = NULL;
							const gchar* _tmp18_ = NULL;
							gchar* _tmp19_ = NULL;
							_tmp16_ = xmlattr;
							_tmp17_ = _tmp16_->children;
							_tmp18_ = _tmp17_->content;
							_tmp19_ = g_strdup (_tmp18_);
							_g_free0 (typeString);
							typeString = _tmp19_;
							break;
						}
					}
				}
			}
		}
	}
	_tmp20_ = property_item_selection_new ("Type", "");
	selection = _tmp20_;
	property_item_selection_add_option (selection, "Hexadecimal", NULL);
	property_item_selection_add_option (selection, "Hexadecimal with point", NULL);
	_tmp21_ = typeString;
	property_item_selection_set_option (selection, _tmp21_);
	_tmp22_ = _vala_configurationProperty;
	property_set_add_item (_tmp22_, (PropertyItem*) selection);
	_property_item_unref0 (selection);
	_g_free0 (typeString);
	if (configurationProperty) {
		*configurationProperty = _vala_configurationProperty;
	} else {
		_property_item_unref0 (_vala_configurationProperty);
	}
}


static void basic_ss_display_component_def_real_save_properties (ComponentDef* base, xmlTextWriter* xmlWriter, PropertySet* configurationProperty) {
	BasicSsDisplayComponentDef * self;
	gchar* typeString = NULL;
	xmlTextWriter* _tmp5_ = NULL;
	const gchar* _tmp6_ = NULL;
	GError * _inner_error_ = NULL;
	self = (BasicSsDisplayComponentDef*) base;
	g_return_if_fail (xmlWriter != NULL);
	g_return_if_fail (configurationProperty != NULL);
	{
		gchar* _tmp0_ = NULL;
		PropertySet* _tmp1_ = NULL;
		gchar* _tmp2_ = NULL;
		gchar* _tmp3_ = NULL;
		_tmp1_ = configurationProperty;
		_tmp2_ = property_item_selection_get_data_throw (_tmp1_, "Type", &_inner_error_);
		_tmp0_ = _tmp2_;
		if (_inner_error_ != NULL) {
			goto __catch9_g_error;
		}
		_tmp3_ = _tmp0_;
		_tmp0_ = NULL;
		_g_free0 (typeString);
		typeString = _tmp3_;
		_g_free0 (_tmp0_);
	}
	goto __finally9;
	__catch9_g_error:
	{
		gchar* _tmp4_ = NULL;
		g_clear_error (&_inner_error_);
		_inner_error_ = NULL;
		_tmp4_ = g_strdup ("Hexadecimal");
		_g_free0 (typeString);
		typeString = _tmp4_;
	}
	__finally9:
	if (_inner_error_ != NULL) {
		_g_free0 (typeString);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
		g_clear_error (&_inner_error_);
		return;
	}
	_tmp5_ = xmlWriter;
	_tmp6_ = typeString;
	xmlTextWriterWriteAttribute (_tmp5_, (xmlChar*) "type", (xmlChar*) _tmp6_);
	_g_free0 (typeString);
}


static gpointer _connection_ref0 (gpointer self) {
	return self ? connection_ref (self) : NULL;
}


static void basic_ss_display_component_def_real_compile_component (ComponentDef* base, CompiledCircuit* compiledCircuit, ComponentInst* componentInst, Connection** connections, int connections_length1, ComponentInst** ancestry, int ancestry_length1) {
	BasicSsDisplayComponentDef * self;
	gchar* typeString = NULL;
	gchar* _tmp0_ = NULL;
	gboolean displayPoint = FALSE;
	Connection* input1Wire = NULL;
	Connection* _tmp1_ = NULL;
	Connection* input2Wire = NULL;
	Connection* _tmp2_ = NULL;
	Connection* input4Wire = NULL;
	Connection* _tmp3_ = NULL;
	Connection* input8Wire = NULL;
	Connection* _tmp4_ = NULL;
	Connection* inputPWire = NULL;
	Connection* _tmp5_ = NULL;
	Connection** _tmp6_ = NULL;
	gint _tmp6__length1 = 0;
	const gchar* _tmp64_ = NULL;
	const gchar* _tmp65_ = NULL;
	GQuark _tmp67_ = 0U;
	static GQuark _tmp66_label0 = 0;
	static GQuark _tmp66_label1 = 0;
	ComponentState* componentState = NULL;
	Connection* _tmp68_ = NULL;
	Connection* _tmp69_ = NULL;
	Connection* _tmp70_ = NULL;
	Connection* _tmp71_ = NULL;
	Connection* _tmp72_ = NULL;
	gboolean _tmp73_ = FALSE;
	ComponentInst** _tmp74_ = NULL;
	gint _tmp74__length1 = 0;
	ComponentInst* _tmp75_ = NULL;
	BasicSsDisplayComponentState* _tmp76_ = NULL;
	CompiledCircuit* _tmp77_ = NULL;
	GError * _inner_error_ = NULL;
	self = (BasicSsDisplayComponentDef*) base;
	g_return_if_fail (compiledCircuit != NULL);
	_tmp0_ = g_strdup ("Hexadecimal");
	typeString = _tmp0_;
	displayPoint = FALSE;
	_tmp1_ = connection_new_fake ();
	input1Wire = _tmp1_;
	_tmp2_ = connection_new_fake ();
	input2Wire = _tmp2_;
	_tmp3_ = connection_new_fake ();
	input4Wire = _tmp3_;
	_tmp4_ = connection_new_fake ();
	input8Wire = _tmp4_;
	_tmp5_ = connection_new_fake ();
	inputPWire = _tmp5_;
	_tmp6_ = connections;
	_tmp6__length1 = connections_length1;
	{
		Connection** connection_collection = NULL;
		gint connection_collection_length1 = 0;
		gint _connection_collection_size_ = 0;
		gint connection_it = 0;
		connection_collection = _tmp6_;
		connection_collection_length1 = _tmp6__length1;
		for (connection_it = 0; connection_it < _tmp6__length1; connection_it = connection_it + 1) {
			Connection* _tmp7_ = NULL;
			Connection* connection = NULL;
			_tmp7_ = _connection_ref0 (connection_collection[connection_it]);
			connection = _tmp7_;
			{
				Connection* _tmp8_ = NULL;
				WireInst* _tmp9_ = NULL;
				WireInst* _tmp10_ = NULL;
				ComponentInst* _tmp11_ = NULL;
				PinInst** _tmp12_ = NULL;
				gint _tmp12__length1 = 0;
				PinInst* _tmp13_ = NULL;
				WireInst** _tmp14_ = NULL;
				gint _tmp14__length1 = 0;
				WireInst* _tmp15_ = NULL;
				Connection* _tmp18_ = NULL;
				WireInst* _tmp19_ = NULL;
				WireInst* _tmp20_ = NULL;
				ComponentInst* _tmp21_ = NULL;
				PinInst** _tmp22_ = NULL;
				gint _tmp22__length1 = 0;
				PinInst* _tmp23_ = NULL;
				WireInst** _tmp24_ = NULL;
				gint _tmp24__length1 = 0;
				WireInst* _tmp25_ = NULL;
				Connection* _tmp28_ = NULL;
				WireInst* _tmp29_ = NULL;
				WireInst* _tmp30_ = NULL;
				ComponentInst* _tmp31_ = NULL;
				PinInst** _tmp32_ = NULL;
				gint _tmp32__length1 = 0;
				PinInst* _tmp33_ = NULL;
				WireInst** _tmp34_ = NULL;
				gint _tmp34__length1 = 0;
				WireInst* _tmp35_ = NULL;
				Connection* _tmp38_ = NULL;
				WireInst* _tmp39_ = NULL;
				WireInst* _tmp40_ = NULL;
				ComponentInst* _tmp41_ = NULL;
				PinInst** _tmp42_ = NULL;
				gint _tmp42__length1 = 0;
				PinInst* _tmp43_ = NULL;
				WireInst** _tmp44_ = NULL;
				gint _tmp44__length1 = 0;
				WireInst* _tmp45_ = NULL;
				Connection* _tmp48_ = NULL;
				WireInst* _tmp49_ = NULL;
				WireInst* _tmp50_ = NULL;
				ComponentInst* _tmp51_ = NULL;
				PinInst** _tmp52_ = NULL;
				gint _tmp52__length1 = 0;
				PinInst* _tmp53_ = NULL;
				WireInst** _tmp54_ = NULL;
				gint _tmp54__length1 = 0;
				WireInst* _tmp55_ = NULL;
				_tmp8_ = connection;
				_tmp9_ = connection_get_wireInst (_tmp8_);
				_tmp10_ = _tmp9_;
				_tmp11_ = componentInst;
				_tmp12_ = _tmp11_->pinInsts;
				_tmp12__length1 = _tmp11_->pinInsts_length1;
				_tmp13_ = _tmp12_[0];
				_tmp14_ = _tmp13_->wireInsts;
				_tmp14__length1 = _tmp13_->wireInsts_length1;
				_tmp15_ = _tmp14_[0];
				if (_tmp10_ == _tmp15_) {
					Connection* _tmp16_ = NULL;
					Connection* _tmp17_ = NULL;
					_tmp16_ = connection;
					_tmp17_ = _connection_ref0 (_tmp16_);
					_connection_unref0 (input1Wire);
					input1Wire = _tmp17_;
				}
				_tmp18_ = connection;
				_tmp19_ = connection_get_wireInst (_tmp18_);
				_tmp20_ = _tmp19_;
				_tmp21_ = componentInst;
				_tmp22_ = _tmp21_->pinInsts;
				_tmp22__length1 = _tmp21_->pinInsts_length1;
				_tmp23_ = _tmp22_[1];
				_tmp24_ = _tmp23_->wireInsts;
				_tmp24__length1 = _tmp23_->wireInsts_length1;
				_tmp25_ = _tmp24_[0];
				if (_tmp20_ == _tmp25_) {
					Connection* _tmp26_ = NULL;
					Connection* _tmp27_ = NULL;
					_tmp26_ = connection;
					_tmp27_ = _connection_ref0 (_tmp26_);
					_connection_unref0 (input2Wire);
					input2Wire = _tmp27_;
				}
				_tmp28_ = connection;
				_tmp29_ = connection_get_wireInst (_tmp28_);
				_tmp30_ = _tmp29_;
				_tmp31_ = componentInst;
				_tmp32_ = _tmp31_->pinInsts;
				_tmp32__length1 = _tmp31_->pinInsts_length1;
				_tmp33_ = _tmp32_[2];
				_tmp34_ = _tmp33_->wireInsts;
				_tmp34__length1 = _tmp33_->wireInsts_length1;
				_tmp35_ = _tmp34_[0];
				if (_tmp30_ == _tmp35_) {
					Connection* _tmp36_ = NULL;
					Connection* _tmp37_ = NULL;
					_tmp36_ = connection;
					_tmp37_ = _connection_ref0 (_tmp36_);
					_connection_unref0 (input4Wire);
					input4Wire = _tmp37_;
				}
				_tmp38_ = connection;
				_tmp39_ = connection_get_wireInst (_tmp38_);
				_tmp40_ = _tmp39_;
				_tmp41_ = componentInst;
				_tmp42_ = _tmp41_->pinInsts;
				_tmp42__length1 = _tmp41_->pinInsts_length1;
				_tmp43_ = _tmp42_[3];
				_tmp44_ = _tmp43_->wireInsts;
				_tmp44__length1 = _tmp43_->wireInsts_length1;
				_tmp45_ = _tmp44_[0];
				if (_tmp40_ == _tmp45_) {
					Connection* _tmp46_ = NULL;
					Connection* _tmp47_ = NULL;
					_tmp46_ = connection;
					_tmp47_ = _connection_ref0 (_tmp46_);
					_connection_unref0 (input8Wire);
					input8Wire = _tmp47_;
				}
				_tmp48_ = connection;
				_tmp49_ = connection_get_wireInst (_tmp48_);
				_tmp50_ = _tmp49_;
				_tmp51_ = componentInst;
				_tmp52_ = _tmp51_->pinInsts;
				_tmp52__length1 = _tmp51_->pinInsts_length1;
				_tmp53_ = _tmp52_[4];
				_tmp54_ = _tmp53_->wireInsts;
				_tmp54__length1 = _tmp53_->wireInsts_length1;
				_tmp55_ = _tmp54_[0];
				if (_tmp50_ == _tmp55_) {
					Connection* _tmp56_ = NULL;
					Connection* _tmp57_ = NULL;
					_tmp56_ = connection;
					_tmp57_ = _connection_ref0 (_tmp56_);
					_connection_unref0 (inputPWire);
					inputPWire = _tmp57_;
				}
				_connection_unref0 (connection);
			}
		}
	}
	{
		gchar* _tmp58_ = NULL;
		ComponentInst* _tmp59_ = NULL;
		PropertySet* _tmp60_ = NULL;
		gchar* _tmp61_ = NULL;
		gchar* _tmp62_ = NULL;
		_tmp59_ = componentInst;
		_tmp60_ = _tmp59_->configuration;
		_tmp61_ = property_item_selection_get_data_throw (_tmp60_, "Type", &_inner_error_);
		_tmp58_ = _tmp61_;
		if (_inner_error_ != NULL) {
			goto __catch10_g_error;
		}
		_tmp62_ = _tmp58_;
		_tmp58_ = NULL;
		_g_free0 (typeString);
		typeString = _tmp62_;
		_g_free0 (_tmp58_);
	}
	goto __finally10;
	__catch10_g_error:
	{
		gchar* _tmp63_ = NULL;
		g_clear_error (&_inner_error_);
		_inner_error_ = NULL;
		_tmp63_ = g_strdup ("Hexadecimal");
		_g_free0 (typeString);
		typeString = _tmp63_;
	}
	__finally10:
	if (_inner_error_ != NULL) {
		_connection_unref0 (inputPWire);
		_connection_unref0 (input8Wire);
		_connection_unref0 (input4Wire);
		_connection_unref0 (input2Wire);
		_connection_unref0 (input1Wire);
		_g_free0 (typeString);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
		g_clear_error (&_inner_error_);
		return;
	}
	_tmp64_ = typeString;
	_tmp65_ = _tmp64_;
	_tmp67_ = (NULL == _tmp65_) ? 0 : g_quark_from_string (_tmp65_);
	if (_tmp67_ == ((0 != _tmp66_label0) ? _tmp66_label0 : (_tmp66_label0 = g_quark_from_static_string ("Hexadecimal")))) {
		switch (0) {
			default:
			{
				displayPoint = FALSE;
				break;
			}
		}
	} else if (_tmp67_ == ((0 != _tmp66_label1) ? _tmp66_label1 : (_tmp66_label1 = g_quark_from_static_string ("Hexadecimal with point")))) {
		switch (0) {
			default:
			{
				displayPoint = TRUE;
				break;
			}
		}
	}
	_tmp68_ = input1Wire;
	_tmp69_ = input2Wire;
	_tmp70_ = input4Wire;
	_tmp71_ = input8Wire;
	_tmp72_ = inputPWire;
	_tmp73_ = displayPoint;
	_tmp74_ = ancestry;
	_tmp74__length1 = ancestry_length1;
	_tmp75_ = componentInst;
	_tmp76_ = basic_ss_display_component_state_new (_tmp68_, _tmp69_, _tmp70_, _tmp71_, _tmp72_, _tmp73_, _tmp74_, _tmp74__length1, _tmp75_);
	componentState = (ComponentState*) _tmp76_;
	_tmp77_ = compiledCircuit;
	compiled_circuit_add_component (_tmp77_, componentState);
	_component_state_unref0 (componentState);
	_connection_unref0 (inputPWire);
	_connection_unref0 (input8Wire);
	_connection_unref0 (input4Wire);
	_connection_unref0 (input2Wire);
	_connection_unref0 (input1Wire);
	_g_free0 (typeString);
}


static void basic_ss_display_component_def_real_configure_inst (ComponentDef* base, ComponentInst* componentInst, gboolean firstLoad) {
	BasicSsDisplayComponentDef * self;
	gchar* typeString = NULL;
	gchar* _tmp0_ = NULL;
	const gchar* _tmp7_ = NULL;
	const gchar* _tmp8_ = NULL;
	GQuark _tmp10_ = 0U;
	static GQuark _tmp9_label0 = 0;
	static GQuark _tmp9_label1 = 0;
	GError * _inner_error_ = NULL;
	self = (BasicSsDisplayComponentDef*) base;
	g_return_if_fail (componentInst != NULL);
	_tmp0_ = g_strdup ("Hexadecimal");
	typeString = _tmp0_;
	{
		gchar* _tmp1_ = NULL;
		ComponentInst* _tmp2_ = NULL;
		PropertySet* _tmp3_ = NULL;
		gchar* _tmp4_ = NULL;
		gchar* _tmp5_ = NULL;
		_tmp2_ = componentInst;
		_tmp3_ = _tmp2_->configuration;
		_tmp4_ = property_item_selection_get_data_throw (_tmp3_, "Type", &_inner_error_);
		_tmp1_ = _tmp4_;
		if (_inner_error_ != NULL) {
			goto __catch11_g_error;
		}
		_tmp5_ = _tmp1_;
		_tmp1_ = NULL;
		_g_free0 (typeString);
		typeString = _tmp5_;
		_g_free0 (_tmp1_);
	}
	goto __finally11;
	__catch11_g_error:
	{
		gchar* _tmp6_ = NULL;
		g_clear_error (&_inner_error_);
		_inner_error_ = NULL;
		_tmp6_ = g_strdup ("Hexadecimal");
		_g_free0 (typeString);
		typeString = _tmp6_;
	}
	__finally11:
	if (_inner_error_ != NULL) {
		_g_free0 (typeString);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
		g_clear_error (&_inner_error_);
		return;
	}
	_tmp7_ = typeString;
	_tmp8_ = _tmp7_;
	_tmp10_ = (NULL == _tmp8_) ? 0 : g_quark_from_string (_tmp8_);
	if (_tmp10_ == ((0 != _tmp9_label0) ? _tmp9_label0 : (_tmp9_label0 = g_quark_from_static_string ("Hexadecimal")))) {
		switch (0) {
			default:
			{
				ComponentInst* _tmp11_ = NULL;
				ComponentInst* _tmp12_ = NULL;
				PinInst** _tmp13_ = NULL;
				gint _tmp13__length1 = 0;
				PinInst* _tmp14_ = NULL;
				ComponentInst* _tmp15_ = NULL;
				PinInst** _tmp16_ = NULL;
				gint _tmp16__length1 = 0;
				PinInst* _tmp17_ = NULL;
				ComponentInst* _tmp18_ = NULL;
				_tmp11_ = componentInst;
				_tmp11_->rightBound = 20;
				_tmp12_ = componentInst;
				_tmp13_ = _tmp12_->pinInsts;
				_tmp13__length1 = _tmp12_->pinInsts_length1;
				_tmp14_ = _tmp13_[4];
				_tmp14_->show = FALSE;
				_tmp15_ = componentInst;
				_tmp16_ = _tmp15_->pinInsts;
				_tmp16__length1 = _tmp15_->pinInsts_length1;
				_tmp17_ = _tmp16_[4];
				_tmp18_ = componentInst;
				pin_inst_disconnect (_tmp17_, _tmp18_);
				break;
			}
		}
	} else if (_tmp10_ == ((0 != _tmp9_label1) ? _tmp9_label1 : (_tmp9_label1 = g_quark_from_static_string ("Hexadecimal with point")))) {
		switch (0) {
			default:
			{
				ComponentInst* _tmp19_ = NULL;
				ComponentInst* _tmp20_ = NULL;
				PinInst** _tmp21_ = NULL;
				gint _tmp21__length1 = 0;
				PinInst* _tmp22_ = NULL;
				_tmp19_ = componentInst;
				_tmp19_->rightBound = 30;
				_tmp20_ = componentInst;
				_tmp21_ = _tmp20_->pinInsts;
				_tmp21__length1 = _tmp20_->pinInsts_length1;
				_tmp22_ = _tmp21_[4];
				_tmp22_->show = TRUE;
				break;
			}
		}
	}
	_g_free0 (typeString);
}


static void basic_ss_display_component_def_real_extra_render (ComponentDef* base, cairo_t* context, Direction direction, gboolean flipped, ComponentInst* componentInst) {
	BasicSsDisplayComponentDef * self;
	cairo_matrix_t oldMatrix = {0};
	cairo_t* _tmp0_ = NULL;
	cairo_matrix_t _tmp1_ = {0};
	gdouble oldLineWidth = 0.0;
	cairo_t* _tmp2_ = NULL;
	gdouble _tmp3_ = 0.0;
	gdouble angle = 0.0;
	ComponentInst* _tmp4_ = NULL;
	Direction _tmp5_ = 0;
	cairo_t* _tmp6_ = NULL;
	gdouble _tmp7_ = 0.0;
	cairo_t* _tmp8_ = NULL;
	cairo_t* _tmp9_ = NULL;
	cairo_t* _tmp10_ = NULL;
	cairo_t* _tmp11_ = NULL;
	cairo_t* _tmp12_ = NULL;
	cairo_t* _tmp13_ = NULL;
	cairo_t* _tmp14_ = NULL;
	cairo_t* _tmp15_ = NULL;
	cairo_t* _tmp16_ = NULL;
	cairo_t* _tmp17_ = NULL;
	cairo_t* _tmp18_ = NULL;
	cairo_t* _tmp19_ = NULL;
	cairo_t* _tmp20_ = NULL;
	cairo_t* _tmp21_ = NULL;
	cairo_t* _tmp22_ = NULL;
	cairo_t* _tmp23_ = NULL;
	cairo_t* _tmp24_ = NULL;
	cairo_t* _tmp25_ = NULL;
	cairo_t* _tmp26_ = NULL;
	cairo_t* _tmp27_ = NULL;
	cairo_t* _tmp28_ = NULL;
	cairo_t* _tmp29_ = NULL;
	cairo_t* _tmp30_ = NULL;
	ComponentInst* _tmp31_ = NULL;
	PinInst** _tmp32_ = NULL;
	gint _tmp32__length1 = 0;
	PinInst* _tmp33_ = NULL;
	gboolean _tmp34_ = FALSE;
	cairo_t* _tmp44_ = NULL;
	gdouble _tmp45_ = 0.0;
	cairo_t* _tmp46_ = NULL;
	cairo_matrix_t _tmp47_ = {0};
	self = (BasicSsDisplayComponentDef*) base;
	g_return_if_fail (context != NULL);
	_tmp0_ = context;
	cairo_get_matrix (_tmp0_, &_tmp1_);
	oldMatrix = _tmp1_;
	_tmp2_ = context;
	_tmp3_ = cairo_get_line_width (_tmp2_);
	oldLineWidth = _tmp3_;
	_tmp4_ = componentInst;
	_tmp5_ = _tmp4_->direction;
	switch (_tmp5_) {
		case DIRECTION_DOWN:
		{
			angle = G_PI * 0.5;
			break;
		}
		case DIRECTION_UP:
		{
			angle = G_PI * 1.5;
			break;
		}
		default:
		{
			angle = (gdouble) 0;
			break;
		}
	}
	_tmp6_ = context;
	_tmp7_ = angle;
	cairo_rotate (_tmp6_, _tmp7_);
	_tmp8_ = context;
	cairo_set_line_width (_tmp8_, (gdouble) 5);
	_tmp9_ = context;
	cairo_set_source_rgb (_tmp9_, 0.8, 0.8, 0.8);
	_tmp10_ = context;
	cairo_move_to (_tmp10_, (gdouble) (-12), (gdouble) (-30));
	_tmp11_ = context;
	cairo_line_to (_tmp11_, (gdouble) 12, (gdouble) (-30));
	_tmp12_ = context;
	cairo_stroke (_tmp12_);
	_tmp13_ = context;
	cairo_move_to (_tmp13_, (gdouble) 15, (gdouble) (-27));
	_tmp14_ = context;
	cairo_line_to (_tmp14_, (gdouble) 15, (gdouble) (-3));
	_tmp15_ = context;
	cairo_stroke (_tmp15_);
	_tmp16_ = context;
	cairo_move_to (_tmp16_, (gdouble) 15, (gdouble) 3);
	_tmp17_ = context;
	cairo_line_to (_tmp17_, (gdouble) 15, (gdouble) 27);
	_tmp18_ = context;
	cairo_stroke (_tmp18_);
	_tmp19_ = context;
	cairo_move_to (_tmp19_, (gdouble) 12, (gdouble) 30);
	_tmp20_ = context;
	cairo_line_to (_tmp20_, (gdouble) (-12), (gdouble) 30);
	_tmp21_ = context;
	cairo_stroke (_tmp21_);
	_tmp22_ = context;
	cairo_move_to (_tmp22_, (gdouble) (-15), (gdouble) 27);
	_tmp23_ = context;
	cairo_line_to (_tmp23_, (gdouble) (-15), (gdouble) 3);
	_tmp24_ = context;
	cairo_stroke (_tmp24_);
	_tmp25_ = context;
	cairo_move_to (_tmp25_, (gdouble) (-15), (gdouble) (-3));
	_tmp26_ = context;
	cairo_line_to (_tmp26_, (gdouble) (-15), (gdouble) (-27));
	_tmp27_ = context;
	cairo_stroke (_tmp27_);
	_tmp28_ = context;
	cairo_move_to (_tmp28_, (gdouble) 12, (gdouble) 0);
	_tmp29_ = context;
	cairo_line_to (_tmp29_, (gdouble) (-12), (gdouble) 0);
	_tmp30_ = context;
	cairo_stroke (_tmp30_);
	_tmp31_ = componentInst;
	_tmp32_ = _tmp31_->pinInsts;
	_tmp32__length1 = _tmp31_->pinInsts_length1;
	_tmp33_ = _tmp32_[4];
	_tmp34_ = _tmp33_->show;
	if (_tmp34_) {
		cairo_line_cap_t oldLineCap = 0;
		cairo_t* _tmp35_ = NULL;
		cairo_line_cap_t _tmp36_ = 0;
		cairo_t* _tmp37_ = NULL;
		cairo_t* _tmp38_ = NULL;
		cairo_t* _tmp39_ = NULL;
		cairo_t* _tmp40_ = NULL;
		cairo_t* _tmp41_ = NULL;
		cairo_t* _tmp42_ = NULL;
		cairo_line_cap_t _tmp43_ = 0;
		_tmp35_ = context;
		_tmp36_ = cairo_get_line_cap (_tmp35_);
		oldLineCap = _tmp36_;
		_tmp37_ = context;
		cairo_set_line_cap (_tmp37_, CAIRO_LINE_CAP_ROUND);
		_tmp38_ = context;
		cairo_set_line_width (_tmp38_, (gdouble) 8);
		_tmp39_ = context;
		cairo_move_to (_tmp39_, 22.5, 27.5);
		_tmp40_ = context;
		cairo_line_to (_tmp40_, 22.5, 27.5);
		_tmp41_ = context;
		cairo_stroke (_tmp41_);
		_tmp42_ = context;
		_tmp43_ = oldLineCap;
		cairo_set_line_cap (_tmp42_, _tmp43_);
	}
	_tmp44_ = context;
	_tmp45_ = oldLineWidth;
	cairo_set_line_width (_tmp44_, _tmp45_);
	_tmp46_ = context;
	_tmp47_ = oldMatrix;
	cairo_set_matrix (_tmp46_, &_tmp47_);
}


static void basic_ss_display_component_def_class_init (BasicSsDisplayComponentDefClass * klass) {
	basic_ss_display_component_def_parent_class = g_type_class_peek_parent (klass);
	COMPONENT_DEF_CLASS (klass)->add_properties = basic_ss_display_component_def_real_add_properties;
	COMPONENT_DEF_CLASS (klass)->get_properties = basic_ss_display_component_def_real_get_properties;
	COMPONENT_DEF_CLASS (klass)->load_properties = basic_ss_display_component_def_real_load_properties;
	COMPONENT_DEF_CLASS (klass)->save_properties = basic_ss_display_component_def_real_save_properties;
	COMPONENT_DEF_CLASS (klass)->compile_component = basic_ss_display_component_def_real_compile_component;
	COMPONENT_DEF_CLASS (klass)->configure_inst = basic_ss_display_component_def_real_configure_inst;
	COMPONENT_DEF_CLASS (klass)->extra_render = basic_ss_display_component_def_real_extra_render;
}


static void basic_ss_display_component_def_instance_init (BasicSsDisplayComponentDef * self) {
}


GType basic_ss_display_component_def_get_type (void) {
	static volatile gsize basic_ss_display_component_def_type_id__volatile = 0;
	if (g_once_init_enter (&basic_ss_display_component_def_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (BasicSsDisplayComponentDefClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) basic_ss_display_component_def_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (BasicSsDisplayComponentDef), 0, (GInstanceInitFunc) basic_ss_display_component_def_instance_init, NULL };
		GType basic_ss_display_component_def_type_id;
		basic_ss_display_component_def_type_id = g_type_register_static (TYPE_COMPONENT_DEF, "BasicSsDisplayComponentDef", &g_define_type_info, 0);
		g_once_init_leave (&basic_ss_display_component_def_type_id__volatile, basic_ss_display_component_def_type_id);
	}
	return basic_ss_display_component_def_type_id__volatile;
}



