Clutter.Path
Description: Reference for Clutter.Path

### Class

# ClutterPath

#### Description [src]

    class Clutter.Path : GObject.InitiallyUnowned {
      /* No available fields */
    }

The `ClutterPath` struct contains only private data and should be accessed with the functions below.

Available since: | 1.0

#### Ancestors

- GInitiallyUnowned
- GObject

#### Constructors

###### clutter_path_new

Creates a new `ClutterPath` instance with no nodes.

Available since: 1.0

###### clutter_path_new_with_description

Creates a new `ClutterPath` instance with the nodes described in `desc`. See `clutter_path_add_string()` for details of the format of the string.

Available since: 1.0

#### Instance methods

###### clutter_path_add_cairo_path

Add the nodes of the Cairo path to the end of `path`.

Available since: 1.0

###### clutter_path_add_close

Adds a `CLUTTER_PATH_CLOSE` type node to the path. This creates a straight line from the last node to the last `CLUTTER_PATH_MOVE_TO` type node.

Available since: 1.0

###### clutter_path_add_curve_to

Adds a `CLUTTER_PATH_CURVE_TO` type node to the path. This causes the actor to follow a bezier from the last node to (`x_3`, `y_3`) using (`x_1`, `y_1`) and (`x_2`,`y_2`) as control points.

Available since: 1.0

###### clutter_path_add_line_to

Adds a `CLUTTER_PATH_LINE_TO` type node to the path. This causes the actor to move to the new coordinates in a straight line.

Available since: 1.0

###### clutter_path_add_move_to

Adds a `CLUTTER_PATH_MOVE_TO` type node to the path. This is usually used as the first node in a path. It can also be used in the middle of the path to cause the actor to jump to the new coordinate.

Available since: 1.0

###### clutter_path_add_node

Adds `node` to the end of the path.

Available since: 1.0

###### clutter_path_add_rel_curve_to

Same as `clutter_path_add_curve_to()` except the coordinates are relative to the previous node.

Available since: 1.0

###### clutter_path_add_rel_line_to

Same as `clutter_path_add_line_to()` except the coordinates are relative to the previous node.

Available since: 1.0

###### clutter_path_add_rel_move_to

Same as `clutter_path_add_move_to()` except the coordinates are relative to the previous node.

Available since: 1.0

###### clutter_path_add_string

Adds new nodes to the end of the path as described in `str`. The format is a subset of the SVG path format. Each node is represented by a letter and is followed by zero, one or three pairs of coordinates. The coordinates can be separated by spaces or a comma. The types are:

Available since: 1.0

###### clutter_path_clear

Removes all nodes from the path.

Available since: 1.0

###### clutter_path_foreach

Calls a function for each node of the path.

Available since: 1.0

###### clutter_path_get_description

Returns a newly allocated string describing the path in the same format as used by clutter_path_add_string().

Available since: 1.0

###### clutter_path_get_length

Retrieves an approximation of the total length of the path.

Available since: 1.0

###### clutter_path_get_n_nodes

Retrieves the number of nodes in the path.

Available since: 1.0

###### clutter_path_get_node

Retrieves the node of the path indexed by `index`.

Available since: 1.0

###### clutter_path_get_nodes

Returns a `GSList` of `ClutterPathNode`s. The list should be freed with g_slist_free(). The nodes are owned by the path and should not be freed. Altering the path may cause the nodes in the list to become invalid so you should copy them if you want to keep the list.

Available since: 1.0

###### clutter_path_get_position

The value in `progress` represents a position along the path where 0.0 is the beginning and 1.0 is the end of the path. An interpolated position is then stored in `position`.

Available since: 1.0

###### clutter_path_insert_node

Inserts `node` into the path before the node at the given offset. If `index_` is negative it will append the node to the end of the path.

Available since: 1.0

###### clutter_path_remove_node

Removes the node at the given offset from the path.

Available since: 1.0

###### clutter_path_replace_node

Replaces the node at offset `index_` with `node`.

Available since: 1.0

###### clutter_path_set_description

Replaces all of the nodes in the path with nodes described by `str`. See `clutter_path_add_string()` for details of the format.

Available since: 1.0

###### clutter_path_to_cairo_path

Add the nodes of the ClutterPath to the path in the Cairo context.

Available since: 1.0

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

#### Properties

###### Clutter.Path:description

No description available.

###### Clutter.Path:length

No description available.

#### Signals

##### Signals inherited from GObject (1)

###### GObject.Object::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

#### Class structure

    struct ClutterPathClass {
      /* no available fields */
    }