    {-# LANGUAGE TypeApplications #-}

    -- | Copyright  : Will Thompson and Iñaki García Etxebarria
    -- License    : LGPL-2.1
    -- Maintainer : Iñaki García Etxebarria
    --
    -- A @PangoTabArray@ contains an array of tab stops.
    --
    -- @PangoTabArray@ can be used to set tab stops in a @PangoLayout@.
    -- Each tab stop has an alignment, a position, and optionally
    -- a character to use as decimal point.

    #if !defined(__HADDOCK_VERSION__)
    #define ENABLE_OVERLOADING
    #endif

    module GI.Pango.Structs.TabArray
        (

    -- * Exported types
        TabArray(..)                            ,

     -- * Methods
    -- |
    --
    --  === __Click to display all available methods, including inherited ones__
    -- ==== Methods
    -- [copy]("GI.Pango.Structs.TabArray#g:method:copy"), [free]("GI.Pango.Structs.TabArray#g:method:free"), [resize]("GI.Pango.Structs.TabArray#g:method:resize"), [sort]("GI.Pango.Structs.TabArray#g:method:sort"), [toString]("GI.Pango.Structs.TabArray#g:method:toString").
    --
    -- ==== Getters
    -- [getDecimalPoint]("GI.Pango.Structs.TabArray#g:method:getDecimalPoint"), [getPositionsInPixels]("GI.Pango.Structs.TabArray#g:method:getPositionsInPixels"), [getSize]("GI.Pango.Structs.TabArray#g:method:getSize"), [getTab]("GI.Pango.Structs.TabArray#g:method:getTab").
    --
    -- ==== Setters
    -- [setDecimalPoint]("GI.Pango.Structs.TabArray#g:method:setDecimalPoint"), [setPositionsInPixels]("GI.Pango.Structs.TabArray#g:method:setPositionsInPixels"), [setTab]("GI.Pango.Structs.TabArray#g:method:setTab").

    #if defined(ENABLE_OVERLOADING)
        ResolveTabArrayMethod                   ,
    #endif

    -- ** copy #method:copy#

    #if defined(ENABLE_OVERLOADING)
        TabArrayCopyMethodInfo                  ,
    #endif
        tabArrayCopy                            ,

    -- ** free #method:free#

    #if defined(ENABLE_OVERLOADING)
        TabArrayFreeMethodInfo                  ,
    #endif
        tabArrayFree                            ,

    -- ** fromString #method:fromString#

        tabArrayFromString                      ,

    -- ** getDecimalPoint #method:getDecimalPoint#

    #if defined(ENABLE_OVERLOADING)
        TabArrayGetDecimalPointMethodInfo       ,
    #endif
        tabArrayGetDecimalPoint                 ,

    -- ** getPositionsInPixels #method:getPositionsInPixels#

    #if defined(ENABLE_OVERLOADING)
        TabArrayGetPositionsInPixelsMethodInfo  ,
    #endif
        tabArrayGetPositionsInPixels            ,

    -- ** getSize #method:getSize#

    #if defined(ENABLE_OVERLOADING)
        TabArrayGetSizeMethodInfo               ,
    #endif
        tabArrayGetSize                         ,

    -- ** getTab #method:getTab#

    #if defined(ENABLE_OVERLOADING)
        TabArrayGetTabMethodInfo                ,
    #endif
        tabArrayGetTab                          ,

    -- ** new #method:new#

        tabArrayNew                             ,

    -- ** resize #method:resize#

    #if defined(ENABLE_OVERLOADING)
        TabArrayResizeMethodInfo                ,
    #endif
        tabArrayResize                          ,

    -- ** setDecimalPoint #method:setDecimalPoint#

    #if defined(ENABLE_OVERLOADING)
        TabArraySetDecimalPointMethodInfo       ,
    #endif
        tabArraySetDecimalPoint                 ,

    -- ** setPositionsInPixels #method:setPositionsInPixels#

    #if defined(ENABLE_OVERLOADING)
        TabArraySetPositionsInPixelsMethodInfo  ,
    #endif
        tabArraySetPositionsInPixels            ,

    -- ** setTab #method:setTab#

    #if defined(ENABLE_OVERLOADING)
        TabArraySetTabMethodInfo                ,
    #endif
        tabArraySetTab                          ,

    -- ** sort #method:sort#

    #if defined(ENABLE_OVERLOADING)
        TabArraySortMethodInfo                  ,
    #endif
        tabArraySort                            ,

    -- ** toString #method:toString#

    #if defined(ENABLE_OVERLOADING)
        TabArrayToStringMethodInfo              ,
    #endif
        tabArrayToString                        ,

        ) 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 qualified Data.Word as DW
    import qualified Data.Int as DI
    import qualified System.Posix.Types as SPT
    import qualified Foreign.C.Types as FCT

    -- Workaround for https://gitlab.haskell.org/ghc/ghc/-/issues/23392
    #if MIN_VERSION_base(4,18,0)
    import {-# SOURCE #-} qualified GI.Pango.Enums as Pango.Enums

    #else
    import {-# SOURCE #-} qualified GI.Pango.Enums as Pango.Enums

    #endif

    -- | Memory-managed wrapper type.
    newtype TabArray = TabArray (SP.ManagedPtr TabArray)
        deriving (TabArray -> TabArray -> Bool
    (TabArray -> TabArray -> Bool)
    -> (TabArray -> TabArray -> Bool) -> Eq TabArray
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: TabArray -> TabArray -> Bool
    == :: TabArray -> TabArray -> Bool
    $c/= :: TabArray -> TabArray -> Bool
    /= :: TabArray -> TabArray -> Bool
    Eq)

    instance SP.ManagedPtrNewtype TabArray where
        toManagedPtr :: TabArray -> ManagedPtr TabArray
    toManagedPtr (TabArray ManagedPtr TabArray
    p) = ManagedPtr TabArray
    p

    foreign import ccall "pango_tab_array_get_type" c_pango_tab_array_get_type ::
        IO GType

    type instance O.ParentTypes TabArray = '[]
    instance O.HasParentTypes TabArray

    instance B.Types.TypedObject TabArray where
        glibType :: IO GType
    glibType = IO GType
    c_pango_tab_array_get_type

    instance B.Types.GBoxed TabArray

    -- | Convert 'TabArray' to and from 'Data.GI.Base.GValue.GValue'. See 'Data.GI.Base.GValue.toGValue' and 'Data.GI.Base.GValue.fromGValue'.
    instance B.GValue.IsGValue (Maybe TabArray) where
        gvalueGType_ :: IO GType
    gvalueGType_ = IO GType
    c_pango_tab_array_get_type
        gvalueSet_ :: Ptr GValue -> Maybe TabArray -> IO ()
    gvalueSet_ Ptr GValue
    gv Maybe TabArray
    P.Nothing = Ptr GValue -> Ptr TabArray -> IO ()
    forall a. Ptr GValue -> Ptr a -> IO ()
    B.GValue.set_boxed Ptr GValue
    gv (Ptr TabArray
    forall a. Ptr a
    FP.nullPtr :: FP.Ptr TabArray)
        gvalueSet_ Ptr GValue
    gv (P.Just TabArray
    obj) = TabArray -> (Ptr TabArray -> IO ()) -> IO ()
    forall a c.
    (HasCallStack, ManagedPtrNewtype a) =>
    a -> (Ptr a -> IO c) -> IO c
    B.ManagedPtr.withManagedPtr TabArray
    obj (Ptr GValue -> Ptr TabArray -> IO ()
    forall a. Ptr GValue -> Ptr a -> IO ()
    B.GValue.set_boxed Ptr GValue
    gv)
        gvalueGet_ :: Ptr GValue -> IO (Maybe TabArray)
    gvalueGet_ Ptr GValue
    gv = do
            Ptr TabArray
    ptr <- Ptr GValue -> IO (Ptr TabArray)
    forall b. Ptr GValue -> IO (Ptr b)
    B.GValue.get_boxed Ptr GValue
    gv :: IO (Ptr TabArray)
            if Ptr TabArray
    ptr Ptr TabArray -> Ptr TabArray -> Bool
    forall a. Eq a => a -> a -> Bool
    /= Ptr TabArray
    forall a. Ptr a
    FP.nullPtr
            then TabArray -> Maybe TabArray
    forall a. a -> Maybe a
    P.Just (TabArray -> Maybe TabArray) -> IO TabArray -> IO (Maybe TabArray)
    forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
    <$> (ManagedPtr TabArray -> TabArray) -> Ptr TabArray -> IO TabArray
    forall a.
    (HasCallStack, GBoxed a) =>
    (ManagedPtr a -> a) -> Ptr a -> IO a
    B.ManagedPtr.newBoxed ManagedPtr TabArray -> TabArray
    TabArray Ptr TabArray
    ptr
            else Maybe TabArray -> IO (Maybe TabArray)
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return Maybe TabArray
    forall a. Maybe a
    P.Nothing

    #if defined(ENABLE_OVERLOADING)
    instance O.HasAttributeList TabArray
    type instance O.AttributeList TabArray = TabArrayAttributeList
    type TabArrayAttributeList = ('[ ] :: [(Symbol, DK.Type)])
    #endif

    -- method TabArray::new
    -- method type : Constructor
    -- Args: [ Arg
    --           { argCName = "initial_size"
    --           , argType = TBasicType TInt
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText =
    --                     Just "Initial number of tab stops to allocate, can be 0"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "positions_in_pixels"
    --           , argType = TBasicType TBoolean
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "whether positions are in pixel units"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Just (TInterface Name { namespace = "Pango" , name = "TabArray" })
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_new" pango_tab_array_new ::
        Int32 ->                                -- initial_size : TBasicType TInt
        CInt ->                                 -- positions_in_pixels : TBasicType TBoolean
        IO (Ptr TabArray)

    -- | Creates an array of /@initialSize@/ tab stops.
    --
    -- Tab stops are specified in pixel units if /@positionsInPixels@/ is 'P.True',
    -- otherwise in Pango units. All stops are initially at position 0.
    tabArrayNew ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        Int32
        -- ^ /@initialSize@/: Initial number of tab stops to allocate, can be 0
        -> Bool
        -- ^ /@positionsInPixels@/: whether positions are in pixel units
        -> m TabArray
        -- ^ __Returns:__ the newly allocated @PangoTabArray@, which should
        --   be freed with 'GI.Pango.Structs.TabArray.tabArrayFree'.
    tabArrayNew :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    Int32 -> Bool -> m TabArray
    tabArrayNew Int32
    initialSize Bool
    positionsInPixels = IO TabArray -> m TabArray
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO TabArray -> m TabArray) -> IO TabArray -> m TabArray
    forall a b. (a -> b) -> a -> b
    $ do
        let positionsInPixels' :: CInt
    positionsInPixels' = (Int -> CInt
    forall a b. (Integral a, Num b) => a -> b
    P.fromIntegral (Int -> CInt) -> (Bool -> Int) -> Bool -> CInt
    forall b c a. (b -> c) -> (a -> b) -> a -> c
    . Bool -> Int
    forall a. Enum a => a -> Int
    P.fromEnum) Bool
    positionsInPixels
        Ptr TabArray
    result <- Int32 -> CInt -> IO (Ptr TabArray)
    pango_tab_array_new Int32
    initialSize CInt
    positionsInPixels'
        Text -> Ptr TabArray -> IO ()
    forall a. HasCallStack => Text -> Ptr a -> IO ()
    checkUnexpectedReturnNULL Text
    "tabArrayNew" Ptr TabArray
    result
        TabArray
    result' <- ((ManagedPtr TabArray -> TabArray) -> Ptr TabArray -> IO TabArray
    forall a.
    (HasCallStack, GBoxed a) =>
    (ManagedPtr a -> a) -> Ptr a -> IO a
    wrapBoxed ManagedPtr TabArray -> TabArray
    TabArray) Ptr TabArray
    result
        TabArray -> IO TabArray
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return TabArray
    result'

    #if defined(ENABLE_OVERLOADING)
    #endif

    -- method TabArray::copy
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "src"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "`PangoTabArray` to copy"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Just (TInterface Name { namespace = "Pango" , name = "TabArray" })
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_copy" pango_tab_array_copy ::
        Ptr TabArray ->                         -- src : TInterface (Name {namespace = "Pango", name = "TabArray"})
        IO (Ptr TabArray)

    -- | Copies a @PangoTabArray@.
    tabArrayCopy ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@src@/: @PangoTabArray@ to copy
        -> m TabArray
        -- ^ __Returns:__ the newly allocated @PangoTabArray@, which should
        --   be freed with 'GI.Pango.Structs.TabArray.tabArrayFree'.
    tabArrayCopy :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> m TabArray
    tabArrayCopy TabArray
    src = IO TabArray -> m TabArray
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO TabArray -> m TabArray) -> IO TabArray -> m TabArray
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    src' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    src
        Ptr TabArray
    result <- Ptr TabArray -> IO (Ptr TabArray)
    pango_tab_array_copy Ptr TabArray
    src'
        Text -> Ptr TabArray -> IO ()
    forall a. HasCallStack => Text -> Ptr a -> IO ()
    checkUnexpectedReturnNULL Text
    "tabArrayCopy" Ptr TabArray
    result
        TabArray
    result' <- ((ManagedPtr TabArray -> TabArray) -> Ptr TabArray -> IO TabArray
    forall a.
    (HasCallStack, GBoxed a) =>
    (ManagedPtr a -> a) -> Ptr a -> IO a
    wrapBoxed ManagedPtr TabArray -> TabArray
    TabArray) Ptr TabArray
    result
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    src
        TabArray -> IO TabArray
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return TabArray
    result'

    #if defined(ENABLE_OVERLOADING)
    data TabArrayCopyMethodInfo
    instance (signature ~ (m TabArray), MonadIO m) => O.OverloadedMethod TabArrayCopyMethodInfo TabArray signature where
        overloadedMethod = tabArrayCopy

    instance O.OverloadedMethodInfo TabArrayCopyMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayCopy",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayCopy"
            })

    #endif

    -- method TabArray::free
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Nothing
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_free" pango_tab_array_free ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        IO ()

    -- | Frees a tab array and associated resources.
    tabArrayFree ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> m ()
    tabArrayFree :: forall (m :: * -> *). (HasCallStack, MonadIO m) => TabArray -> m ()
    tabArrayFree TabArray
    tabArray = IO () -> m ()
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO () -> m ()) -> IO () -> m ()
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        Ptr TabArray -> IO ()
    pango_tab_array_free Ptr TabArray
    tabArray'
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        () -> IO ()
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return ()

    #if defined(ENABLE_OVERLOADING)
    data TabArrayFreeMethodInfo
    instance (signature ~ (m ()), MonadIO m) => O.OverloadedMethod TabArrayFreeMethodInfo TabArray signature where
        overloadedMethod = tabArrayFree

    instance O.OverloadedMethodInfo TabArrayFreeMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayFree",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayFree"
            })

    #endif

    -- method TabArray::get_decimal_point
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "tab_index"
    --           , argType = TBasicType TInt
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "the index of a tab stop"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Just (TBasicType TUniChar)
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_get_decimal_point" pango_tab_array_get_decimal_point ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        Int32 ->                                -- tab_index : TBasicType TInt
        IO CInt

    -- | Gets the Unicode character to use as decimal point.
    --
    -- This is only relevant for tabs with 'GI.Pango.Enums.TabAlignDecimal' alignment,
    -- which align content at the first occurrence of the decimal point
    -- character.
    --
    -- The default value of 0 means that Pango will use the
    -- decimal point according to the current locale.
    --
    -- /Since: 1.50/
    tabArrayGetDecimalPoint ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> Int32
        -- ^ /@tabIndex@/: the index of a tab stop
        -> m Char
    tabArrayGetDecimalPoint :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> Int32 -> m Char
    tabArrayGetDecimalPoint TabArray
    tabArray Int32
    tabIndex = IO Char -> m Char
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO Char -> m Char) -> IO Char -> m Char
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        CInt
    result <- Ptr TabArray -> Int32 -> IO CInt
    pango_tab_array_get_decimal_point Ptr TabArray
    tabArray' Int32
    tabIndex
        let result' :: Char
    result' = (Int -> Char
    chr (Int -> Char) -> (CInt -> Int) -> CInt -> Char
    forall b c a. (b -> c) -> (a -> b) -> a -> c
    . CInt -> Int
    forall a b. (Integral a, Num b) => a -> b
    fromIntegral) CInt
    result
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        Char -> IO Char
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return Char
    result'

    #if defined(ENABLE_OVERLOADING)
    data TabArrayGetDecimalPointMethodInfo
    instance (signature ~ (Int32 -> m Char), MonadIO m) => O.OverloadedMethod TabArrayGetDecimalPointMethodInfo TabArray signature where
        overloadedMethod = tabArrayGetDecimalPoint

    instance O.OverloadedMethodInfo TabArrayGetDecimalPointMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayGetDecimalPoint",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayGetDecimalPoint"
            })

    #endif

    -- method TabArray::get_positions_in_pixels
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Just (TBasicType TBoolean)
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_get_positions_in_pixels" pango_tab_array_get_positions_in_pixels ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        IO CInt

    -- | Returns 'P.True' if the tab positions are in pixels,
    -- 'P.False' if they are in Pango units.
    tabArrayGetPositionsInPixels ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> m Bool
        -- ^ __Returns:__ whether positions are in pixels.
    tabArrayGetPositionsInPixels :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> m Bool
    tabArrayGetPositionsInPixels TabArray
    tabArray = IO Bool -> m Bool
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        CInt
    result <- Ptr TabArray -> IO CInt
    pango_tab_array_get_positions_in_pixels Ptr TabArray
    tabArray'
        let result' :: Bool
    result' = (CInt -> CInt -> Bool
    forall a. Eq a => a -> a -> Bool
    /= CInt
    0) CInt
    result
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        Bool -> IO Bool
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return Bool
    result'

    #if defined(ENABLE_OVERLOADING)
    data TabArrayGetPositionsInPixelsMethodInfo
    instance (signature ~ (m Bool), MonadIO m) => O.OverloadedMethod TabArrayGetPositionsInPixelsMethodInfo TabArray signature where
        overloadedMethod = tabArrayGetPositionsInPixels

    instance O.OverloadedMethodInfo TabArrayGetPositionsInPixelsMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayGetPositionsInPixels",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayGetPositionsInPixels"
            })

    #endif

    -- method TabArray::get_size
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Just (TBasicType TInt)
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_get_size" pango_tab_array_get_size ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        IO Int32

    -- | Gets the number of tab stops in /@tabArray@/.
    tabArrayGetSize ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> m Int32
        -- ^ __Returns:__ the number of tab stops in the array.
    tabArrayGetSize :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> m Int32
    tabArrayGetSize TabArray
    tabArray = IO Int32 -> m Int32
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO Int32 -> m Int32) -> IO Int32 -> m Int32
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        Int32
    result <- Ptr TabArray -> IO Int32
    pango_tab_array_get_size Ptr TabArray
    tabArray'
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        Int32 -> IO Int32
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return Int32
    result

    #if defined(ENABLE_OVERLOADING)
    data TabArrayGetSizeMethodInfo
    instance (signature ~ (m Int32), MonadIO m) => O.OverloadedMethod TabArrayGetSizeMethodInfo TabArray signature where
        overloadedMethod = tabArrayGetSize

    instance O.OverloadedMethodInfo TabArrayGetSizeMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayGetSize",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayGetSize"
            })

    #endif

    -- method TabArray::get_tab
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "tab_index"
    --           , argType = TBasicType TInt
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "tab stop index" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "alignment"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabAlign" }
    --           , direction = DirectionOut
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "location to store alignment"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferEverything
    --           }
    --       , Arg
    --           { argCName = "location"
    --           , argType = TBasicType TInt
    --           , direction = DirectionOut
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "location to store tab position"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferEverything
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Nothing
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_get_tab" pango_tab_array_get_tab ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        Int32 ->                                -- tab_index : TBasicType TInt
        Ptr CUInt ->                            -- alignment : TInterface (Name {namespace = "Pango", name = "TabAlign"})
        Ptr Int32 ->                            -- location : TBasicType TInt
        IO ()

    -- | Gets the alignment and position of a tab stop.
    tabArrayGetTab ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> Int32
        -- ^ /@tabIndex@/: tab stop index
        -> m ((Pango.Enums.TabAlign, Int32))
    tabArrayGetTab :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> Int32 -> m (TabAlign, Int32)
    tabArrayGetTab TabArray
    tabArray Int32
    tabIndex = IO (TabAlign, Int32) -> m (TabAlign, Int32)
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO (TabAlign, Int32) -> m (TabAlign, Int32))
    -> IO (TabAlign, Int32) -> m (TabAlign, Int32)
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        Ptr CUInt
    alignment <- IO (Ptr CUInt)
    forall a. Storable a => IO (Ptr a)
    allocMem :: IO (Ptr CUInt)
        Ptr Int32
    location <- IO (Ptr Int32)
    forall a. Storable a => IO (Ptr a)
    allocMem :: IO (Ptr Int32)
        Ptr TabArray -> Int32 -> Ptr CUInt -> Ptr Int32 -> IO ()
    pango_tab_array_get_tab Ptr TabArray
    tabArray' Int32
    tabIndex Ptr CUInt
    alignment Ptr Int32
    location
        CUInt
    alignment' <- Ptr CUInt -> IO CUInt
    forall a. Storable a => Ptr a -> IO a
    peek Ptr CUInt
    alignment
        let alignment'' :: TabAlign
    alignment'' = (Int -> TabAlign
    forall a. Enum a => Int -> a
    toEnum (Int -> TabAlign) -> (CUInt -> Int) -> CUInt -> TabAlign
    forall b c a. (b -> c) -> (a -> b) -> a -> c
    . CUInt -> Int
    forall a b. (Integral a, Num b) => a -> b
    fromIntegral) CUInt
    alignment'
        Int32
    location' <- Ptr Int32 -> IO Int32
    forall a. Storable a => Ptr a -> IO a
    peek Ptr Int32
    location
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        Ptr CUInt -> IO ()
    forall a. Ptr a -> IO ()
    freeMem Ptr CUInt
    alignment
        Ptr Int32 -> IO ()
    forall a. Ptr a -> IO ()
    freeMem Ptr Int32
    location
        (TabAlign, Int32) -> IO (TabAlign, Int32)
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return (TabAlign
    alignment'', Int32
    location')

    #if defined(ENABLE_OVERLOADING)
    data TabArrayGetTabMethodInfo
    instance (signature ~ (Int32 -> m ((Pango.Enums.TabAlign, Int32))), MonadIO m) => O.OverloadedMethod TabArrayGetTabMethodInfo TabArray signature where
        overloadedMethod = tabArrayGetTab

    instance O.OverloadedMethodInfo TabArrayGetTabMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayGetTab",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayGetTab"
            })

    #endif

    -- XXX Could not generate method TabArray::get_tabs
    {-  Bad introspection data: `TCArray False (-1) (-1) (TBasicType TInt)' is an array type, but contains no length information,
        so it cannot be unpacked.
    -}
    -- method TabArray::resize
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "new_size"
    --           , argType = TBasicType TInt
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "new size of the array"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Nothing
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_resize" pango_tab_array_resize ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        Int32 ->                                -- new_size : TBasicType TInt
        IO ()

    -- | Resizes a tab array.
    --
    -- You must subsequently initialize any tabs
    -- that were added as a result of growing the array.
    tabArrayResize ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> Int32
        -- ^ /@newSize@/: new size of the array
        -> m ()
    tabArrayResize :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> Int32 -> m ()
    tabArrayResize TabArray
    tabArray Int32
    newSize = IO () -> m ()
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO () -> m ()) -> IO () -> m ()
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        Ptr TabArray -> Int32 -> IO ()
    pango_tab_array_resize Ptr TabArray
    tabArray' Int32
    newSize
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        () -> IO ()
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return ()

    #if defined(ENABLE_OVERLOADING)
    data TabArrayResizeMethodInfo
    instance (signature ~ (Int32 -> m ()), MonadIO m) => O.OverloadedMethod TabArrayResizeMethodInfo TabArray signature where
        overloadedMethod = tabArrayResize

    instance O.OverloadedMethodInfo TabArrayResizeMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayResize",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayResize"
            })

    #endif

    -- method TabArray::set_decimal_point
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "tab_index"
    --           , argType = TBasicType TInt
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "the index of a tab stop"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "decimal_point"
    --           , argType = TBasicType TUniChar
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "the decimal point to use"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Nothing
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_set_decimal_point" pango_tab_array_set_decimal_point ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        Int32 ->                                -- tab_index : TBasicType TInt
        CInt ->                                 -- decimal_point : TBasicType TUniChar
        IO ()

    -- | Sets the Unicode character to use as decimal point.
    --
    -- This is only relevant for tabs with 'GI.Pango.Enums.TabAlignDecimal' alignment,
    -- which align content at the first occurrence of the decimal point
    -- character.
    --
    -- By default, Pango uses the decimal point according
    -- to the current locale.
    --
    -- /Since: 1.50/
    tabArraySetDecimalPoint ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> Int32
        -- ^ /@tabIndex@/: the index of a tab stop
        -> Char
        -- ^ /@decimalPoint@/: the decimal point to use
        -> m ()
    tabArraySetDecimalPoint :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> Int32 -> Char -> m ()
    tabArraySetDecimalPoint TabArray
    tabArray Int32
    tabIndex Char
    decimalPoint = IO () -> m ()
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO () -> m ()) -> IO () -> m ()
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        let decimalPoint' :: CInt
    decimalPoint' = (Int -> CInt
    forall a b. (Integral a, Num b) => a -> b
    P.fromIntegral (Int -> CInt) -> (Char -> Int) -> Char -> CInt
    forall b c a. (b -> c) -> (a -> b) -> a -> c
    . Char -> Int
    SP.ord) Char
    decimalPoint
        Ptr TabArray -> Int32 -> CInt -> IO ()
    pango_tab_array_set_decimal_point Ptr TabArray
    tabArray' Int32
    tabIndex CInt
    decimalPoint'
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        () -> IO ()
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return ()

    #if defined(ENABLE_OVERLOADING)
    data TabArraySetDecimalPointMethodInfo
    instance (signature ~ (Int32 -> Char -> m ()), MonadIO m) => O.OverloadedMethod TabArraySetDecimalPointMethodInfo TabArray signature where
        overloadedMethod = tabArraySetDecimalPoint

    instance O.OverloadedMethodInfo TabArraySetDecimalPointMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArraySetDecimalPoint",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArraySetDecimalPoint"
            })

    #endif

    -- method TabArray::set_positions_in_pixels
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "positions_in_pixels"
    --           , argType = TBasicType TBoolean
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "whether positions are in pixels"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Nothing
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_set_positions_in_pixels" pango_tab_array_set_positions_in_pixels ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        CInt ->                                 -- positions_in_pixels : TBasicType TBoolean
        IO ()

    -- | Sets whether positions in this array are specified in
    -- pixels.
    --
    -- /Since: 1.50/
    tabArraySetPositionsInPixels ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> Bool
        -- ^ /@positionsInPixels@/: whether positions are in pixels
        -> m ()
    tabArraySetPositionsInPixels :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> Bool -> m ()
    tabArraySetPositionsInPixels TabArray
    tabArray Bool
    positionsInPixels = IO () -> m ()
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO () -> m ()) -> IO () -> m ()
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        let positionsInPixels' :: CInt
    positionsInPixels' = (Int -> CInt
    forall a b. (Integral a, Num b) => a -> b
    P.fromIntegral (Int -> CInt) -> (Bool -> Int) -> Bool -> CInt
    forall b c a. (b -> c) -> (a -> b) -> a -> c
    . Bool -> Int
    forall a. Enum a => a -> Int
    P.fromEnum) Bool
    positionsInPixels
        Ptr TabArray -> CInt -> IO ()
    pango_tab_array_set_positions_in_pixels Ptr TabArray
    tabArray' CInt
    positionsInPixels'
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        () -> IO ()
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return ()

    #if defined(ENABLE_OVERLOADING)
    data TabArraySetPositionsInPixelsMethodInfo
    instance (signature ~ (Bool -> m ()), MonadIO m) => O.OverloadedMethod TabArraySetPositionsInPixelsMethodInfo TabArray signature where
        overloadedMethod = tabArraySetPositionsInPixels

    instance O.OverloadedMethodInfo TabArraySetPositionsInPixelsMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArraySetPositionsInPixels",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArraySetPositionsInPixels"
            })

    #endif

    -- method TabArray::set_tab
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "tab_index"
    --           , argType = TBasicType TInt
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "the index of a tab stop"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "alignment"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabAlign" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "tab alignment" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       , Arg
    --           { argCName = "location"
    --           , argType = TBasicType TInt
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "tab location in Pango units"
    --                 , sinceVersion = Nothing
    --                 }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Nothing
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_set_tab" pango_tab_array_set_tab ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        Int32 ->                                -- tab_index : TBasicType TInt
        CUInt ->                                -- alignment : TInterface (Name {namespace = "Pango", name = "TabAlign"})
        Int32 ->                                -- location : TBasicType TInt
        IO ()

    -- | Sets the alignment and location of a tab stop.
    tabArraySetTab ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> Int32
        -- ^ /@tabIndex@/: the index of a tab stop
        -> Pango.Enums.TabAlign
        -- ^ /@alignment@/: tab alignment
        -> Int32
        -- ^ /@location@/: tab location in Pango units
        -> m ()
    tabArraySetTab :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> Int32 -> TabAlign -> Int32 -> m ()
    tabArraySetTab TabArray
    tabArray Int32
    tabIndex TabAlign
    alignment Int32
    location = IO () -> m ()
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO () -> m ()) -> IO () -> m ()
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        let alignment' :: CUInt
    alignment' = (Int -> CUInt
    forall a b. (Integral a, Num b) => a -> b
    fromIntegral (Int -> CUInt) -> (TabAlign -> Int) -> TabAlign -> CUInt
    forall b c a. (b -> c) -> (a -> b) -> a -> c
    . TabAlign -> Int
    forall a. Enum a => a -> Int
    fromEnum) TabAlign
    alignment
        Ptr TabArray -> Int32 -> CUInt -> Int32 -> IO ()
    pango_tab_array_set_tab Ptr TabArray
    tabArray' Int32
    tabIndex CUInt
    alignment' Int32
    location
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        () -> IO ()
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return ()

    #if defined(ENABLE_OVERLOADING)
    data TabArraySetTabMethodInfo
    instance (signature ~ (Int32 -> Pango.Enums.TabAlign -> Int32 -> m ()), MonadIO m) => O.OverloadedMethod TabArraySetTabMethodInfo TabArray signature where
        overloadedMethod = tabArraySetTab

    instance O.OverloadedMethodInfo TabArraySetTabMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArraySetTab",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArraySetTab"
            })

    #endif

    -- method TabArray::sort
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Nothing
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_sort" pango_tab_array_sort ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        IO ()

    -- | Utility function to ensure that the tab stops are in increasing order.
    --
    -- /Since: 1.50/
    tabArraySort ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> m ()
    tabArraySort :: forall (m :: * -> *). (HasCallStack, MonadIO m) => TabArray -> m ()
    tabArraySort TabArray
    tabArray = IO () -> m ()
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO () -> m ()) -> IO () -> m ()
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        Ptr TabArray -> IO ()
    pango_tab_array_sort Ptr TabArray
    tabArray'
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        () -> IO ()
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return ()

    #if defined(ENABLE_OVERLOADING)
    data TabArraySortMethodInfo
    instance (signature ~ (m ()), MonadIO m) => O.OverloadedMethod TabArraySortMethodInfo TabArray signature where
        overloadedMethod = tabArraySort

    instance O.OverloadedMethodInfo TabArraySortMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArraySort",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArraySort"
            })

    #endif

    -- method TabArray::to_string
    -- method type : OrdinaryMethod
    -- Args: [ Arg
    --           { argCName = "tab_array"
    --           , argType =
    --               TInterface Name { namespace = "Pango" , name = "TabArray" }
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a `PangoTabArray`" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Just (TBasicType TUTF8)
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_to_string" pango_tab_array_to_string ::
        Ptr TabArray ->                         -- tab_array : TInterface (Name {namespace = "Pango", name = "TabArray"})
        IO CString

    -- | Serializes a @PangoTabArray@ to a string.
    --
    -- No guarantees are made about the format of the string,
    -- it may change between Pango versions.
    --
    -- The intended use of this function is testing and
    -- debugging. The format is not meant as a permanent
    -- storage format.
    --
    -- /Since: 1.50/
    tabArrayToString ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        TabArray
        -- ^ /@tabArray@/: a @PangoTabArray@
        -> m T.Text
        -- ^ __Returns:__ a newly allocated string
    tabArrayToString :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    TabArray -> m Text
    tabArrayToString TabArray
    tabArray = IO Text -> m Text
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO Text -> m Text) -> IO Text -> m Text
    forall a b. (a -> b) -> a -> b
    $ do
        Ptr TabArray
    tabArray' <- TabArray -> IO (Ptr TabArray)
    forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
    unsafeManagedPtrGetPtr TabArray
    tabArray
        CString
    result <- Ptr TabArray -> IO CString
    pango_tab_array_to_string Ptr TabArray
    tabArray'
        Text -> CString -> IO ()
    forall a. HasCallStack => Text -> Ptr a -> IO ()
    checkUnexpectedReturnNULL Text
    "tabArrayToString" CString
    result
        Text
    result' <- HasCallStack => CString -> IO Text
    CString -> IO Text
    cstringToText CString
    result
        CString -> IO ()
    forall a. Ptr a -> IO ()
    freeMem CString
    result
        TabArray -> IO ()
    forall a. ManagedPtrNewtype a => a -> IO ()
    touchManagedPtr TabArray
    tabArray
        Text -> IO Text
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return Text
    result'

    #if defined(ENABLE_OVERLOADING)
    data TabArrayToStringMethodInfo
    instance (signature ~ (m T.Text), MonadIO m) => O.OverloadedMethod TabArrayToStringMethodInfo TabArray signature where
        overloadedMethod = tabArrayToString

    instance O.OverloadedMethodInfo TabArrayToStringMethodInfo TabArray where
        overloadedMethodInfo = P.Just (O.ResolvedSymbolInfo {
            O.resolvedSymbolName = "GI.Pango.Structs.TabArray.tabArrayToString",
            O.resolvedSymbolURL = "https://hackage.haskell.org/package/gi-pango-1.0.30/docs/GI-Pango-Structs-TabArray.html#v:tabArrayToString"
            })

    #endif

    -- method TabArray::from_string
    -- method type : MemberFunction
    -- Args: [ Arg
    --           { argCName = "text"
    --           , argType = TBasicType TUTF8
    --           , direction = DirectionIn
    --           , mayBeNull = False
    --           , argDoc =
    --               Documentation
    --                 { rawDocText = Just "a string" , sinceVersion = Nothing }
    --           , argScope = ScopeTypeInvalid
    --           , argClosure = -1
    --           , argDestroy = -1
    --           , argCallerAllocates = False
    --           , argCallbackUserData = False
    --           , transfer = TransferNothing
    --           }
    --       ]
    -- Lengths: []
    -- returnType: Just (TInterface Name { namespace = "Pango" , name = "TabArray" })
    -- throws : False
    -- Skip return : False

    foreign import ccall "pango_tab_array_from_string" pango_tab_array_from_string ::
        CString ->                              -- text : TBasicType TUTF8
        IO (Ptr TabArray)

    -- | Deserializes a @PangoTabArray@ from a string.
    --
    -- This is the counterpart to 'GI.Pango.Structs.TabArray.tabArrayToString'.
    -- See that functions for details about the format.
    --
    -- /Since: 1.50/
    tabArrayFromString ::
        (B.CallStack.HasCallStack, MonadIO m) =>
        T.Text
        -- ^ /@text@/: a string
        -> m (Maybe TabArray)
        -- ^ __Returns:__ a new @PangoTabArray@
    tabArrayFromString :: forall (m :: * -> *).
    (HasCallStack, MonadIO m) =>
    Text -> m (Maybe TabArray)
    tabArrayFromString Text
    text = IO (Maybe TabArray) -> m (Maybe TabArray)
    forall a. IO a -> m a
    forall (m :: * -> *) a. MonadIO m => IO a -> m a
    liftIO (IO (Maybe TabArray) -> m (Maybe TabArray))
    -> IO (Maybe TabArray) -> m (Maybe TabArray)
    forall a b. (a -> b) -> a -> b
    $ do
        CString
    text' <- Text -> IO CString
    textToCString Text
    text
        Ptr TabArray
    result <- CString -> IO (Ptr TabArray)
    pango_tab_array_from_string CString
    text'
        Maybe TabArray
    maybeResult <- Ptr TabArray
    -> (Ptr TabArray -> IO TabArray) -> IO (Maybe TabArray)
    forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
    convertIfNonNull Ptr TabArray
    result ((Ptr TabArray -> IO TabArray) -> IO (Maybe TabArray))
    -> (Ptr TabArray -> IO TabArray) -> IO (Maybe TabArray)
    forall a b. (a -> b) -> a -> b
    $ \Ptr TabArray
    result' -> do
            TabArray
    result'' <- ((ManagedPtr TabArray -> TabArray) -> Ptr TabArray -> IO TabArray
    forall a.
    (HasCallStack, GBoxed a) =>
    (ManagedPtr a -> a) -> Ptr a -> IO a
    wrapBoxed ManagedPtr TabArray -> TabArray
    TabArray) Ptr TabArray
    result'
            TabArray -> IO TabArray
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return TabArray
    result''
        CString -> IO ()
    forall a. Ptr a -> IO ()
    freeMem CString
    text'
        Maybe TabArray -> IO (Maybe TabArray)
    forall a. a -> IO a
    forall (m :: * -> *) a. Monad m => a -> m a
    return Maybe TabArray
    maybeResult

    #if defined(ENABLE_OVERLOADING)
    #endif

    #if defined(ENABLE_OVERLOADING)
    type family ResolveTabArrayMethod (t :: Symbol) (o :: DK.Type) :: DK.Type where
        ResolveTabArrayMethod "copy" o = TabArrayCopyMethodInfo
        ResolveTabArrayMethod "free" o = TabArrayFreeMethodInfo
        ResolveTabArrayMethod "resize" o = TabArrayResizeMethodInfo
        ResolveTabArrayMethod "sort" o = TabArraySortMethodInfo
        ResolveTabArrayMethod "toString" o = TabArrayToStringMethodInfo
        ResolveTabArrayMethod "getDecimalPoint" o = TabArrayGetDecimalPointMethodInfo
        ResolveTabArrayMethod "getPositionsInPixels" o = TabArrayGetPositionsInPixelsMethodInfo
        ResolveTabArrayMethod "getSize" o = TabArrayGetSizeMethodInfo
        ResolveTabArrayMethod "getTab" o = TabArrayGetTabMethodInfo
        ResolveTabArrayMethod "setDecimalPoint" o = TabArraySetDecimalPointMethodInfo
        ResolveTabArrayMethod "setPositionsInPixels" o = TabArraySetPositionsInPixelsMethodInfo
        ResolveTabArrayMethod "setTab" o = TabArraySetTabMethodInfo
        ResolveTabArrayMethod l o = O.MethodResolutionFailed l o

    instance (info ~ ResolveTabArrayMethod t TabArray, O.OverloadedMethod info TabArray p) => OL.IsLabel t (TabArray -> 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 ~ ResolveTabArrayMethod t TabArray, O.OverloadedMethod info TabArray p, R.HasField t TabArray p) => R.HasField t TabArray p where
        getField = O.overloadedMethod @info

    #endif

    instance (info ~ ResolveTabArrayMethod t TabArray, O.OverloadedMethodInfo info TabArray) => OL.IsLabel t (O.MethodProxy info TabArray) where
    #if MIN_VERSION_base(4,10,0)
        fromLabel = O.MethodProxy
    #else
        fromLabel _ = O.MethodProxy
    #endif

    #endif