![]() |
![]() |
![]() |
V_Sim API - Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Signals |
#define VISU_TYPE #define VISU (obj) #define VISU_CLASS (klass) #define IS_VISU_TYPE (obj) #define IS_VISU_CLASS (klass) #define VISU_GET_CLASS (obj) VisuObject; VisuObjectClass; gboolean visu_object_redraw (gpointer data
); gboolean visu_object_redrawForce (gpointer data
); #define VISU_ADD_REDRAW #define VISU_FORCE_REDRAW GType visuObject_get_type (void
); #define VISU_INSTANCE VisuObject* visuObjectGet_static (); #define VISU_SIGNALS gboolean visu_object_setRendering (VisuObject *obj
,VisuRendering *method
); VisuRendering* visu_object_getRendering (VisuObject *obj
);
"DirectoryChanged" : Run Last / No Recursion / No Hooks "OpenGLAskForReDraw" : Run Last / No Recursion / No Hooks "OpenGLForceReDraw" : Run Last / No Recursion / No Hooks "colorNewAvailable" : Run Last / No Recursion / No Hooks "dataLoaded" : Run Last / No Recursion / No Hooks "dataNew" : Run Last / No Recursion / No Hooks "dataReadyForRendering" : Run Last / No Recursion / No Hooks "renderingChanged" : Run Last / No Recursion / No Hooks "resourcesLoaded" : Run Last / No Recursion / No Hooks
At the present time, the signals are global to all V_Sim, owned by a variable include in each parts called visu. This is wherre these signals are defined.
#define VISU(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VISU_TYPE, VisuObject))
Cast the given obj
into VisuObject type.
|
a GObject to cast. |
#define VISU_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VISU_TYPE, VisuObjectClass))
Cast the given klass
into VisuObjectClass.
|
a GObjectClass to cast. |
#define IS_VISU_TYPE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VISU_TYPE))
Test if the given ogj
is of the type of VisuObject object.
|
a GObject to test. |
#define IS_VISU_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VISU_TYPE))
Test if the given klass
is of the type of VisuObjectClass class.
|
a GObjectClass to test. |
#define VISU_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VISU_TYPE, VisuObjectClass))
It returns the class of the given obj
.
|
a GObject to get the class of. |
typedef struct { GObjectClass parent; guint signals[VISU_NB_SIGNAL]; } VisuObjectClass;
This structure describes the class VisuObjectClass.
GObjectClass |
an object to inherit from (NULL here). |
guint |
the array with the signals. |
gboolean visu_object_redraw (gpointer data
);
Call the signal OpenGLAskForReDraw. The API is adapted to the routine to be added in the gloop. Use VISU_ADD_REDRAW instead of this routine.
|
a string.. allow-none. |
Returns : |
FALSE to stop the emission as soon as done. |
gboolean visu_object_redrawForce (gpointer data
);
Call the signal OpenGLForceReDraw. The API is adapted to the routine to be added in the gloop. Use VISU_FORCE_REDRAW instead of this routine.
|
a string.. allow-none. |
Returns : |
FALSE to stop the emission as soon as done. |
#define VISU_ADD_REDRAW g_idle_add(visu_object_redraw, (gpointer)__func__)
A macro to ask V_Sim to redraw the rendering area at next idle time, except if the deferred redraw option is set.
#define VISU_FORCE_REDRAW g_idle_add(visu_object_redrawForce, (gpointer)__func__)
Force V_Sim to redraw at the next idle time, whatever value for the deferred redraw option.
GType visuObject_get_type (void
);
This method returns the type of VisuObject, use VISU_TYPE instead.
Returns : |
the type of VisuObject. |
#define VISU_INSTANCE visuObjectGet_static()
This routine is used to get the global VisuObject object to listen to its signals.
VisuObject* visuObjectGet_static ();
Internal routine to access the VisuObject object instanciated by default. Use VISU_INSTANCE instead.
#define VISU_SIGNALS VISU_GET_CLASS(VISU_INSTANCE)->signals
Get the list of signals of a VisuObject.
gboolean visu_object_setRendering (VisuObject *obj
,VisuRendering *method
);
Choose the method used to render the data.
|
a VisuObject object. |
|
a VisuRendering method. |
Returns : |
TRUE if the rendering method of obj is actually changed.
|
VisuRendering* visu_object_getRendering (VisuObject *obj
);
Get the current method used to render the data.
|
a VisuObject object. |
Returns : |
the rendering method attached to obj .
|
"DirectoryChanged"
signalvoid user_function (VisuObject *visuObj, guint kind, gpointer user_data) : Run Last / No Recursion / No Hooks
The current directory has been changed. The kind of directory is
defined by kind
(see #).
|
the object emitting the signal. |
|
a flag. |
|
user data set when the signal handler was connected. |
Since 3.6
"OpenGLAskForReDraw"
signalvoid user_function (VisuObject *visuObj, gpointer user_data) : Run Last / No Recursion / No Hooks
Internal signal, use VISU_ADD_REDRAW()
instead.
|
the object emitting the signal. |
|
user data set when the signal handler was connected. |
"OpenGLForceReDraw"
signalvoid user_function (VisuObject *visuObj, gpointer user_data) : Run Last / No Recursion / No Hooks
Internal signal, use VISU_FORCE_REDRAW()
instead.
|
the object emitting the signal. |
|
user data set when the signal handler was connected. |
"colorNewAvailable"
signalvoid user_function (VisuObject *visuObj, gpointer color, gpointer user_data) : Run Last / No Recursion / No Hooks
A new ToolColor is available.
|
the object emitting the signal. |
|
the newly created ToolColor. |
|
user data set when the signal handler was connected. |
Since 3.2
"dataLoaded"
signalvoid user_function (VisuObject *visuObj, GObject *dataObj, gpointer user_data) : Run Last / No Recursion / No Hooks
The given dataObj
is fully populated and ready for usage.
|
the object emitting the signal. |
|
the newly created VisuData. |
|
user data set when the signal handler was connected. |
Since 3.1
"dataNew"
signalvoid user_function (VisuObject *visuObj, GObject *dataObj, gpointer user_data) : Run Last / No Recursion / No Hooks
A new VisuData is available.
|
the object emitting the signal. |
|
the newly created VisuData. |
|
user data set when the signal handler was connected. |
Since 3.2
"dataReadyForRendering"
signalvoid user_function (VisuObject *visuObj, GObject *dataObj, gpointer user_data) : Run Last / No Recursion / No Hooks
The given dataObj
is fully set up and ready for rendering (no
further internal modifications will occur).
|
the object emitting the signal. |
|
the newly created VisuData. |
|
user data set when the signal handler was connected. |
"renderingChanged"
signalvoid user_function (VisuObject *visuObj, gpointer meth, gpointer user_data) : Run Last / No Recursion / No Hooks
The rendering method has been changed.
|
the object emitting the signal. |
|
the newly chosen VisuRendering method. |
|
user data set when the signal handler was connected. |
"resourcesLoaded"
signalvoid user_function (VisuObject *visuObj, GObject *dataObj, gpointer user_data) : Run Last / No Recursion / No Hooks
The resource file has been read.
|
the object emitting the signal. |
|
the associated VisuData. |
|
user data set when the signal handler was connected. |