Copyright | Will Thompson and Iñaki García Etxebarria |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
The BehaviourPath
structure contains only private data
and should be accessed using the provided API
Since: 0.2
Synopsis
- newtype BehaviourPath = BehaviourPath (ManagedPtr BehaviourPath)
- class (GObject o, IsDescendantOf BehaviourPath o) => IsBehaviourPath o
- toBehaviourPath :: (MonadIO m, IsBehaviourPath o) => o -> m BehaviourPath
- behaviourPathGetPath :: (HasCallStack, MonadIO m, IsBehaviourPath a) => a -> m Path
- behaviourPathNew :: (HasCallStack, MonadIO m, IsAlpha a, IsPath b) => Maybe a -> b -> m BehaviourPath
- behaviourPathNewWithDescription :: (HasCallStack, MonadIO m, IsAlpha a) => Maybe a -> Text -> m BehaviourPath
- behaviourPathNewWithKnots :: (HasCallStack, MonadIO m, IsAlpha a) => Maybe a -> [Knot] -> m BehaviourPath
- behaviourPathSetPath :: (HasCallStack, MonadIO m, IsBehaviourPath a, IsPath b) => a -> b -> m ()
- constructBehaviourPathPath :: (IsBehaviourPath o, MonadIO m, IsPath a) => a -> m (GValueConstruct o)
- getBehaviourPathPath :: (MonadIO m, IsBehaviourPath o) => o -> m Path
- setBehaviourPathPath :: (MonadIO m, IsBehaviourPath o, IsPath a) => o -> a -> m ()
- type BehaviourPathKnotReachedCallback = Word32 -> IO ()
- afterBehaviourPathKnotReached :: (IsBehaviourPath a, MonadIO m) => a -> ((?self :: a) => BehaviourPathKnotReachedCallback) -> m SignalHandlerId
- onBehaviourPathKnotReached :: (IsBehaviourPath a, MonadIO m) => a -> ((?self :: a) => BehaviourPathKnotReachedCallback) -> m SignalHandlerId
Exported types
newtype BehaviourPath Source #
Memory-managed wrapper type.
Instances
Eq BehaviourPath Source # | |
Defined in GI.Clutter.Objects.BehaviourPath (==) :: BehaviourPath -> BehaviourPath -> Bool # (/=) :: BehaviourPath -> BehaviourPath -> Bool # | |
GObject BehaviourPath Source # | |
Defined in GI.Clutter.Objects.BehaviourPath | |
ManagedPtrNewtype BehaviourPath Source # | |
Defined in GI.Clutter.Objects.BehaviourPath | |
TypedObject BehaviourPath Source # | |
Defined in GI.Clutter.Objects.BehaviourPath | |
HasParentTypes BehaviourPath Source # | |
Defined in GI.Clutter.Objects.BehaviourPath | |
IsGValue (Maybe BehaviourPath) Source # | Convert |
Defined in GI.Clutter.Objects.BehaviourPath gvalueGType_ :: IO GType # gvalueSet_ :: Ptr GValue -> Maybe BehaviourPath -> IO () # gvalueGet_ :: Ptr GValue -> IO (Maybe BehaviourPath) # | |
type ParentTypes BehaviourPath Source # | |
Defined in GI.Clutter.Objects.BehaviourPath |
class (GObject o, IsDescendantOf BehaviourPath o) => IsBehaviourPath o Source #
Type class for types which can be safely cast to BehaviourPath
, for instance with toBehaviourPath
.
Instances
(GObject o, IsDescendantOf BehaviourPath o) => IsBehaviourPath o Source # | |
Defined in GI.Clutter.Objects.BehaviourPath |
toBehaviourPath :: (MonadIO m, IsBehaviourPath o) => o -> m BehaviourPath Source #
Cast to BehaviourPath
, for types for which this is known to be safe. For general casts, use castTo
.
Methods
Click to display all available methods, including inherited ones
Methods
actorsForeach, apply, bindProperty, bindPropertyFull, forceFloating, freezeNotify, getv, isApplied, isFloating, notify, notifyByPspec, parseCustomNode, ref, refSink, remove, removeAll, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getActors, getAlpha, getData, getId, getNActors, getNthActor, getPath, getProperty, getQdata.
Setters
setAlpha, setCustomProperty, setData, setDataFull, setId, setPath, setProperty.
getPath
:: (HasCallStack, MonadIO m, IsBehaviourPath a) | |
=> a |
|
-> m Path | Returns: the path |
Deprecated: (Since version 1.6)
Get the current path of the behaviour
Since: 1.0
new
:: (HasCallStack, MonadIO m, IsAlpha a, IsPath b) | |
=> Maybe a | |
-> b | |
-> m BehaviourPath | Returns: a |
Deprecated: (Since version 1.6)
Creates a new path behaviour. You can use this behaviour to drive
actors along the nodes of a path, described by path
.
This will claim the floating reference on the Path
so you
do not need to unref if it.
If alpha
is not Nothing
, the Behaviour
will take ownership
of the Alpha
instance. In the case when alpha
is Nothing
,
it can be set later with behaviourSetAlpha
.
Since: 0.2
newWithDescription
behaviourPathNewWithDescription Source #
:: (HasCallStack, MonadIO m, IsAlpha a) | |
=> Maybe a | |
-> Text |
|
-> m BehaviourPath | Returns: a |
Deprecated: (Since version 1.6)
Creates a new path behaviour using the path described by desc
. See
pathAddString
for a description of the format.
If alpha
is not Nothing
, the Behaviour
will take ownership
of the Alpha
instance. In the case when alpha
is Nothing
,
it can be set later with behaviourSetAlpha
.
Since: 1.0
newWithKnots
behaviourPathNewWithKnots Source #
:: (HasCallStack, MonadIO m, IsAlpha a) | |
=> Maybe a | |
-> [Knot] |
|
-> m BehaviourPath | Returns: a |
Deprecated: (Since version 1.6)
Creates a new path behaviour that will make the actors visit all of the given knots in order with straight lines in between.
A path will be created where the first knot is used in a
PathNodeTypeMoveTo
and the subsequent knots are used in
PathNodeTypeLineTo
s.
If alpha
is not Nothing
, the Behaviour
will take ownership
of the Alpha
instance. In the case when alpha
is Nothing
,
it can be set later with behaviourSetAlpha
.
Since: 1.0
setPath
:: (HasCallStack, MonadIO m, IsBehaviourPath a, IsPath b) | |
=> a |
|
-> b |
|
-> m () |
Deprecated: (Since version 1.6)
Change the path that the actors will follow. This will take the
floating reference on the Path
so you do not need to unref
it.
Since: 1.0
Properties
path
No description available in the introspection data.
constructBehaviourPathPath :: (IsBehaviourPath o, MonadIO m, IsPath a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “path
” property. This is rarely needed directly, but it is used by new
.
getBehaviourPathPath :: (MonadIO m, IsBehaviourPath o) => o -> m Path Source #
Get the value of the “path
” property.
When overloading is enabled, this is equivalent to
get
behaviourPath #path
setBehaviourPathPath :: (MonadIO m, IsBehaviourPath o, IsPath a) => o -> a -> m () Source #
Set the value of the “path
” property.
When overloading is enabled, this is equivalent to
set
behaviourPath [ #path:=
value ]
Signals
knotReached
type BehaviourPathKnotReachedCallback Source #
Deprecated: (Since version 1.6)
This signal is emitted each time a node defined inside the path is reached.
Since: 0.2
afterBehaviourPathKnotReached :: (IsBehaviourPath a, MonadIO m) => a -> ((?self :: a) => BehaviourPathKnotReachedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the knotReached signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
behaviourPath #knotReached callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onBehaviourPathKnotReached :: (IsBehaviourPath a, MonadIO m) => a -> ((?self :: a) => BehaviourPathKnotReachedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the knotReached signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
behaviourPath #knotReached callback