{-# LANGUAGE TypeApplications #-}
#if (MIN_VERSION_haskell_gi_overloading(1,0,0) && !defined(__HADDOCK_VERSION__))
#define ENABLE_OVERLOADING
#endif
module GI.Pango.Structs.Analysis
(
Analysis(..) ,
newZeroAnalysis ,
#if defined(ENABLE_OVERLOADING)
ResolveAnalysisMethod ,
#endif
#if defined(ENABLE_OVERLOADING)
analysis_extraAttrs ,
#endif
clearAnalysisExtraAttrs ,
getAnalysisExtraAttrs ,
setAnalysisExtraAttrs ,
#if defined(ENABLE_OVERLOADING)
analysis_flags ,
#endif
getAnalysisFlags ,
setAnalysisFlags ,
#if defined(ENABLE_OVERLOADING)
analysis_font ,
#endif
clearAnalysisFont ,
getAnalysisFont ,
setAnalysisFont ,
#if defined(ENABLE_OVERLOADING)
analysis_gravity ,
#endif
getAnalysisGravity ,
setAnalysisGravity ,
#if defined(ENABLE_OVERLOADING)
analysis_langEngine ,
#endif
clearAnalysisLangEngine ,
getAnalysisLangEngine ,
setAnalysisLangEngine ,
#if defined(ENABLE_OVERLOADING)
analysis_language ,
#endif
clearAnalysisLanguage ,
getAnalysisLanguage ,
setAnalysisLanguage ,
#if defined(ENABLE_OVERLOADING)
analysis_level ,
#endif
getAnalysisLevel ,
setAnalysisLevel ,
#if defined(ENABLE_OVERLOADING)
analysis_script ,
#endif
getAnalysisScript ,
setAnalysisScript ,
#if defined(ENABLE_OVERLOADING)
analysis_shapeEngine ,
#endif
clearAnalysisShapeEngine ,
getAnalysisShapeEngine ,
setAnalysisShapeEngine ,
) 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.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
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.Text as T
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 {-# SOURCE #-} qualified GI.Pango.Objects.EngineLang as Pango.EngineLang
import {-# SOURCE #-} qualified GI.Pango.Objects.EngineShape as Pango.EngineShape
import {-# SOURCE #-} qualified GI.Pango.Objects.Font as Pango.Font
import {-# SOURCE #-} qualified GI.Pango.Structs.Language as Pango.Language
newtype Analysis = Analysis (SP.ManagedPtr Analysis)
deriving (Analysis -> Analysis -> Bool
(Analysis -> Analysis -> Bool)
-> (Analysis -> Analysis -> Bool) -> Eq Analysis
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Analysis -> Analysis -> Bool
$c/= :: Analysis -> Analysis -> Bool
== :: Analysis -> Analysis -> Bool
$c== :: Analysis -> Analysis -> Bool
Eq)
instance SP.ManagedPtrNewtype Analysis where
toManagedPtr :: Analysis -> ManagedPtr Analysis
toManagedPtr (Analysis ManagedPtr Analysis
p) = ManagedPtr Analysis
p
instance BoxedPtr Analysis where
boxedPtrCopy :: Analysis -> IO Analysis
boxedPtrCopy = \Analysis
p -> Analysis -> (Ptr Analysis -> IO Analysis) -> IO Analysis
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
B.ManagedPtr.withManagedPtr Analysis
p (Int -> Ptr Analysis -> IO (Ptr Analysis)
forall a. (HasCallStack, CallocPtr a) => Int -> Ptr a -> IO (Ptr a)
copyBytes Int
48 (Ptr Analysis -> IO (Ptr Analysis))
-> (Ptr Analysis -> IO Analysis) -> Ptr Analysis -> IO Analysis
forall (m :: * -> *) a b c.
Monad m =>
(a -> m b) -> (b -> m c) -> a -> m c
>=> (ManagedPtr Analysis -> Analysis) -> Ptr Analysis -> IO Analysis
forall a.
(HasCallStack, BoxedPtr a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
B.ManagedPtr.wrapPtr ManagedPtr Analysis -> Analysis
Analysis)
boxedPtrFree :: Analysis -> IO ()
boxedPtrFree = \Analysis
x -> Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
SP.withManagedPtr Analysis
x Ptr Analysis -> IO ()
forall a. Ptr a -> IO ()
SP.freeMem
instance CallocPtr Analysis where
boxedPtrCalloc :: IO (Ptr Analysis)
boxedPtrCalloc = Int -> IO (Ptr Analysis)
forall a. Int -> IO (Ptr a)
callocBytes Int
48
newZeroAnalysis :: MonadIO m => m Analysis
newZeroAnalysis :: m Analysis
newZeroAnalysis = IO Analysis -> m Analysis
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Analysis -> m Analysis) -> IO Analysis -> m Analysis
forall a b. (a -> b) -> a -> b
$ IO (Ptr Analysis)
forall a. CallocPtr a => IO (Ptr a)
boxedPtrCalloc IO (Ptr Analysis) -> (Ptr Analysis -> IO Analysis) -> IO Analysis
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= (ManagedPtr Analysis -> Analysis) -> Ptr Analysis -> IO Analysis
forall a.
(HasCallStack, BoxedPtr a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
wrapPtr ManagedPtr Analysis -> Analysis
Analysis
instance tag ~ 'AttrSet => Constructible Analysis tag where
new :: (ManagedPtr Analysis -> Analysis)
-> [AttrOp Analysis tag] -> m Analysis
new ManagedPtr Analysis -> Analysis
_ [AttrOp Analysis tag]
attrs = do
Analysis
o <- m Analysis
forall (m :: * -> *). MonadIO m => m Analysis
newZeroAnalysis
Analysis -> [AttrOp Analysis 'AttrSet] -> m ()
forall o (m :: * -> *).
MonadIO m =>
o -> [AttrOp o 'AttrSet] -> m ()
GI.Attributes.set Analysis
o [AttrOp Analysis tag]
[AttrOp Analysis 'AttrSet]
attrs
Analysis -> m Analysis
forall (m :: * -> *) a. Monad m => a -> m a
return Analysis
o
getAnalysisShapeEngine :: MonadIO m => Analysis -> m (Maybe Pango.EngineShape.EngineShape)
getAnalysisShapeEngine :: Analysis -> m (Maybe EngineShape)
getAnalysisShapeEngine Analysis
s = IO (Maybe EngineShape) -> m (Maybe EngineShape)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe EngineShape) -> m (Maybe EngineShape))
-> IO (Maybe EngineShape) -> m (Maybe EngineShape)
forall a b. (a -> b) -> a -> b
$ Analysis
-> (Ptr Analysis -> IO (Maybe EngineShape))
-> IO (Maybe EngineShape)
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO (Maybe EngineShape))
-> IO (Maybe EngineShape))
-> (Ptr Analysis -> IO (Maybe EngineShape))
-> IO (Maybe EngineShape)
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr EngineShape
val <- Ptr (Ptr EngineShape) -> IO (Ptr EngineShape)
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr EngineShape)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) :: IO (Ptr Pango.EngineShape.EngineShape)
Maybe EngineShape
result <- Ptr EngineShape
-> (Ptr EngineShape -> IO EngineShape) -> IO (Maybe EngineShape)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr EngineShape
val ((Ptr EngineShape -> IO EngineShape) -> IO (Maybe EngineShape))
-> (Ptr EngineShape -> IO EngineShape) -> IO (Maybe EngineShape)
forall a b. (a -> b) -> a -> b
$ \Ptr EngineShape
val' -> do
EngineShape
val'' <- ((ManagedPtr EngineShape -> EngineShape)
-> Ptr EngineShape -> IO EngineShape
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr EngineShape -> EngineShape
Pango.EngineShape.EngineShape) Ptr EngineShape
val'
EngineShape -> IO EngineShape
forall (m :: * -> *) a. Monad m => a -> m a
return EngineShape
val''
Maybe EngineShape -> IO (Maybe EngineShape)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe EngineShape
result
setAnalysisShapeEngine :: MonadIO m => Analysis -> Ptr Pango.EngineShape.EngineShape -> m ()
setAnalysisShapeEngine :: Analysis -> Ptr EngineShape -> m ()
setAnalysisShapeEngine Analysis
s Ptr EngineShape
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr EngineShape) -> Ptr EngineShape -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr EngineShape)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) (Ptr EngineShape
val :: Ptr Pango.EngineShape.EngineShape)
clearAnalysisShapeEngine :: MonadIO m => Analysis -> m ()
clearAnalysisShapeEngine :: Analysis -> m ()
clearAnalysisShapeEngine Analysis
s = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr EngineShape) -> Ptr EngineShape -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr EngineShape)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) (Ptr EngineShape
forall a. Ptr a
FP.nullPtr :: Ptr Pango.EngineShape.EngineShape)
#if defined(ENABLE_OVERLOADING)
data AnalysisShapeEngineFieldInfo
instance AttrInfo AnalysisShapeEngineFieldInfo where
type AttrBaseTypeConstraint AnalysisShapeEngineFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisShapeEngineFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint AnalysisShapeEngineFieldInfo = (~) (Ptr Pango.EngineShape.EngineShape)
type AttrTransferTypeConstraint AnalysisShapeEngineFieldInfo = (~)(Ptr Pango.EngineShape.EngineShape)
type AttrTransferType AnalysisShapeEngineFieldInfo = (Ptr Pango.EngineShape.EngineShape)
type AttrGetType AnalysisShapeEngineFieldInfo = Maybe Pango.EngineShape.EngineShape
type AttrLabel AnalysisShapeEngineFieldInfo = "shape_engine"
type AttrOrigin AnalysisShapeEngineFieldInfo = Analysis
attrGet = getAnalysisShapeEngine
attrSet = setAnalysisShapeEngine
attrConstruct = undefined
attrClear = clearAnalysisShapeEngine
attrTransfer _ v = do
return v
analysis_shapeEngine :: AttrLabelProxy "shapeEngine"
analysis_shapeEngine = AttrLabelProxy
#endif
getAnalysisLangEngine :: MonadIO m => Analysis -> m (Maybe Pango.EngineLang.EngineLang)
getAnalysisLangEngine :: Analysis -> m (Maybe EngineLang)
getAnalysisLangEngine Analysis
s = IO (Maybe EngineLang) -> m (Maybe EngineLang)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe EngineLang) -> m (Maybe EngineLang))
-> IO (Maybe EngineLang) -> m (Maybe EngineLang)
forall a b. (a -> b) -> a -> b
$ Analysis
-> (Ptr Analysis -> IO (Maybe EngineLang)) -> IO (Maybe EngineLang)
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO (Maybe EngineLang)) -> IO (Maybe EngineLang))
-> (Ptr Analysis -> IO (Maybe EngineLang)) -> IO (Maybe EngineLang)
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr EngineLang
val <- Ptr (Ptr EngineLang) -> IO (Ptr EngineLang)
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr EngineLang)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) :: IO (Ptr Pango.EngineLang.EngineLang)
Maybe EngineLang
result <- Ptr EngineLang
-> (Ptr EngineLang -> IO EngineLang) -> IO (Maybe EngineLang)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr EngineLang
val ((Ptr EngineLang -> IO EngineLang) -> IO (Maybe EngineLang))
-> (Ptr EngineLang -> IO EngineLang) -> IO (Maybe EngineLang)
forall a b. (a -> b) -> a -> b
$ \Ptr EngineLang
val' -> do
EngineLang
val'' <- ((ManagedPtr EngineLang -> EngineLang)
-> Ptr EngineLang -> IO EngineLang
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr EngineLang -> EngineLang
Pango.EngineLang.EngineLang) Ptr EngineLang
val'
EngineLang -> IO EngineLang
forall (m :: * -> *) a. Monad m => a -> m a
return EngineLang
val''
Maybe EngineLang -> IO (Maybe EngineLang)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe EngineLang
result
setAnalysisLangEngine :: MonadIO m => Analysis -> Ptr Pango.EngineLang.EngineLang -> m ()
setAnalysisLangEngine :: Analysis -> Ptr EngineLang -> m ()
setAnalysisLangEngine Analysis
s Ptr EngineLang
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr EngineLang) -> Ptr EngineLang -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr EngineLang)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) (Ptr EngineLang
val :: Ptr Pango.EngineLang.EngineLang)
clearAnalysisLangEngine :: MonadIO m => Analysis -> m ()
clearAnalysisLangEngine :: Analysis -> m ()
clearAnalysisLangEngine Analysis
s = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr EngineLang) -> Ptr EngineLang -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr EngineLang)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) (Ptr EngineLang
forall a. Ptr a
FP.nullPtr :: Ptr Pango.EngineLang.EngineLang)
#if defined(ENABLE_OVERLOADING)
data AnalysisLangEngineFieldInfo
instance AttrInfo AnalysisLangEngineFieldInfo where
type AttrBaseTypeConstraint AnalysisLangEngineFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisLangEngineFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint AnalysisLangEngineFieldInfo = (~) (Ptr Pango.EngineLang.EngineLang)
type AttrTransferTypeConstraint AnalysisLangEngineFieldInfo = (~)(Ptr Pango.EngineLang.EngineLang)
type AttrTransferType AnalysisLangEngineFieldInfo = (Ptr Pango.EngineLang.EngineLang)
type AttrGetType AnalysisLangEngineFieldInfo = Maybe Pango.EngineLang.EngineLang
type AttrLabel AnalysisLangEngineFieldInfo = "lang_engine"
type AttrOrigin AnalysisLangEngineFieldInfo = Analysis
attrGet = getAnalysisLangEngine
attrSet = setAnalysisLangEngine
attrConstruct = undefined
attrClear = clearAnalysisLangEngine
attrTransfer _ v = do
return v
analysis_langEngine :: AttrLabelProxy "langEngine"
analysis_langEngine = AttrLabelProxy
#endif
getAnalysisFont :: MonadIO m => Analysis -> m (Maybe Pango.Font.Font)
getAnalysisFont :: Analysis -> m (Maybe Font)
getAnalysisFont Analysis
s = IO (Maybe Font) -> m (Maybe Font)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe Font) -> m (Maybe Font))
-> IO (Maybe Font) -> m (Maybe Font)
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO (Maybe Font)) -> IO (Maybe Font)
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO (Maybe Font)) -> IO (Maybe Font))
-> (Ptr Analysis -> IO (Maybe Font)) -> IO (Maybe Font)
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr Font
val <- Ptr (Ptr Font) -> IO (Ptr Font)
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr Font)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) :: IO (Ptr Pango.Font.Font)
Maybe Font
result <- Ptr Font -> (Ptr Font -> IO Font) -> IO (Maybe Font)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr Font
val ((Ptr Font -> IO Font) -> IO (Maybe Font))
-> (Ptr Font -> IO Font) -> IO (Maybe Font)
forall a b. (a -> b) -> a -> b
$ \Ptr Font
val' -> do
Font
val'' <- ((ManagedPtr Font -> Font) -> Ptr Font -> IO Font
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr Font -> Font
Pango.Font.Font) Ptr Font
val'
Font -> IO Font
forall (m :: * -> *) a. Monad m => a -> m a
return Font
val''
Maybe Font -> IO (Maybe Font)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Font
result
setAnalysisFont :: MonadIO m => Analysis -> Ptr Pango.Font.Font -> m ()
setAnalysisFont :: Analysis -> Ptr Font -> m ()
setAnalysisFont Analysis
s Ptr Font
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr Font) -> Ptr Font -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr Font)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) (Ptr Font
val :: Ptr Pango.Font.Font)
clearAnalysisFont :: MonadIO m => Analysis -> m ()
clearAnalysisFont :: Analysis -> m ()
clearAnalysisFont Analysis
s = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr Font) -> Ptr Font -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr Font)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) (Ptr Font
forall a. Ptr a
FP.nullPtr :: Ptr Pango.Font.Font)
#if defined(ENABLE_OVERLOADING)
data AnalysisFontFieldInfo
instance AttrInfo AnalysisFontFieldInfo where
type AttrBaseTypeConstraint AnalysisFontFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisFontFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint AnalysisFontFieldInfo = (~) (Ptr Pango.Font.Font)
type AttrTransferTypeConstraint AnalysisFontFieldInfo = (~)(Ptr Pango.Font.Font)
type AttrTransferType AnalysisFontFieldInfo = (Ptr Pango.Font.Font)
type AttrGetType AnalysisFontFieldInfo = Maybe Pango.Font.Font
type AttrLabel AnalysisFontFieldInfo = "font"
type AttrOrigin AnalysisFontFieldInfo = Analysis
attrGet = getAnalysisFont
attrSet = setAnalysisFont
attrConstruct = undefined
attrClear = clearAnalysisFont
attrTransfer _ v = do
return v
analysis_font :: AttrLabelProxy "font"
analysis_font = AttrLabelProxy
#endif
getAnalysisLevel :: MonadIO m => Analysis -> m Word8
getAnalysisLevel :: Analysis -> m Word8
getAnalysisLevel Analysis
s = IO Word8 -> m Word8
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Word8 -> m Word8) -> IO Word8 -> m Word8
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO Word8) -> IO Word8
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO Word8) -> IO Word8)
-> (Ptr Analysis -> IO Word8) -> IO Word8
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Word8
val <- Ptr Word8 -> IO Word8
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24) :: IO Word8
Word8 -> IO Word8
forall (m :: * -> *) a. Monad m => a -> m a
return Word8
val
setAnalysisLevel :: MonadIO m => Analysis -> Word8 -> m ()
setAnalysisLevel :: Analysis -> Word8 -> m ()
setAnalysisLevel Analysis
s Word8
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr Word8 -> Word8 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24) (Word8
val :: Word8)
#if defined(ENABLE_OVERLOADING)
data AnalysisLevelFieldInfo
instance AttrInfo AnalysisLevelFieldInfo where
type AttrBaseTypeConstraint AnalysisLevelFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisLevelFieldInfo = '[ 'AttrSet, 'AttrGet]
type AttrSetTypeConstraint AnalysisLevelFieldInfo = (~) Word8
type AttrTransferTypeConstraint AnalysisLevelFieldInfo = (~)Word8
type AttrTransferType AnalysisLevelFieldInfo = Word8
type AttrGetType AnalysisLevelFieldInfo = Word8
type AttrLabel AnalysisLevelFieldInfo = "level"
type AttrOrigin AnalysisLevelFieldInfo = Analysis
attrGet = getAnalysisLevel
attrSet = setAnalysisLevel
attrConstruct = undefined
attrClear = undefined
attrTransfer _ v = do
return v
analysis_level :: AttrLabelProxy "level"
analysis_level = AttrLabelProxy
#endif
getAnalysisGravity :: MonadIO m => Analysis -> m Word8
getAnalysisGravity :: Analysis -> m Word8
getAnalysisGravity Analysis
s = IO Word8 -> m Word8
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Word8 -> m Word8) -> IO Word8 -> m Word8
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO Word8) -> IO Word8
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO Word8) -> IO Word8)
-> (Ptr Analysis -> IO Word8) -> IO Word8
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Word8
val <- Ptr Word8 -> IO Word8
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
25) :: IO Word8
Word8 -> IO Word8
forall (m :: * -> *) a. Monad m => a -> m a
return Word8
val
setAnalysisGravity :: MonadIO m => Analysis -> Word8 -> m ()
setAnalysisGravity :: Analysis -> Word8 -> m ()
setAnalysisGravity Analysis
s Word8
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr Word8 -> Word8 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
25) (Word8
val :: Word8)
#if defined(ENABLE_OVERLOADING)
data AnalysisGravityFieldInfo
instance AttrInfo AnalysisGravityFieldInfo where
type AttrBaseTypeConstraint AnalysisGravityFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisGravityFieldInfo = '[ 'AttrSet, 'AttrGet]
type AttrSetTypeConstraint AnalysisGravityFieldInfo = (~) Word8
type AttrTransferTypeConstraint AnalysisGravityFieldInfo = (~)Word8
type AttrTransferType AnalysisGravityFieldInfo = Word8
type AttrGetType AnalysisGravityFieldInfo = Word8
type AttrLabel AnalysisGravityFieldInfo = "gravity"
type AttrOrigin AnalysisGravityFieldInfo = Analysis
attrGet = getAnalysisGravity
attrSet = setAnalysisGravity
attrConstruct = undefined
attrClear = undefined
attrTransfer _ v = do
return v
analysis_gravity :: AttrLabelProxy "gravity"
analysis_gravity = AttrLabelProxy
#endif
getAnalysisFlags :: MonadIO m => Analysis -> m Word8
getAnalysisFlags :: Analysis -> m Word8
getAnalysisFlags Analysis
s = IO Word8 -> m Word8
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Word8 -> m Word8) -> IO Word8 -> m Word8
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO Word8) -> IO Word8
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO Word8) -> IO Word8)
-> (Ptr Analysis -> IO Word8) -> IO Word8
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Word8
val <- Ptr Word8 -> IO Word8
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
26) :: IO Word8
Word8 -> IO Word8
forall (m :: * -> *) a. Monad m => a -> m a
return Word8
val
setAnalysisFlags :: MonadIO m => Analysis -> Word8 -> m ()
setAnalysisFlags :: Analysis -> Word8 -> m ()
setAnalysisFlags Analysis
s Word8
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr Word8 -> Word8 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
26) (Word8
val :: Word8)
#if defined(ENABLE_OVERLOADING)
data AnalysisFlagsFieldInfo
instance AttrInfo AnalysisFlagsFieldInfo where
type AttrBaseTypeConstraint AnalysisFlagsFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisFlagsFieldInfo = '[ 'AttrSet, 'AttrGet]
type AttrSetTypeConstraint AnalysisFlagsFieldInfo = (~) Word8
type AttrTransferTypeConstraint AnalysisFlagsFieldInfo = (~)Word8
type AttrTransferType AnalysisFlagsFieldInfo = Word8
type AttrGetType AnalysisFlagsFieldInfo = Word8
type AttrLabel AnalysisFlagsFieldInfo = "flags"
type AttrOrigin AnalysisFlagsFieldInfo = Analysis
attrGet = getAnalysisFlags
attrSet = setAnalysisFlags
attrConstruct = undefined
attrClear = undefined
attrTransfer _ v = do
return v
analysis_flags :: AttrLabelProxy "flags"
analysis_flags = AttrLabelProxy
#endif
getAnalysisScript :: MonadIO m => Analysis -> m Word8
getAnalysisScript :: Analysis -> m Word8
getAnalysisScript Analysis
s = IO Word8 -> m Word8
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Word8 -> m Word8) -> IO Word8 -> m Word8
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO Word8) -> IO Word8
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO Word8) -> IO Word8)
-> (Ptr Analysis -> IO Word8) -> IO Word8
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Word8
val <- Ptr Word8 -> IO Word8
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
27) :: IO Word8
Word8 -> IO Word8
forall (m :: * -> *) a. Monad m => a -> m a
return Word8
val
setAnalysisScript :: MonadIO m => Analysis -> Word8 -> m ()
setAnalysisScript :: Analysis -> Word8 -> m ()
setAnalysisScript Analysis
s Word8
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr Word8 -> Word8 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr Word8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
27) (Word8
val :: Word8)
#if defined(ENABLE_OVERLOADING)
data AnalysisScriptFieldInfo
instance AttrInfo AnalysisScriptFieldInfo where
type AttrBaseTypeConstraint AnalysisScriptFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisScriptFieldInfo = '[ 'AttrSet, 'AttrGet]
type AttrSetTypeConstraint AnalysisScriptFieldInfo = (~) Word8
type AttrTransferTypeConstraint AnalysisScriptFieldInfo = (~)Word8
type AttrTransferType AnalysisScriptFieldInfo = Word8
type AttrGetType AnalysisScriptFieldInfo = Word8
type AttrLabel AnalysisScriptFieldInfo = "script"
type AttrOrigin AnalysisScriptFieldInfo = Analysis
attrGet = getAnalysisScript
attrSet = setAnalysisScript
attrConstruct = undefined
attrClear = undefined
attrTransfer _ v = do
return v
analysis_script :: AttrLabelProxy "script"
analysis_script = AttrLabelProxy
#endif
getAnalysisLanguage :: MonadIO m => Analysis -> m (Maybe Pango.Language.Language)
getAnalysisLanguage :: Analysis -> m (Maybe Language)
getAnalysisLanguage Analysis
s = IO (Maybe Language) -> m (Maybe Language)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe Language) -> m (Maybe Language))
-> IO (Maybe Language) -> m (Maybe Language)
forall a b. (a -> b) -> a -> b
$ Analysis
-> (Ptr Analysis -> IO (Maybe Language)) -> IO (Maybe Language)
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO (Maybe Language)) -> IO (Maybe Language))
-> (Ptr Analysis -> IO (Maybe Language)) -> IO (Maybe Language)
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr Language
val <- Ptr (Ptr Language) -> IO (Ptr Language)
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr Language)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) :: IO (Ptr Pango.Language.Language)
Maybe Language
result <- Ptr Language
-> (Ptr Language -> IO Language) -> IO (Maybe Language)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr Language
val ((Ptr Language -> IO Language) -> IO (Maybe Language))
-> (Ptr Language -> IO Language) -> IO (Maybe Language)
forall a b. (a -> b) -> a -> b
$ \Ptr Language
val' -> do
Language
val'' <- ((ManagedPtr Language -> Language) -> Ptr Language -> IO Language
forall a.
(HasCallStack, GBoxed a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
newBoxed ManagedPtr Language -> Language
Pango.Language.Language) Ptr Language
val'
Language -> IO Language
forall (m :: * -> *) a. Monad m => a -> m a
return Language
val''
Maybe Language -> IO (Maybe Language)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Language
result
setAnalysisLanguage :: MonadIO m => Analysis -> Ptr Pango.Language.Language -> m ()
setAnalysisLanguage :: Analysis -> Ptr Language -> m ()
setAnalysisLanguage Analysis
s Ptr Language
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr Language) -> Ptr Language -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr Language)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) (Ptr Language
val :: Ptr Pango.Language.Language)
clearAnalysisLanguage :: MonadIO m => Analysis -> m ()
clearAnalysisLanguage :: Analysis -> m ()
clearAnalysisLanguage Analysis
s = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr Language) -> Ptr Language -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr Language)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) (Ptr Language
forall a. Ptr a
FP.nullPtr :: Ptr Pango.Language.Language)
#if defined(ENABLE_OVERLOADING)
data AnalysisLanguageFieldInfo
instance AttrInfo AnalysisLanguageFieldInfo where
type AttrBaseTypeConstraint AnalysisLanguageFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisLanguageFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint AnalysisLanguageFieldInfo = (~) (Ptr Pango.Language.Language)
type AttrTransferTypeConstraint AnalysisLanguageFieldInfo = (~)(Ptr Pango.Language.Language)
type AttrTransferType AnalysisLanguageFieldInfo = (Ptr Pango.Language.Language)
type AttrGetType AnalysisLanguageFieldInfo = Maybe Pango.Language.Language
type AttrLabel AnalysisLanguageFieldInfo = "language"
type AttrOrigin AnalysisLanguageFieldInfo = Analysis
attrGet = getAnalysisLanguage
attrSet = setAnalysisLanguage
attrConstruct = undefined
attrClear = clearAnalysisLanguage
attrTransfer _ v = do
return v
analysis_language :: AttrLabelProxy "language"
analysis_language = AttrLabelProxy
#endif
getAnalysisExtraAttrs :: MonadIO m => Analysis -> m ([Ptr ()])
Analysis
s = IO [Ptr ()] -> m [Ptr ()]
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO [Ptr ()] -> m [Ptr ()]) -> IO [Ptr ()] -> m [Ptr ()]
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO [Ptr ()]) -> IO [Ptr ()]
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO [Ptr ()]) -> IO [Ptr ()])
-> (Ptr Analysis -> IO [Ptr ()]) -> IO [Ptr ()]
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (GSList (Ptr ()))
val <- Ptr (Ptr (GSList (Ptr ()))) -> IO (Ptr (GSList (Ptr ())))
forall a. Storable a => Ptr a -> IO a
peek (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr (GSList (Ptr ())))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
40) :: IO (Ptr (GSList (Ptr ())))
[Ptr ()]
val' <- Ptr (GSList (Ptr ())) -> IO [Ptr ()]
forall a. Ptr (GSList (Ptr a)) -> IO [Ptr a]
unpackGSList Ptr (GSList (Ptr ()))
val
[Ptr ()] -> IO [Ptr ()]
forall (m :: * -> *) a. Monad m => a -> m a
return [Ptr ()]
val'
setAnalysisExtraAttrs :: MonadIO m => Analysis -> Ptr (GSList (Ptr ())) -> m ()
Analysis
s Ptr (GSList (Ptr ()))
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr (GSList (Ptr ()))) -> Ptr (GSList (Ptr ())) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr (GSList (Ptr ())))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
40) (Ptr (GSList (Ptr ()))
val :: Ptr (GSList (Ptr ())))
clearAnalysisExtraAttrs :: MonadIO m => Analysis -> m ()
Analysis
s = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ Analysis -> (Ptr Analysis -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr Analysis
s ((Ptr Analysis -> IO ()) -> IO ())
-> (Ptr Analysis -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Analysis
ptr -> do
Ptr (Ptr (GSList (Ptr ()))) -> Ptr (GSList (Ptr ())) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Analysis
ptr Ptr Analysis -> Int -> Ptr (Ptr (GSList (Ptr ())))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
40) (Ptr (GSList (Ptr ()))
forall a. Ptr a
FP.nullPtr :: Ptr (GSList (Ptr ())))
#if defined(ENABLE_OVERLOADING)
data AnalysisExtraAttrsFieldInfo
instance AttrInfo AnalysisExtraAttrsFieldInfo where
type AttrBaseTypeConstraint AnalysisExtraAttrsFieldInfo = (~) Analysis
type AttrAllowedOps AnalysisExtraAttrsFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
type AttrSetTypeConstraint AnalysisExtraAttrsFieldInfo = (~) (Ptr (GSList (Ptr ())))
type AttrTransferTypeConstraint AnalysisExtraAttrsFieldInfo = (~)(Ptr (GSList (Ptr ())))
type AttrTransferType AnalysisExtraAttrsFieldInfo = (Ptr (GSList (Ptr ())))
type AttrGetType AnalysisExtraAttrsFieldInfo = [Ptr ()]
type AttrLabel AnalysisExtraAttrsFieldInfo = "extra_attrs"
type AttrOrigin AnalysisExtraAttrsFieldInfo = Analysis
attrGet = getAnalysisExtraAttrs
attrSet = setAnalysisExtraAttrs
attrConstruct = undefined
attrClear = clearAnalysisExtraAttrs
attrTransfer _ v = do
return v
analysis_extraAttrs :: AttrLabelProxy "extraAttrs"
analysis_extraAttrs = AttrLabelProxy
#endif
#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList Analysis
type instance O.AttributeList Analysis = AnalysisAttributeList
type AnalysisAttributeList = ('[ '("shapeEngine", AnalysisShapeEngineFieldInfo), '("langEngine", AnalysisLangEngineFieldInfo), '("font", AnalysisFontFieldInfo), '("level", AnalysisLevelFieldInfo), '("gravity", AnalysisGravityFieldInfo), '("flags", AnalysisFlagsFieldInfo), '("script", AnalysisScriptFieldInfo), '("language", AnalysisLanguageFieldInfo), '("extraAttrs", AnalysisExtraAttrsFieldInfo)] :: [(Symbol, *)])
#endif
#if defined(ENABLE_OVERLOADING)
type family ResolveAnalysisMethod (t :: Symbol) (o :: *) :: * where
ResolveAnalysisMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveAnalysisMethod t Analysis, O.MethodInfo info Analysis p) => OL.IsLabel t (Analysis -> p) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.overloadedMethod @info
#else
fromLabel _ = O.overloadedMethod @info
#endif
#endif