{- |
Copyright  : Will Thompson, Iñaki García Etxebarria and Jonas Platte
License    : LGPL-2.1
Maintainer : Iñaki García Etxebarria (garetxe@gmail.com)
-}

module GI.Gtk.Objects.PrintSettings
    ( 

-- * Exported types
    PrintSettings(..)                       ,
    PrintSettingsK                          ,
    toPrintSettings                         ,
    noPrintSettings                         ,


 -- * Methods
-- ** printSettingsCopy
    printSettingsCopy                       ,


-- ** printSettingsForeach
    printSettingsForeach                    ,


-- ** printSettingsGet
    printSettingsGet                        ,


-- ** printSettingsGetBool
    printSettingsGetBool                    ,


-- ** printSettingsGetCollate
    printSettingsGetCollate                 ,


-- ** printSettingsGetDefaultSource
    printSettingsGetDefaultSource           ,


-- ** printSettingsGetDither
    printSettingsGetDither                  ,


-- ** printSettingsGetDouble
    printSettingsGetDouble                  ,


-- ** printSettingsGetDoubleWithDefault
    printSettingsGetDoubleWithDefault       ,


-- ** printSettingsGetDuplex
    printSettingsGetDuplex                  ,


-- ** printSettingsGetFinishings
    printSettingsGetFinishings              ,


-- ** printSettingsGetInt
    printSettingsGetInt                     ,


-- ** printSettingsGetIntWithDefault
    printSettingsGetIntWithDefault          ,


-- ** printSettingsGetLength
    printSettingsGetLength                  ,


-- ** printSettingsGetMediaType
    printSettingsGetMediaType               ,


-- ** printSettingsGetNCopies
    printSettingsGetNCopies                 ,


-- ** printSettingsGetNumberUp
    printSettingsGetNumberUp                ,


-- ** printSettingsGetNumberUpLayout
    printSettingsGetNumberUpLayout          ,


-- ** printSettingsGetOrientation
    printSettingsGetOrientation             ,


-- ** printSettingsGetOutputBin
    printSettingsGetOutputBin               ,


-- ** printSettingsGetPageRanges
    printSettingsGetPageRanges              ,


-- ** printSettingsGetPageSet
    printSettingsGetPageSet                 ,


-- ** printSettingsGetPaperHeight
    printSettingsGetPaperHeight             ,


-- ** printSettingsGetPaperSize
    printSettingsGetPaperSize               ,


-- ** printSettingsGetPaperWidth
    printSettingsGetPaperWidth              ,


-- ** printSettingsGetPrintPages
    printSettingsGetPrintPages              ,


-- ** printSettingsGetPrinter
    printSettingsGetPrinter                 ,


-- ** printSettingsGetPrinterLpi
    printSettingsGetPrinterLpi              ,


-- ** printSettingsGetQuality
    printSettingsGetQuality                 ,


-- ** printSettingsGetResolution
    printSettingsGetResolution              ,


-- ** printSettingsGetResolutionX
    printSettingsGetResolutionX             ,


-- ** printSettingsGetResolutionY
    printSettingsGetResolutionY             ,


-- ** printSettingsGetReverse
    printSettingsGetReverse                 ,


-- ** printSettingsGetScale
    printSettingsGetScale                   ,


-- ** printSettingsGetUseColor
    printSettingsGetUseColor                ,


-- ** printSettingsHasKey
    printSettingsHasKey                     ,


-- ** printSettingsLoadFile
    printSettingsLoadFile                   ,


-- ** printSettingsLoadKeyFile
    printSettingsLoadKeyFile                ,


-- ** printSettingsNew
    printSettingsNew                        ,


-- ** printSettingsNewFromFile
    printSettingsNewFromFile                ,


-- ** printSettingsNewFromKeyFile
    printSettingsNewFromKeyFile             ,


-- ** printSettingsSet
    printSettingsSet                        ,


-- ** printSettingsSetBool
    printSettingsSetBool                    ,


-- ** printSettingsSetCollate
    printSettingsSetCollate                 ,


-- ** printSettingsSetDefaultSource
    printSettingsSetDefaultSource           ,


-- ** printSettingsSetDither
    printSettingsSetDither                  ,


-- ** printSettingsSetDouble
    printSettingsSetDouble                  ,


-- ** printSettingsSetDuplex
    printSettingsSetDuplex                  ,


-- ** printSettingsSetFinishings
    printSettingsSetFinishings              ,


-- ** printSettingsSetInt
    printSettingsSetInt                     ,


-- ** printSettingsSetLength
    printSettingsSetLength                  ,


-- ** printSettingsSetMediaType
    printSettingsSetMediaType               ,


-- ** printSettingsSetNCopies
    printSettingsSetNCopies                 ,


-- ** printSettingsSetNumberUp
    printSettingsSetNumberUp                ,


-- ** printSettingsSetNumberUpLayout
    printSettingsSetNumberUpLayout          ,


-- ** printSettingsSetOrientation
    printSettingsSetOrientation             ,


-- ** printSettingsSetOutputBin
    printSettingsSetOutputBin               ,


-- ** printSettingsSetPageRanges
    printSettingsSetPageRanges              ,


-- ** printSettingsSetPageSet
    printSettingsSetPageSet                 ,


-- ** printSettingsSetPaperHeight
    printSettingsSetPaperHeight             ,


-- ** printSettingsSetPaperSize
    printSettingsSetPaperSize               ,


-- ** printSettingsSetPaperWidth
    printSettingsSetPaperWidth              ,


-- ** printSettingsSetPrintPages
    printSettingsSetPrintPages              ,


-- ** printSettingsSetPrinter
    printSettingsSetPrinter                 ,


-- ** printSettingsSetPrinterLpi
    printSettingsSetPrinterLpi              ,


-- ** printSettingsSetQuality
    printSettingsSetQuality                 ,


-- ** printSettingsSetResolution
    printSettingsSetResolution              ,


-- ** printSettingsSetResolutionXy
    printSettingsSetResolutionXy            ,


-- ** printSettingsSetReverse
    printSettingsSetReverse                 ,


-- ** printSettingsSetScale
    printSettingsSetScale                   ,


-- ** printSettingsSetUseColor
    printSettingsSetUseColor                ,


-- ** printSettingsToFile
    printSettingsToFile                     ,


-- ** printSettingsToKeyFile
    printSettingsToKeyFile                  ,


-- ** printSettingsUnset
    printSettingsUnset                      ,




    ) where

import Prelude ()
import Data.GI.Base.ShortPrelude

import qualified Data.Text as T
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map

import GI.Gtk.Types
import GI.Gtk.Callbacks
import qualified GI.GLib as GLib
import qualified GI.GObject as GObject

newtype PrintSettings = PrintSettings (ForeignPtr PrintSettings)
foreign import ccall "gtk_print_settings_get_type"
    c_gtk_print_settings_get_type :: IO GType

type instance ParentTypes PrintSettings = PrintSettingsParentTypes
type PrintSettingsParentTypes = '[GObject.Object]

instance GObject PrintSettings where
    gobjectIsInitiallyUnowned _ = False
    gobjectType _ = c_gtk_print_settings_get_type
    

class GObject o => PrintSettingsK o
instance (GObject o, IsDescendantOf PrintSettings o) => PrintSettingsK o

toPrintSettings :: PrintSettingsK o => o -> IO PrintSettings
toPrintSettings = unsafeCastTo PrintSettings

noPrintSettings :: Maybe PrintSettings
noPrintSettings = Nothing

type instance AttributeList PrintSettings = PrintSettingsAttributeList
type PrintSettingsAttributeList = ('[ ] :: [(Symbol, *)])

type instance SignalList PrintSettings = PrintSettingsSignalList
type PrintSettingsSignalList = ('[ '("notify", GObject.ObjectNotifySignalInfo), '("notify::[property]", GObjectNotifySignalInfo)] :: [(Symbol, *)])

-- method PrintSettings::new
-- method type : Constructor
-- Args : []
-- Lengths : []
-- hInArgs : []
-- returnType : TInterface "Gtk" "PrintSettings"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_new" gtk_print_settings_new :: 
    IO (Ptr PrintSettings)


printSettingsNew ::
    (MonadIO m) =>
    m PrintSettings
printSettingsNew  = liftIO $ do
    result <- gtk_print_settings_new
    checkUnexpectedReturnNULL "gtk_print_settings_new" result
    result' <- (wrapObject PrintSettings) result
    return result'

-- method PrintSettings::new_from_file
-- method type : Constructor
-- Args : [Arg {argName = "file_name", argType = TBasicType TFileName, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "file_name", argType = TBasicType TFileName, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PrintSettings"
-- throws : True
-- Skip return : False

foreign import ccall "gtk_print_settings_new_from_file" gtk_print_settings_new_from_file :: 
    CString ->                              -- file_name : TBasicType TFileName
    Ptr (Ptr GError) ->                     -- error
    IO (Ptr PrintSettings)


printSettingsNewFromFile ::
    (MonadIO m) =>
    [Char] ->                               -- file_name
    m PrintSettings
printSettingsNewFromFile file_name = liftIO $ do
    file_name' <- stringToCString file_name
    onException (do
        result <- propagateGError $ gtk_print_settings_new_from_file file_name'
        checkUnexpectedReturnNULL "gtk_print_settings_new_from_file" result
        result' <- (wrapObject PrintSettings) result
        freeMem file_name'
        return result'
     ) (do
        freeMem file_name'
     )

-- method PrintSettings::new_from_key_file
-- method type : Constructor
-- Args : [Arg {argName = "key_file", argType = TInterface "GLib" "KeyFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group_name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "key_file", argType = TInterface "GLib" "KeyFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group_name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PrintSettings"
-- throws : True
-- Skip return : False

foreign import ccall "gtk_print_settings_new_from_key_file" gtk_print_settings_new_from_key_file :: 
    Ptr GLib.KeyFile ->                     -- key_file : TInterface "GLib" "KeyFile"
    CString ->                              -- group_name : TBasicType TUTF8
    Ptr (Ptr GError) ->                     -- error
    IO (Ptr PrintSettings)


printSettingsNewFromKeyFile ::
    (MonadIO m) =>
    GLib.KeyFile ->                         -- key_file
    Maybe (T.Text) ->                       -- group_name
    m PrintSettings
printSettingsNewFromKeyFile key_file group_name = liftIO $ do
    let key_file' = unsafeManagedPtrGetPtr key_file
    maybeGroup_name <- case group_name of
        Nothing -> return nullPtr
        Just jGroup_name -> do
            jGroup_name' <- textToCString jGroup_name
            return jGroup_name'
    onException (do
        result <- propagateGError $ gtk_print_settings_new_from_key_file key_file' maybeGroup_name
        checkUnexpectedReturnNULL "gtk_print_settings_new_from_key_file" result
        result' <- (wrapObject PrintSettings) result
        touchManagedPtr key_file
        freeMem maybeGroup_name
        return result'
     ) (do
        freeMem maybeGroup_name
     )

-- method PrintSettings::copy
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PrintSettings"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_copy" gtk_print_settings_copy :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO (Ptr PrintSettings)


printSettingsCopy ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m PrintSettings
printSettingsCopy _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_copy _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_copy" result
    result' <- (wrapObject PrintSettings) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::foreach
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "func", argType = TInterface "Gtk" "PrintSettingsFunc", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeCall, argClosure = 2, argDestroy = -1, transfer = TransferNothing},Arg {argName = "user_data", argType = TBasicType TVoid, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "func", argType = TInterface "Gtk" "PrintSettingsFunc", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeCall, argClosure = 2, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_foreach" gtk_print_settings_foreach :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    FunPtr PrintSettingsFuncC ->            -- func : TInterface "Gtk" "PrintSettingsFunc"
    Ptr () ->                               -- user_data : TBasicType TVoid
    IO ()


printSettingsForeach ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    PrintSettingsFunc ->                    -- func
    m ()
printSettingsForeach _obj func = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    func' <- mkPrintSettingsFunc (printSettingsFuncWrapper Nothing func)
    let user_data = nullPtr
    gtk_print_settings_foreach _obj' func' user_data
    safeFreeFunPtr $ castFunPtrToPtr func'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::get
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUTF8
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get" gtk_print_settings_get :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    IO CString


printSettingsGet ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    m T.Text
printSettingsGet _obj key = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    result <- gtk_print_settings_get _obj' key'
    checkUnexpectedReturnNULL "gtk_print_settings_get" result
    result' <- cstringToText result
    touchManagedPtr _obj
    freeMem key'
    return result'

-- method PrintSettings::get_bool
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_bool" gtk_print_settings_get_bool :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    IO CInt


printSettingsGetBool ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    m Bool
printSettingsGetBool _obj key = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    result <- gtk_print_settings_get_bool _obj' key'
    let result' = (/= 0) result
    touchManagedPtr _obj
    freeMem key'
    return result'

-- method PrintSettings::get_collate
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_collate" gtk_print_settings_get_collate :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CInt


printSettingsGetCollate ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Bool
printSettingsGetCollate _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_collate _obj'
    let result' = (/= 0) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_default_source
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUTF8
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_default_source" gtk_print_settings_get_default_source :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CString


printSettingsGetDefaultSource ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m T.Text
printSettingsGetDefaultSource _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_default_source _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_get_default_source" result
    result' <- cstringToText result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_dither
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUTF8
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_dither" gtk_print_settings_get_dither :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CString


printSettingsGetDither ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m T.Text
printSettingsGetDither _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_dither _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_get_dither" result
    result' <- cstringToText result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_double
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TDouble
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_double" gtk_print_settings_get_double :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    IO CDouble


printSettingsGetDouble ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    m Double
printSettingsGetDouble _obj key = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    result <- gtk_print_settings_get_double _obj' key'
    let result' = realToFrac result
    touchManagedPtr _obj
    freeMem key'
    return result'

-- method PrintSettings::get_double_with_default
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "def", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "def", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TDouble
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_double_with_default" gtk_print_settings_get_double_with_default :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    CDouble ->                              -- def : TBasicType TDouble
    IO CDouble


printSettingsGetDoubleWithDefault ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Double ->                               -- def
    m Double
printSettingsGetDoubleWithDefault _obj key def = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    let def' = realToFrac def
    result <- gtk_print_settings_get_double_with_default _obj' key' def'
    let result' = realToFrac result
    touchManagedPtr _obj
    freeMem key'
    return result'

-- method PrintSettings::get_duplex
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PrintDuplex"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_duplex" gtk_print_settings_get_duplex :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CUInt


printSettingsGetDuplex ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m PrintDuplex
printSettingsGetDuplex _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_duplex _obj'
    let result' = (toEnum . fromIntegral) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_finishings
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUTF8
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_finishings" gtk_print_settings_get_finishings :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CString


printSettingsGetFinishings ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m T.Text
printSettingsGetFinishings _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_finishings _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_get_finishings" result
    result' <- cstringToText result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_int
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TInt32
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_int" gtk_print_settings_get_int :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    IO Int32


printSettingsGetInt ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    m Int32
printSettingsGetInt _obj key = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    result <- gtk_print_settings_get_int _obj' key'
    touchManagedPtr _obj
    freeMem key'
    return result

-- method PrintSettings::get_int_with_default
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "def", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "def", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TInt32
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_int_with_default" gtk_print_settings_get_int_with_default :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    Int32 ->                                -- def : TBasicType TInt32
    IO Int32


printSettingsGetIntWithDefault ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Int32 ->                                -- def
    m Int32
printSettingsGetIntWithDefault _obj key def = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    result <- gtk_print_settings_get_int_with_default _obj' key' def
    touchManagedPtr _obj
    freeMem key'
    return result

-- method PrintSettings::get_length
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TDouble
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_length" gtk_print_settings_get_length :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    CUInt ->                                -- unit : TInterface "Gtk" "Unit"
    IO CDouble


printSettingsGetLength ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Unit ->                                 -- unit
    m Double
printSettingsGetLength _obj key unit = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    let unit' = (fromIntegral . fromEnum) unit
    result <- gtk_print_settings_get_length _obj' key' unit'
    let result' = realToFrac result
    touchManagedPtr _obj
    freeMem key'
    return result'

-- method PrintSettings::get_media_type
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUTF8
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_media_type" gtk_print_settings_get_media_type :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CString


printSettingsGetMediaType ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m T.Text
printSettingsGetMediaType _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_media_type _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_get_media_type" result
    result' <- cstringToText result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_n_copies
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TInt32
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_n_copies" gtk_print_settings_get_n_copies :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO Int32


printSettingsGetNCopies ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Int32
printSettingsGetNCopies _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_n_copies _obj'
    touchManagedPtr _obj
    return result

-- method PrintSettings::get_number_up
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TInt32
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_number_up" gtk_print_settings_get_number_up :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO Int32


printSettingsGetNumberUp ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Int32
printSettingsGetNumberUp _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_number_up _obj'
    touchManagedPtr _obj
    return result

-- method PrintSettings::get_number_up_layout
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "NumberUpLayout"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_number_up_layout" gtk_print_settings_get_number_up_layout :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CUInt


printSettingsGetNumberUpLayout ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m NumberUpLayout
printSettingsGetNumberUpLayout _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_number_up_layout _obj'
    let result' = (toEnum . fromIntegral) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_orientation
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PageOrientation"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_orientation" gtk_print_settings_get_orientation :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CUInt


printSettingsGetOrientation ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m PageOrientation
printSettingsGetOrientation _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_orientation _obj'
    let result' = (toEnum . fromIntegral) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_output_bin
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUTF8
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_output_bin" gtk_print_settings_get_output_bin :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CString


printSettingsGetOutputBin ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m T.Text
printSettingsGetOutputBin _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_output_bin _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_get_output_bin" result
    result' <- cstringToText result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_page_ranges
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "num_ranges", argType = TBasicType TInt32, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}]
-- Lengths : [Arg {argName = "num_ranges", argType = TBasicType TInt32, direction = DirectionOut, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferEverything}]
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TCArray False (-1) 1 (TInterface "Gtk" "PageRange")
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_page_ranges" gtk_print_settings_get_page_ranges :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Ptr Int32 ->                            -- num_ranges : TBasicType TInt32
    IO (Ptr PageRange)


printSettingsGetPageRanges ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m [PageRange]
printSettingsGetPageRanges _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    num_ranges <- allocMem :: IO (Ptr Int32)
    result <- gtk_print_settings_get_page_ranges _obj' num_ranges
    num_ranges' <- peek num_ranges
    checkUnexpectedReturnNULL "gtk_print_settings_get_page_ranges" result
    result' <- (unpackBlockArrayWithLength 8 num_ranges') result
    result'' <- mapM (wrapPtr PageRange) result'
    freeMem result
    touchManagedPtr _obj
    freeMem num_ranges
    return result''

-- method PrintSettings::get_page_set
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PageSet"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_page_set" gtk_print_settings_get_page_set :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CUInt


printSettingsGetPageSet ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m PageSet
printSettingsGetPageSet _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_page_set _obj'
    let result' = (toEnum . fromIntegral) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_paper_height
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TDouble
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_paper_height" gtk_print_settings_get_paper_height :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- unit : TInterface "Gtk" "Unit"
    IO CDouble


printSettingsGetPaperHeight ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Unit ->                                 -- unit
    m Double
printSettingsGetPaperHeight _obj unit = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let unit' = (fromIntegral . fromEnum) unit
    result <- gtk_print_settings_get_paper_height _obj' unit'
    let result' = realToFrac result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_paper_size
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PaperSize"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_paper_size" gtk_print_settings_get_paper_size :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO (Ptr PaperSize)


printSettingsGetPaperSize ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m PaperSize
printSettingsGetPaperSize _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_paper_size _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_get_paper_size" result
    result' <- (wrapBoxed PaperSize) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_paper_width
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TDouble
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_paper_width" gtk_print_settings_get_paper_width :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- unit : TInterface "Gtk" "Unit"
    IO CDouble


printSettingsGetPaperWidth ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Unit ->                                 -- unit
    m Double
printSettingsGetPaperWidth _obj unit = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let unit' = (fromIntegral . fromEnum) unit
    result <- gtk_print_settings_get_paper_width _obj' unit'
    let result' = realToFrac result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_print_pages
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PrintPages"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_print_pages" gtk_print_settings_get_print_pages :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CUInt


printSettingsGetPrintPages ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m PrintPages
printSettingsGetPrintPages _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_print_pages _obj'
    let result' = (toEnum . fromIntegral) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_printer
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TUTF8
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_printer" gtk_print_settings_get_printer :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CString


printSettingsGetPrinter ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m T.Text
printSettingsGetPrinter _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_printer _obj'
    checkUnexpectedReturnNULL "gtk_print_settings_get_printer" result
    result' <- cstringToText result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_printer_lpi
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TDouble
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_printer_lpi" gtk_print_settings_get_printer_lpi :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CDouble


printSettingsGetPrinterLpi ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Double
printSettingsGetPrinterLpi _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_printer_lpi _obj'
    let result' = realToFrac result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_quality
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "PrintQuality"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_quality" gtk_print_settings_get_quality :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CUInt


printSettingsGetQuality ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m PrintQuality
printSettingsGetQuality _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_quality _obj'
    let result' = (toEnum . fromIntegral) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_resolution
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TInt32
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_resolution" gtk_print_settings_get_resolution :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO Int32


printSettingsGetResolution ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Int32
printSettingsGetResolution _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_resolution _obj'
    touchManagedPtr _obj
    return result

-- method PrintSettings::get_resolution_x
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TInt32
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_resolution_x" gtk_print_settings_get_resolution_x :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO Int32


printSettingsGetResolutionX ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Int32
printSettingsGetResolutionX _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_resolution_x _obj'
    touchManagedPtr _obj
    return result

-- method PrintSettings::get_resolution_y
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TInt32
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_resolution_y" gtk_print_settings_get_resolution_y :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO Int32


printSettingsGetResolutionY ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Int32
printSettingsGetResolutionY _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_resolution_y _obj'
    touchManagedPtr _obj
    return result

-- method PrintSettings::get_reverse
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_reverse" gtk_print_settings_get_reverse :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CInt


printSettingsGetReverse ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Bool
printSettingsGetReverse _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_reverse _obj'
    let result' = (/= 0) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_scale
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TDouble
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_scale" gtk_print_settings_get_scale :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CDouble


printSettingsGetScale ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Double
printSettingsGetScale _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_scale _obj'
    let result' = realToFrac result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::get_use_color
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_get_use_color" gtk_print_settings_get_use_color :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    IO CInt


printSettingsGetUseColor ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    m Bool
printSettingsGetUseColor _obj = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    result <- gtk_print_settings_get_use_color _obj'
    let result' = (/= 0) result
    touchManagedPtr _obj
    return result'

-- method PrintSettings::has_key
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_has_key" gtk_print_settings_has_key :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    IO CInt


printSettingsHasKey ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    m Bool
printSettingsHasKey _obj key = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    result <- gtk_print_settings_has_key _obj' key'
    let result' = (/= 0) result
    touchManagedPtr _obj
    freeMem key'
    return result'

-- method PrintSettings::load_file
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "file_name", argType = TBasicType TFileName, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "file_name", argType = TBasicType TFileName, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : True
-- Skip return : False

foreign import ccall "gtk_print_settings_load_file" gtk_print_settings_load_file :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- file_name : TBasicType TFileName
    Ptr (Ptr GError) ->                     -- error
    IO CInt


printSettingsLoadFile ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    [Char] ->                               -- file_name
    m ()
printSettingsLoadFile _obj file_name = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    file_name' <- stringToCString file_name
    onException (do
        _ <- propagateGError $ gtk_print_settings_load_file _obj' file_name'
        touchManagedPtr _obj
        freeMem file_name'
        return ()
     ) (do
        freeMem file_name'
     )

-- method PrintSettings::load_key_file
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key_file", argType = TInterface "GLib" "KeyFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group_name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key_file", argType = TInterface "GLib" "KeyFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group_name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : True
-- Skip return : False

foreign import ccall "gtk_print_settings_load_key_file" gtk_print_settings_load_key_file :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Ptr GLib.KeyFile ->                     -- key_file : TInterface "GLib" "KeyFile"
    CString ->                              -- group_name : TBasicType TUTF8
    Ptr (Ptr GError) ->                     -- error
    IO CInt


printSettingsLoadKeyFile ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    GLib.KeyFile ->                         -- key_file
    Maybe (T.Text) ->                       -- group_name
    m ()
printSettingsLoadKeyFile _obj key_file group_name = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let key_file' = unsafeManagedPtrGetPtr key_file
    maybeGroup_name <- case group_name of
        Nothing -> return nullPtr
        Just jGroup_name -> do
            jGroup_name' <- textToCString jGroup_name
            return jGroup_name'
    onException (do
        _ <- propagateGError $ gtk_print_settings_load_key_file _obj' key_file' maybeGroup_name
        touchManagedPtr _obj
        touchManagedPtr key_file
        freeMem maybeGroup_name
        return ()
     ) (do
        freeMem maybeGroup_name
     )

-- method PrintSettings::set
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = True, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set" gtk_print_settings_set :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    CString ->                              -- value : TBasicType TUTF8
    IO ()


printSettingsSet ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Maybe (T.Text) ->                       -- value
    m ()
printSettingsSet _obj key value = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    maybeValue <- case value of
        Nothing -> return nullPtr
        Just jValue -> do
            jValue' <- textToCString jValue
            return jValue'
    gtk_print_settings_set _obj' key' maybeValue
    touchManagedPtr _obj
    freeMem key'
    freeMem maybeValue
    return ()

-- method PrintSettings::set_bool
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_bool" gtk_print_settings_set_bool :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    CInt ->                                 -- value : TBasicType TBoolean
    IO ()


printSettingsSetBool ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Bool ->                                 -- value
    m ()
printSettingsSetBool _obj key value = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    let value' = (fromIntegral . fromEnum) value
    gtk_print_settings_set_bool _obj' key' value'
    touchManagedPtr _obj
    freeMem key'
    return ()

-- method PrintSettings::set_collate
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "collate", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "collate", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_collate" gtk_print_settings_set_collate :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CInt ->                                 -- collate : TBasicType TBoolean
    IO ()


printSettingsSetCollate ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Bool ->                                 -- collate
    m ()
printSettingsSetCollate _obj collate = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let collate' = (fromIntegral . fromEnum) collate
    gtk_print_settings_set_collate _obj' collate'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_default_source
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "default_source", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "default_source", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_default_source" gtk_print_settings_set_default_source :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- default_source : TBasicType TUTF8
    IO ()


printSettingsSetDefaultSource ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- default_source
    m ()
printSettingsSetDefaultSource _obj default_source = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    default_source' <- textToCString default_source
    gtk_print_settings_set_default_source _obj' default_source'
    touchManagedPtr _obj
    freeMem default_source'
    return ()

-- method PrintSettings::set_dither
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "dither", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "dither", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_dither" gtk_print_settings_set_dither :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- dither : TBasicType TUTF8
    IO ()


printSettingsSetDither ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- dither
    m ()
printSettingsSetDither _obj dither = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    dither' <- textToCString dither
    gtk_print_settings_set_dither _obj' dither'
    touchManagedPtr _obj
    freeMem dither'
    return ()

-- method PrintSettings::set_double
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_double" gtk_print_settings_set_double :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    CDouble ->                              -- value : TBasicType TDouble
    IO ()


printSettingsSetDouble ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Double ->                               -- value
    m ()
printSettingsSetDouble _obj key value = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    let value' = realToFrac value
    gtk_print_settings_set_double _obj' key' value'
    touchManagedPtr _obj
    freeMem key'
    return ()

-- method PrintSettings::set_duplex
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "duplex", argType = TInterface "Gtk" "PrintDuplex", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "duplex", argType = TInterface "Gtk" "PrintDuplex", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_duplex" gtk_print_settings_set_duplex :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- duplex : TInterface "Gtk" "PrintDuplex"
    IO ()


printSettingsSetDuplex ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    PrintDuplex ->                          -- duplex
    m ()
printSettingsSetDuplex _obj duplex = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let duplex' = (fromIntegral . fromEnum) duplex
    gtk_print_settings_set_duplex _obj' duplex'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_finishings
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "finishings", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "finishings", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_finishings" gtk_print_settings_set_finishings :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- finishings : TBasicType TUTF8
    IO ()


printSettingsSetFinishings ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- finishings
    m ()
printSettingsSetFinishings _obj finishings = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    finishings' <- textToCString finishings
    gtk_print_settings_set_finishings _obj' finishings'
    touchManagedPtr _obj
    freeMem finishings'
    return ()

-- method PrintSettings::set_int
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_int" gtk_print_settings_set_int :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    Int32 ->                                -- value : TBasicType TInt32
    IO ()


printSettingsSetInt ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Int32 ->                                -- value
    m ()
printSettingsSetInt _obj key value = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    gtk_print_settings_set_int _obj' key' value
    touchManagedPtr _obj
    freeMem key'
    return ()

-- method PrintSettings::set_length
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_length" gtk_print_settings_set_length :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    CDouble ->                              -- value : TBasicType TDouble
    CUInt ->                                -- unit : TInterface "Gtk" "Unit"
    IO ()


printSettingsSetLength ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    Double ->                               -- value
    Unit ->                                 -- unit
    m ()
printSettingsSetLength _obj key value unit = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    let value' = realToFrac value
    let unit' = (fromIntegral . fromEnum) unit
    gtk_print_settings_set_length _obj' key' value' unit'
    touchManagedPtr _obj
    freeMem key'
    return ()

-- method PrintSettings::set_media_type
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "media_type", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "media_type", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_media_type" gtk_print_settings_set_media_type :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- media_type : TBasicType TUTF8
    IO ()


printSettingsSetMediaType ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- media_type
    m ()
printSettingsSetMediaType _obj media_type = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    media_type' <- textToCString media_type
    gtk_print_settings_set_media_type _obj' media_type'
    touchManagedPtr _obj
    freeMem media_type'
    return ()

-- method PrintSettings::set_n_copies
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "num_copies", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "num_copies", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_n_copies" gtk_print_settings_set_n_copies :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Int32 ->                                -- num_copies : TBasicType TInt32
    IO ()


printSettingsSetNCopies ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Int32 ->                                -- num_copies
    m ()
printSettingsSetNCopies _obj num_copies = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    gtk_print_settings_set_n_copies _obj' num_copies
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_number_up
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "number_up", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "number_up", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_number_up" gtk_print_settings_set_number_up :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Int32 ->                                -- number_up : TBasicType TInt32
    IO ()


printSettingsSetNumberUp ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Int32 ->                                -- number_up
    m ()
printSettingsSetNumberUp _obj number_up = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    gtk_print_settings_set_number_up _obj' number_up
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_number_up_layout
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "number_up_layout", argType = TInterface "Gtk" "NumberUpLayout", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "number_up_layout", argType = TInterface "Gtk" "NumberUpLayout", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_number_up_layout" gtk_print_settings_set_number_up_layout :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- number_up_layout : TInterface "Gtk" "NumberUpLayout"
    IO ()


printSettingsSetNumberUpLayout ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    NumberUpLayout ->                       -- number_up_layout
    m ()
printSettingsSetNumberUpLayout _obj number_up_layout = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let number_up_layout' = (fromIntegral . fromEnum) number_up_layout
    gtk_print_settings_set_number_up_layout _obj' number_up_layout'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_orientation
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "orientation", argType = TInterface "Gtk" "PageOrientation", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "orientation", argType = TInterface "Gtk" "PageOrientation", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_orientation" gtk_print_settings_set_orientation :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- orientation : TInterface "Gtk" "PageOrientation"
    IO ()


printSettingsSetOrientation ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    PageOrientation ->                      -- orientation
    m ()
printSettingsSetOrientation _obj orientation = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let orientation' = (fromIntegral . fromEnum) orientation
    gtk_print_settings_set_orientation _obj' orientation'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_output_bin
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "output_bin", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "output_bin", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_output_bin" gtk_print_settings_set_output_bin :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- output_bin : TBasicType TUTF8
    IO ()


printSettingsSetOutputBin ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- output_bin
    m ()
printSettingsSetOutputBin _obj output_bin = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    output_bin' <- textToCString output_bin
    gtk_print_settings_set_output_bin _obj' output_bin'
    touchManagedPtr _obj
    freeMem output_bin'
    return ()

-- method PrintSettings::set_page_ranges
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "page_ranges", argType = TCArray False (-1) 2 (TInterface "Gtk" "PageRange"), direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "num_ranges", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : [Arg {argName = "num_ranges", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "page_ranges", argType = TCArray False (-1) 2 (TInterface "Gtk" "PageRange"), direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_page_ranges" gtk_print_settings_set_page_ranges :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Ptr PageRange ->                        -- page_ranges : TCArray False (-1) 2 (TInterface "Gtk" "PageRange")
    Int32 ->                                -- num_ranges : TBasicType TInt32
    IO ()


printSettingsSetPageRanges ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    [PageRange] ->                          -- page_ranges
    m ()
printSettingsSetPageRanges _obj page_ranges = liftIO $ do
    let num_ranges = fromIntegral $ length page_ranges
    let _obj' = unsafeManagedPtrCastPtr _obj
    let page_ranges' = map unsafeManagedPtrGetPtr page_ranges
    page_ranges'' <- packBlockArray 8 page_ranges'
    gtk_print_settings_set_page_ranges _obj' page_ranges'' num_ranges
    touchManagedPtr _obj
    mapM_ touchManagedPtr page_ranges
    freeMem page_ranges''
    return ()

-- method PrintSettings::set_page_set
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "page_set", argType = TInterface "Gtk" "PageSet", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "page_set", argType = TInterface "Gtk" "PageSet", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_page_set" gtk_print_settings_set_page_set :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- page_set : TInterface "Gtk" "PageSet"
    IO ()


printSettingsSetPageSet ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    PageSet ->                              -- page_set
    m ()
printSettingsSetPageSet _obj page_set = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let page_set' = (fromIntegral . fromEnum) page_set
    gtk_print_settings_set_page_set _obj' page_set'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_paper_height
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "height", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "height", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_paper_height" gtk_print_settings_set_paper_height :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CDouble ->                              -- height : TBasicType TDouble
    CUInt ->                                -- unit : TInterface "Gtk" "Unit"
    IO ()


printSettingsSetPaperHeight ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Double ->                               -- height
    Unit ->                                 -- unit
    m ()
printSettingsSetPaperHeight _obj height unit = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let height' = realToFrac height
    let unit' = (fromIntegral . fromEnum) unit
    gtk_print_settings_set_paper_height _obj' height' unit'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_paper_size
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "paper_size", argType = TInterface "Gtk" "PaperSize", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "paper_size", argType = TInterface "Gtk" "PaperSize", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_paper_size" gtk_print_settings_set_paper_size :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Ptr PaperSize ->                        -- paper_size : TInterface "Gtk" "PaperSize"
    IO ()


printSettingsSetPaperSize ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    PaperSize ->                            -- paper_size
    m ()
printSettingsSetPaperSize _obj paper_size = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let paper_size' = unsafeManagedPtrGetPtr paper_size
    gtk_print_settings_set_paper_size _obj' paper_size'
    touchManagedPtr _obj
    touchManagedPtr paper_size
    return ()

-- method PrintSettings::set_paper_width
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "width", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "width", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "unit", argType = TInterface "Gtk" "Unit", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_paper_width" gtk_print_settings_set_paper_width :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CDouble ->                              -- width : TBasicType TDouble
    CUInt ->                                -- unit : TInterface "Gtk" "Unit"
    IO ()


printSettingsSetPaperWidth ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Double ->                               -- width
    Unit ->                                 -- unit
    m ()
printSettingsSetPaperWidth _obj width unit = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let width' = realToFrac width
    let unit' = (fromIntegral . fromEnum) unit
    gtk_print_settings_set_paper_width _obj' width' unit'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_print_pages
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "pages", argType = TInterface "Gtk" "PrintPages", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "pages", argType = TInterface "Gtk" "PrintPages", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_print_pages" gtk_print_settings_set_print_pages :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- pages : TInterface "Gtk" "PrintPages"
    IO ()


printSettingsSetPrintPages ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    PrintPages ->                           -- pages
    m ()
printSettingsSetPrintPages _obj pages = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let pages' = (fromIntegral . fromEnum) pages
    gtk_print_settings_set_print_pages _obj' pages'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_printer
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "printer", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "printer", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_printer" gtk_print_settings_set_printer :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- printer : TBasicType TUTF8
    IO ()


printSettingsSetPrinter ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- printer
    m ()
printSettingsSetPrinter _obj printer = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    printer' <- textToCString printer
    gtk_print_settings_set_printer _obj' printer'
    touchManagedPtr _obj
    freeMem printer'
    return ()

-- method PrintSettings::set_printer_lpi
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "lpi", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "lpi", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_printer_lpi" gtk_print_settings_set_printer_lpi :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CDouble ->                              -- lpi : TBasicType TDouble
    IO ()


printSettingsSetPrinterLpi ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Double ->                               -- lpi
    m ()
printSettingsSetPrinterLpi _obj lpi = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let lpi' = realToFrac lpi
    gtk_print_settings_set_printer_lpi _obj' lpi'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_quality
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "quality", argType = TInterface "Gtk" "PrintQuality", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "quality", argType = TInterface "Gtk" "PrintQuality", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_quality" gtk_print_settings_set_quality :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CUInt ->                                -- quality : TInterface "Gtk" "PrintQuality"
    IO ()


printSettingsSetQuality ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    PrintQuality ->                         -- quality
    m ()
printSettingsSetQuality _obj quality = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let quality' = (fromIntegral . fromEnum) quality
    gtk_print_settings_set_quality _obj' quality'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_resolution
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "resolution", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "resolution", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_resolution" gtk_print_settings_set_resolution :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Int32 ->                                -- resolution : TBasicType TInt32
    IO ()


printSettingsSetResolution ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Int32 ->                                -- resolution
    m ()
printSettingsSetResolution _obj resolution = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    gtk_print_settings_set_resolution _obj' resolution
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_resolution_xy
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "resolution_x", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "resolution_y", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "resolution_x", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "resolution_y", argType = TBasicType TInt32, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_resolution_xy" gtk_print_settings_set_resolution_xy :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Int32 ->                                -- resolution_x : TBasicType TInt32
    Int32 ->                                -- resolution_y : TBasicType TInt32
    IO ()


printSettingsSetResolutionXy ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Int32 ->                                -- resolution_x
    Int32 ->                                -- resolution_y
    m ()
printSettingsSetResolutionXy _obj resolution_x resolution_y = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    gtk_print_settings_set_resolution_xy _obj' resolution_x resolution_y
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_reverse
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "reverse", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "reverse", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_reverse" gtk_print_settings_set_reverse :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CInt ->                                 -- reverse : TBasicType TBoolean
    IO ()


printSettingsSetReverse ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Bool ->                                 -- reverse
    m ()
printSettingsSetReverse _obj reverse = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let reverse' = (fromIntegral . fromEnum) reverse
    gtk_print_settings_set_reverse _obj' reverse'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_scale
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "scale", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "scale", argType = TBasicType TDouble, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_scale" gtk_print_settings_set_scale :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CDouble ->                              -- scale : TBasicType TDouble
    IO ()


printSettingsSetScale ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Double ->                               -- scale
    m ()
printSettingsSetScale _obj scale = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let scale' = realToFrac scale
    gtk_print_settings_set_scale _obj' scale'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::set_use_color
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "use_color", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "use_color", argType = TBasicType TBoolean, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_set_use_color" gtk_print_settings_set_use_color :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CInt ->                                 -- use_color : TBasicType TBoolean
    IO ()


printSettingsSetUseColor ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    Bool ->                                 -- use_color
    m ()
printSettingsSetUseColor _obj use_color = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let use_color' = (fromIntegral . fromEnum) use_color
    gtk_print_settings_set_use_color _obj' use_color'
    touchManagedPtr _obj
    return ()

-- method PrintSettings::to_file
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "file_name", argType = TBasicType TFileName, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "file_name", argType = TBasicType TFileName, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TBoolean
-- throws : True
-- Skip return : False

foreign import ccall "gtk_print_settings_to_file" gtk_print_settings_to_file :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- file_name : TBasicType TFileName
    Ptr (Ptr GError) ->                     -- error
    IO CInt


printSettingsToFile ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    [Char] ->                               -- file_name
    m ()
printSettingsToFile _obj file_name = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    file_name' <- stringToCString file_name
    onException (do
        _ <- propagateGError $ gtk_print_settings_to_file _obj' file_name'
        touchManagedPtr _obj
        freeMem file_name'
        return ()
     ) (do
        freeMem file_name'
     )

-- method PrintSettings::to_key_file
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key_file", argType = TInterface "GLib" "KeyFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group_name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key_file", argType = TInterface "GLib" "KeyFile", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "group_name", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_to_key_file" gtk_print_settings_to_key_file :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    Ptr GLib.KeyFile ->                     -- key_file : TInterface "GLib" "KeyFile"
    CString ->                              -- group_name : TBasicType TUTF8
    IO ()


printSettingsToKeyFile ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    GLib.KeyFile ->                         -- key_file
    T.Text ->                               -- group_name
    m ()
printSettingsToKeyFile _obj key_file group_name = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    let key_file' = unsafeManagedPtrGetPtr key_file
    group_name' <- textToCString group_name
    gtk_print_settings_to_key_file _obj' key_file' group_name'
    touchManagedPtr _obj
    touchManagedPtr key_file
    freeMem group_name'
    return ()

-- method PrintSettings::unset
-- method type : OrdinaryMethod
-- Args : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "_obj", argType = TInterface "Gtk" "PrintSettings", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "key", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TBasicType TVoid
-- throws : False
-- Skip return : False

foreign import ccall "gtk_print_settings_unset" gtk_print_settings_unset :: 
    Ptr PrintSettings ->                    -- _obj : TInterface "Gtk" "PrintSettings"
    CString ->                              -- key : TBasicType TUTF8
    IO ()


printSettingsUnset ::
    (MonadIO m, PrintSettingsK a) =>
    a ->                                    -- _obj
    T.Text ->                               -- key
    m ()
printSettingsUnset _obj key = liftIO $ do
    let _obj' = unsafeManagedPtrCastPtr _obj
    key' <- textToCString key
    gtk_print_settings_unset _obj' key'
    touchManagedPtr _obj
    freeMem key'
    return ()