forked from enlightenment/efl
57 lines
2.4 KiB
Plaintext
57 lines
2.4 KiB
Plaintext
class @beta Efl.Canvas.Animation_Rotate extends Efl.Canvas.Animation
|
|
{
|
|
[[Animated rotation effect.
|
|
|
|
The @Efl.Canvas.Object will rotate around a pivot point from one degree to another.
|
|
Coordinates for the pivot point can be relative to another object or absolute
|
|
(relative to the containing canvas).
|
|
|
|
Note: Changing an object's position using @Efl.Gfx.Entity.position while this
|
|
animation is running might lead to unexpected results.
|
|
]]
|
|
c_prefix: efl_animation_rotate;
|
|
data: Efl_Canvas_Animation_Rotate_Data;
|
|
methods {
|
|
@property rotate {
|
|
[[Degree range to animate and pivot object.
|
|
The object will rotate from $from_degree to $to_degree around the pivot point.
|
|
All of the object's vertices (i.e. the corners, if it's a rectangular object)
|
|
will be rotated by these degrees, relative to the pivot point inside the pivot object.
|
|
The pivot point is another object $pivot plus an additional offset $center_point.
|
|
]]
|
|
set {
|
|
}
|
|
get {
|
|
}
|
|
values {
|
|
from_degree: double; [[Initial rotation (from 0 to 360). 0 means no rotation.]]
|
|
to_degree: double; [[Ending rotation (from 0 to 360). 0 means no rotation.]]
|
|
pivot: Efl.Canvas.Object; [[Object to use as pivot. $NULL means the animated object itself.]]
|
|
center_point: Eina.Vector2; [[Position in pixels of the pivot point inside the pivot object.
|
|
$[(0,0)] means the upper-left corner.]]
|
|
}
|
|
}
|
|
@property rotate_absolute {
|
|
[[Degree range to animate and absolute pivot point.
|
|
The object will rotate from $from_degree to $to_degree around the pivot point.
|
|
All of the object's vertices (i.e. the corners, if it's a rectangular object)
|
|
will be rotated by these degrees, relative to an absolute pivot point.
|
|
The pivot point is relative to the canvas.
|
|
]]
|
|
set {
|
|
}
|
|
get {
|
|
}
|
|
values {
|
|
from_degree: double; [[Initial rotation (from 0 to 360). 0 means no rotation.]]
|
|
to_degree: double; [[Ending rotation (from 0 to 360). 0 means no rotation.]]
|
|
pivot_point : Eina.Position2D; [[Position of the pivot point relative to the canvas.]]
|
|
}
|
|
}
|
|
}
|
|
implements {
|
|
Efl.Object.constructor;
|
|
Efl.Canvas.Animation.animation_apply;
|
|
}
|
|
}
|