| Clutter Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | Object Hierarchy | Properties | Signals | ||||
ClutterPathConstraint; ClutterConstraint * clutter_path_constraint_new (ClutterPath *path,gfloat offset); void clutter_path_constraint_set_path (ClutterPathConstraint *constraint,ClutterPath *path); ClutterPath * clutter_path_constraint_get_path (ClutterPathConstraint *constraint); void clutter_path_constraint_set_offset (ClutterPathConstraint *constraint,gfloat offset); gfloat clutter_path_constraint_get_offset (ClutterPathConstraint *constraint);
GObject
+----GInitiallyUnowned
+----ClutterActorMeta
+----ClutterConstraint
+----ClutterPathConstraint
ClutterPathConstraint is a simple constraint that modifies the allocation of the ClutterActor to which it has been applied using a ClutterPath.
By setting the "offset" property it is possible to control how far along the path the ClutterActor should be.
ClutterPathConstraint is available since Clutter 1.6.
typedef struct _ClutterPathConstraint ClutterPathConstraint;
ClutterPathConstraint is an opaque structure whose members cannot be directly accessed
Since 1.6
ClutterConstraint * clutter_path_constraint_new (ClutterPath *path,gfloat offset);
Creates a new ClutterPathConstraint with the given path and offset
|
a ClutterPath, or NULL. [allow-none]
|
|
the offset along the ClutterPath |
Returns : |
the newly created ClutterPathConstraint |
Since 1.6
void clutter_path_constraint_set_path (ClutterPathConstraint *constraint,ClutterPath *path);
Sets the path to be followed by the ClutterPathConstraint.
The constraint will take ownership of the ClutterPath passed to this
function.
|
a ClutterPathConstraint |
|
a ClutterPath. [allow-none] |
Since 1.6
ClutterPath * clutter_path_constraint_get_path (ClutterPathConstraint *constraint);
Retrieves a pointer to the ClutterPath used by constraint.
|
a ClutterPathConstraint |
Returns : |
the ClutterPath used by the
ClutterPathConstraint, or NULL. The returned ClutterPath is owned
by the constraint and it should not be unreferenced. [transfer none]
|
Since 1.6
void clutter_path_constraint_set_offset (ClutterPathConstraint *constraint,gfloat offset);
Sets the offset along the ClutterPath used by constraint.
|
a ClutterPathConstraint |
|
the offset along the path |
Since 1.6
gfloat clutter_path_constraint_get_offset (ClutterPathConstraint *constraint);
Retrieves the offset along the ClutterPath used by constraint.
|
a ClutterPathConstraint |
Returns : |
the offset |
Since 1.6
"offset" property "offset" gfloat : Read / Write
The offset along the "path", between -1.0 and 2.0.
Allowed values: [-1,2]
Default value: 0
Since 1.6
"path" property"path" ClutterPath* : Read / Write
The ClutterPath used to constrain the position of an actor.
Since 1.6
"node-reached" signalvoid user_function (ClutterPathConstraint *constraint,
ClutterActor *actor,
guint index,
gpointer user_data) : Run Last
The ::node-reached signal is emitted each time a "offset" value results in the actor passing a ClutterPathNode
|
the ClutterPathConstraint that emitted the signal |
|
the ClutterActor using the constraint
|
|
the index of the node that has been reached |
|
user data set when the signal handler was connected. |
Since 1.6