Clutter.Animator

g Clutter.Animator Clutter.Animator Clutter.Scriptable Clutter.Scriptable Clutter.Scriptable->Clutter.Animator GObject.GInterface GObject.GInterface GObject.GInterface->Clutter.Scriptable GObject.Object GObject.Object GObject.Object->Clutter.Animator

Subclasses:

None

Methods

Inherited:

GObject.Object (37), Clutter.Scriptable (4)

Structs:

GObject.ObjectClass (5)

class

new ()

compute_value (object, property_name, progress, value)

get_duration ()

get_keys (object, property_name, progress)

get_timeline ()

property_get_ease_in (object, property_name)

property_get_interpolation (object, property_name)

property_set_ease_in (object, property_name, ease_in)

property_set_interpolation (object, property_name, interpolation)

remove_key (object, property_name, progress)

set_duration (duration)

set_key (object, property_name, mode, progress, value)

set_timeline (timeline)

start ()

Virtual Methods

Inherited:

GObject.Object (7), Clutter.Scriptable (4)

Properties

Name

Type

Flags

Short Description

duration

int

r/w

The duration of the animation deprecated

timeline

Clutter.Timeline

r/w

The timeline of the animation deprecated

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent_instance

GObject.Object

r

Class Details

class Clutter.Animator(**kwargs)
Bases:

GObject.Object, Clutter.Scriptable

Abstract:

No

Structure:

Clutter.AnimatorClass

The Clutter.Animator structure contains only private data and should be accessed using the provided API

New in version 1.2.

Deprecated since version 1.12.

classmethod new()
Returns:

a new Clutter.Animator.

Return type:

Clutter.Animator

Creates a new Clutter.Animator instance

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

compute_value(object, property_name, progress, value)
Parameters:
Returns:

True if the computation yields has a value, otherwise (when an error occurs or the progress is before any of the keys) False is returned and the GObject.Value is left untouched

Return type:

bool

Compute the value for a managed property at a given progress.

If the property is an ease-in property, the current value of the property on the object will be used as the starting point for computation.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

get_duration()
Returns:

the duration of the animation, in milliseconds

Return type:

int

Retrieves the current duration of an animator

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

get_keys(object, property_name, progress)
Parameters:
  • object (GObject.Object or None) – a GObject.Object to search for, or None for all objects

  • property_name (str or None) – a specific property name to query for, or None for all properties

  • progress (float) – a specific progress to search for, or a negative value for all progresses

Returns:

a list of Clutter.AnimatorKey s; the contents of the list are owned by the Clutter.Animator, but you should free the returned list when done, using g_list_free()

Return type:

[Clutter.AnimatorKey]

Returns a list of pointers to opaque structures with accessor functions that describe the keys added to an animator.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

get_timeline()
Returns:

the Clutter.Timeline that drives the animator

Return type:

Clutter.Timeline

Get the timeline hooked up for driving the Clutter.Animator

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

property_get_ease_in(object, property_name)
Parameters:
Returns:

True if the property is eased in

Return type:

bool

Checks if a property value is to be eased into the animation.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

property_get_interpolation(object, property_name)
Parameters:
Returns:

a Clutter.Interpolation value.

Return type:

Clutter.Interpolation

Get the interpolation used by animator for a property on a particular object.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

property_set_ease_in(object, property_name, ease_in)
Parameters:

Sets whether a property value is to be eased into the animation.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

property_set_interpolation(object, property_name, interpolation)
Parameters:

Set the interpolation method to use, Clutter.Interpolation.LINEAR causes the values to linearly change between the values, and Clutter.Interpolation.CUBIC causes the values to smoothly change between the values.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

remove_key(object, property_name, progress)
Parameters:

Removes all keys matching the conditions specificed in the arguments.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

set_duration(duration)
Parameters:

duration (int) – milliseconds a run of the animator should last.

Runs the timeline of the Clutter.Animator with a duration in msecs as specified.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

set_key(object, property_name, mode, progress, value)
Parameters:
  • object (GObject.Object) – a GObject.Object

  • property_name (str) – the property to specify a key for

  • mode (int) – the id of the alpha function to use

  • progress (float) – the normalized range at which stage of the animation this value applies

  • value (GObject.Value) – the value property_name should have at progress.

Returns:

The animator instance

Return type:

Clutter.Animator

Sets a single key in the Clutter.Animator for the property_name of object at progress.

See also: clutter_animator_set()

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

set_timeline(timeline)
Parameters:

timeline (Clutter.Timeline) – a Clutter.Timeline

Sets an external timeline that will be used for driving the animation

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

start()
Returns:

the Clutter.Timeline that drives the animator. The returned timeline is owned by the Clutter.Animator and it should not be unreferenced

Return type:

Clutter.Timeline

Start the Clutter.Animator, this is a thin wrapper that rewinds and starts the animators current timeline.

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

Property Details

Clutter.Animator.props.duration
Name:

duration

Type:

int

Default Value:

2000

Flags:

READABLE, WRITABLE

The duration of the Clutter.Timeline used by the Clutter.Animator to drive the animation

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead

Clutter.Animator.props.timeline
Name:

timeline

Type:

Clutter.Timeline

Default Value:

None

Flags:

READABLE, WRITABLE

The Clutter.Timeline used by the Clutter.Animator to drive the animation

New in version 1.2.

Deprecated since version 1.12: Use Clutter.KeyframeTransition instead