{-# LINE 2 "./Graphics/UI/Gtk/Gdk/PixbufAnimation.chs" #-}
module Graphics.UI.Gtk.Gdk.PixbufAnimation (
PixbufAnimation,
PixbufAnimationClass,
castToPixbufAnimation, gTypePixbufAnimation,
toPixbufAnimation,
PixbufAnimationIter,
PixbufAnimationIterClass,
castToPixbufAnimationIter, gTypePixbufAnimationIter,
toPixbufAnimationIter,
PixbufSimpleAnim,
PixbufSimpleAnimClass,
castToPixbufSimpleAnim, gTypePixbufSimpleAnim,
toPixbufSimpleAnim,
pixbufAnimationNewFromFile,
pixbufSimpleAnimNew,
pixbufAnimationGetWidth,
pixbufAnimationGetHeight,
pixbufAnimationGetIter,
pixbufAnimationIsStaticImage,
pixbufAnimationGetStaticImage,
pixbufAnimationIterAdvance,
pixbufAnimationIterGetDelayTime,
pixbufAnimationIterOnCurrentlyLoadingFrame,
pixbufAnimationIterGetPixbuf,
pixbufSimpleAnimAddFrame,
pixbufSimpleAnimSetLoop,
pixbufSimpleAnimGetLoop
) where
import Control.Monad (liftM)
import System.Glib.FFI
import System.Glib.UTFString
import System.Glib.GDateTime
import System.Glib.GObject
import Graphics.UI.Gtk.Types
{-# LINE 83 "./Graphics/UI/Gtk/Gdk/PixbufAnimation.chs" #-}
import System.Glib.GError (propagateGError)
{-# LINE 86 "./Graphics/UI/Gtk/Gdk/PixbufAnimation.chs" #-}
pixbufAnimationNewFromFile :: GlibFilePath fp
=> fp
-> IO PixbufAnimation
pixbufAnimationNewFromFile :: forall fp. GlibFilePath fp => fp -> IO PixbufAnimation
pixbufAnimationNewFromFile fp
fname =
(ForeignPtr PixbufAnimation -> PixbufAnimation,
FinalizerPtr PixbufAnimation)
-> IO (Ptr PixbufAnimation) -> IO PixbufAnimation
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
wrapNewGObject (ForeignPtr PixbufAnimation -> PixbufAnimation,
FinalizerPtr PixbufAnimation)
forall {a}.
(ForeignPtr PixbufAnimation -> PixbufAnimation, FinalizerPtr a)
mkPixbufAnimation (IO (Ptr PixbufAnimation) -> IO PixbufAnimation)
-> IO (Ptr PixbufAnimation) -> IO PixbufAnimation
forall a b. (a -> b) -> a -> b
$
(Ptr (Ptr ()) -> IO (Ptr PixbufAnimation))
-> IO (Ptr PixbufAnimation)
forall a. (Ptr (Ptr ()) -> IO a) -> IO a
propagateGError ((Ptr (Ptr ()) -> IO (Ptr PixbufAnimation))
-> IO (Ptr PixbufAnimation))
-> (Ptr (Ptr ()) -> IO (Ptr PixbufAnimation))
-> IO (Ptr PixbufAnimation)
forall a b. (a -> b) -> a -> b
$ \Ptr (Ptr ())
errPtrPtr ->
fp
-> (CString -> IO (Ptr PixbufAnimation))
-> IO (Ptr PixbufAnimation)
forall a. fp -> (CString -> IO a) -> IO a
forall fp a. GlibFilePath fp => fp -> (CString -> IO a) -> IO a
withUTFFilePath fp
fname ((CString -> IO (Ptr PixbufAnimation)) -> IO (Ptr PixbufAnimation))
-> (CString -> IO (Ptr PixbufAnimation))
-> IO (Ptr PixbufAnimation)
forall a b. (a -> b) -> a -> b
$ \CString
strPtr ->
CString -> Ptr (Ptr ()) -> IO (Ptr PixbufAnimation)
gdk_pixbuf_animation_new_from_file CString
strPtr Ptr (Ptr ())
errPtrPtr
pixbufAnimationGetWidth :: PixbufAnimation
-> IO Int
pixbufAnimationGetWidth :: PixbufAnimation -> IO Int
pixbufAnimationGetWidth PixbufAnimation
self = (CInt -> Int) -> IO CInt -> IO Int
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral (IO CInt -> IO Int) -> IO CInt -> IO Int
forall a b. (a -> b) -> a -> b
$ (\(PixbufAnimation ForeignPtr PixbufAnimation
arg1) -> ForeignPtr PixbufAnimation
-> (Ptr PixbufAnimation -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimation
arg1 ((Ptr PixbufAnimation -> IO CInt) -> IO CInt)
-> (Ptr PixbufAnimation -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimation
argPtr1 ->Ptr PixbufAnimation -> IO CInt
gdk_pixbuf_animation_get_width Ptr PixbufAnimation
argPtr1) PixbufAnimation
self
pixbufAnimationGetHeight :: PixbufAnimation
-> IO Int
pixbufAnimationGetHeight :: PixbufAnimation -> IO Int
pixbufAnimationGetHeight PixbufAnimation
self = (CInt -> Int) -> IO CInt -> IO Int
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral (IO CInt -> IO Int) -> IO CInt -> IO Int
forall a b. (a -> b) -> a -> b
$ (\(PixbufAnimation ForeignPtr PixbufAnimation
arg1) -> ForeignPtr PixbufAnimation
-> (Ptr PixbufAnimation -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimation
arg1 ((Ptr PixbufAnimation -> IO CInt) -> IO CInt)
-> (Ptr PixbufAnimation -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimation
argPtr1 ->Ptr PixbufAnimation -> IO CInt
gdk_pixbuf_animation_get_height Ptr PixbufAnimation
argPtr1) PixbufAnimation
self
pixbufAnimationGetIter :: PixbufAnimation
-> Maybe GTimeVal
-> IO PixbufAnimationIter
pixbufAnimationGetIter :: PixbufAnimation -> Maybe GTimeVal -> IO PixbufAnimationIter
pixbufAnimationGetIter PixbufAnimation
self Maybe GTimeVal
tv = (GTimeVal
-> (Ptr GTimeVal -> IO PixbufAnimationIter)
-> IO PixbufAnimationIter)
-> Maybe GTimeVal
-> (Ptr GTimeVal -> IO PixbufAnimationIter)
-> IO PixbufAnimationIter
forall a b c.
(a -> (Ptr b -> IO c) -> IO c)
-> Maybe a -> (Ptr b -> IO c) -> IO c
maybeWith GTimeVal
-> (Ptr GTimeVal -> IO PixbufAnimationIter)
-> IO PixbufAnimationIter
forall a b. Storable a => a -> (Ptr a -> IO b) -> IO b
with Maybe GTimeVal
tv ((Ptr GTimeVal -> IO PixbufAnimationIter)
-> IO PixbufAnimationIter)
-> (Ptr GTimeVal -> IO PixbufAnimationIter)
-> IO PixbufAnimationIter
forall a b. (a -> b) -> a -> b
$ \Ptr GTimeVal
stPtr ->
(ForeignPtr PixbufAnimationIter -> PixbufAnimationIter,
FinalizerPtr PixbufAnimationIter)
-> IO (Ptr PixbufAnimationIter) -> IO PixbufAnimationIter
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
wrapNewGObject (ForeignPtr PixbufAnimationIter -> PixbufAnimationIter,
FinalizerPtr PixbufAnimationIter)
forall {a}.
(ForeignPtr PixbufAnimationIter -> PixbufAnimationIter,
FinalizerPtr a)
mkPixbufAnimationIter (IO (Ptr PixbufAnimationIter) -> IO PixbufAnimationIter)
-> IO (Ptr PixbufAnimationIter) -> IO PixbufAnimationIter
forall a b. (a -> b) -> a -> b
$
(\(PixbufAnimation ForeignPtr PixbufAnimation
arg1) Ptr ()
arg2 -> ForeignPtr PixbufAnimation
-> (Ptr PixbufAnimation -> IO (Ptr PixbufAnimationIter))
-> IO (Ptr PixbufAnimationIter)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimation
arg1 ((Ptr PixbufAnimation -> IO (Ptr PixbufAnimationIter))
-> IO (Ptr PixbufAnimationIter))
-> (Ptr PixbufAnimation -> IO (Ptr PixbufAnimationIter))
-> IO (Ptr PixbufAnimationIter)
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimation
argPtr1 ->Ptr PixbufAnimation -> Ptr () -> IO (Ptr PixbufAnimationIter)
gdk_pixbuf_animation_get_iter Ptr PixbufAnimation
argPtr1 Ptr ()
arg2) PixbufAnimation
self (Ptr GTimeVal -> Ptr ()
forall a b. Ptr a -> Ptr b
castPtr Ptr GTimeVal
stPtr)
pixbufAnimationIsStaticImage :: PixbufAnimation
-> IO Bool
pixbufAnimationIsStaticImage :: PixbufAnimation -> IO Bool
pixbufAnimationIsStaticImage PixbufAnimation
self = (CInt -> Bool) -> IO CInt -> IO Bool
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Bool
forall a. (Eq a, Num a) => a -> Bool
toBool (IO CInt -> IO Bool) -> IO CInt -> IO Bool
forall a b. (a -> b) -> a -> b
$ (\(PixbufAnimation ForeignPtr PixbufAnimation
arg1) -> ForeignPtr PixbufAnimation
-> (Ptr PixbufAnimation -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimation
arg1 ((Ptr PixbufAnimation -> IO CInt) -> IO CInt)
-> (Ptr PixbufAnimation -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimation
argPtr1 ->Ptr PixbufAnimation -> IO CInt
gdk_pixbuf_animation_is_static_image Ptr PixbufAnimation
argPtr1) PixbufAnimation
self
pixbufAnimationGetStaticImage :: PixbufAnimation
-> IO (Maybe Pixbuf)
pixbufAnimationGetStaticImage :: PixbufAnimation -> IO (Maybe Pixbuf)
pixbufAnimationGetStaticImage PixbufAnimation
self =
(IO (Ptr Pixbuf) -> IO Pixbuf)
-> IO (Ptr Pixbuf) -> IO (Maybe Pixbuf)
forall a. (IO (Ptr a) -> IO a) -> IO (Ptr a) -> IO (Maybe a)
maybeNull ((ForeignPtr Pixbuf -> Pixbuf, FinalizerPtr Pixbuf)
-> IO (Ptr Pixbuf) -> IO Pixbuf
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
makeNewGObject (ForeignPtr Pixbuf -> Pixbuf, FinalizerPtr Pixbuf)
forall {a}. (ForeignPtr Pixbuf -> Pixbuf, FinalizerPtr a)
mkPixbuf) (IO (Ptr Pixbuf) -> IO (Maybe Pixbuf))
-> IO (Ptr Pixbuf) -> IO (Maybe Pixbuf)
forall a b. (a -> b) -> a -> b
$ (\(PixbufAnimation ForeignPtr PixbufAnimation
arg1) -> ForeignPtr PixbufAnimation
-> (Ptr PixbufAnimation -> IO (Ptr Pixbuf)) -> IO (Ptr Pixbuf)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimation
arg1 ((Ptr PixbufAnimation -> IO (Ptr Pixbuf)) -> IO (Ptr Pixbuf))
-> (Ptr PixbufAnimation -> IO (Ptr Pixbuf)) -> IO (Ptr Pixbuf)
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimation
argPtr1 ->Ptr PixbufAnimation -> IO (Ptr Pixbuf)
gdk_pixbuf_animation_get_static_image Ptr PixbufAnimation
argPtr1) PixbufAnimation
self
pixbufAnimationIterAdvance :: PixbufAnimationIter
-> Maybe GTimeVal
-> IO Bool
pixbufAnimationIterAdvance :: PixbufAnimationIter -> Maybe GTimeVal -> IO Bool
pixbufAnimationIterAdvance PixbufAnimationIter
iter Maybe GTimeVal
currentTime = (CInt -> Bool) -> IO CInt -> IO Bool
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Bool
forall a. (Eq a, Num a) => a -> Bool
toBool (IO CInt -> IO Bool) -> IO CInt -> IO Bool
forall a b. (a -> b) -> a -> b
$ (GTimeVal -> (Ptr GTimeVal -> IO CInt) -> IO CInt)
-> Maybe GTimeVal -> (Ptr GTimeVal -> IO CInt) -> IO CInt
forall a b c.
(a -> (Ptr b -> IO c) -> IO c)
-> Maybe a -> (Ptr b -> IO c) -> IO c
maybeWith GTimeVal -> (Ptr GTimeVal -> IO CInt) -> IO CInt
forall a b. Storable a => a -> (Ptr a -> IO b) -> IO b
with Maybe GTimeVal
currentTime ((Ptr GTimeVal -> IO CInt) -> IO CInt)
-> (Ptr GTimeVal -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr GTimeVal
tvPtr ->
(\(PixbufAnimationIter ForeignPtr PixbufAnimationIter
arg1) Ptr ()
arg2 -> ForeignPtr PixbufAnimationIter
-> (Ptr PixbufAnimationIter -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimationIter
arg1 ((Ptr PixbufAnimationIter -> IO CInt) -> IO CInt)
-> (Ptr PixbufAnimationIter -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimationIter
argPtr1 ->Ptr PixbufAnimationIter -> Ptr () -> IO CInt
gdk_pixbuf_animation_iter_advance Ptr PixbufAnimationIter
argPtr1 Ptr ()
arg2) PixbufAnimationIter
iter (Ptr GTimeVal -> Ptr ()
forall a b. Ptr a -> Ptr b
castPtr Ptr GTimeVal
tvPtr)
pixbufAnimationIterGetDelayTime :: PixbufAnimationIter
-> IO Int
pixbufAnimationIterGetDelayTime :: PixbufAnimationIter -> IO Int
pixbufAnimationIterGetDelayTime PixbufAnimationIter
self = (CInt -> Int) -> IO CInt -> IO Int
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral (IO CInt -> IO Int) -> IO CInt -> IO Int
forall a b. (a -> b) -> a -> b
$
(\(PixbufAnimationIter ForeignPtr PixbufAnimationIter
arg1) -> ForeignPtr PixbufAnimationIter
-> (Ptr PixbufAnimationIter -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimationIter
arg1 ((Ptr PixbufAnimationIter -> IO CInt) -> IO CInt)
-> (Ptr PixbufAnimationIter -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimationIter
argPtr1 ->Ptr PixbufAnimationIter -> IO CInt
gdk_pixbuf_animation_iter_get_delay_time Ptr PixbufAnimationIter
argPtr1) PixbufAnimationIter
self
pixbufAnimationIterOnCurrentlyLoadingFrame :: PixbufAnimationIter
-> IO Bool
pixbufAnimationIterOnCurrentlyLoadingFrame :: PixbufAnimationIter -> IO Bool
pixbufAnimationIterOnCurrentlyLoadingFrame PixbufAnimationIter
iter = (CInt -> Bool) -> IO CInt -> IO Bool
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Bool
forall a. (Eq a, Num a) => a -> Bool
toBool (IO CInt -> IO Bool) -> IO CInt -> IO Bool
forall a b. (a -> b) -> a -> b
$
(\(PixbufAnimationIter ForeignPtr PixbufAnimationIter
arg1) -> ForeignPtr PixbufAnimationIter
-> (Ptr PixbufAnimationIter -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimationIter
arg1 ((Ptr PixbufAnimationIter -> IO CInt) -> IO CInt)
-> (Ptr PixbufAnimationIter -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimationIter
argPtr1 ->Ptr PixbufAnimationIter -> IO CInt
gdk_pixbuf_animation_iter_on_currently_loading_frame Ptr PixbufAnimationIter
argPtr1) PixbufAnimationIter
iter
pixbufAnimationIterGetPixbuf :: PixbufAnimationIter
-> IO Pixbuf
pixbufAnimationIterGetPixbuf :: PixbufAnimationIter -> IO Pixbuf
pixbufAnimationIterGetPixbuf PixbufAnimationIter
iter = (ForeignPtr Pixbuf -> Pixbuf, FinalizerPtr Pixbuf)
-> IO (Ptr Pixbuf) -> IO Pixbuf
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
makeNewGObject (ForeignPtr Pixbuf -> Pixbuf, FinalizerPtr Pixbuf)
forall {a}. (ForeignPtr Pixbuf -> Pixbuf, FinalizerPtr a)
mkPixbuf (IO (Ptr Pixbuf) -> IO Pixbuf) -> IO (Ptr Pixbuf) -> IO Pixbuf
forall a b. (a -> b) -> a -> b
$
(\(PixbufAnimationIter ForeignPtr PixbufAnimationIter
arg1) -> ForeignPtr PixbufAnimationIter
-> (Ptr PixbufAnimationIter -> IO (Ptr Pixbuf)) -> IO (Ptr Pixbuf)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufAnimationIter
arg1 ((Ptr PixbufAnimationIter -> IO (Ptr Pixbuf)) -> IO (Ptr Pixbuf))
-> (Ptr PixbufAnimationIter -> IO (Ptr Pixbuf)) -> IO (Ptr Pixbuf)
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufAnimationIter
argPtr1 ->Ptr PixbufAnimationIter -> IO (Ptr Pixbuf)
gdk_pixbuf_animation_iter_get_pixbuf Ptr PixbufAnimationIter
argPtr1) PixbufAnimationIter
iter
pixbufSimpleAnimNew :: Int
-> Int
-> Float
-> IO PixbufSimpleAnim
pixbufSimpleAnimNew :: Int -> Int -> Float -> IO PixbufSimpleAnim
pixbufSimpleAnimNew Int
width Int
height Float
rate = (ForeignPtr PixbufSimpleAnim -> PixbufSimpleAnim,
FinalizerPtr PixbufSimpleAnim)
-> IO (Ptr PixbufSimpleAnim) -> IO PixbufSimpleAnim
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
wrapNewGObject (ForeignPtr PixbufSimpleAnim -> PixbufSimpleAnim,
FinalizerPtr PixbufSimpleAnim)
forall {a}.
(ForeignPtr PixbufSimpleAnim -> PixbufSimpleAnim, FinalizerPtr a)
mkPixbufSimpleAnim (IO (Ptr PixbufSimpleAnim) -> IO PixbufSimpleAnim)
-> IO (Ptr PixbufSimpleAnim) -> IO PixbufSimpleAnim
forall a b. (a -> b) -> a -> b
$
CInt -> CInt -> CFloat -> IO (Ptr PixbufSimpleAnim)
gdk_pixbuf_simple_anim_new (Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral Int
width) (Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral Int
height) (Float -> CFloat
forall a b. (Real a, Fractional b) => a -> b
realToFrac Float
rate)
pixbufSimpleAnimAddFrame :: PixbufSimpleAnim
-> Pixbuf
-> IO ()
pixbufSimpleAnimAddFrame :: PixbufSimpleAnim -> Pixbuf -> IO ()
pixbufSimpleAnimAddFrame PixbufSimpleAnim
psa Pixbuf
pb = (\(PixbufSimpleAnim ForeignPtr PixbufSimpleAnim
arg1) (Pixbuf ForeignPtr Pixbuf
arg2) -> ForeignPtr PixbufSimpleAnim
-> (Ptr PixbufSimpleAnim -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufSimpleAnim
arg1 ((Ptr PixbufSimpleAnim -> IO ()) -> IO ())
-> (Ptr PixbufSimpleAnim -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufSimpleAnim
argPtr1 ->ForeignPtr Pixbuf -> (Ptr Pixbuf -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Pixbuf
arg2 ((Ptr Pixbuf -> IO ()) -> IO ()) -> (Ptr Pixbuf -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Pixbuf
argPtr2 ->Ptr PixbufSimpleAnim -> Ptr Pixbuf -> IO ()
gdk_pixbuf_simple_anim_add_frame Ptr PixbufSimpleAnim
argPtr1 Ptr Pixbuf
argPtr2) PixbufSimpleAnim
psa Pixbuf
pb
pixbufSimpleAnimSetLoop :: PixbufSimpleAnim
-> Bool
-> IO ()
pixbufSimpleAnimSetLoop :: PixbufSimpleAnim -> Bool -> IO ()
pixbufSimpleAnimSetLoop PixbufSimpleAnim
animation Bool
loop = (\(PixbufSimpleAnim ForeignPtr PixbufSimpleAnim
arg1) CInt
arg2 -> ForeignPtr PixbufSimpleAnim
-> (Ptr PixbufSimpleAnim -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufSimpleAnim
arg1 ((Ptr PixbufSimpleAnim -> IO ()) -> IO ())
-> (Ptr PixbufSimpleAnim -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufSimpleAnim
argPtr1 ->Ptr PixbufSimpleAnim -> CInt -> IO ()
gdk_pixbuf_simple_anim_set_loop Ptr PixbufSimpleAnim
argPtr1 CInt
arg2) PixbufSimpleAnim
animation (Bool -> CInt
forall a. Num a => Bool -> a
fromBool Bool
loop)
pixbufSimpleAnimGetLoop :: PixbufSimpleAnim
-> IO Bool
pixbufSimpleAnimGetLoop :: PixbufSimpleAnim -> IO Bool
pixbufSimpleAnimGetLoop PixbufSimpleAnim
animation = (CInt -> Bool) -> IO CInt -> IO Bool
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Bool
forall a. (Eq a, Num a) => a -> Bool
toBool (IO CInt -> IO Bool) -> IO CInt -> IO Bool
forall a b. (a -> b) -> a -> b
$ (\(PixbufSimpleAnim ForeignPtr PixbufSimpleAnim
arg1) -> ForeignPtr PixbufSimpleAnim
-> (Ptr PixbufSimpleAnim -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr PixbufSimpleAnim
arg1 ((Ptr PixbufSimpleAnim -> IO CInt) -> IO CInt)
-> (Ptr PixbufSimpleAnim -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr PixbufSimpleAnim
argPtr1 ->Ptr PixbufSimpleAnim -> IO CInt
gdk_pixbuf_simple_anim_get_loop Ptr PixbufSimpleAnim
argPtr1) PixbufSimpleAnim
animation
foreign import ccall unsafe "gdk_pixbuf_animation_new_from_file"
gdk_pixbuf_animation_new_from_file :: ((Ptr CChar) -> ((Ptr (Ptr ())) -> (IO (Ptr PixbufAnimation))))
foreign import ccall unsafe "gdk_pixbuf_animation_get_width"
gdk_pixbuf_animation_get_width :: ((Ptr PixbufAnimation) -> (IO CInt))
foreign import ccall unsafe "gdk_pixbuf_animation_get_height"
gdk_pixbuf_animation_get_height :: ((Ptr PixbufAnimation) -> (IO CInt))
foreign import ccall unsafe "gdk_pixbuf_animation_get_iter"
gdk_pixbuf_animation_get_iter :: ((Ptr PixbufAnimation) -> ((Ptr ()) -> (IO (Ptr PixbufAnimationIter))))
foreign import ccall unsafe "gdk_pixbuf_animation_is_static_image"
gdk_pixbuf_animation_is_static_image :: ((Ptr PixbufAnimation) -> (IO CInt))
foreign import ccall unsafe "gdk_pixbuf_animation_get_static_image"
gdk_pixbuf_animation_get_static_image :: ((Ptr PixbufAnimation) -> (IO (Ptr Pixbuf)))
foreign import ccall unsafe "gdk_pixbuf_animation_iter_advance"
gdk_pixbuf_animation_iter_advance :: ((Ptr PixbufAnimationIter) -> ((Ptr ()) -> (IO CInt)))
foreign import ccall unsafe "gdk_pixbuf_animation_iter_get_delay_time"
gdk_pixbuf_animation_iter_get_delay_time :: ((Ptr PixbufAnimationIter) -> (IO CInt))
foreign import ccall unsafe "gdk_pixbuf_animation_iter_on_currently_loading_frame"
gdk_pixbuf_animation_iter_on_currently_loading_frame :: ((Ptr PixbufAnimationIter) -> (IO CInt))
foreign import ccall unsafe "gdk_pixbuf_animation_iter_get_pixbuf"
gdk_pixbuf_animation_iter_get_pixbuf :: ((Ptr PixbufAnimationIter) -> (IO (Ptr Pixbuf)))
foreign import ccall unsafe "gdk_pixbuf_simple_anim_new"
gdk_pixbuf_simple_anim_new :: (CInt -> (CInt -> (CFloat -> (IO (Ptr PixbufSimpleAnim)))))
foreign import ccall unsafe "gdk_pixbuf_simple_anim_add_frame"
gdk_pixbuf_simple_anim_add_frame :: ((Ptr PixbufSimpleAnim) -> ((Ptr Pixbuf) -> (IO ())))
foreign import ccall unsafe "gdk_pixbuf_simple_anim_set_loop"
gdk_pixbuf_simple_anim_set_loop :: ((Ptr PixbufSimpleAnim) -> (CInt -> (IO ())))
foreign import ccall unsafe "gdk_pixbuf_simple_anim_get_loop"
gdk_pixbuf_simple_anim_get_loop :: ((Ptr PixbufSimpleAnim) -> (IO CInt))