gi-clutter-1.0.3: clutter GObject bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.Clutter.Objects.Alpha

Description

Alpha combines a Timeline and a function. The contents of the Alpha structure are private and should only be accessed using the provided API.

Since: 0.2

Synopsis

Exported types

newtype Alpha Source #

Memory-managed wrapper type.

Constructors

Alpha (ManagedPtr Alpha) 

Instances

Instances details
Eq Alpha Source # 
Instance details

Defined in GI.Clutter.Objects.Alpha

Methods

(==) :: Alpha -> Alpha -> Bool #

(/=) :: Alpha -> Alpha -> Bool #

GObject Alpha Source # 
Instance details

Defined in GI.Clutter.Objects.Alpha

ManagedPtrNewtype Alpha Source # 
Instance details

Defined in GI.Clutter.Objects.Alpha

Methods

toManagedPtr :: Alpha -> ManagedPtr Alpha

TypedObject Alpha Source # 
Instance details

Defined in GI.Clutter.Objects.Alpha

Methods

glibType :: IO GType

HasParentTypes Alpha Source # 
Instance details

Defined in GI.Clutter.Objects.Alpha

IsGValue (Maybe Alpha) Source #

Convert Alpha to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.Clutter.Objects.Alpha

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe Alpha -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe Alpha)

type ParentTypes Alpha Source # 
Instance details

Defined in GI.Clutter.Objects.Alpha

type ParentTypes Alpha = '[Object, Scriptable]

class (GObject o, IsDescendantOf Alpha o) => IsAlpha o Source #

Type class for types which can be safely cast to Alpha, for instance with toAlpha.

Instances

Instances details
(GObject o, IsDescendantOf Alpha o) => IsAlpha o Source # 
Instance details

Defined in GI.Clutter.Objects.Alpha

toAlpha :: (MonadIO m, IsAlpha o) => o -> m Alpha Source #

Cast to Alpha, for types for which this is known to be safe. For general casts, use castTo.

Methods

getAlpha

alphaGetAlpha Source #

Arguments

:: (HasCallStack, MonadIO m, IsAlpha a) 
=> a

alpha: A Alpha

-> m Double

Returns: The current alpha value for the alpha

Deprecated: (Since version 1.12)Use timelineGetProgress

Query the current alpha value.

Since: 0.2

getMode

alphaGetMode Source #

Arguments

:: (HasCallStack, MonadIO m, IsAlpha a) 
=> a

alpha: a Alpha

-> m CULong

Returns: the animation mode

Deprecated: (Since version 1.12)Use Timeline instead

Retrieves the AnimationMode used by alpha.

Since: 1.0

getTimeline

alphaGetTimeline Source #

Arguments

:: (HasCallStack, MonadIO m, IsAlpha a) 
=> a

alpha: A Alpha

-> m Timeline

Returns: a Timeline instance

Deprecated: (Since version 1.12)Use Timeline directlry

Gets the Timeline bound to alpha.

Since: 0.2

new

alphaNew Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> m Alpha

Returns: the newly created empty Alpha instance.

Deprecated: (Since version 1.12)Use Timeline instead

Creates a new Alpha instance. You must set a function to compute the alpha value using alphaSetFunc and bind a Timeline object to the Alpha instance using alphaSetTimeline.

You should use the newly created Alpha instance inside a Behaviour object.

Since: 0.2

newFull

alphaNewFull Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimeline a) 
=> a

timeline: Timeline timeline

-> CULong

mode: animation mode

-> m Alpha

Returns: the newly created Alpha

Deprecated: (Since version 1.12)Use Timeline instead

Creates a new Alpha instance and sets the timeline and animation mode.

See also alphaSetTimeline and alphaSetMode.

Since: 1.0

newWithFunc

alphaNewWithFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimeline a) 
=> a

timeline: a Timeline

-> AlphaFunc

func: a AlphaFunc

-> m Alpha

Returns: the newly created Alpha

Deprecated: (Since version 1.12)Use Timeline instead

Creates a new Alpha instances and sets the timeline and the alpha function.

This function will not register func as a global alpha function.

See also alphaSetTimeline and alphaSetFunc.

Since: 1.0

registerFunc

alphaRegisterFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> GClosure a

closure: a Closure

-> m CULong

Returns: the logical id of the alpha function

Deprecated: (Since version 1.12)There is no direct replacement for this function. Use timelineSetProgressFunc on each specific Timeline instance

Closure variant of clutter_alpha_register_func().

Registers a global alpha function and returns its logical id to be used by alphaSetMode or by Animation.

The logical id is always greater than AnimationModeAnimationLast.

Since: 1.0

setClosure

alphaSetClosure Source #

Arguments

:: (HasCallStack, MonadIO m, IsAlpha a) 
=> a

alpha: A Alpha

-> GClosure b

closure: A Closure

-> m () 

Deprecated: (Since version 1.12)Use timelineSetProgressFunc

Sets the Closure used to compute the alpha value at each frame of the Timeline bound to alpha.

Since: 0.8

setFunc

alphaSetFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsAlpha a) 
=> a

alpha: A Alpha

-> AlphaFunc

func: A AlphaFunc

-> m () 

Deprecated: (Since version 1.12)Use timelineSetProgressFunc

Sets the AlphaFunc function used to compute the alpha value at each frame of the Timeline bound to alpha.

This function will not register func as a global alpha function.

Since: 0.2

setMode

alphaSetMode Source #

Arguments

:: (HasCallStack, MonadIO m, IsAlpha a) 
=> a

alpha: a Alpha

-> CULong

mode: a AnimationMode

-> m () 

Deprecated: (Since version 1.12)Use Timeline and timelineSetProgressMode instead

Sets the progress function of alpha using the symbolic value of mode, as taken by the AnimationMode enumeration or using the value returned by clutter_alpha_register_func().

Since: 1.0

setTimeline

alphaSetTimeline Source #

Arguments

:: (HasCallStack, MonadIO m, IsAlpha a, IsTimeline b) 
=> a

alpha: A Alpha

-> b

timeline: A Timeline

-> m () 

Deprecated: (Since version 1.12)Use Timeline directly

Binds alpha to timeline.

Since: 0.2

Properties

alpha

The alpha value as computed by the alpha function. The linear interval is 0.0 to 1.0, but the Alpha allows overshooting by one unit in each direction, so the valid interval is -1.0 to 2.0.

Since: 0.2

getAlphaAlpha :: (MonadIO m, IsAlpha o) => o -> m Double Source #

Get the value of the “alpha” property. When overloading is enabled, this is equivalent to

get alpha #alpha

mode

The progress function logical id - either a value from the AnimationMode enumeration or a value returned by clutter_alpha_register_func().

If AnimationModeCustomMode is used then the function set using alphaSetClosure or alphaSetFunc will be used.

Since: 1.0

constructAlphaMode :: (IsAlpha o, MonadIO m) => CULong -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “mode” property. This is rarely needed directly, but it is used by new.

getAlphaMode :: (MonadIO m, IsAlpha o) => o -> m CULong Source #

Get the value of the “mode” property. When overloading is enabled, this is equivalent to

get alpha #mode

setAlphaMode :: (MonadIO m, IsAlpha o) => o -> CULong -> m () Source #

Set the value of the “mode” property. When overloading is enabled, this is equivalent to

set alpha [ #mode := value ]

timeline

A Timeline instance used to drive the alpha function.

Since: 0.2

constructAlphaTimeline :: (IsAlpha o, MonadIO m, IsTimeline a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “timeline” property. This is rarely needed directly, but it is used by new.

getAlphaTimeline :: (MonadIO m, IsAlpha o) => o -> m Timeline Source #

Get the value of the “timeline” property. When overloading is enabled, this is equivalent to

get alpha #timeline

setAlphaTimeline :: (MonadIO m, IsAlpha o, IsTimeline a) => o -> a -> m () Source #

Set the value of the “timeline” property. When overloading is enabled, this is equivalent to

set alpha [ #timeline := value ]