#define ENABLE_OVERLOADING (MIN_VERSION_haskell_gi_overloading(1,0,0) \
&& !defined(__HADDOCK_VERSION__))
module GI.Pango.Objects.FontsetSimple
(
FontsetSimple(..) ,
IsFontsetSimple ,
toFontsetSimple ,
noFontsetSimple ,
#if ENABLE_OVERLOADING
FontsetSimpleAppendMethodInfo ,
#endif
fontsetSimpleAppend ,
fontsetSimpleNew ,
#if ENABLE_OVERLOADING
FontsetSimpleSizeMethodInfo ,
#endif
fontsetSimpleSize ,
) 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.ManagedPtr as B.ManagedPtr
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.Text as T
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GI.GObject.Objects.Object as GObject.Object
import {-# SOURCE #-} qualified GI.Pango.Objects.Font as Pango.Font
import {-# SOURCE #-} qualified GI.Pango.Objects.Fontset as Pango.Fontset
import {-# SOURCE #-} qualified GI.Pango.Structs.Language as Pango.Language
newtype FontsetSimple = FontsetSimple (ManagedPtr FontsetSimple)
foreign import ccall "pango_fontset_simple_get_type"
c_pango_fontset_simple_get_type :: IO GType
instance GObject FontsetSimple where
gobjectType _ = c_pango_fontset_simple_get_type
class GObject o => IsFontsetSimple o
#if MIN_VERSION_base(4,9,0)
instance {-# OVERLAPPABLE #-} (GObject a, O.UnknownAncestorError FontsetSimple a) =>
IsFontsetSimple a
#endif
instance IsFontsetSimple FontsetSimple
instance Pango.Fontset.IsFontset FontsetSimple
instance GObject.Object.IsObject FontsetSimple
toFontsetSimple :: (MonadIO m, IsFontsetSimple o) => o -> m FontsetSimple
toFontsetSimple = liftIO . unsafeCastTo FontsetSimple
noFontsetSimple :: Maybe FontsetSimple
noFontsetSimple = Nothing
#if ENABLE_OVERLOADING
type family ResolveFontsetSimpleMethod (t :: Symbol) (o :: *) :: * where
ResolveFontsetSimpleMethod "append" o = FontsetSimpleAppendMethodInfo
ResolveFontsetSimpleMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
ResolveFontsetSimpleMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
ResolveFontsetSimpleMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
ResolveFontsetSimpleMethod "foreach" o = Pango.Fontset.FontsetForeachMethodInfo
ResolveFontsetSimpleMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
ResolveFontsetSimpleMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
ResolveFontsetSimpleMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
ResolveFontsetSimpleMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
ResolveFontsetSimpleMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
ResolveFontsetSimpleMethod "ref" o = GObject.Object.ObjectRefMethodInfo
ResolveFontsetSimpleMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
ResolveFontsetSimpleMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
ResolveFontsetSimpleMethod "size" o = FontsetSimpleSizeMethodInfo
ResolveFontsetSimpleMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
ResolveFontsetSimpleMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
ResolveFontsetSimpleMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
ResolveFontsetSimpleMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
ResolveFontsetSimpleMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
ResolveFontsetSimpleMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
ResolveFontsetSimpleMethod "getFont" o = Pango.Fontset.FontsetGetFontMethodInfo
ResolveFontsetSimpleMethod "getMetrics" o = Pango.Fontset.FontsetGetMetricsMethodInfo
ResolveFontsetSimpleMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
ResolveFontsetSimpleMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
ResolveFontsetSimpleMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
ResolveFontsetSimpleMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
ResolveFontsetSimpleMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveFontsetSimpleMethod t FontsetSimple, O.MethodInfo info FontsetSimple p) => O.IsLabelProxy t (FontsetSimple -> p) where
fromLabelProxy _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#if MIN_VERSION_base(4,9,0)
instance (info ~ ResolveFontsetSimpleMethod t FontsetSimple, O.MethodInfo info FontsetSimple p) => O.IsLabel t (FontsetSimple -> p) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#else
fromLabel _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#endif
#endif
#endif
#if ENABLE_OVERLOADING
instance O.HasAttributeList FontsetSimple
type instance O.AttributeList FontsetSimple = FontsetSimpleAttributeList
type FontsetSimpleAttributeList = ('[ ] :: [(Symbol, *)])
#endif
#if ENABLE_OVERLOADING
#endif
#if ENABLE_OVERLOADING
type instance O.SignalList FontsetSimple = FontsetSimpleSignalList
type FontsetSimpleSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo)] :: [(Symbol, *)])
#endif
foreign import ccall "pango_fontset_simple_new" pango_fontset_simple_new ::
Ptr Pango.Language.Language ->
IO (Ptr FontsetSimple)
fontsetSimpleNew ::
(B.CallStack.HasCallStack, MonadIO m) =>
Pango.Language.Language
-> m FontsetSimple
fontsetSimpleNew language = liftIO $ do
language' <- unsafeManagedPtrGetPtr language
result <- pango_fontset_simple_new language'
checkUnexpectedReturnNULL "fontsetSimpleNew" result
result' <- (wrapObject FontsetSimple) result
touchManagedPtr language
return result'
#if ENABLE_OVERLOADING
#endif
foreign import ccall "pango_fontset_simple_append" pango_fontset_simple_append ::
Ptr FontsetSimple ->
Ptr Pango.Font.Font ->
IO ()
fontsetSimpleAppend ::
(B.CallStack.HasCallStack, MonadIO m, IsFontsetSimple a, Pango.Font.IsFont b) =>
a
-> b
-> m ()
fontsetSimpleAppend fontset font = liftIO $ do
fontset' <- unsafeManagedPtrCastPtr fontset
font' <- unsafeManagedPtrCastPtr font
pango_fontset_simple_append fontset' font'
touchManagedPtr fontset
touchManagedPtr font
return ()
#if ENABLE_OVERLOADING
data FontsetSimpleAppendMethodInfo
instance (signature ~ (b -> m ()), MonadIO m, IsFontsetSimple a, Pango.Font.IsFont b) => O.MethodInfo FontsetSimpleAppendMethodInfo a signature where
overloadedMethod _ = fontsetSimpleAppend
#endif
foreign import ccall "pango_fontset_simple_size" pango_fontset_simple_size ::
Ptr FontsetSimple ->
IO Int32
fontsetSimpleSize ::
(B.CallStack.HasCallStack, MonadIO m, IsFontsetSimple a) =>
a
-> m Int32
fontsetSimpleSize fontset = liftIO $ do
fontset' <- unsafeManagedPtrCastPtr fontset
result <- pango_fontset_simple_size fontset'
touchManagedPtr fontset
return result
#if ENABLE_OVERLOADING
data FontsetSimpleSizeMethodInfo
instance (signature ~ (m Int32), MonadIO m, IsFontsetSimple a) => O.MethodInfo FontsetSimpleSizeMethodInfo a signature where
overloadedMethod _ = fontsetSimpleSize
#endif