{-# LANGUAGE TypeApplications #-}
#if (MIN_VERSION_haskell_gi_overloading(1,0,0) && !defined(__HADDOCK_VERSION__))
#define ENABLE_OVERLOADING
#endif
module GI.GdkPixbuf.Structs.PixbufFormat
(
PixbufFormat(..) ,
newZeroPixbufFormat ,
#if defined(ENABLE_OVERLOADING)
ResolvePixbufFormatMethod ,
#endif
#if defined(ENABLE_OVERLOADING)
PixbufFormatCopyMethodInfo ,
#endif
pixbufFormatCopy ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatFreeMethodInfo ,
#endif
pixbufFormatFree ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatGetDescriptionMethodInfo ,
#endif
pixbufFormatGetDescription ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatGetExtensionsMethodInfo ,
#endif
pixbufFormatGetExtensions ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatGetLicenseMethodInfo ,
#endif
pixbufFormatGetLicense ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatGetMimeTypesMethodInfo ,
#endif
pixbufFormatGetMimeTypes ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatGetNameMethodInfo ,
#endif
pixbufFormatGetName ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatIsDisabledMethodInfo ,
#endif
pixbufFormatIsDisabled ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatIsSaveOptionSupportedMethodInfo,
#endif
pixbufFormatIsSaveOptionSupported ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatIsScalableMethodInfo ,
#endif
pixbufFormatIsScalable ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatIsWritableMethodInfo ,
#endif
pixbufFormatIsWritable ,
#if defined(ENABLE_OVERLOADING)
PixbufFormatSetDisabledMethodInfo ,
#endif
pixbufFormatSetDisabled ,
clearPixbufFormatDescription ,
getPixbufFormatDescription ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_description ,
#endif
setPixbufFormatDescription ,
getPixbufFormatDisabled ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_disabled ,
#endif
setPixbufFormatDisabled ,
clearPixbufFormatDomain ,
getPixbufFormatDomain ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_domain ,
#endif
setPixbufFormatDomain ,
clearPixbufFormatExtensions ,
getPixbufFormatExtensions ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_extensions ,
#endif
setPixbufFormatExtensions ,
getPixbufFormatFlags ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_flags ,
#endif
setPixbufFormatFlags ,
clearPixbufFormatLicense ,
getPixbufFormatLicense ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_license ,
#endif
setPixbufFormatLicense ,
clearPixbufFormatMimeTypes ,
getPixbufFormatMimeTypes ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_mimeTypes ,
#endif
setPixbufFormatMimeTypes ,
clearPixbufFormatName ,
getPixbufFormatName ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_name ,
#endif
setPixbufFormatName ,
clearPixbufFormatSignature ,
getPixbufFormatSignature ,
#if defined(ENABLE_OVERLOADING)
pixbufFormat_signature ,
#endif
setPixbufFormatSignature ,
) where
import Data.GI.Base.ShortPrelude
import qualified Data.GI.Base.ShortPrelude as SP
import qualified Data.GI.Base.Overloading as O
import qualified Prelude as P
import qualified Data.GI.Base.Attributes as GI.Attributes
import qualified Data.GI.Base.BasicTypes as B.Types
import qualified Data.GI.Base.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GArray as B.GArray
import qualified Data.GI.Base.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GHashTable as B.GHT
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GValue as B.GValue
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
import qualified Data.GI.Base.Properties as B.Properties
import qualified Data.GI.Base.Signals as B.Signals
import qualified Control.Monad.IO.Class as MIO
import qualified Data.Coerce as Coerce
import qualified Data.Text as T
import qualified Data.Kind as DK
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GHC.OverloadedLabels as OL
import qualified GHC.Records as R
import {-# SOURCE #-} qualified GI.GdkPixbuf.Structs.PixbufModulePattern as GdkPixbuf.PixbufModulePattern
newtype PixbufFormat = PixbufFormat (SP.ManagedPtr PixbufFormat)
deriving (PixbufFormat -> PixbufFormat -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PixbufFormat -> PixbufFormat -> Bool
$c/= :: PixbufFormat -> PixbufFormat -> Bool
== :: PixbufFormat -> PixbufFormat -> Bool
$c== :: PixbufFormat -> PixbufFormat -> Bool
Eq)
instance SP.ManagedPtrNewtype PixbufFormat where
toManagedPtr :: PixbufFormat -> ManagedPtr PixbufFormat
toManagedPtr (PixbufFormat ManagedPtr PixbufFormat
p) = ManagedPtr PixbufFormat
p
foreign import ccall "gdk_pixbuf_format_get_type" c_gdk_pixbuf_format_get_type ::
IO GType
type instance O.ParentTypes PixbufFormat = '[]
instance O.HasParentTypes PixbufFormat
instance B.Types.TypedObject PixbufFormat where
glibType :: IO GType
glibType = IO GType
c_gdk_pixbuf_format_get_type
instance B.Types.GBoxed PixbufFormat
instance B.GValue.IsGValue (Maybe PixbufFormat) where
gvalueGType_ :: IO GType
gvalueGType_ = IO GType
c_gdk_pixbuf_format_get_type
gvalueSet_ :: Ptr GValue -> Maybe PixbufFormat -> IO ()
gvalueSet_ Ptr GValue
gv Maybe PixbufFormat
P.Nothing = forall a. Ptr GValue -> Ptr a -> IO ()
B.GValue.set_boxed Ptr GValue
gv (forall a. Ptr a
FP.nullPtr :: FP.Ptr PixbufFormat)
gvalueSet_ Ptr GValue
gv (P.Just PixbufFormat
obj) = forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
B.ManagedPtr.withManagedPtr PixbufFormat
obj (forall a. Ptr GValue -> Ptr a -> IO ()
B.GValue.set_boxed Ptr GValue
gv)
gvalueGet_ :: Ptr GValue -> IO (Maybe PixbufFormat)
gvalueGet_ Ptr GValue
gv = do
Ptr PixbufFormat
ptr <- forall b. Ptr GValue -> IO (Ptr b)
B.GValue.get_boxed Ptr GValue
gv :: IO (Ptr PixbufFormat)
if Ptr PixbufFormat
ptr forall a. Eq a => a -> a -> Bool
/= forall a. Ptr a
FP.nullPtr
then forall a. a -> Maybe a
P.Just forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> forall a.
(HasCallStack, GBoxed a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
B.ManagedPtr.newBoxed ManagedPtr PixbufFormat -> PixbufFormat
PixbufFormat Ptr PixbufFormat
ptr
else forall (m :: * -> *) a. Monad m => a -> m a
return forall a. Maybe a
P.Nothing
newZeroPixbufFormat :: MonadIO m => m PixbufFormat
newZeroPixbufFormat :: forall (m :: * -> *). MonadIO m => m PixbufFormat
newZeroPixbufFormat = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a. GBoxed a => Int -> IO (Ptr a)
callocBoxedBytes Int
36 forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= forall a.
(HasCallStack, GBoxed a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
wrapBoxed ManagedPtr PixbufFormat -> PixbufFormat
PixbufFormat
instance tag ~ 'AttrSet => Constructible PixbufFormat tag where
new :: forall (m :: * -> *).
MonadIO m =>
(ManagedPtr PixbufFormat -> PixbufFormat)
-> [AttrOp PixbufFormat tag] -> m PixbufFormat
new ManagedPtr PixbufFormat -> PixbufFormat
_ [AttrOp PixbufFormat tag]
attrs = do
PixbufFormat
o <- forall (m :: * -> *). MonadIO m => m PixbufFormat
newZeroPixbufFormat
forall o (m :: * -> *).
MonadIO m =>
o -> [AttrOp o 'AttrSet] -> m ()
GI.Attributes.set PixbufFormat
o [AttrOp PixbufFormat tag]
attrs
forall (m :: * -> *) a. Monad m => a -> m a
return PixbufFormat
o
getPixbufFormatName :: MonadIO m => PixbufFormat -> m (Maybe T.Text)
getPixbufFormatName :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m (Maybe Text)
getPixbufFormatName PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
CString
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) :: IO CString
Maybe Text
result <- forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull CString
val forall a b. (a -> b) -> a -> b
$ \CString
val' -> do
Text
val'' <- HasCallStack => CString -> IO Text
cstringToText CString
val'
forall (m :: * -> *) a. Monad m => a -> m a
return Text
val''
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Text
result
setPixbufFormatName :: MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatName :: forall (m :: * -> *). MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatName PixbufFormat
s CString
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) (CString
val :: CString)
clearPixbufFormatName :: MonadIO m => PixbufFormat -> m ()
clearPixbufFormatName :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m ()
clearPixbufFormatName PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) (forall a. Ptr a
FP.nullPtr :: CString)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatNameFieldInfo
instance AttrInfo PixbufFormatNameFieldInfo where
type AttrBaseTypeConstraint PixbufFormatNameFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatNameFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint PixbufFormatNameFieldInfo = (~) CString
type AttrTransferTypeConstraint PixbufFormatNameFieldInfo = (~)CString
type AttrTransferType PixbufFormatNameFieldInfo = CString
type AttrGetType PixbufFormatNameFieldInfo = Maybe T.Text
type AttrLabel PixbufFormatNameFieldInfo = "name"
type AttrOrigin PixbufFormatNameFieldInfo = PixbufFormat
attrGet = getPixbufFormatName
attrSet = setPixbufFormatName
attrConstruct = undefined
attrClear = clearPixbufFormatName
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.name"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:name"
})
pixbufFormat_name :: AttrLabelProxy "name"
pixbufFormat_name = AttrLabelProxy
#endif
getPixbufFormatSignature :: MonadIO m => PixbufFormat -> m (Maybe GdkPixbuf.PixbufModulePattern.PixbufModulePattern)
getPixbufFormatSignature :: forall (m :: * -> *).
MonadIO m =>
PixbufFormat -> m (Maybe PixbufModulePattern)
getPixbufFormatSignature PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
Ptr PixbufModulePattern
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
4) :: IO (Ptr GdkPixbuf.PixbufModulePattern.PixbufModulePattern)
Maybe PixbufModulePattern
result <- forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr PixbufModulePattern
val forall a b. (a -> b) -> a -> b
$ \Ptr PixbufModulePattern
val' -> do
PixbufModulePattern
val'' <- (forall a.
(HasCallStack, BoxedPtr a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
newPtr ManagedPtr PixbufModulePattern -> PixbufModulePattern
GdkPixbuf.PixbufModulePattern.PixbufModulePattern) Ptr PixbufModulePattern
val'
forall (m :: * -> *) a. Monad m => a -> m a
return PixbufModulePattern
val''
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe PixbufModulePattern
result
setPixbufFormatSignature :: MonadIO m => PixbufFormat -> Ptr GdkPixbuf.PixbufModulePattern.PixbufModulePattern -> m ()
setPixbufFormatSignature :: forall (m :: * -> *).
MonadIO m =>
PixbufFormat -> Ptr PixbufModulePattern -> m ()
setPixbufFormatSignature PixbufFormat
s Ptr PixbufModulePattern
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
4) (Ptr PixbufModulePattern
val :: Ptr GdkPixbuf.PixbufModulePattern.PixbufModulePattern)
clearPixbufFormatSignature :: MonadIO m => PixbufFormat -> m ()
clearPixbufFormatSignature :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m ()
clearPixbufFormatSignature PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
4) (forall a. Ptr a
FP.nullPtr :: Ptr GdkPixbuf.PixbufModulePattern.PixbufModulePattern)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatSignatureFieldInfo
instance AttrInfo PixbufFormatSignatureFieldInfo where
type AttrBaseTypeConstraint PixbufFormatSignatureFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatSignatureFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint PixbufFormatSignatureFieldInfo = (~) (Ptr GdkPixbuf.PixbufModulePattern.PixbufModulePattern)
type AttrTransferTypeConstraint PixbufFormatSignatureFieldInfo = (~)(Ptr GdkPixbuf.PixbufModulePattern.PixbufModulePattern)
type AttrTransferType PixbufFormatSignatureFieldInfo = (Ptr GdkPixbuf.PixbufModulePattern.PixbufModulePattern)
type AttrGetType PixbufFormatSignatureFieldInfo = Maybe GdkPixbuf.PixbufModulePattern.PixbufModulePattern
type AttrLabel PixbufFormatSignatureFieldInfo = "signature"
type AttrOrigin PixbufFormatSignatureFieldInfo = PixbufFormat
attrGet = getPixbufFormatSignature
attrSet = setPixbufFormatSignature
attrConstruct = undefined
attrClear = clearPixbufFormatSignature
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.signature"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:signature"
})
pixbufFormat_signature :: AttrLabelProxy "signature"
pixbufFormat_signature = AttrLabelProxy
#endif
getPixbufFormatDomain :: MonadIO m => PixbufFormat -> m (Maybe T.Text)
getPixbufFormatDomain :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m (Maybe Text)
getPixbufFormatDomain PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
CString
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) :: IO CString
Maybe Text
result <- forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull CString
val forall a b. (a -> b) -> a -> b
$ \CString
val' -> do
Text
val'' <- HasCallStack => CString -> IO Text
cstringToText CString
val'
forall (m :: * -> *) a. Monad m => a -> m a
return Text
val''
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Text
result
setPixbufFormatDomain :: MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatDomain :: forall (m :: * -> *). MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatDomain PixbufFormat
s CString
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) (CString
val :: CString)
clearPixbufFormatDomain :: MonadIO m => PixbufFormat -> m ()
clearPixbufFormatDomain :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m ()
clearPixbufFormatDomain PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) (forall a. Ptr a
FP.nullPtr :: CString)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatDomainFieldInfo
instance AttrInfo PixbufFormatDomainFieldInfo where
type AttrBaseTypeConstraint PixbufFormatDomainFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatDomainFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint PixbufFormatDomainFieldInfo = (~) CString
type AttrTransferTypeConstraint PixbufFormatDomainFieldInfo = (~)CString
type AttrTransferType PixbufFormatDomainFieldInfo = CString
type AttrGetType PixbufFormatDomainFieldInfo = Maybe T.Text
type AttrLabel PixbufFormatDomainFieldInfo = "domain"
type AttrOrigin PixbufFormatDomainFieldInfo = PixbufFormat
attrGet = getPixbufFormatDomain
attrSet = setPixbufFormatDomain
attrConstruct = undefined
attrClear = clearPixbufFormatDomain
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.domain"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:domain"
})
pixbufFormat_domain :: AttrLabelProxy "domain"
pixbufFormat_domain = AttrLabelProxy
#endif
getPixbufFormatDescription :: MonadIO m => PixbufFormat -> m (Maybe T.Text)
getPixbufFormatDescription :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m (Maybe Text)
getPixbufFormatDescription PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
CString
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
12) :: IO CString
Maybe Text
result <- forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull CString
val forall a b. (a -> b) -> a -> b
$ \CString
val' -> do
Text
val'' <- HasCallStack => CString -> IO Text
cstringToText CString
val'
forall (m :: * -> *) a. Monad m => a -> m a
return Text
val''
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Text
result
setPixbufFormatDescription :: MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatDescription :: forall (m :: * -> *). MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatDescription PixbufFormat
s CString
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
12) (CString
val :: CString)
clearPixbufFormatDescription :: MonadIO m => PixbufFormat -> m ()
clearPixbufFormatDescription :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m ()
clearPixbufFormatDescription PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
12) (forall a. Ptr a
FP.nullPtr :: CString)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatDescriptionFieldInfo
instance AttrInfo PixbufFormatDescriptionFieldInfo where
type AttrBaseTypeConstraint PixbufFormatDescriptionFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatDescriptionFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint PixbufFormatDescriptionFieldInfo = (~) CString
type AttrTransferTypeConstraint PixbufFormatDescriptionFieldInfo = (~)CString
type AttrTransferType PixbufFormatDescriptionFieldInfo = CString
type AttrGetType PixbufFormatDescriptionFieldInfo = Maybe T.Text
type AttrLabel PixbufFormatDescriptionFieldInfo = "description"
type AttrOrigin PixbufFormatDescriptionFieldInfo = PixbufFormat
attrGet = getPixbufFormatDescription
attrSet = setPixbufFormatDescription
attrConstruct = undefined
attrClear = clearPixbufFormatDescription
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.description"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:description"
})
pixbufFormat_description :: AttrLabelProxy "description"
pixbufFormat_description = AttrLabelProxy
#endif
getPixbufFormatMimeTypes :: MonadIO m => PixbufFormat -> m (Maybe [T.Text])
getPixbufFormatMimeTypes :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m (Maybe [Text])
getPixbufFormatMimeTypes PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
Ptr CString
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) :: IO (Ptr CString)
Maybe [Text]
result <- forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr CString
val forall a b. (a -> b) -> a -> b
$ \Ptr CString
val' -> do
[Text]
val'' <- HasCallStack => Ptr CString -> IO [Text]
unpackZeroTerminatedUTF8CArray Ptr CString
val'
forall (m :: * -> *) a. Monad m => a -> m a
return [Text]
val''
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe [Text]
result
setPixbufFormatMimeTypes :: MonadIO m => PixbufFormat -> Ptr CString -> m ()
setPixbufFormatMimeTypes :: forall (m :: * -> *).
MonadIO m =>
PixbufFormat -> Ptr CString -> m ()
setPixbufFormatMimeTypes PixbufFormat
s Ptr CString
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) (Ptr CString
val :: Ptr CString)
clearPixbufFormatMimeTypes :: MonadIO m => PixbufFormat -> m ()
clearPixbufFormatMimeTypes :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m ()
clearPixbufFormatMimeTypes PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) (forall a. Ptr a
FP.nullPtr :: Ptr CString)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatMimeTypesFieldInfo
instance AttrInfo PixbufFormatMimeTypesFieldInfo where
type AttrBaseTypeConstraint PixbufFormatMimeTypesFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatMimeTypesFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint PixbufFormatMimeTypesFieldInfo = (~) (Ptr CString)
type AttrTransferTypeConstraint PixbufFormatMimeTypesFieldInfo = (~)(Ptr CString)
type AttrTransferType PixbufFormatMimeTypesFieldInfo = (Ptr CString)
type AttrGetType PixbufFormatMimeTypesFieldInfo = Maybe [T.Text]
type AttrLabel PixbufFormatMimeTypesFieldInfo = "mime_types"
type AttrOrigin PixbufFormatMimeTypesFieldInfo = PixbufFormat
attrGet = getPixbufFormatMimeTypes
attrSet = setPixbufFormatMimeTypes
attrConstruct = undefined
attrClear = clearPixbufFormatMimeTypes
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.mimeTypes"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:mimeTypes"
})
pixbufFormat_mimeTypes :: AttrLabelProxy "mimeTypes"
pixbufFormat_mimeTypes = AttrLabelProxy
#endif
getPixbufFormatExtensions :: MonadIO m => PixbufFormat -> m (Maybe [T.Text])
getPixbufFormatExtensions :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m (Maybe [Text])
getPixbufFormatExtensions PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
Ptr CString
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
20) :: IO (Ptr CString)
Maybe [Text]
result <- forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr CString
val forall a b. (a -> b) -> a -> b
$ \Ptr CString
val' -> do
[Text]
val'' <- HasCallStack => Ptr CString -> IO [Text]
unpackZeroTerminatedUTF8CArray Ptr CString
val'
forall (m :: * -> *) a. Monad m => a -> m a
return [Text]
val''
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe [Text]
result
setPixbufFormatExtensions :: MonadIO m => PixbufFormat -> Ptr CString -> m ()
setPixbufFormatExtensions :: forall (m :: * -> *).
MonadIO m =>
PixbufFormat -> Ptr CString -> m ()
setPixbufFormatExtensions PixbufFormat
s Ptr CString
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
20) (Ptr CString
val :: Ptr CString)
clearPixbufFormatExtensions :: MonadIO m => PixbufFormat -> m ()
clearPixbufFormatExtensions :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m ()
clearPixbufFormatExtensions PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
20) (forall a. Ptr a
FP.nullPtr :: Ptr CString)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatExtensionsFieldInfo
instance AttrInfo PixbufFormatExtensionsFieldInfo where
type AttrBaseTypeConstraint PixbufFormatExtensionsFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatExtensionsFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint PixbufFormatExtensionsFieldInfo = (~) (Ptr CString)
type AttrTransferTypeConstraint PixbufFormatExtensionsFieldInfo = (~)(Ptr CString)
type AttrTransferType PixbufFormatExtensionsFieldInfo = (Ptr CString)
type AttrGetType PixbufFormatExtensionsFieldInfo = Maybe [T.Text]
type AttrLabel PixbufFormatExtensionsFieldInfo = "extensions"
type AttrOrigin PixbufFormatExtensionsFieldInfo = PixbufFormat
attrGet = getPixbufFormatExtensions
attrSet = setPixbufFormatExtensions
attrConstruct = undefined
attrClear = clearPixbufFormatExtensions
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.extensions"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:extensions"
})
pixbufFormat_extensions :: AttrLabelProxy "extensions"
pixbufFormat_extensions = AttrLabelProxy
#endif
getPixbufFormatFlags :: MonadIO m => PixbufFormat -> m Word32
getPixbufFormatFlags :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m Word32
getPixbufFormatFlags PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
Word32
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24) :: IO Word32
forall (m :: * -> *) a. Monad m => a -> m a
return Word32
val
setPixbufFormatFlags :: MonadIO m => PixbufFormat -> Word32 -> m ()
setPixbufFormatFlags :: forall (m :: * -> *). MonadIO m => PixbufFormat -> Word32 -> m ()
setPixbufFormatFlags PixbufFormat
s Word32
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24) (Word32
val :: Word32)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatFlagsFieldInfo
instance AttrInfo PixbufFormatFlagsFieldInfo where
type AttrBaseTypeConstraint PixbufFormatFlagsFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatFlagsFieldInfo = '[ 'AttrSet, 'AttrGet]
type AttrSetTypeConstraint PixbufFormatFlagsFieldInfo = (~) Word32
type AttrTransferTypeConstraint PixbufFormatFlagsFieldInfo = (~)Word32
type AttrTransferType PixbufFormatFlagsFieldInfo = Word32
type AttrGetType PixbufFormatFlagsFieldInfo = Word32
type AttrLabel PixbufFormatFlagsFieldInfo = "flags"
type AttrOrigin PixbufFormatFlagsFieldInfo = PixbufFormat
attrGet = getPixbufFormatFlags
attrSet = setPixbufFormatFlags
attrConstruct = undefined
attrClear = undefined
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.flags"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:flags"
})
pixbufFormat_flags :: AttrLabelProxy "flags"
pixbufFormat_flags = AttrLabelProxy
#endif
getPixbufFormatDisabled :: MonadIO m => PixbufFormat -> m Bool
getPixbufFormatDisabled :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m Bool
getPixbufFormatDisabled PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
CInt
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
28) :: IO CInt
let val' :: Bool
val' = (forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
val
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
val'
setPixbufFormatDisabled :: MonadIO m => PixbufFormat -> Bool -> m ()
setPixbufFormatDisabled :: forall (m :: * -> *). MonadIO m => PixbufFormat -> Bool -> m ()
setPixbufFormatDisabled PixbufFormat
s Bool
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
let val' :: CInt
val' = (forall a b. (Integral a, Num b) => a -> b
P.fromIntegral forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall a. Enum a => a -> Int
P.fromEnum) Bool
val
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
28) (CInt
val' :: CInt)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatDisabledFieldInfo
instance AttrInfo PixbufFormatDisabledFieldInfo where
type AttrBaseTypeConstraint PixbufFormatDisabledFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatDisabledFieldInfo = '[ 'AttrSet, 'AttrGet]
type AttrSetTypeConstraint PixbufFormatDisabledFieldInfo = (~) Bool
type AttrTransferTypeConstraint PixbufFormatDisabledFieldInfo = (~)Bool
type AttrTransferType PixbufFormatDisabledFieldInfo = Bool
type AttrGetType PixbufFormatDisabledFieldInfo = Bool
type AttrLabel PixbufFormatDisabledFieldInfo = "disabled"
type AttrOrigin PixbufFormatDisabledFieldInfo = PixbufFormat
attrGet = getPixbufFormatDisabled
attrSet = setPixbufFormatDisabled
attrConstruct = undefined
attrClear = undefined
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.disabled"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:disabled"
})
pixbufFormat_disabled :: AttrLabelProxy "disabled"
pixbufFormat_disabled = AttrLabelProxy
#endif
getPixbufFormatLicense :: MonadIO m => PixbufFormat -> m (Maybe T.Text)
getPixbufFormatLicense :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m (Maybe Text)
getPixbufFormatLicense PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
CString
val <- forall a. Storable a => Ptr a -> IO a
peek (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) :: IO CString
Maybe Text
result <- forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull CString
val forall a b. (a -> b) -> a -> b
$ \CString
val' -> do
Text
val'' <- HasCallStack => CString -> IO Text
cstringToText CString
val'
forall (m :: * -> *) a. Monad m => a -> m a
return Text
val''
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Text
result
setPixbufFormatLicense :: MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatLicense :: forall (m :: * -> *). MonadIO m => PixbufFormat -> CString -> m ()
setPixbufFormatLicense PixbufFormat
s CString
val = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) (CString
val :: CString)
clearPixbufFormatLicense :: MonadIO m => PixbufFormat -> m ()
clearPixbufFormatLicense :: forall (m :: * -> *). MonadIO m => PixbufFormat -> m ()
clearPixbufFormatLicense PixbufFormat
s = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr PixbufFormat
s forall a b. (a -> b) -> a -> b
$ \Ptr PixbufFormat
ptr -> do
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr PixbufFormat
ptr forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) (forall a. Ptr a
FP.nullPtr :: CString)
#if defined(ENABLE_OVERLOADING)
data PixbufFormatLicenseFieldInfo
instance AttrInfo PixbufFormatLicenseFieldInfo where
type AttrBaseTypeConstraint PixbufFormatLicenseFieldInfo = (~) PixbufFormat
type AttrAllowedOps PixbufFormatLicenseFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint PixbufFormatLicenseFieldInfo = (~) CString
type AttrTransferTypeConstraint PixbufFormatLicenseFieldInfo = (~)CString
type AttrTransferType PixbufFormatLicenseFieldInfo = CString
type AttrGetType PixbufFormatLicenseFieldInfo = Maybe T.Text
type AttrLabel PixbufFormatLicenseFieldInfo = "license"
type AttrOrigin PixbufFormatLicenseFieldInfo = PixbufFormat
attrGet = getPixbufFormatLicense
attrSet = setPixbufFormatLicense
attrConstruct = undefined
attrClear = clearPixbufFormatLicense
attrTransfer _ v = do
return v
dbgAttrInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.license"
, O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#g:attr:license"
})
pixbufFormat_license :: AttrLabelProxy "license"
pixbufFormat_license = AttrLabelProxy
#endif
#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList PixbufFormat
type instance O.AttributeList PixbufFormat = PixbufFormatAttributeList
type PixbufFormatAttributeList = ('[ '("name", PixbufFormatNameFieldInfo), '("signature", PixbufFormatSignatureFieldInfo), '("domain", PixbufFormatDomainFieldInfo), '("description", PixbufFormatDescriptionFieldInfo), '("mimeTypes", PixbufFormatMimeTypesFieldInfo), '("extensions", PixbufFormatExtensionsFieldInfo), '("flags", PixbufFormatFlagsFieldInfo), '("disabled", PixbufFormatDisabledFieldInfo), '("license", PixbufFormatLicenseFieldInfo)] :: [(Symbol, DK.Type)])
#endif
foreign import ccall "gdk_pixbuf_format_copy" gdk_pixbuf_format_copy ::
Ptr PixbufFormat ->
IO (Ptr PixbufFormat)
pixbufFormatCopy ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m PixbufFormat
pixbufFormatCopy :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m PixbufFormat
pixbufFormatCopy PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
Ptr PixbufFormat
result <- Ptr PixbufFormat -> IO (Ptr PixbufFormat)
gdk_pixbuf_format_copy Ptr PixbufFormat
format'
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"pixbufFormatCopy" Ptr PixbufFormat
result
PixbufFormat
result' <- (forall a.
(HasCallStack, GBoxed a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
wrapBoxed ManagedPtr PixbufFormat -> PixbufFormat
PixbufFormat) Ptr PixbufFormat
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return PixbufFormat
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatCopyMethodInfo
instance (signature ~ (m PixbufFormat), MonadIO m) => O.OverloadedMethod PixbufFormatCopyMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatCopy
instance O.OverloadedMethodInfo PixbufFormatCopyMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatCopy",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatCopy"
})
#endif
foreign import ccall "gdk_pixbuf_format_free" gdk_pixbuf_format_free ::
Ptr PixbufFormat ->
IO ()
pixbufFormatFree ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m ()
pixbufFormatFree :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m ()
pixbufFormatFree PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
Ptr PixbufFormat -> IO ()
gdk_pixbuf_format_free Ptr PixbufFormat
format'
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data PixbufFormatFreeMethodInfo
instance (signature ~ (m ()), MonadIO m) => O.OverloadedMethod PixbufFormatFreeMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatFree
instance O.OverloadedMethodInfo PixbufFormatFreeMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatFree",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatFree"
})
#endif
foreign import ccall "gdk_pixbuf_format_get_description" gdk_pixbuf_format_get_description ::
Ptr PixbufFormat ->
IO CString
pixbufFormatGetDescription ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m T.Text
pixbufFormatGetDescription :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m Text
pixbufFormatGetDescription PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
CString
result <- Ptr PixbufFormat -> IO CString
gdk_pixbuf_format_get_description Ptr PixbufFormat
format'
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"pixbufFormatGetDescription" CString
result
Text
result' <- HasCallStack => CString -> IO Text
cstringToText CString
result
forall a. Ptr a -> IO ()
freeMem CString
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return Text
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatGetDescriptionMethodInfo
instance (signature ~ (m T.Text), MonadIO m) => O.OverloadedMethod PixbufFormatGetDescriptionMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatGetDescription
instance O.OverloadedMethodInfo PixbufFormatGetDescriptionMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatGetDescription",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatGetDescription"
})
#endif
foreign import ccall "gdk_pixbuf_format_get_extensions" gdk_pixbuf_format_get_extensions ::
Ptr PixbufFormat ->
IO (Ptr CString)
pixbufFormatGetExtensions ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m [T.Text]
pixbufFormatGetExtensions :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m [Text]
pixbufFormatGetExtensions PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
Ptr CString
result <- Ptr PixbufFormat -> IO (Ptr CString)
gdk_pixbuf_format_get_extensions Ptr PixbufFormat
format'
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"pixbufFormatGetExtensions" Ptr CString
result
[Text]
result' <- HasCallStack => Ptr CString -> IO [Text]
unpackZeroTerminatedUTF8CArray Ptr CString
result
forall a b. (Ptr a -> IO b) -> Ptr (Ptr a) -> IO ()
mapZeroTerminatedCArray forall a. Ptr a -> IO ()
freeMem Ptr CString
result
forall a. Ptr a -> IO ()
freeMem Ptr CString
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return [Text]
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatGetExtensionsMethodInfo
instance (signature ~ (m [T.Text]), MonadIO m) => O.OverloadedMethod PixbufFormatGetExtensionsMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatGetExtensions
instance O.OverloadedMethodInfo PixbufFormatGetExtensionsMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatGetExtensions",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatGetExtensions"
})
#endif
foreign import ccall "gdk_pixbuf_format_get_license" gdk_pixbuf_format_get_license ::
Ptr PixbufFormat ->
IO CString
pixbufFormatGetLicense ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m T.Text
pixbufFormatGetLicense :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m Text
pixbufFormatGetLicense PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
CString
result <- Ptr PixbufFormat -> IO CString
gdk_pixbuf_format_get_license Ptr PixbufFormat
format'
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"pixbufFormatGetLicense" CString
result
Text
result' <- HasCallStack => CString -> IO Text
cstringToText CString
result
forall a. Ptr a -> IO ()
freeMem CString
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return Text
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatGetLicenseMethodInfo
instance (signature ~ (m T.Text), MonadIO m) => O.OverloadedMethod PixbufFormatGetLicenseMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatGetLicense
instance O.OverloadedMethodInfo PixbufFormatGetLicenseMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatGetLicense",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatGetLicense"
})
#endif
foreign import ccall "gdk_pixbuf_format_get_mime_types" gdk_pixbuf_format_get_mime_types ::
Ptr PixbufFormat ->
IO (Ptr CString)
pixbufFormatGetMimeTypes ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m [T.Text]
pixbufFormatGetMimeTypes :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m [Text]
pixbufFormatGetMimeTypes PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
Ptr CString
result <- Ptr PixbufFormat -> IO (Ptr CString)
gdk_pixbuf_format_get_mime_types Ptr PixbufFormat
format'
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"pixbufFormatGetMimeTypes" Ptr CString
result
[Text]
result' <- HasCallStack => Ptr CString -> IO [Text]
unpackZeroTerminatedUTF8CArray Ptr CString
result
forall a b. (Ptr a -> IO b) -> Ptr (Ptr a) -> IO ()
mapZeroTerminatedCArray forall a. Ptr a -> IO ()
freeMem Ptr CString
result
forall a. Ptr a -> IO ()
freeMem Ptr CString
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return [Text]
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatGetMimeTypesMethodInfo
instance (signature ~ (m [T.Text]), MonadIO m) => O.OverloadedMethod PixbufFormatGetMimeTypesMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatGetMimeTypes
instance O.OverloadedMethodInfo PixbufFormatGetMimeTypesMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatGetMimeTypes",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatGetMimeTypes"
})
#endif
foreign import ccall "gdk_pixbuf_format_get_name" gdk_pixbuf_format_get_name ::
Ptr PixbufFormat ->
IO CString
pixbufFormatGetName ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m T.Text
pixbufFormatGetName :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m Text
pixbufFormatGetName PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
CString
result <- Ptr PixbufFormat -> IO CString
gdk_pixbuf_format_get_name Ptr PixbufFormat
format'
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"pixbufFormatGetName" CString
result
Text
result' <- HasCallStack => CString -> IO Text
cstringToText CString
result
forall a. Ptr a -> IO ()
freeMem CString
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return Text
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatGetNameMethodInfo
instance (signature ~ (m T.Text), MonadIO m) => O.OverloadedMethod PixbufFormatGetNameMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatGetName
instance O.OverloadedMethodInfo PixbufFormatGetNameMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatGetName",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatGetName"
})
#endif
foreign import ccall "gdk_pixbuf_format_is_disabled" gdk_pixbuf_format_is_disabled ::
Ptr PixbufFormat ->
IO CInt
pixbufFormatIsDisabled ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m Bool
pixbufFormatIsDisabled :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m Bool
pixbufFormatIsDisabled PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
CInt
result <- Ptr PixbufFormat -> IO CInt
gdk_pixbuf_format_is_disabled Ptr PixbufFormat
format'
let result' :: Bool
result' = (forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatIsDisabledMethodInfo
instance (signature ~ (m Bool), MonadIO m) => O.OverloadedMethod PixbufFormatIsDisabledMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatIsDisabled
instance O.OverloadedMethodInfo PixbufFormatIsDisabledMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatIsDisabled",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatIsDisabled"
})
#endif
foreign import ccall "gdk_pixbuf_format_is_save_option_supported" gdk_pixbuf_format_is_save_option_supported ::
Ptr PixbufFormat ->
CString ->
IO CInt
pixbufFormatIsSaveOptionSupported ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> T.Text
-> m Bool
pixbufFormatIsSaveOptionSupported :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> Text -> m Bool
pixbufFormatIsSaveOptionSupported PixbufFormat
format Text
optionKey = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
CString
optionKey' <- Text -> IO CString
textToCString Text
optionKey
CInt
result <- Ptr PixbufFormat -> CString -> IO CInt
gdk_pixbuf_format_is_save_option_supported Ptr PixbufFormat
format' CString
optionKey'
let result' :: Bool
result' = (forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall a. Ptr a -> IO ()
freeMem CString
optionKey'
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatIsSaveOptionSupportedMethodInfo
instance (signature ~ (T.Text -> m Bool), MonadIO m) => O.OverloadedMethod PixbufFormatIsSaveOptionSupportedMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatIsSaveOptionSupported
instance O.OverloadedMethodInfo PixbufFormatIsSaveOptionSupportedMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatIsSaveOptionSupported",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatIsSaveOptionSupported"
})
#endif
foreign import ccall "gdk_pixbuf_format_is_scalable" gdk_pixbuf_format_is_scalable ::
Ptr PixbufFormat ->
IO CInt
pixbufFormatIsScalable ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m Bool
pixbufFormatIsScalable :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m Bool
pixbufFormatIsScalable PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
CInt
result <- Ptr PixbufFormat -> IO CInt
gdk_pixbuf_format_is_scalable Ptr PixbufFormat
format'
let result' :: Bool
result' = (forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatIsScalableMethodInfo
instance (signature ~ (m Bool), MonadIO m) => O.OverloadedMethod PixbufFormatIsScalableMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatIsScalable
instance O.OverloadedMethodInfo PixbufFormatIsScalableMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatIsScalable",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatIsScalable"
})
#endif
foreign import ccall "gdk_pixbuf_format_is_writable" gdk_pixbuf_format_is_writable ::
Ptr PixbufFormat ->
IO CInt
pixbufFormatIsWritable ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> m Bool
pixbufFormatIsWritable :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> m Bool
pixbufFormatIsWritable PixbufFormat
format = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
CInt
result <- Ptr PixbufFormat -> IO CInt
gdk_pixbuf_format_is_writable Ptr PixbufFormat
format'
let result' :: Bool
result' = (forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'
#if defined(ENABLE_OVERLOADING)
data PixbufFormatIsWritableMethodInfo
instance (signature ~ (m Bool), MonadIO m) => O.OverloadedMethod PixbufFormatIsWritableMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatIsWritable
instance O.OverloadedMethodInfo PixbufFormatIsWritableMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatIsWritable",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatIsWritable"
})
#endif
foreign import ccall "gdk_pixbuf_format_set_disabled" gdk_pixbuf_format_set_disabled ::
Ptr PixbufFormat ->
CInt ->
IO ()
pixbufFormatSetDisabled ::
(B.CallStack.HasCallStack, MonadIO m) =>
PixbufFormat
-> Bool
-> m ()
pixbufFormatSetDisabled :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
PixbufFormat -> Bool -> m ()
pixbufFormatSetDisabled PixbufFormat
format Bool
disabled = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
Ptr PixbufFormat
format' <- forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr PixbufFormat
format
let disabled' :: CInt
disabled' = (forall a b. (Integral a, Num b) => a -> b
P.fromIntegral forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall a. Enum a => a -> Int
P.fromEnum) Bool
disabled
Ptr PixbufFormat -> CInt -> IO ()
gdk_pixbuf_format_set_disabled Ptr PixbufFormat
format' CInt
disabled'
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr PixbufFormat
format
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data PixbufFormatSetDisabledMethodInfo
instance (signature ~ (Bool -> m ()), MonadIO m) => O.OverloadedMethod PixbufFormatSetDisabledMethodInfo PixbufFormat signature where
overloadedMethod = pixbufFormatSetDisabled
instance O.OverloadedMethodInfo PixbufFormatSetDisabledMethodInfo PixbufFormat where
overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
O.resolvedSymbolName = "GI.GdkPixbuf.Structs.PixbufFormat.pixbufFormatSetDisabled",
O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-gdkpixbuf-2.0.29/docs/GI-GdkPixbuf-Structs-PixbufFormat.html#v:pixbufFormatSetDisabled"
})
#endif
#if defined(ENABLE_OVERLOADING)
type family ResolvePixbufFormatMethod (t :: Symbol) (o :: DK.Type) :: DK.Type where
ResolvePixbufFormatMethod "copy" o = PixbufFormatCopyMethodInfo
ResolvePixbufFormatMethod "free" o = PixbufFormatFreeMethodInfo
ResolvePixbufFormatMethod "isDisabled" o = PixbufFormatIsDisabledMethodInfo
ResolvePixbufFormatMethod "isSaveOptionSupported" o = PixbufFormatIsSaveOptionSupportedMethodInfo
ResolvePixbufFormatMethod "isScalable" o = PixbufFormatIsScalableMethodInfo
ResolvePixbufFormatMethod "isWritable" o = PixbufFormatIsWritableMethodInfo
ResolvePixbufFormatMethod "getDescription" o = PixbufFormatGetDescriptionMethodInfo
ResolvePixbufFormatMethod "getExtensions" o = PixbufFormatGetExtensionsMethodInfo
ResolvePixbufFormatMethod "getLicense" o = PixbufFormatGetLicenseMethodInfo
ResolvePixbufFormatMethod "getMimeTypes" o = PixbufFormatGetMimeTypesMethodInfo
ResolvePixbufFormatMethod "getName" o = PixbufFormatGetNameMethodInfo
ResolvePixbufFormatMethod "setDisabled" o = PixbufFormatSetDisabledMethodInfo
ResolvePixbufFormatMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolvePixbufFormatMethod t PixbufFormat, O.OverloadedMethod info PixbufFormat p) => OL.IsLabel t (PixbufFormat -> p) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.overloadedMethod @info
#else
fromLabel _ = O.overloadedMethod @info
#endif
#if MIN_VERSION_base(4,13,0)
instance (info ~ ResolvePixbufFormatMethod t PixbufFormat, O.OverloadedMethod info PixbufFormat p, R.HasField t PixbufFormat p) => R.HasField t PixbufFormat p where
getField = O.overloadedMethod @info
#endif
instance (info ~ ResolvePixbufFormatMethod t PixbufFormat, O.OverloadedMethodInfo info PixbufFormat) => OL.IsLabel t (O.MethodProxy info PixbufFormat) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.MethodProxy
#else
fromLabel _ = O.MethodProxy
#endif
#endif