{-# LANGUAGE TypeApplications #-}


-- | Copyright  : Will Thompson, Iñaki García Etxebarria and Jonas Platte
-- License    : LGPL-2.1
-- Maintainer : Iñaki García Etxebarria
-- 
-- A t'GI.Gtk.Objects.CheckButton.CheckButton' places a label next to an indicator.
-- 
-- = CSS nodes
-- 
-- 
-- === /plain code/
-- >
-- >checkbutton[.text-button]
-- >├── check
-- >╰── [label]
-- 
-- 
-- A t'GI.Gtk.Objects.CheckButton.CheckButton' has a main node with name checkbutton. If the
-- t'GI.Gtk.Objects.CheckButton.CheckButton':@/label/@ property is set, it contains a label child.
-- The indicator node is named check when no group is set, and radio
-- if the checkbutton is grouped together with other checkbuttons.
-- 
-- = Accessibility
-- 
-- GtkCheckButton uses the @/GTK_ACCESSIBLE_ROLE_CHECKBOX/@ role.

#if (MIN_VERSION_haskell_gi_overloading(1,0,0) && !defined(__HADDOCK_VERSION__))
#define ENABLE_OVERLOADING
#endif

module GI.Gtk.Objects.CheckButton
    ( 

-- * Exported types
    CheckButton(..)                         ,
    IsCheckButton                           ,
    toCheckButton                           ,


 -- * Methods
-- | 
-- 
--  === __Click to display all available methods, including inherited ones__
-- ==== Methods
-- [actionSetEnabled]("GI.Gtk.Objects.Widget#g:method:actionSetEnabled"), [activate]("GI.Gtk.Objects.Widget#g:method:activate"), [activateAction]("GI.Gtk.Objects.Widget#g:method:activateAction"), [activateDefault]("GI.Gtk.Objects.Widget#g:method:activateDefault"), [addController]("GI.Gtk.Objects.Widget#g:method:addController"), [addCssClass]("GI.Gtk.Objects.Widget#g:method:addCssClass"), [addMnemonicLabel]("GI.Gtk.Objects.Widget#g:method:addMnemonicLabel"), [addTickCallback]("GI.Gtk.Objects.Widget#g:method:addTickCallback"), [allocate]("GI.Gtk.Objects.Widget#g:method:allocate"), [bindProperty]("GI.GObject.Objects.Object#g:method:bindProperty"), [bindPropertyFull]("GI.GObject.Objects.Object#g:method:bindPropertyFull"), [childFocus]("GI.Gtk.Objects.Widget#g:method:childFocus"), [computeBounds]("GI.Gtk.Objects.Widget#g:method:computeBounds"), [computeExpand]("GI.Gtk.Objects.Widget#g:method:computeExpand"), [computePoint]("GI.Gtk.Objects.Widget#g:method:computePoint"), [computeTransform]("GI.Gtk.Objects.Widget#g:method:computeTransform"), [contains]("GI.Gtk.Objects.Widget#g:method:contains"), [createPangoContext]("GI.Gtk.Objects.Widget#g:method:createPangoContext"), [createPangoLayout]("GI.Gtk.Objects.Widget#g:method:createPangoLayout"), [dragCheckThreshold]("GI.Gtk.Objects.Widget#g:method:dragCheckThreshold"), [errorBell]("GI.Gtk.Objects.Widget#g:method:errorBell"), [forceFloating]("GI.GObject.Objects.Object#g:method:forceFloating"), [freezeNotify]("GI.GObject.Objects.Object#g:method:freezeNotify"), [getv]("GI.GObject.Objects.Object#g:method:getv"), [grabFocus]("GI.Gtk.Objects.Widget#g:method:grabFocus"), [hasCssClass]("GI.Gtk.Objects.Widget#g:method:hasCssClass"), [hasDefault]("GI.Gtk.Objects.Widget#g:method:hasDefault"), [hasFocus]("GI.Gtk.Objects.Widget#g:method:hasFocus"), [hasVisibleFocus]("GI.Gtk.Objects.Widget#g:method:hasVisibleFocus"), [hide]("GI.Gtk.Objects.Widget#g:method:hide"), [inDestruction]("GI.Gtk.Objects.Widget#g:method:inDestruction"), [initTemplate]("GI.Gtk.Objects.Widget#g:method:initTemplate"), [insertActionGroup]("GI.Gtk.Objects.Widget#g:method:insertActionGroup"), [insertAfter]("GI.Gtk.Objects.Widget#g:method:insertAfter"), [insertBefore]("GI.Gtk.Objects.Widget#g:method:insertBefore"), [isAncestor]("GI.Gtk.Objects.Widget#g:method:isAncestor"), [isDrawable]("GI.Gtk.Objects.Widget#g:method:isDrawable"), [isFloating]("GI.GObject.Objects.Object#g:method:isFloating"), [isFocus]("GI.Gtk.Objects.Widget#g:method:isFocus"), [isSensitive]("GI.Gtk.Objects.Widget#g:method:isSensitive"), [isVisible]("GI.Gtk.Objects.Widget#g:method:isVisible"), [keynavFailed]("GI.Gtk.Objects.Widget#g:method:keynavFailed"), [listMnemonicLabels]("GI.Gtk.Objects.Widget#g:method:listMnemonicLabels"), [map]("GI.Gtk.Objects.Widget#g:method:map"), [measure]("GI.Gtk.Objects.Widget#g:method:measure"), [mnemonicActivate]("GI.Gtk.Objects.Widget#g:method:mnemonicActivate"), [notify]("GI.GObject.Objects.Object#g:method:notify"), [notifyByPspec]("GI.GObject.Objects.Object#g:method:notifyByPspec"), [observeChildren]("GI.Gtk.Objects.Widget#g:method:observeChildren"), [observeControllers]("GI.Gtk.Objects.Widget#g:method:observeControllers"), [pick]("GI.Gtk.Objects.Widget#g:method:pick"), [queueAllocate]("GI.Gtk.Objects.Widget#g:method:queueAllocate"), [queueDraw]("GI.Gtk.Objects.Widget#g:method:queueDraw"), [queueResize]("GI.Gtk.Objects.Widget#g:method:queueResize"), [realize]("GI.Gtk.Objects.Widget#g:method:realize"), [ref]("GI.GObject.Objects.Object#g:method:ref"), [refSink]("GI.GObject.Objects.Object#g:method:refSink"), [removeController]("GI.Gtk.Objects.Widget#g:method:removeController"), [removeCssClass]("GI.Gtk.Objects.Widget#g:method:removeCssClass"), [removeMnemonicLabel]("GI.Gtk.Objects.Widget#g:method:removeMnemonicLabel"), [removeTickCallback]("GI.Gtk.Objects.Widget#g:method:removeTickCallback"), [resetProperty]("GI.Gtk.Interfaces.Accessible#g:method:resetProperty"), [resetRelation]("GI.Gtk.Interfaces.Accessible#g:method:resetRelation"), [resetState]("GI.Gtk.Interfaces.Accessible#g:method:resetState"), [runDispose]("GI.GObject.Objects.Object#g:method:runDispose"), [shouldLayout]("GI.Gtk.Objects.Widget#g:method:shouldLayout"), [show]("GI.Gtk.Objects.Widget#g:method:show"), [sizeAllocate]("GI.Gtk.Objects.Widget#g:method:sizeAllocate"), [snapshotChild]("GI.Gtk.Objects.Widget#g:method:snapshotChild"), [stealData]("GI.GObject.Objects.Object#g:method:stealData"), [stealQdata]("GI.GObject.Objects.Object#g:method:stealQdata"), [thawNotify]("GI.GObject.Objects.Object#g:method:thawNotify"), [translateCoordinates]("GI.Gtk.Objects.Widget#g:method:translateCoordinates"), [triggerTooltipQuery]("GI.Gtk.Objects.Widget#g:method:triggerTooltipQuery"), [unmap]("GI.Gtk.Objects.Widget#g:method:unmap"), [unparent]("GI.Gtk.Objects.Widget#g:method:unparent"), [unrealize]("GI.Gtk.Objects.Widget#g:method:unrealize"), [unref]("GI.GObject.Objects.Object#g:method:unref"), [unsetStateFlags]("GI.Gtk.Objects.Widget#g:method:unsetStateFlags"), [updateProperty]("GI.Gtk.Interfaces.Accessible#g:method:updateProperty"), [updateRelation]("GI.Gtk.Interfaces.Accessible#g:method:updateRelation"), [updateState]("GI.Gtk.Interfaces.Accessible#g:method:updateState"), [watchClosure]("GI.GObject.Objects.Object#g:method:watchClosure").
-- 
-- ==== Getters
-- [getAccessibleRole]("GI.Gtk.Interfaces.Accessible#g:method:getAccessibleRole"), [getActionName]("GI.Gtk.Interfaces.Actionable#g:method:getActionName"), [getActionTargetValue]("GI.Gtk.Interfaces.Actionable#g:method:getActionTargetValue"), [getActive]("GI.Gtk.Objects.CheckButton#g:method:getActive"), [getAllocatedBaseline]("GI.Gtk.Objects.Widget#g:method:getAllocatedBaseline"), [getAllocatedHeight]("GI.Gtk.Objects.Widget#g:method:getAllocatedHeight"), [getAllocatedWidth]("GI.Gtk.Objects.Widget#g:method:getAllocatedWidth"), [getAllocation]("GI.Gtk.Objects.Widget#g:method:getAllocation"), [getAncestor]("GI.Gtk.Objects.Widget#g:method:getAncestor"), [getBuildableId]("GI.Gtk.Interfaces.Buildable#g:method:getBuildableId"), [getCanFocus]("GI.Gtk.Objects.Widget#g:method:getCanFocus"), [getCanTarget]("GI.Gtk.Objects.Widget#g:method:getCanTarget"), [getChildVisible]("GI.Gtk.Objects.Widget#g:method:getChildVisible"), [getClipboard]("GI.Gtk.Objects.Widget#g:method:getClipboard"), [getCssClasses]("GI.Gtk.Objects.Widget#g:method:getCssClasses"), [getCssName]("GI.Gtk.Objects.Widget#g:method:getCssName"), [getCursor]("GI.Gtk.Objects.Widget#g:method:getCursor"), [getData]("GI.GObject.Objects.Object#g:method:getData"), [getDirection]("GI.Gtk.Objects.Widget#g:method:getDirection"), [getDisplay]("GI.Gtk.Objects.Widget#g:method:getDisplay"), [getFirstChild]("GI.Gtk.Objects.Widget#g:method:getFirstChild"), [getFocusChild]("GI.Gtk.Objects.Widget#g:method:getFocusChild"), [getFocusOnClick]("GI.Gtk.Objects.Widget#g:method:getFocusOnClick"), [getFocusable]("GI.Gtk.Objects.Widget#g:method:getFocusable"), [getFontMap]("GI.Gtk.Objects.Widget#g:method:getFontMap"), [getFontOptions]("GI.Gtk.Objects.Widget#g:method:getFontOptions"), [getFrameClock]("GI.Gtk.Objects.Widget#g:method:getFrameClock"), [getHalign]("GI.Gtk.Objects.Widget#g:method:getHalign"), [getHasTooltip]("GI.Gtk.Objects.Widget#g:method:getHasTooltip"), [getHeight]("GI.Gtk.Objects.Widget#g:method:getHeight"), [getHexpand]("GI.Gtk.Objects.Widget#g:method:getHexpand"), [getHexpandSet]("GI.Gtk.Objects.Widget#g:method:getHexpandSet"), [getInconsistent]("GI.Gtk.Objects.CheckButton#g:method:getInconsistent"), [getLabel]("GI.Gtk.Objects.CheckButton#g:method:getLabel"), [getLastChild]("GI.Gtk.Objects.Widget#g:method:getLastChild"), [getLayoutManager]("GI.Gtk.Objects.Widget#g:method:getLayoutManager"), [getMapped]("GI.Gtk.Objects.Widget#g:method:getMapped"), [getMarginBottom]("GI.Gtk.Objects.Widget#g:method:getMarginBottom"), [getMarginEnd]("GI.Gtk.Objects.Widget#g:method:getMarginEnd"), [getMarginStart]("GI.Gtk.Objects.Widget#g:method:getMarginStart"), [getMarginTop]("GI.Gtk.Objects.Widget#g:method:getMarginTop"), [getName]("GI.Gtk.Objects.Widget#g:method:getName"), [getNative]("GI.Gtk.Objects.Widget#g:method:getNative"), [getNextSibling]("GI.Gtk.Objects.Widget#g:method:getNextSibling"), [getOpacity]("GI.Gtk.Objects.Widget#g:method:getOpacity"), [getOverflow]("GI.Gtk.Objects.Widget#g:method:getOverflow"), [getPangoContext]("GI.Gtk.Objects.Widget#g:method:getPangoContext"), [getParent]("GI.Gtk.Objects.Widget#g:method:getParent"), [getPreferredSize]("GI.Gtk.Objects.Widget#g:method:getPreferredSize"), [getPrevSibling]("GI.Gtk.Objects.Widget#g:method:getPrevSibling"), [getPrimaryClipboard]("GI.Gtk.Objects.Widget#g:method:getPrimaryClipboard"), [getProperty]("GI.GObject.Objects.Object#g:method:getProperty"), [getQdata]("GI.GObject.Objects.Object#g:method:getQdata"), [getRealized]("GI.Gtk.Objects.Widget#g:method:getRealized"), [getReceivesDefault]("GI.Gtk.Objects.Widget#g:method:getReceivesDefault"), [getRequestMode]("GI.Gtk.Objects.Widget#g:method:getRequestMode"), [getRoot]("GI.Gtk.Objects.Widget#g:method:getRoot"), [getScaleFactor]("GI.Gtk.Objects.Widget#g:method:getScaleFactor"), [getSensitive]("GI.Gtk.Objects.Widget#g:method:getSensitive"), [getSettings]("GI.Gtk.Objects.Widget#g:method:getSettings"), [getSize]("GI.Gtk.Objects.Widget#g:method:getSize"), [getSizeRequest]("GI.Gtk.Objects.Widget#g:method:getSizeRequest"), [getStateFlags]("GI.Gtk.Objects.Widget#g:method:getStateFlags"), [getStyleContext]("GI.Gtk.Objects.Widget#g:method:getStyleContext"), [getTemplateChild]("GI.Gtk.Objects.Widget#g:method:getTemplateChild"), [getTooltipMarkup]("GI.Gtk.Objects.Widget#g:method:getTooltipMarkup"), [getTooltipText]("GI.Gtk.Objects.Widget#g:method:getTooltipText"), [getUseUnderline]("GI.Gtk.Objects.CheckButton#g:method:getUseUnderline"), [getValign]("GI.Gtk.Objects.Widget#g:method:getValign"), [getVexpand]("GI.Gtk.Objects.Widget#g:method:getVexpand"), [getVexpandSet]("GI.Gtk.Objects.Widget#g:method:getVexpandSet"), [getVisible]("GI.Gtk.Objects.Widget#g:method:getVisible"), [getWidth]("GI.Gtk.Objects.Widget#g:method:getWidth").
-- 
-- ==== Setters
-- [setActionName]("GI.Gtk.Interfaces.Actionable#g:method:setActionName"), [setActionTargetValue]("GI.Gtk.Interfaces.Actionable#g:method:setActionTargetValue"), [setActive]("GI.Gtk.Objects.CheckButton#g:method:setActive"), [setCanFocus]("GI.Gtk.Objects.Widget#g:method:setCanFocus"), [setCanTarget]("GI.Gtk.Objects.Widget#g:method:setCanTarget"), [setChildVisible]("GI.Gtk.Objects.Widget#g:method:setChildVisible"), [setCssClasses]("GI.Gtk.Objects.Widget#g:method:setCssClasses"), [setCursor]("GI.Gtk.Objects.Widget#g:method:setCursor"), [setCursorFromName]("GI.Gtk.Objects.Widget#g:method:setCursorFromName"), [setData]("GI.GObject.Objects.Object#g:method:setData"), [setDataFull]("GI.GObject.Objects.Object#g:method:setDataFull"), [setDetailedActionName]("GI.Gtk.Interfaces.Actionable#g:method:setDetailedActionName"), [setDirection]("GI.Gtk.Objects.Widget#g:method:setDirection"), [setFocusChild]("GI.Gtk.Objects.Widget#g:method:setFocusChild"), [setFocusOnClick]("GI.Gtk.Objects.Widget#g:method:setFocusOnClick"), [setFocusable]("GI.Gtk.Objects.Widget#g:method:setFocusable"), [setFontMap]("GI.Gtk.Objects.Widget#g:method:setFontMap"), [setFontOptions]("GI.Gtk.Objects.Widget#g:method:setFontOptions"), [setGroup]("GI.Gtk.Objects.CheckButton#g:method:setGroup"), [setHalign]("GI.Gtk.Objects.Widget#g:method:setHalign"), [setHasTooltip]("GI.Gtk.Objects.Widget#g:method:setHasTooltip"), [setHexpand]("GI.Gtk.Objects.Widget#g:method:setHexpand"), [setHexpandSet]("GI.Gtk.Objects.Widget#g:method:setHexpandSet"), [setInconsistent]("GI.Gtk.Objects.CheckButton#g:method:setInconsistent"), [setLabel]("GI.Gtk.Objects.CheckButton#g:method:setLabel"), [setLayoutManager]("GI.Gtk.Objects.Widget#g:method:setLayoutManager"), [setMarginBottom]("GI.Gtk.Objects.Widget#g:method:setMarginBottom"), [setMarginEnd]("GI.Gtk.Objects.Widget#g:method:setMarginEnd"), [setMarginStart]("GI.Gtk.Objects.Widget#g:method:setMarginStart"), [setMarginTop]("GI.Gtk.Objects.Widget#g:method:setMarginTop"), [setName]("GI.Gtk.Objects.Widget#g:method:setName"), [setOpacity]("GI.Gtk.Objects.Widget#g:method:setOpacity"), [setOverflow]("GI.Gtk.Objects.Widget#g:method:setOverflow"), [setParent]("GI.Gtk.Objects.Widget#g:method:setParent"), [setProperty]("GI.GObject.Objects.Object#g:method:setProperty"), [setReceivesDefault]("GI.Gtk.Objects.Widget#g:method:setReceivesDefault"), [setSensitive]("GI.Gtk.Objects.Widget#g:method:setSensitive"), [setSizeRequest]("GI.Gtk.Objects.Widget#g:method:setSizeRequest"), [setStateFlags]("GI.Gtk.Objects.Widget#g:method:setStateFlags"), [setTooltipMarkup]("GI.Gtk.Objects.Widget#g:method:setTooltipMarkup"), [setTooltipText]("GI.Gtk.Objects.Widget#g:method:setTooltipText"), [setUseUnderline]("GI.Gtk.Objects.CheckButton#g:method:setUseUnderline"), [setValign]("GI.Gtk.Objects.Widget#g:method:setValign"), [setVexpand]("GI.Gtk.Objects.Widget#g:method:setVexpand"), [setVexpandSet]("GI.Gtk.Objects.Widget#g:method:setVexpandSet"), [setVisible]("GI.Gtk.Objects.Widget#g:method:setVisible").

#if defined(ENABLE_OVERLOADING)
    ResolveCheckButtonMethod                ,
#endif

-- ** getActive #method:getActive#

#if defined(ENABLE_OVERLOADING)
    CheckButtonGetActiveMethodInfo          ,
#endif
    checkButtonGetActive                    ,


-- ** getInconsistent #method:getInconsistent#

#if defined(ENABLE_OVERLOADING)
    CheckButtonGetInconsistentMethodInfo    ,
#endif
    checkButtonGetInconsistent              ,


-- ** getLabel #method:getLabel#

#if defined(ENABLE_OVERLOADING)
    CheckButtonGetLabelMethodInfo           ,
#endif
    checkButtonGetLabel                     ,


-- ** getUseUnderline #method:getUseUnderline#

#if defined(ENABLE_OVERLOADING)
    CheckButtonGetUseUnderlineMethodInfo    ,
#endif
    checkButtonGetUseUnderline              ,


-- ** new #method:new#

    checkButtonNew                          ,


-- ** newWithLabel #method:newWithLabel#

    checkButtonNewWithLabel                 ,


-- ** newWithMnemonic #method:newWithMnemonic#

    checkButtonNewWithMnemonic              ,


-- ** setActive #method:setActive#

#if defined(ENABLE_OVERLOADING)
    CheckButtonSetActiveMethodInfo          ,
#endif
    checkButtonSetActive                    ,


-- ** setGroup #method:setGroup#

#if defined(ENABLE_OVERLOADING)
    CheckButtonSetGroupMethodInfo           ,
#endif
    checkButtonSetGroup                     ,


-- ** setInconsistent #method:setInconsistent#

#if defined(ENABLE_OVERLOADING)
    CheckButtonSetInconsistentMethodInfo    ,
#endif
    checkButtonSetInconsistent              ,


-- ** setLabel #method:setLabel#

#if defined(ENABLE_OVERLOADING)
    CheckButtonSetLabelMethodInfo           ,
#endif
    checkButtonSetLabel                     ,


-- ** setUseUnderline #method:setUseUnderline#

#if defined(ENABLE_OVERLOADING)
    CheckButtonSetUseUnderlineMethodInfo    ,
#endif
    checkButtonSetUseUnderline              ,




 -- * Properties


-- ** active #attr:active#
-- | /No description available in the introspection data./

#if defined(ENABLE_OVERLOADING)
    CheckButtonActivePropertyInfo           ,
#endif
#if defined(ENABLE_OVERLOADING)
    checkButtonActive                       ,
#endif
    constructCheckButtonActive              ,
    getCheckButtonActive                    ,
    setCheckButtonActive                    ,


-- ** group #attr:group#
-- | /No description available in the introspection data./

#if defined(ENABLE_OVERLOADING)
    CheckButtonGroupPropertyInfo            ,
#endif
#if defined(ENABLE_OVERLOADING)
    checkButtonGroup                        ,
#endif
    clearCheckButtonGroup                   ,
    constructCheckButtonGroup               ,
    setCheckButtonGroup                     ,


-- ** inconsistent #attr:inconsistent#
-- | /No description available in the introspection data./

#if defined(ENABLE_OVERLOADING)
    CheckButtonInconsistentPropertyInfo     ,
#endif
#if defined(ENABLE_OVERLOADING)
    checkButtonInconsistent                 ,
#endif
    constructCheckButtonInconsistent        ,
    getCheckButtonInconsistent              ,
    setCheckButtonInconsistent              ,


-- ** label #attr:label#
-- | /No description available in the introspection data./

#if defined(ENABLE_OVERLOADING)
    CheckButtonLabelPropertyInfo            ,
#endif
#if defined(ENABLE_OVERLOADING)
    checkButtonLabel                        ,
#endif
    clearCheckButtonLabel                   ,
    constructCheckButtonLabel               ,
    getCheckButtonLabel                     ,
    setCheckButtonLabel                     ,


-- ** useUnderline #attr:useUnderline#
-- | /No description available in the introspection data./

#if defined(ENABLE_OVERLOADING)
    CheckButtonUseUnderlinePropertyInfo     ,
#endif
#if defined(ENABLE_OVERLOADING)
    checkButtonUseUnderline                 ,
#endif
    constructCheckButtonUseUnderline        ,
    getCheckButtonUseUnderline              ,
    setCheckButtonUseUnderline              ,




 -- * Signals


-- ** toggled #signal:toggled#

    C_CheckButtonToggledCallback            ,
    CheckButtonToggledCallback              ,
#if defined(ENABLE_OVERLOADING)
    CheckButtonToggledSignalInfo            ,
#endif
    afterCheckButtonToggled                 ,
    genClosure_CheckButtonToggled           ,
    mk_CheckButtonToggledCallback           ,
    noCheckButtonToggledCallback            ,
    onCheckButtonToggled                    ,
    wrap_CheckButtonToggledCallback         ,




    ) where

import Data.GI.Base.ShortPrelude
import qualified Data.GI.Base.ShortPrelude as SP
import qualified Data.GI.Base.Overloading as O
import qualified Prelude as P

import qualified Data.GI.Base.Attributes as GI.Attributes
import qualified Data.GI.Base.BasicTypes as B.Types
import qualified Data.GI.Base.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GArray as B.GArray
import qualified Data.GI.Base.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GValue as B.GValue
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
import qualified Data.GI.Base.Properties as B.Properties
import qualified Data.GI.Base.Signals as B.Signals
import qualified Control.Monad.IO.Class as MIO
import qualified Data.Text as T
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GHC.OverloadedLabels as OL
import qualified GHC.Records as R

import qualified GI.GObject.Objects.Object as GObject.Object
import {-# SOURCE #-} qualified GI.Gtk.Interfaces.Accessible as Gtk.Accessible
import {-# SOURCE #-} qualified GI.Gtk.Interfaces.Actionable as Gtk.Actionable
import {-# SOURCE #-} qualified GI.Gtk.Interfaces.Buildable as Gtk.Buildable
import {-# SOURCE #-} qualified GI.Gtk.Interfaces.ConstraintTarget as Gtk.ConstraintTarget
import {-# SOURCE #-} qualified GI.Gtk.Objects.Widget as Gtk.Widget

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

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

foreign import ccall "gtk_check_button_get_type"
    c_gtk_check_button_get_type :: IO B.Types.GType

instance B.Types.TypedObject CheckButton where
    glibType :: IO GType
glibType = IO GType
c_gtk_check_button_get_type

instance B.Types.GObject CheckButton

-- | Type class for types which can be safely cast to `CheckButton`, for instance with `toCheckButton`.
class (SP.GObject o, O.IsDescendantOf CheckButton o) => IsCheckButton o
instance (SP.GObject o, O.IsDescendantOf CheckButton o) => IsCheckButton o

instance O.HasParentTypes CheckButton
type instance O.ParentTypes CheckButton = '[Gtk.Widget.Widget, GObject.Object.Object, Gtk.Accessible.Accessible, Gtk.Actionable.Actionable, Gtk.Buildable.Buildable, Gtk.ConstraintTarget.ConstraintTarget]

-- | Cast to `CheckButton`, for types for which this is known to be safe. For general casts, use `Data.GI.Base.ManagedPtr.castTo`.
toCheckButton :: (MIO.MonadIO m, IsCheckButton o) => o -> m CheckButton
toCheckButton :: forall (m :: * -> *) o.
(MonadIO m, IsCheckButton o) =>
o -> m CheckButton
toCheckButton = IO CheckButton -> m CheckButton
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO CheckButton -> m CheckButton)
-> (o -> IO CheckButton) -> o -> m CheckButton
forall b c a. (b -> c) -> (a -> b) -> a -> c
. (ManagedPtr CheckButton -> CheckButton) -> o -> IO CheckButton
forall o o'.
(HasCallStack, ManagedPtrNewtype o, TypedObject o,
 ManagedPtrNewtype o', TypedObject o') =>
(ManagedPtr o' -> o') -> o -> IO o'
B.ManagedPtr.unsafeCastTo ManagedPtr CheckButton -> CheckButton
CheckButton

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

#if defined(ENABLE_OVERLOADING)
type family ResolveCheckButtonMethod (t :: Symbol) (o :: *) :: * where
    ResolveCheckButtonMethod "actionSetEnabled" o = Gtk.Widget.WidgetActionSetEnabledMethodInfo
    ResolveCheckButtonMethod "activate" o = Gtk.Widget.WidgetActivateMethodInfo
    ResolveCheckButtonMethod "activateAction" o = Gtk.Widget.WidgetActivateActionMethodInfo
    ResolveCheckButtonMethod "activateDefault" o = Gtk.Widget.WidgetActivateDefaultMethodInfo
    ResolveCheckButtonMethod "addController" o = Gtk.Widget.WidgetAddControllerMethodInfo
    ResolveCheckButtonMethod "addCssClass" o = Gtk.Widget.WidgetAddCssClassMethodInfo
    ResolveCheckButtonMethod "addMnemonicLabel" o = Gtk.Widget.WidgetAddMnemonicLabelMethodInfo
    ResolveCheckButtonMethod "addTickCallback" o = Gtk.Widget.WidgetAddTickCallbackMethodInfo
    ResolveCheckButtonMethod "allocate" o = Gtk.Widget.WidgetAllocateMethodInfo
    ResolveCheckButtonMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
    ResolveCheckButtonMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
    ResolveCheckButtonMethod "childFocus" o = Gtk.Widget.WidgetChildFocusMethodInfo
    ResolveCheckButtonMethod "computeBounds" o = Gtk.Widget.WidgetComputeBoundsMethodInfo
    ResolveCheckButtonMethod "computeExpand" o = Gtk.Widget.WidgetComputeExpandMethodInfo
    ResolveCheckButtonMethod "computePoint" o = Gtk.Widget.WidgetComputePointMethodInfo
    ResolveCheckButtonMethod "computeTransform" o = Gtk.Widget.WidgetComputeTransformMethodInfo
    ResolveCheckButtonMethod "contains" o = Gtk.Widget.WidgetContainsMethodInfo
    ResolveCheckButtonMethod "createPangoContext" o = Gtk.Widget.WidgetCreatePangoContextMethodInfo
    ResolveCheckButtonMethod "createPangoLayout" o = Gtk.Widget.WidgetCreatePangoLayoutMethodInfo
    ResolveCheckButtonMethod "dragCheckThreshold" o = Gtk.Widget.WidgetDragCheckThresholdMethodInfo
    ResolveCheckButtonMethod "errorBell" o = Gtk.Widget.WidgetErrorBellMethodInfo
    ResolveCheckButtonMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
    ResolveCheckButtonMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
    ResolveCheckButtonMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
    ResolveCheckButtonMethod "grabFocus" o = Gtk.Widget.WidgetGrabFocusMethodInfo
    ResolveCheckButtonMethod "hasCssClass" o = Gtk.Widget.WidgetHasCssClassMethodInfo
    ResolveCheckButtonMethod "hasDefault" o = Gtk.Widget.WidgetHasDefaultMethodInfo
    ResolveCheckButtonMethod "hasFocus" o = Gtk.Widget.WidgetHasFocusMethodInfo
    ResolveCheckButtonMethod "hasVisibleFocus" o = Gtk.Widget.WidgetHasVisibleFocusMethodInfo
    ResolveCheckButtonMethod "hide" o = Gtk.Widget.WidgetHideMethodInfo
    ResolveCheckButtonMethod "inDestruction" o = Gtk.Widget.WidgetInDestructionMethodInfo
    ResolveCheckButtonMethod "initTemplate" o = Gtk.Widget.WidgetInitTemplateMethodInfo
    ResolveCheckButtonMethod "insertActionGroup" o = Gtk.Widget.WidgetInsertActionGroupMethodInfo
    ResolveCheckButtonMethod "insertAfter" o = Gtk.Widget.WidgetInsertAfterMethodInfo
    ResolveCheckButtonMethod "insertBefore" o = Gtk.Widget.WidgetInsertBeforeMethodInfo
    ResolveCheckButtonMethod "isAncestor" o = Gtk.Widget.WidgetIsAncestorMethodInfo
    ResolveCheckButtonMethod "isDrawable" o = Gtk.Widget.WidgetIsDrawableMethodInfo
    ResolveCheckButtonMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
    ResolveCheckButtonMethod "isFocus" o = Gtk.Widget.WidgetIsFocusMethodInfo
    ResolveCheckButtonMethod "isSensitive" o = Gtk.Widget.WidgetIsSensitiveMethodInfo
    ResolveCheckButtonMethod "isVisible" o = Gtk.Widget.WidgetIsVisibleMethodInfo
    ResolveCheckButtonMethod "keynavFailed" o = Gtk.Widget.WidgetKeynavFailedMethodInfo
    ResolveCheckButtonMethod "listMnemonicLabels" o = Gtk.Widget.WidgetListMnemonicLabelsMethodInfo
    ResolveCheckButtonMethod "map" o = Gtk.Widget.WidgetMapMethodInfo
    ResolveCheckButtonMethod "measure" o = Gtk.Widget.WidgetMeasureMethodInfo
    ResolveCheckButtonMethod "mnemonicActivate" o = Gtk.Widget.WidgetMnemonicActivateMethodInfo
    ResolveCheckButtonMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
    ResolveCheckButtonMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
    ResolveCheckButtonMethod "observeChildren" o = Gtk.Widget.WidgetObserveChildrenMethodInfo
    ResolveCheckButtonMethod "observeControllers" o = Gtk.Widget.WidgetObserveControllersMethodInfo
    ResolveCheckButtonMethod "pick" o = Gtk.Widget.WidgetPickMethodInfo
    ResolveCheckButtonMethod "queueAllocate" o = Gtk.Widget.WidgetQueueAllocateMethodInfo
    ResolveCheckButtonMethod "queueDraw" o = Gtk.Widget.WidgetQueueDrawMethodInfo
    ResolveCheckButtonMethod "queueResize" o = Gtk.Widget.WidgetQueueResizeMethodInfo
    ResolveCheckButtonMethod "realize" o = Gtk.Widget.WidgetRealizeMethodInfo
    ResolveCheckButtonMethod "ref" o = GObject.Object.ObjectRefMethodInfo
    ResolveCheckButtonMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
    ResolveCheckButtonMethod "removeController" o = Gtk.Widget.WidgetRemoveControllerMethodInfo
    ResolveCheckButtonMethod "removeCssClass" o = Gtk.Widget.WidgetRemoveCssClassMethodInfo
    ResolveCheckButtonMethod "removeMnemonicLabel" o = Gtk.Widget.WidgetRemoveMnemonicLabelMethodInfo
    ResolveCheckButtonMethod "removeTickCallback" o = Gtk.Widget.WidgetRemoveTickCallbackMethodInfo
    ResolveCheckButtonMethod "resetProperty" o = Gtk.Accessible.AccessibleResetPropertyMethodInfo
    ResolveCheckButtonMethod "resetRelation" o = Gtk.Accessible.AccessibleResetRelationMethodInfo
    ResolveCheckButtonMethod "resetState" o = Gtk.Accessible.AccessibleResetStateMethodInfo
    ResolveCheckButtonMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
    ResolveCheckButtonMethod "shouldLayout" o = Gtk.Widget.WidgetShouldLayoutMethodInfo
    ResolveCheckButtonMethod "show" o = Gtk.Widget.WidgetShowMethodInfo
    ResolveCheckButtonMethod "sizeAllocate" o = Gtk.Widget.WidgetSizeAllocateMethodInfo
    ResolveCheckButtonMethod "snapshotChild" o = Gtk.Widget.WidgetSnapshotChildMethodInfo
    ResolveCheckButtonMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
    ResolveCheckButtonMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
    ResolveCheckButtonMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
    ResolveCheckButtonMethod "translateCoordinates" o = Gtk.Widget.WidgetTranslateCoordinatesMethodInfo
    ResolveCheckButtonMethod "triggerTooltipQuery" o = Gtk.Widget.WidgetTriggerTooltipQueryMethodInfo
    ResolveCheckButtonMethod "unmap" o = Gtk.Widget.WidgetUnmapMethodInfo
    ResolveCheckButtonMethod "unparent" o = Gtk.Widget.WidgetUnparentMethodInfo
    ResolveCheckButtonMethod "unrealize" o = Gtk.Widget.WidgetUnrealizeMethodInfo
    ResolveCheckButtonMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
    ResolveCheckButtonMethod "unsetStateFlags" o = Gtk.Widget.WidgetUnsetStateFlagsMethodInfo
    ResolveCheckButtonMethod "updateProperty" o = Gtk.Accessible.AccessibleUpdatePropertyMethodInfo
    ResolveCheckButtonMethod "updateRelation" o = Gtk.Accessible.AccessibleUpdateRelationMethodInfo
    ResolveCheckButtonMethod "updateState" o = Gtk.Accessible.AccessibleUpdateStateMethodInfo
    ResolveCheckButtonMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
    ResolveCheckButtonMethod "getAccessibleRole" o = Gtk.Accessible.AccessibleGetAccessibleRoleMethodInfo
    ResolveCheckButtonMethod "getActionName" o = Gtk.Actionable.ActionableGetActionNameMethodInfo
    ResolveCheckButtonMethod "getActionTargetValue" o = Gtk.Actionable.ActionableGetActionTargetValueMethodInfo
    ResolveCheckButtonMethod "getActive" o = CheckButtonGetActiveMethodInfo
    ResolveCheckButtonMethod "getAllocatedBaseline" o = Gtk.Widget.WidgetGetAllocatedBaselineMethodInfo
    ResolveCheckButtonMethod "getAllocatedHeight" o = Gtk.Widget.WidgetGetAllocatedHeightMethodInfo
    ResolveCheckButtonMethod "getAllocatedWidth" o = Gtk.Widget.WidgetGetAllocatedWidthMethodInfo
    ResolveCheckButtonMethod "getAllocation" o = Gtk.Widget.WidgetGetAllocationMethodInfo
    ResolveCheckButtonMethod "getAncestor" o = Gtk.Widget.WidgetGetAncestorMethodInfo
    ResolveCheckButtonMethod "getBuildableId" o = Gtk.Buildable.BuildableGetBuildableIdMethodInfo
    ResolveCheckButtonMethod "getCanFocus" o = Gtk.Widget.WidgetGetCanFocusMethodInfo
    ResolveCheckButtonMethod "getCanTarget" o = Gtk.Widget.WidgetGetCanTargetMethodInfo
    ResolveCheckButtonMethod "getChildVisible" o = Gtk.Widget.WidgetGetChildVisibleMethodInfo
    ResolveCheckButtonMethod "getClipboard" o = Gtk.Widget.WidgetGetClipboardMethodInfo
    ResolveCheckButtonMethod "getCssClasses" o = Gtk.Widget.WidgetGetCssClassesMethodInfo
    ResolveCheckButtonMethod "getCssName" o = Gtk.Widget.WidgetGetCssNameMethodInfo
    ResolveCheckButtonMethod "getCursor" o = Gtk.Widget.WidgetGetCursorMethodInfo
    ResolveCheckButtonMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
    ResolveCheckButtonMethod "getDirection" o = Gtk.Widget.WidgetGetDirectionMethodInfo
    ResolveCheckButtonMethod "getDisplay" o = Gtk.Widget.WidgetGetDisplayMethodInfo
    ResolveCheckButtonMethod "getFirstChild" o = Gtk.Widget.WidgetGetFirstChildMethodInfo
    ResolveCheckButtonMethod "getFocusChild" o = Gtk.Widget.WidgetGetFocusChildMethodInfo
    ResolveCheckButtonMethod "getFocusOnClick" o = Gtk.Widget.WidgetGetFocusOnClickMethodInfo
    ResolveCheckButtonMethod "getFocusable" o = Gtk.Widget.WidgetGetFocusableMethodInfo
    ResolveCheckButtonMethod "getFontMap" o = Gtk.Widget.WidgetGetFontMapMethodInfo
    ResolveCheckButtonMethod "getFontOptions" o = Gtk.Widget.WidgetGetFontOptionsMethodInfo
    ResolveCheckButtonMethod "getFrameClock" o = Gtk.Widget.WidgetGetFrameClockMethodInfo
    ResolveCheckButtonMethod "getHalign" o = Gtk.Widget.WidgetGetHalignMethodInfo
    ResolveCheckButtonMethod "getHasTooltip" o = Gtk.Widget.WidgetGetHasTooltipMethodInfo
    ResolveCheckButtonMethod "getHeight" o = Gtk.Widget.WidgetGetHeightMethodInfo
    ResolveCheckButtonMethod "getHexpand" o = Gtk.Widget.WidgetGetHexpandMethodInfo
    ResolveCheckButtonMethod "getHexpandSet" o = Gtk.Widget.WidgetGetHexpandSetMethodInfo
    ResolveCheckButtonMethod "getInconsistent" o = CheckButtonGetInconsistentMethodInfo
    ResolveCheckButtonMethod "getLabel" o = CheckButtonGetLabelMethodInfo
    ResolveCheckButtonMethod "getLastChild" o = Gtk.Widget.WidgetGetLastChildMethodInfo
    ResolveCheckButtonMethod "getLayoutManager" o = Gtk.Widget.WidgetGetLayoutManagerMethodInfo
    ResolveCheckButtonMethod "getMapped" o = Gtk.Widget.WidgetGetMappedMethodInfo
    ResolveCheckButtonMethod "getMarginBottom" o = Gtk.Widget.WidgetGetMarginBottomMethodInfo
    ResolveCheckButtonMethod "getMarginEnd" o = Gtk.Widget.WidgetGetMarginEndMethodInfo
    ResolveCheckButtonMethod "getMarginStart" o = Gtk.Widget.WidgetGetMarginStartMethodInfo
    ResolveCheckButtonMethod "getMarginTop" o = Gtk.Widget.WidgetGetMarginTopMethodInfo
    ResolveCheckButtonMethod "getName" o = Gtk.Widget.WidgetGetNameMethodInfo
    ResolveCheckButtonMethod "getNative" o = Gtk.Widget.WidgetGetNativeMethodInfo
    ResolveCheckButtonMethod "getNextSibling" o = Gtk.Widget.WidgetGetNextSiblingMethodInfo
    ResolveCheckButtonMethod "getOpacity" o = Gtk.Widget.WidgetGetOpacityMethodInfo
    ResolveCheckButtonMethod "getOverflow" o = Gtk.Widget.WidgetGetOverflowMethodInfo
    ResolveCheckButtonMethod "getPangoContext" o = Gtk.Widget.WidgetGetPangoContextMethodInfo
    ResolveCheckButtonMethod "getParent" o = Gtk.Widget.WidgetGetParentMethodInfo
    ResolveCheckButtonMethod "getPreferredSize" o = Gtk.Widget.WidgetGetPreferredSizeMethodInfo
    ResolveCheckButtonMethod "getPrevSibling" o = Gtk.Widget.WidgetGetPrevSiblingMethodInfo
    ResolveCheckButtonMethod "getPrimaryClipboard" o = Gtk.Widget.WidgetGetPrimaryClipboardMethodInfo
    ResolveCheckButtonMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
    ResolveCheckButtonMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
    ResolveCheckButtonMethod "getRealized" o = Gtk.Widget.WidgetGetRealizedMethodInfo
    ResolveCheckButtonMethod "getReceivesDefault" o = Gtk.Widget.WidgetGetReceivesDefaultMethodInfo
    ResolveCheckButtonMethod "getRequestMode" o = Gtk.Widget.WidgetGetRequestModeMethodInfo
    ResolveCheckButtonMethod "getRoot" o = Gtk.Widget.WidgetGetRootMethodInfo
    ResolveCheckButtonMethod "getScaleFactor" o = Gtk.Widget.WidgetGetScaleFactorMethodInfo
    ResolveCheckButtonMethod "getSensitive" o = Gtk.Widget.WidgetGetSensitiveMethodInfo
    ResolveCheckButtonMethod "getSettings" o = Gtk.Widget.WidgetGetSettingsMethodInfo
    ResolveCheckButtonMethod "getSize" o = Gtk.Widget.WidgetGetSizeMethodInfo
    ResolveCheckButtonMethod "getSizeRequest" o = Gtk.Widget.WidgetGetSizeRequestMethodInfo
    ResolveCheckButtonMethod "getStateFlags" o = Gtk.Widget.WidgetGetStateFlagsMethodInfo
    ResolveCheckButtonMethod "getStyleContext" o = Gtk.Widget.WidgetGetStyleContextMethodInfo
    ResolveCheckButtonMethod "getTemplateChild" o = Gtk.Widget.WidgetGetTemplateChildMethodInfo
    ResolveCheckButtonMethod "getTooltipMarkup" o = Gtk.Widget.WidgetGetTooltipMarkupMethodInfo
    ResolveCheckButtonMethod "getTooltipText" o = Gtk.Widget.WidgetGetTooltipTextMethodInfo
    ResolveCheckButtonMethod "getUseUnderline" o = CheckButtonGetUseUnderlineMethodInfo
    ResolveCheckButtonMethod "getValign" o = Gtk.Widget.WidgetGetValignMethodInfo
    ResolveCheckButtonMethod "getVexpand" o = Gtk.Widget.WidgetGetVexpandMethodInfo
    ResolveCheckButtonMethod "getVexpandSet" o = Gtk.Widget.WidgetGetVexpandSetMethodInfo
    ResolveCheckButtonMethod "getVisible" o = Gtk.Widget.WidgetGetVisibleMethodInfo
    ResolveCheckButtonMethod "getWidth" o = Gtk.Widget.WidgetGetWidthMethodInfo
    ResolveCheckButtonMethod "setActionName" o = Gtk.Actionable.ActionableSetActionNameMethodInfo
    ResolveCheckButtonMethod "setActionTargetValue" o = Gtk.Actionable.ActionableSetActionTargetValueMethodInfo
    ResolveCheckButtonMethod "setActive" o = CheckButtonSetActiveMethodInfo
    ResolveCheckButtonMethod "setCanFocus" o = Gtk.Widget.WidgetSetCanFocusMethodInfo
    ResolveCheckButtonMethod "setCanTarget" o = Gtk.Widget.WidgetSetCanTargetMethodInfo
    ResolveCheckButtonMethod "setChildVisible" o = Gtk.Widget.WidgetSetChildVisibleMethodInfo
    ResolveCheckButtonMethod "setCssClasses" o = Gtk.Widget.WidgetSetCssClassesMethodInfo
    ResolveCheckButtonMethod "setCursor" o = Gtk.Widget.WidgetSetCursorMethodInfo
    ResolveCheckButtonMethod "setCursorFromName" o = Gtk.Widget.WidgetSetCursorFromNameMethodInfo
    ResolveCheckButtonMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
    ResolveCheckButtonMethod "setDataFull" o = GObject.Object.ObjectSetDataFullMethodInfo
    ResolveCheckButtonMethod "setDetailedActionName" o = Gtk.Actionable.ActionableSetDetailedActionNameMethodInfo
    ResolveCheckButtonMethod "setDirection" o = Gtk.Widget.WidgetSetDirectionMethodInfo
    ResolveCheckButtonMethod "setFocusChild" o = Gtk.Widget.WidgetSetFocusChildMethodInfo
    ResolveCheckButtonMethod "setFocusOnClick" o = Gtk.Widget.WidgetSetFocusOnClickMethodInfo
    ResolveCheckButtonMethod "setFocusable" o = Gtk.Widget.WidgetSetFocusableMethodInfo
    ResolveCheckButtonMethod "setFontMap" o = Gtk.Widget.WidgetSetFontMapMethodInfo
    ResolveCheckButtonMethod "setFontOptions" o = Gtk.Widget.WidgetSetFontOptionsMethodInfo
    ResolveCheckButtonMethod "setGroup" o = CheckButtonSetGroupMethodInfo
    ResolveCheckButtonMethod "setHalign" o = Gtk.Widget.WidgetSetHalignMethodInfo
    ResolveCheckButtonMethod "setHasTooltip" o = Gtk.Widget.WidgetSetHasTooltipMethodInfo
    ResolveCheckButtonMethod "setHexpand" o = Gtk.Widget.WidgetSetHexpandMethodInfo
    ResolveCheckButtonMethod "setHexpandSet" o = Gtk.Widget.WidgetSetHexpandSetMethodInfo
    ResolveCheckButtonMethod "setInconsistent" o = CheckButtonSetInconsistentMethodInfo
    ResolveCheckButtonMethod "setLabel" o = CheckButtonSetLabelMethodInfo
    ResolveCheckButtonMethod "setLayoutManager" o = Gtk.Widget.WidgetSetLayoutManagerMethodInfo
    ResolveCheckButtonMethod "setMarginBottom" o = Gtk.Widget.WidgetSetMarginBottomMethodInfo
    ResolveCheckButtonMethod "setMarginEnd" o = Gtk.Widget.WidgetSetMarginEndMethodInfo
    ResolveCheckButtonMethod "setMarginStart" o = Gtk.Widget.WidgetSetMarginStartMethodInfo
    ResolveCheckButtonMethod "setMarginTop" o = Gtk.Widget.WidgetSetMarginTopMethodInfo
    ResolveCheckButtonMethod "setName" o = Gtk.Widget.WidgetSetNameMethodInfo
    ResolveCheckButtonMethod "setOpacity" o = Gtk.Widget.WidgetSetOpacityMethodInfo
    ResolveCheckButtonMethod "setOverflow" o = Gtk.Widget.WidgetSetOverflowMethodInfo
    ResolveCheckButtonMethod "setParent" o = Gtk.Widget.WidgetSetParentMethodInfo
    ResolveCheckButtonMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
    ResolveCheckButtonMethod "setReceivesDefault" o = Gtk.Widget.WidgetSetReceivesDefaultMethodInfo
    ResolveCheckButtonMethod "setSensitive" o = Gtk.Widget.WidgetSetSensitiveMethodInfo
    ResolveCheckButtonMethod "setSizeRequest" o = Gtk.Widget.WidgetSetSizeRequestMethodInfo
    ResolveCheckButtonMethod "setStateFlags" o = Gtk.Widget.WidgetSetStateFlagsMethodInfo
    ResolveCheckButtonMethod "setTooltipMarkup" o = Gtk.Widget.WidgetSetTooltipMarkupMethodInfo
    ResolveCheckButtonMethod "setTooltipText" o = Gtk.Widget.WidgetSetTooltipTextMethodInfo
    ResolveCheckButtonMethod "setUseUnderline" o = CheckButtonSetUseUnderlineMethodInfo
    ResolveCheckButtonMethod "setValign" o = Gtk.Widget.WidgetSetValignMethodInfo
    ResolveCheckButtonMethod "setVexpand" o = Gtk.Widget.WidgetSetVexpandMethodInfo
    ResolveCheckButtonMethod "setVexpandSet" o = Gtk.Widget.WidgetSetVexpandSetMethodInfo
    ResolveCheckButtonMethod "setVisible" o = Gtk.Widget.WidgetSetVisibleMethodInfo
    ResolveCheckButtonMethod l o = O.MethodResolutionFailed l o

instance (info ~ ResolveCheckButtonMethod t CheckButton, O.OverloadedMethod info CheckButton p) => OL.IsLabel t (CheckButton -> p) where
#if MIN_VERSION_base(4,10,0)
    fromLabel = O.overloadedMethod @info
#else
    fromLabel _ = O.overloadedMethod @info
#endif

#if MIN_VERSION_base(4,13,0)
instance (info ~ ResolveCheckButtonMethod t CheckButton, O.OverloadedMethod info CheckButton p, R.HasField t CheckButton p) => R.HasField t CheckButton p where
    getField = O.overloadedMethod @info

#endif

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

#endif

-- signal CheckButton::toggled
-- | Emitted when the buttons\'s t'GI.Gtk.Objects.CheckButton.CheckButton':@/active/@ flag changes.
type CheckButtonToggledCallback =
    IO ()

-- | A convenience synonym for @`Nothing` :: `Maybe` `CheckButtonToggledCallback`@.
noCheckButtonToggledCallback :: Maybe CheckButtonToggledCallback
noCheckButtonToggledCallback :: Maybe (IO ())
noCheckButtonToggledCallback = Maybe (IO ())
forall a. Maybe a
Nothing

-- | Type for the callback on the (unwrapped) C side.
type C_CheckButtonToggledCallback =
    Ptr () ->                               -- object
    Ptr () ->                               -- user_data
    IO ()

-- | Generate a function pointer callable from C code, from a `C_CheckButtonToggledCallback`.
foreign import ccall "wrapper"
    mk_CheckButtonToggledCallback :: C_CheckButtonToggledCallback -> IO (FunPtr C_CheckButtonToggledCallback)

-- | Wrap the callback into a `GClosure`.
genClosure_CheckButtonToggled :: MonadIO m => CheckButtonToggledCallback -> m (GClosure C_CheckButtonToggledCallback)
genClosure_CheckButtonToggled :: forall (m :: * -> *).
MonadIO m =>
IO () -> m (GClosure C_CheckButtonToggledCallback)
genClosure_CheckButtonToggled IO ()
cb = IO (GClosure C_CheckButtonToggledCallback)
-> m (GClosure C_CheckButtonToggledCallback)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (GClosure C_CheckButtonToggledCallback)
 -> m (GClosure C_CheckButtonToggledCallback))
-> IO (GClosure C_CheckButtonToggledCallback)
-> m (GClosure C_CheckButtonToggledCallback)
forall a b. (a -> b) -> a -> b
$ do
    let cb' :: C_CheckButtonToggledCallback
cb' = IO () -> C_CheckButtonToggledCallback
wrap_CheckButtonToggledCallback IO ()
cb
    C_CheckButtonToggledCallback
-> IO (FunPtr C_CheckButtonToggledCallback)
mk_CheckButtonToggledCallback C_CheckButtonToggledCallback
cb' IO (FunPtr C_CheckButtonToggledCallback)
-> (FunPtr C_CheckButtonToggledCallback
    -> IO (GClosure C_CheckButtonToggledCallback))
-> IO (GClosure C_CheckButtonToggledCallback)
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= FunPtr C_CheckButtonToggledCallback
-> IO (GClosure C_CheckButtonToggledCallback)
forall (m :: * -> *) a. MonadIO m => FunPtr a -> m (GClosure a)
B.GClosure.newGClosure


-- | Wrap a `CheckButtonToggledCallback` into a `C_CheckButtonToggledCallback`.
wrap_CheckButtonToggledCallback ::
    CheckButtonToggledCallback ->
    C_CheckButtonToggledCallback
wrap_CheckButtonToggledCallback :: IO () -> C_CheckButtonToggledCallback
wrap_CheckButtonToggledCallback IO ()
_cb Ptr ()
_ Ptr ()
_ = do
    IO ()
_cb 


-- | Connect a signal handler for the [toggled](#signal:toggled) signal, to be run before the default handler.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Signals.on' checkButton #toggled callback
-- @
-- 
-- 
onCheckButtonToggled :: (IsCheckButton a, MonadIO m) => a -> CheckButtonToggledCallback -> m SignalHandlerId
onCheckButtonToggled :: forall a (m :: * -> *).
(IsCheckButton a, MonadIO m) =>
a -> IO () -> m SignalHandlerId
onCheckButtonToggled a
obj IO ()
cb = IO SignalHandlerId -> m SignalHandlerId
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO SignalHandlerId -> m SignalHandlerId)
-> IO SignalHandlerId -> m SignalHandlerId
forall a b. (a -> b) -> a -> b
$ do
    let cb' :: C_CheckButtonToggledCallback
cb' = IO () -> C_CheckButtonToggledCallback
wrap_CheckButtonToggledCallback IO ()
cb
    FunPtr C_CheckButtonToggledCallback
cb'' <- C_CheckButtonToggledCallback
-> IO (FunPtr C_CheckButtonToggledCallback)
mk_CheckButtonToggledCallback C_CheckButtonToggledCallback
cb'
    a
-> Text
-> FunPtr C_CheckButtonToggledCallback
-> SignalConnectMode
-> Maybe Text
-> IO SignalHandlerId
forall o a.
GObject o =>
o
-> Text
-> FunPtr a
-> SignalConnectMode
-> Maybe Text
-> IO SignalHandlerId
connectSignalFunPtr a
obj Text
"toggled" FunPtr C_CheckButtonToggledCallback
cb'' SignalConnectMode
SignalConnectBefore Maybe Text
forall a. Maybe a
Nothing

-- | Connect a signal handler for the [toggled](#signal:toggled) signal, to be run after the default handler.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Signals.after' checkButton #toggled callback
-- @
-- 
-- 
afterCheckButtonToggled :: (IsCheckButton a, MonadIO m) => a -> CheckButtonToggledCallback -> m SignalHandlerId
afterCheckButtonToggled :: forall a (m :: * -> *).
(IsCheckButton a, MonadIO m) =>
a -> IO () -> m SignalHandlerId
afterCheckButtonToggled a
obj IO ()
cb = IO SignalHandlerId -> m SignalHandlerId
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO SignalHandlerId -> m SignalHandlerId)
-> IO SignalHandlerId -> m SignalHandlerId
forall a b. (a -> b) -> a -> b
$ do
    let cb' :: C_CheckButtonToggledCallback
cb' = IO () -> C_CheckButtonToggledCallback
wrap_CheckButtonToggledCallback IO ()
cb
    FunPtr C_CheckButtonToggledCallback
cb'' <- C_CheckButtonToggledCallback
-> IO (FunPtr C_CheckButtonToggledCallback)
mk_CheckButtonToggledCallback C_CheckButtonToggledCallback
cb'
    a
-> Text
-> FunPtr C_CheckButtonToggledCallback
-> SignalConnectMode
-> Maybe Text
-> IO SignalHandlerId
forall o a.
GObject o =>
o
-> Text
-> FunPtr a
-> SignalConnectMode
-> Maybe Text
-> IO SignalHandlerId
connectSignalFunPtr a
obj Text
"toggled" FunPtr C_CheckButtonToggledCallback
cb'' SignalConnectMode
SignalConnectAfter Maybe Text
forall a. Maybe a
Nothing


#if defined(ENABLE_OVERLOADING)
data CheckButtonToggledSignalInfo
instance SignalInfo CheckButtonToggledSignalInfo where
    type HaskellCallbackType CheckButtonToggledSignalInfo = CheckButtonToggledCallback
    connectSignal obj cb connectMode detail = do
        let cb' = wrap_CheckButtonToggledCallback cb
        cb'' <- mk_CheckButtonToggledCallback cb'
        connectSignalFunPtr obj "toggled" cb'' connectMode detail

#endif

-- VVV Prop "active"
   -- Type: TBasicType TBoolean
   -- Flags: [PropertyReadable,PropertyWritable]
   -- Nullable: (Just False,Just False)

-- | Get the value of the “@active@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' checkButton #active
-- @
getCheckButtonActive :: (MonadIO m, IsCheckButton o) => o -> m Bool
getCheckButtonActive :: forall (m :: * -> *) o. (MonadIO m, IsCheckButton o) => o -> m Bool
getCheckButtonActive o
obj = IO Bool -> m Bool
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ o -> String -> IO Bool
forall a. GObject a => a -> String -> IO Bool
B.Properties.getObjectPropertyBool o
obj String
"active"

-- | Set the value of the “@active@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' checkButton [ #active 'Data.GI.Base.Attributes.:=' value ]
-- @
setCheckButtonActive :: (MonadIO m, IsCheckButton o) => o -> Bool -> m ()
setCheckButtonActive :: forall (m :: * -> *) o.
(MonadIO m, IsCheckButton o) =>
o -> Bool -> m ()
setCheckButtonActive o
obj Bool
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    o -> String -> Bool -> IO ()
forall a. GObject a => a -> String -> Bool -> IO ()
B.Properties.setObjectPropertyBool o
obj String
"active" Bool
val

-- | Construct a `GValueConstruct` with valid value for the “@active@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
constructCheckButtonActive :: (IsCheckButton o, MIO.MonadIO m) => Bool -> m (GValueConstruct o)
constructCheckButtonActive :: forall o (m :: * -> *).
(IsCheckButton o, MonadIO m) =>
Bool -> m (GValueConstruct o)
constructCheckButtonActive Bool
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
    IO (GValueConstruct o) -> IO (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Bool -> IO (GValueConstruct o)
forall o. String -> Bool -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyBool String
"active" Bool
val

#if defined(ENABLE_OVERLOADING)
data CheckButtonActivePropertyInfo
instance AttrInfo CheckButtonActivePropertyInfo where
    type AttrAllowedOps CheckButtonActivePropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrBaseTypeConstraint CheckButtonActivePropertyInfo = IsCheckButton
    type AttrSetTypeConstraint CheckButtonActivePropertyInfo = (~) Bool
    type AttrTransferTypeConstraint CheckButtonActivePropertyInfo = (~) Bool
    type AttrTransferType CheckButtonActivePropertyInfo = Bool
    type AttrGetType CheckButtonActivePropertyInfo = Bool
    type AttrLabel CheckButtonActivePropertyInfo = "active"
    type AttrOrigin CheckButtonActivePropertyInfo = CheckButton
    attrGet = getCheckButtonActive
    attrSet = setCheckButtonActive
    attrTransfer _ v = do
        return v
    attrConstruct = constructCheckButtonActive
    attrClear = undefined
#endif

-- VVV Prop "group"
   -- Type: TInterface (Name {namespace = "Gtk", name = "CheckButton"})
   -- Flags: [PropertyWritable]
   -- Nullable: (Nothing,Just True)

-- | Set the value of the “@group@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' checkButton [ #group 'Data.GI.Base.Attributes.:=' value ]
-- @
setCheckButtonGroup :: (MonadIO m, IsCheckButton o, IsCheckButton a) => o -> a -> m ()
setCheckButtonGroup :: forall (m :: * -> *) o a.
(MonadIO m, IsCheckButton o, IsCheckButton a) =>
o -> a -> m ()
setCheckButtonGroup o
obj a
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    o -> String -> Maybe a -> IO ()
forall a b.
(GObject a, GObject b) =>
a -> String -> Maybe b -> IO ()
B.Properties.setObjectPropertyObject o
obj String
"group" (a -> Maybe a
forall a. a -> Maybe a
Just a
val)

-- | Construct a `GValueConstruct` with valid value for the “@group@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
constructCheckButtonGroup :: (IsCheckButton o, MIO.MonadIO m, IsCheckButton a) => a -> m (GValueConstruct o)
constructCheckButtonGroup :: forall o (m :: * -> *) a.
(IsCheckButton o, MonadIO m, IsCheckButton a) =>
a -> m (GValueConstruct o)
constructCheckButtonGroup a
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
    IO (GValueConstruct o) -> IO (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Maybe a -> IO (GValueConstruct o)
forall a o.
GObject a =>
String -> Maybe a -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyObject String
"group" (a -> Maybe a
forall a. a -> Maybe a
P.Just a
val)

-- | Set the value of the “@group@” property to `Nothing`.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.clear' #group
-- @
clearCheckButtonGroup :: (MonadIO m, IsCheckButton o) => o -> m ()
clearCheckButtonGroup :: forall (m :: * -> *) o. (MonadIO m, IsCheckButton o) => o -> m ()
clearCheckButtonGroup o
obj = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ o -> String -> Maybe CheckButton -> IO ()
forall a b.
(GObject a, GObject b) =>
a -> String -> Maybe b -> IO ()
B.Properties.setObjectPropertyObject o
obj String
"group" (Maybe CheckButton
forall a. Maybe a
Nothing :: Maybe CheckButton)

#if defined(ENABLE_OVERLOADING)
data CheckButtonGroupPropertyInfo
instance AttrInfo CheckButtonGroupPropertyInfo where
    type AttrAllowedOps CheckButtonGroupPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrClear]
    type AttrBaseTypeConstraint CheckButtonGroupPropertyInfo = IsCheckButton
    type AttrSetTypeConstraint CheckButtonGroupPropertyInfo = IsCheckButton
    type AttrTransferTypeConstraint CheckButtonGroupPropertyInfo = IsCheckButton
    type AttrTransferType CheckButtonGroupPropertyInfo = CheckButton
    type AttrGetType CheckButtonGroupPropertyInfo = ()
    type AttrLabel CheckButtonGroupPropertyInfo = "group"
    type AttrOrigin CheckButtonGroupPropertyInfo = CheckButton
    attrGet = undefined
    attrSet = setCheckButtonGroup
    attrTransfer _ v = do
        unsafeCastTo CheckButton v
    attrConstruct = constructCheckButtonGroup
    attrClear = clearCheckButtonGroup
#endif

-- VVV Prop "inconsistent"
   -- Type: TBasicType TBoolean
   -- Flags: [PropertyReadable,PropertyWritable]
   -- Nullable: (Just False,Just False)

-- | Get the value of the “@inconsistent@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' checkButton #inconsistent
-- @
getCheckButtonInconsistent :: (MonadIO m, IsCheckButton o) => o -> m Bool
getCheckButtonInconsistent :: forall (m :: * -> *) o. (MonadIO m, IsCheckButton o) => o -> m Bool
getCheckButtonInconsistent o
obj = IO Bool -> m Bool
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ o -> String -> IO Bool
forall a. GObject a => a -> String -> IO Bool
B.Properties.getObjectPropertyBool o
obj String
"inconsistent"

-- | Set the value of the “@inconsistent@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' checkButton [ #inconsistent 'Data.GI.Base.Attributes.:=' value ]
-- @
setCheckButtonInconsistent :: (MonadIO m, IsCheckButton o) => o -> Bool -> m ()
setCheckButtonInconsistent :: forall (m :: * -> *) o.
(MonadIO m, IsCheckButton o) =>
o -> Bool -> m ()
setCheckButtonInconsistent o
obj Bool
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    o -> String -> Bool -> IO ()
forall a. GObject a => a -> String -> Bool -> IO ()
B.Properties.setObjectPropertyBool o
obj String
"inconsistent" Bool
val

-- | Construct a `GValueConstruct` with valid value for the “@inconsistent@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
constructCheckButtonInconsistent :: (IsCheckButton o, MIO.MonadIO m) => Bool -> m (GValueConstruct o)
constructCheckButtonInconsistent :: forall o (m :: * -> *).
(IsCheckButton o, MonadIO m) =>
Bool -> m (GValueConstruct o)
constructCheckButtonInconsistent Bool
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
    IO (GValueConstruct o) -> IO (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Bool -> IO (GValueConstruct o)
forall o. String -> Bool -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyBool String
"inconsistent" Bool
val

#if defined(ENABLE_OVERLOADING)
data CheckButtonInconsistentPropertyInfo
instance AttrInfo CheckButtonInconsistentPropertyInfo where
    type AttrAllowedOps CheckButtonInconsistentPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrBaseTypeConstraint CheckButtonInconsistentPropertyInfo = IsCheckButton
    type AttrSetTypeConstraint CheckButtonInconsistentPropertyInfo = (~) Bool
    type AttrTransferTypeConstraint CheckButtonInconsistentPropertyInfo = (~) Bool
    type AttrTransferType CheckButtonInconsistentPropertyInfo = Bool
    type AttrGetType CheckButtonInconsistentPropertyInfo = Bool
    type AttrLabel CheckButtonInconsistentPropertyInfo = "inconsistent"
    type AttrOrigin CheckButtonInconsistentPropertyInfo = CheckButton
    attrGet = getCheckButtonInconsistent
    attrSet = setCheckButtonInconsistent
    attrTransfer _ v = do
        return v
    attrConstruct = constructCheckButtonInconsistent
    attrClear = undefined
#endif

-- VVV Prop "label"
   -- Type: TBasicType TUTF8
   -- Flags: [PropertyReadable,PropertyWritable]
   -- Nullable: (Just True,Just True)

-- | Get the value of the “@label@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' checkButton #label
-- @
getCheckButtonLabel :: (MonadIO m, IsCheckButton o) => o -> m (Maybe T.Text)
getCheckButtonLabel :: forall (m :: * -> *) o.
(MonadIO m, IsCheckButton o) =>
o -> m (Maybe Text)
getCheckButtonLabel o
obj = IO (Maybe Text) -> m (Maybe Text)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (Maybe Text) -> m (Maybe Text))
-> IO (Maybe Text) -> m (Maybe Text)
forall a b. (a -> b) -> a -> b
$ o -> String -> IO (Maybe Text)
forall a. GObject a => a -> String -> IO (Maybe Text)
B.Properties.getObjectPropertyString o
obj String
"label"

-- | Set the value of the “@label@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' checkButton [ #label 'Data.GI.Base.Attributes.:=' value ]
-- @
setCheckButtonLabel :: (MonadIO m, IsCheckButton o) => o -> T.Text -> m ()
setCheckButtonLabel :: forall (m :: * -> *) o.
(MonadIO m, IsCheckButton o) =>
o -> Text -> m ()
setCheckButtonLabel o
obj Text
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    o -> String -> Maybe Text -> IO ()
forall a. GObject a => a -> String -> Maybe Text -> IO ()
B.Properties.setObjectPropertyString o
obj String
"label" (Text -> Maybe Text
forall a. a -> Maybe a
Just Text
val)

-- | Construct a `GValueConstruct` with valid value for the “@label@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
constructCheckButtonLabel :: (IsCheckButton o, MIO.MonadIO m) => T.Text -> m (GValueConstruct o)
constructCheckButtonLabel :: forall o (m :: * -> *).
(IsCheckButton o, MonadIO m) =>
Text -> m (GValueConstruct o)
constructCheckButtonLabel Text
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
    IO (GValueConstruct o) -> IO (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Maybe Text -> IO (GValueConstruct o)
forall o. String -> Maybe Text -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyString String
"label" (Text -> Maybe Text
forall a. a -> Maybe a
P.Just Text
val)

-- | Set the value of the “@label@” property to `Nothing`.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.clear' #label
-- @
clearCheckButtonLabel :: (MonadIO m, IsCheckButton o) => o -> m ()
clearCheckButtonLabel :: forall (m :: * -> *) o. (MonadIO m, IsCheckButton o) => o -> m ()
clearCheckButtonLabel o
obj = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ o -> String -> Maybe Text -> IO ()
forall a. GObject a => a -> String -> Maybe Text -> IO ()
B.Properties.setObjectPropertyString o
obj String
"label" (Maybe Text
forall a. Maybe a
Nothing :: Maybe T.Text)

#if defined(ENABLE_OVERLOADING)
data CheckButtonLabelPropertyInfo
instance AttrInfo CheckButtonLabelPropertyInfo where
    type AttrAllowedOps CheckButtonLabelPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet, 'AttrClear]
    type AttrBaseTypeConstraint CheckButtonLabelPropertyInfo = IsCheckButton
    type AttrSetTypeConstraint CheckButtonLabelPropertyInfo = (~) T.Text
    type AttrTransferTypeConstraint CheckButtonLabelPropertyInfo = (~) T.Text
    type AttrTransferType CheckButtonLabelPropertyInfo = T.Text
    type AttrGetType CheckButtonLabelPropertyInfo = (Maybe T.Text)
    type AttrLabel CheckButtonLabelPropertyInfo = "label"
    type AttrOrigin CheckButtonLabelPropertyInfo = CheckButton
    attrGet = getCheckButtonLabel
    attrSet = setCheckButtonLabel
    attrTransfer _ v = do
        return v
    attrConstruct = constructCheckButtonLabel
    attrClear = clearCheckButtonLabel
#endif

-- VVV Prop "use-underline"
   -- Type: TBasicType TBoolean
   -- Flags: [PropertyReadable,PropertyWritable]
   -- Nullable: (Just False,Just False)

-- | Get the value of the “@use-underline@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' checkButton #useUnderline
-- @
getCheckButtonUseUnderline :: (MonadIO m, IsCheckButton o) => o -> m Bool
getCheckButtonUseUnderline :: forall (m :: * -> *) o. (MonadIO m, IsCheckButton o) => o -> m Bool
getCheckButtonUseUnderline o
obj = IO Bool -> m Bool
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ o -> String -> IO Bool
forall a. GObject a => a -> String -> IO Bool
B.Properties.getObjectPropertyBool o
obj String
"use-underline"

-- | Set the value of the “@use-underline@” property.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' checkButton [ #useUnderline 'Data.GI.Base.Attributes.:=' value ]
-- @
setCheckButtonUseUnderline :: (MonadIO m, IsCheckButton o) => o -> Bool -> m ()
setCheckButtonUseUnderline :: forall (m :: * -> *) o.
(MonadIO m, IsCheckButton o) =>
o -> Bool -> m ()
setCheckButtonUseUnderline o
obj Bool
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    o -> String -> Bool -> IO ()
forall a. GObject a => a -> String -> Bool -> IO ()
B.Properties.setObjectPropertyBool o
obj String
"use-underline" Bool
val

-- | Construct a `GValueConstruct` with valid value for the “@use-underline@” property. This is rarely needed directly, but it is used by `Data.GI.Base.Constructible.new`.
constructCheckButtonUseUnderline :: (IsCheckButton o, MIO.MonadIO m) => Bool -> m (GValueConstruct o)
constructCheckButtonUseUnderline :: forall o (m :: * -> *).
(IsCheckButton o, MonadIO m) =>
Bool -> m (GValueConstruct o)
constructCheckButtonUseUnderline Bool
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
    IO (GValueConstruct o) -> IO (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Bool -> IO (GValueConstruct o)
forall o. String -> Bool -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyBool String
"use-underline" Bool
val

#if defined(ENABLE_OVERLOADING)
data CheckButtonUseUnderlinePropertyInfo
instance AttrInfo CheckButtonUseUnderlinePropertyInfo where
    type AttrAllowedOps CheckButtonUseUnderlinePropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet]
    type AttrBaseTypeConstraint CheckButtonUseUnderlinePropertyInfo = IsCheckButton
    type AttrSetTypeConstraint CheckButtonUseUnderlinePropertyInfo = (~) Bool
    type AttrTransferTypeConstraint CheckButtonUseUnderlinePropertyInfo = (~) Bool
    type AttrTransferType CheckButtonUseUnderlinePropertyInfo = Bool
    type AttrGetType CheckButtonUseUnderlinePropertyInfo = Bool
    type AttrLabel CheckButtonUseUnderlinePropertyInfo = "use-underline"
    type AttrOrigin CheckButtonUseUnderlinePropertyInfo = CheckButton
    attrGet = getCheckButtonUseUnderline
    attrSet = setCheckButtonUseUnderline
    attrTransfer _ v = do
        return v
    attrConstruct = constructCheckButtonUseUnderline
    attrClear = undefined
#endif

#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList CheckButton
type instance O.AttributeList CheckButton = CheckButtonAttributeList
type CheckButtonAttributeList = ('[ '("accessibleRole", Gtk.Accessible.AccessibleAccessibleRolePropertyInfo), '("actionName", Gtk.Actionable.ActionableActionNamePropertyInfo), '("actionTarget", Gtk.Actionable.ActionableActionTargetPropertyInfo), '("active", CheckButtonActivePropertyInfo), '("canFocus", Gtk.Widget.WidgetCanFocusPropertyInfo), '("canTarget", Gtk.Widget.WidgetCanTargetPropertyInfo), '("cssClasses", Gtk.Widget.WidgetCssClassesPropertyInfo), '("cssName", Gtk.Widget.WidgetCssNamePropertyInfo), '("cursor", Gtk.Widget.WidgetCursorPropertyInfo), '("focusOnClick", Gtk.Widget.WidgetFocusOnClickPropertyInfo), '("focusable", Gtk.Widget.WidgetFocusablePropertyInfo), '("group", CheckButtonGroupPropertyInfo), '("halign", Gtk.Widget.WidgetHalignPropertyInfo), '("hasDefault", Gtk.Widget.WidgetHasDefaultPropertyInfo), '("hasFocus", Gtk.Widget.WidgetHasFocusPropertyInfo), '("hasTooltip", Gtk.Widget.WidgetHasTooltipPropertyInfo), '("heightRequest", Gtk.Widget.WidgetHeightRequestPropertyInfo), '("hexpand", Gtk.Widget.WidgetHexpandPropertyInfo), '("hexpandSet", Gtk.Widget.WidgetHexpandSetPropertyInfo), '("inconsistent", CheckButtonInconsistentPropertyInfo), '("label", CheckButtonLabelPropertyInfo), '("layoutManager", Gtk.Widget.WidgetLayoutManagerPropertyInfo), '("marginBottom", Gtk.Widget.WidgetMarginBottomPropertyInfo), '("marginEnd", Gtk.Widget.WidgetMarginEndPropertyInfo), '("marginStart", Gtk.Widget.WidgetMarginStartPropertyInfo), '("marginTop", Gtk.Widget.WidgetMarginTopPropertyInfo), '("name", Gtk.Widget.WidgetNamePropertyInfo), '("opacity", Gtk.Widget.WidgetOpacityPropertyInfo), '("overflow", Gtk.Widget.WidgetOverflowPropertyInfo), '("parent", Gtk.Widget.WidgetParentPropertyInfo), '("receivesDefault", Gtk.Widget.WidgetReceivesDefaultPropertyInfo), '("root", Gtk.Widget.WidgetRootPropertyInfo), '("scaleFactor", Gtk.Widget.WidgetScaleFactorPropertyInfo), '("sensitive", Gtk.Widget.WidgetSensitivePropertyInfo), '("tooltipMarkup", Gtk.Widget.WidgetTooltipMarkupPropertyInfo), '("tooltipText", Gtk.Widget.WidgetTooltipTextPropertyInfo), '("useUnderline", CheckButtonUseUnderlinePropertyInfo), '("valign", Gtk.Widget.WidgetValignPropertyInfo), '("vexpand", Gtk.Widget.WidgetVexpandPropertyInfo), '("vexpandSet", Gtk.Widget.WidgetVexpandSetPropertyInfo), '("visible", Gtk.Widget.WidgetVisiblePropertyInfo), '("widthRequest", Gtk.Widget.WidgetWidthRequestPropertyInfo)] :: [(Symbol, *)])
#endif

#if defined(ENABLE_OVERLOADING)
checkButtonActive :: AttrLabelProxy "active"
checkButtonActive = AttrLabelProxy

checkButtonGroup :: AttrLabelProxy "group"
checkButtonGroup = AttrLabelProxy

checkButtonInconsistent :: AttrLabelProxy "inconsistent"
checkButtonInconsistent = AttrLabelProxy

checkButtonLabel :: AttrLabelProxy "label"
checkButtonLabel = AttrLabelProxy

checkButtonUseUnderline :: AttrLabelProxy "useUnderline"
checkButtonUseUnderline = AttrLabelProxy

#endif

#if defined(ENABLE_OVERLOADING)
type instance O.SignalList CheckButton = CheckButtonSignalList
type CheckButtonSignalList = ('[ '("destroy", Gtk.Widget.WidgetDestroySignalInfo), '("directionChanged", Gtk.Widget.WidgetDirectionChangedSignalInfo), '("hide", Gtk.Widget.WidgetHideSignalInfo), '("keynavFailed", Gtk.Widget.WidgetKeynavFailedSignalInfo), '("map", Gtk.Widget.WidgetMapSignalInfo), '("mnemonicActivate", Gtk.Widget.WidgetMnemonicActivateSignalInfo), '("moveFocus", Gtk.Widget.WidgetMoveFocusSignalInfo), '("notify", GObject.Object.ObjectNotifySignalInfo), '("queryTooltip", Gtk.Widget.WidgetQueryTooltipSignalInfo), '("realize", Gtk.Widget.WidgetRealizeSignalInfo), '("show", Gtk.Widget.WidgetShowSignalInfo), '("stateFlagsChanged", Gtk.Widget.WidgetStateFlagsChangedSignalInfo), '("toggled", CheckButtonToggledSignalInfo), '("unmap", Gtk.Widget.WidgetUnmapSignalInfo), '("unrealize", Gtk.Widget.WidgetUnrealizeSignalInfo)] :: [(Symbol, *)])

#endif

-- method CheckButton::new
-- method type : Constructor
-- Args: []
-- Lengths: []
-- returnType: Just (TInterface Name { namespace = "Gtk" , name = "CheckButton" })
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_new" gtk_check_button_new :: 
    IO (Ptr CheckButton)

-- | Creates a new t'GI.Gtk.Objects.CheckButton.CheckButton'.
checkButtonNew ::
    (B.CallStack.HasCallStack, MonadIO m) =>
    m CheckButton
    -- ^ __Returns:__ a t'GI.Gtk.Objects.Widget.Widget'.
checkButtonNew :: forall (m :: * -> *). (HasCallStack, MonadIO m) => m CheckButton
checkButtonNew  = IO CheckButton -> m CheckButton
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO CheckButton -> m CheckButton)
-> IO CheckButton -> m CheckButton
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
result <- IO (Ptr CheckButton)
gtk_check_button_new
    Text -> Ptr CheckButton -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"checkButtonNew" Ptr CheckButton
result
    CheckButton
result' <- ((ManagedPtr CheckButton -> CheckButton)
-> Ptr CheckButton -> IO CheckButton
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr CheckButton -> CheckButton
CheckButton) Ptr CheckButton
result
    CheckButton -> IO CheckButton
forall (m :: * -> *) a. Monad m => a -> m a
return CheckButton
result'

#if defined(ENABLE_OVERLOADING)
#endif

-- method CheckButton::new_with_label
-- method type : Constructor
-- Args: [ Arg
--           { argCName = "label"
--           , argType = TBasicType TUTF8
--           , direction = DirectionIn
--           , mayBeNull = True
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "the text for the check button."
--                 , sinceVersion = Nothing
--                 }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Just (TInterface Name { namespace = "Gtk" , name = "CheckButton" })
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_new_with_label" gtk_check_button_new_with_label :: 
    CString ->                              -- label : TBasicType TUTF8
    IO (Ptr CheckButton)

-- | Creates a new t'GI.Gtk.Objects.CheckButton.CheckButton' with a t'GI.Gtk.Objects.Label.Label' next to it, if
-- /@label@/ is non-'P.Nothing'.
checkButtonNewWithLabel ::
    (B.CallStack.HasCallStack, MonadIO m) =>
    Maybe (T.Text)
    -- ^ /@label@/: the text for the check button.
    -> m CheckButton
    -- ^ __Returns:__ a new t'GI.Gtk.Objects.CheckButton.CheckButton'
checkButtonNewWithLabel :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
Maybe Text -> m CheckButton
checkButtonNewWithLabel Maybe Text
label = IO CheckButton -> m CheckButton
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO CheckButton -> m CheckButton)
-> IO CheckButton -> m CheckButton
forall a b. (a -> b) -> a -> b
$ do
    Ptr CChar
maybeLabel <- case Maybe Text
label of
        Maybe Text
Nothing -> Ptr CChar -> IO (Ptr CChar)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CChar
forall a. Ptr a
nullPtr
        Just Text
jLabel -> do
            Ptr CChar
jLabel' <- Text -> IO (Ptr CChar)
textToCString Text
jLabel
            Ptr CChar -> IO (Ptr CChar)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CChar
jLabel'
    Ptr CheckButton
result <- Ptr CChar -> IO (Ptr CheckButton)
gtk_check_button_new_with_label Ptr CChar
maybeLabel
    Text -> Ptr CheckButton -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"checkButtonNewWithLabel" Ptr CheckButton
result
    CheckButton
result' <- ((ManagedPtr CheckButton -> CheckButton)
-> Ptr CheckButton -> IO CheckButton
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr CheckButton -> CheckButton
CheckButton) Ptr CheckButton
result
    Ptr CChar -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr CChar
maybeLabel
    CheckButton -> IO CheckButton
forall (m :: * -> *) a. Monad m => a -> m a
return CheckButton
result'

#if defined(ENABLE_OVERLOADING)
#endif

-- method CheckButton::new_with_mnemonic
-- method type : Constructor
-- Args: [ Arg
--           { argCName = "label"
--           , argType = TBasicType TUTF8
--           , direction = DirectionIn
--           , mayBeNull = True
--           , argDoc =
--               Documentation
--                 { rawDocText =
--                     Just
--                       "The text of the button, with an underscore in front of the\n  mnemonic character"
--                 , sinceVersion = Nothing
--                 }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Just (TInterface Name { namespace = "Gtk" , name = "CheckButton" })
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_new_with_mnemonic" gtk_check_button_new_with_mnemonic :: 
    CString ->                              -- label : TBasicType TUTF8
    IO (Ptr CheckButton)

-- | Creates a new t'GI.Gtk.Objects.CheckButton.CheckButton' containing a label. Underscores
-- in /@label@/ indicate the mnemonic for the check button.
checkButtonNewWithMnemonic ::
    (B.CallStack.HasCallStack, MonadIO m) =>
    Maybe (T.Text)
    -- ^ /@label@/: The text of the button, with an underscore in front of the
    --   mnemonic character
    -> m CheckButton
    -- ^ __Returns:__ a new t'GI.Gtk.Objects.CheckButton.CheckButton'
checkButtonNewWithMnemonic :: forall (m :: * -> *).
(HasCallStack, MonadIO m) =>
Maybe Text -> m CheckButton
checkButtonNewWithMnemonic Maybe Text
label = IO CheckButton -> m CheckButton
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO CheckButton -> m CheckButton)
-> IO CheckButton -> m CheckButton
forall a b. (a -> b) -> a -> b
$ do
    Ptr CChar
maybeLabel <- case Maybe Text
label of
        Maybe Text
Nothing -> Ptr CChar -> IO (Ptr CChar)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CChar
forall a. Ptr a
nullPtr
        Just Text
jLabel -> do
            Ptr CChar
jLabel' <- Text -> IO (Ptr CChar)
textToCString Text
jLabel
            Ptr CChar -> IO (Ptr CChar)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CChar
jLabel'
    Ptr CheckButton
result <- Ptr CChar -> IO (Ptr CheckButton)
gtk_check_button_new_with_mnemonic Ptr CChar
maybeLabel
    Text -> Ptr CheckButton -> IO ()
forall a. HasCallStack => Text -> Ptr a -> IO ()
checkUnexpectedReturnNULL Text
"checkButtonNewWithMnemonic" Ptr CheckButton
result
    CheckButton
result' <- ((ManagedPtr CheckButton -> CheckButton)
-> Ptr CheckButton -> IO CheckButton
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr CheckButton -> CheckButton
CheckButton) Ptr CheckButton
result
    Ptr CChar -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr CChar
maybeLabel
    CheckButton -> IO CheckButton
forall (m :: * -> *) a. Monad m => a -> m a
return CheckButton
result'

#if defined(ENABLE_OVERLOADING)
#endif

-- method CheckButton::get_active
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "self"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Just (TBasicType TBoolean)
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_get_active" gtk_check_button_get_active :: 
    Ptr CheckButton ->                      -- self : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    IO CInt

-- | Returns the current value of the t'GI.Gtk.Objects.CheckButton.CheckButton':@/active/@ property.
checkButtonGetActive ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@self@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> m Bool
    -- ^ __Returns:__ The value of the t'GI.Gtk.Objects.CheckButton.CheckButton':@/active/@ property.
    --   See 'GI.Gtk.Objects.CheckButton.checkButtonSetActive' for details on how to set a new value.
checkButtonGetActive :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> m Bool
checkButtonGetActive a
self = IO Bool -> m Bool
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
self' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
    CInt
result <- Ptr CheckButton -> IO CInt
gtk_check_button_get_active Ptr CheckButton
self'
    let result' :: Bool
result' = (CInt -> CInt -> Bool
forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
    Bool -> IO Bool
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'

#if defined(ENABLE_OVERLOADING)
data CheckButtonGetActiveMethodInfo
instance (signature ~ (m Bool), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonGetActiveMethodInfo a signature where
    overloadedMethod = checkButtonGetActive

instance O.OverloadedMethodInfo CheckButtonGetActiveMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonGetActive",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonGetActive"
        }


#endif

-- method CheckButton::get_inconsistent
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "check_button"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Just (TBasicType TBoolean)
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_get_inconsistent" gtk_check_button_get_inconsistent :: 
    Ptr CheckButton ->                      -- check_button : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    IO CInt

-- | Returns whether the check button is in an inconsistent state.
checkButtonGetInconsistent ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@checkButton@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> m Bool
    -- ^ __Returns:__ 'P.True' if /@checkButton@/ is currently in an \'in between\' state, 'P.False' otherwise.
checkButtonGetInconsistent :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> m Bool
checkButtonGetInconsistent a
checkButton = IO Bool -> m Bool
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
checkButton' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
checkButton
    CInt
result <- Ptr CheckButton -> IO CInt
gtk_check_button_get_inconsistent Ptr CheckButton
checkButton'
    let result' :: Bool
result' = (CInt -> CInt -> Bool
forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
checkButton
    Bool -> IO Bool
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'

#if defined(ENABLE_OVERLOADING)
data CheckButtonGetInconsistentMethodInfo
instance (signature ~ (m Bool), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonGetInconsistentMethodInfo a signature where
    overloadedMethod = checkButtonGetInconsistent

instance O.OverloadedMethodInfo CheckButtonGetInconsistentMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonGetInconsistent",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonGetInconsistent"
        }


#endif

-- method CheckButton::get_label
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "self"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Just (TBasicType TUTF8)
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_get_label" gtk_check_button_get_label :: 
    Ptr CheckButton ->                      -- self : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    IO CString

-- | Returns the label of the checkbutton.
checkButtonGetLabel ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@self@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> m (Maybe T.Text)
    -- ^ __Returns:__ The label /@self@/ shows next to the indicator.
    --   If no label is shown, 'P.Nothing' will be returned.
checkButtonGetLabel :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> m (Maybe Text)
checkButtonGetLabel a
self = IO (Maybe Text) -> m (Maybe Text)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe Text) -> m (Maybe Text))
-> IO (Maybe Text) -> m (Maybe Text)
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
self' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
    Ptr CChar
result <- Ptr CheckButton -> IO (Ptr CChar)
gtk_check_button_get_label Ptr CheckButton
self'
    Maybe Text
maybeResult <- Ptr CChar -> (Ptr CChar -> IO Text) -> IO (Maybe Text)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
convertIfNonNull Ptr CChar
result ((Ptr CChar -> IO Text) -> IO (Maybe Text))
-> (Ptr CChar -> IO Text) -> IO (Maybe Text)
forall a b. (a -> b) -> a -> b
$ \Ptr CChar
result' -> do
        Text
result'' <- HasCallStack => Ptr CChar -> IO Text
Ptr CChar -> IO Text
cstringToText Ptr CChar
result'
        Text -> IO Text
forall (m :: * -> *) a. Monad m => a -> m a
return Text
result''
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
    Maybe Text -> IO (Maybe Text)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Text
maybeResult

#if defined(ENABLE_OVERLOADING)
data CheckButtonGetLabelMethodInfo
instance (signature ~ (m (Maybe T.Text)), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonGetLabelMethodInfo a signature where
    overloadedMethod = checkButtonGetLabel

instance O.OverloadedMethodInfo CheckButtonGetLabelMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonGetLabel",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonGetLabel"
        }


#endif

-- method CheckButton::get_use_underline
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "self"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Just (TBasicType TBoolean)
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_get_use_underline" gtk_check_button_get_use_underline :: 
    Ptr CheckButton ->                      -- self : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    IO CInt

-- | Returns the current value of the t'GI.Gtk.Objects.CheckButton.CheckButton':@/use-underline/@ property.
checkButtonGetUseUnderline ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@self@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> m Bool
    -- ^ __Returns:__ The value of the t'GI.Gtk.Objects.CheckButton.CheckButton':@/use-underline/@ property.
    --   See 'GI.Gtk.Objects.CheckButton.checkButtonSetUseUnderline' for details on how to set a new value.
checkButtonGetUseUnderline :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> m Bool
checkButtonGetUseUnderline a
self = IO Bool -> m Bool
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Bool -> m Bool) -> IO Bool -> m Bool
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
self' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
    CInt
result <- Ptr CheckButton -> IO CInt
gtk_check_button_get_use_underline Ptr CheckButton
self'
    let result' :: Bool
result' = (CInt -> CInt -> Bool
forall a. Eq a => a -> a -> Bool
/= CInt
0) CInt
result
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
    Bool -> IO Bool
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
result'

#if defined(ENABLE_OVERLOADING)
data CheckButtonGetUseUnderlineMethodInfo
instance (signature ~ (m Bool), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonGetUseUnderlineMethodInfo a signature where
    overloadedMethod = checkButtonGetUseUnderline

instance O.OverloadedMethodInfo CheckButtonGetUseUnderlineMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonGetUseUnderline",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonGetUseUnderline"
        }


#endif

-- method CheckButton::set_active
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "self"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       , Arg
--           { argCName = "setting"
--           , argType = TBasicType TBoolean
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "the new value to set"
--                 , sinceVersion = Nothing
--                 }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Nothing
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_set_active" gtk_check_button_set_active :: 
    Ptr CheckButton ->                      -- self : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    CInt ->                                 -- setting : TBasicType TBoolean
    IO ()

-- | Sets the new value of the t'GI.Gtk.Objects.CheckButton.CheckButton':@/active/@ property.
-- See also 'GI.Gtk.Objects.CheckButton.checkButtonGetActive'.
-- 
-- Setting t'GI.Gtk.Objects.CheckButton.CheckButton':@/active/@ to 'P.True' will add the @:checked:@ state to
-- both the checkbutton and the indicator CSS node.
checkButtonSetActive ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@self@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> Bool
    -- ^ /@setting@/: the new value to set
    -> m ()
checkButtonSetActive :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> Bool -> m ()
checkButtonSetActive a
self Bool
setting = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
self' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
    let setting' :: CInt
setting' = (Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Int -> CInt) -> (Bool -> Int) -> Bool -> CInt
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Bool -> Int
forall a. Enum a => a -> Int
fromEnum) Bool
setting
    Ptr CheckButton -> CInt -> IO ()
gtk_check_button_set_active Ptr CheckButton
self' CInt
setting'
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
    () -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()

#if defined(ENABLE_OVERLOADING)
data CheckButtonSetActiveMethodInfo
instance (signature ~ (Bool -> m ()), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonSetActiveMethodInfo a signature where
    overloadedMethod = checkButtonSetActive

instance O.OverloadedMethodInfo CheckButtonSetActiveMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonSetActive",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonSetActive"
        }


#endif

-- method CheckButton::set_group
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "self"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       , Arg
--           { argCName = "group"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = True
--           , argDoc =
--               Documentation
--                 { rawDocText =
--                     Just "another #GtkCheckButton to\n  form a group with"
--                 , sinceVersion = Nothing
--                 }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Nothing
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_set_group" gtk_check_button_set_group :: 
    Ptr CheckButton ->                      -- self : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    Ptr CheckButton ->                      -- group : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    IO ()

-- | Adds /@self@/ to the group of /@group@/. In a group of multiple check buttons,
-- only one button can be active at a time.
-- 
-- Setting the group of a check button also changes the css name of the
-- indicator widget\'s CSS node to \'radio\'.
-- 
-- The behavior of a checkbutton in a group is also commonly known as
-- a \'radio button\'.
-- 
-- Note that the same effect can be achieved via the t'GI.Gtk.Interfaces.Actionable.Actionable'
-- api, by using the same action with parameter type and state type \'s\'
-- for all buttons in the group, and giving each button its own target
-- value.
checkButtonSetGroup ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a, IsCheckButton b) =>
    a
    -- ^ /@self@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> Maybe (b)
    -- ^ /@group@/: another t'GI.Gtk.Objects.CheckButton.CheckButton' to
    --   form a group with
    -> m ()
checkButtonSetGroup :: forall (m :: * -> *) a b.
(HasCallStack, MonadIO m, IsCheckButton a, IsCheckButton b) =>
a -> Maybe b -> m ()
checkButtonSetGroup a
self Maybe b
group = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
self' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
    Ptr CheckButton
maybeGroup <- case Maybe b
group of
        Maybe b
Nothing -> Ptr CheckButton -> IO (Ptr CheckButton)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CheckButton
forall a. Ptr a
nullPtr
        Just b
jGroup -> do
            Ptr CheckButton
jGroup' <- b -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr b
jGroup
            Ptr CheckButton -> IO (Ptr CheckButton)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CheckButton
jGroup'
    Ptr CheckButton -> Ptr CheckButton -> IO ()
gtk_check_button_set_group Ptr CheckButton
self' Ptr CheckButton
maybeGroup
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
    Maybe b -> (b -> IO ()) -> IO ()
forall (m :: * -> *) a. Monad m => Maybe a -> (a -> m ()) -> m ()
whenJust Maybe b
group b -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr
    () -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()

#if defined(ENABLE_OVERLOADING)
data CheckButtonSetGroupMethodInfo
instance (signature ~ (Maybe (b) -> m ()), MonadIO m, IsCheckButton a, IsCheckButton b) => O.OverloadedMethod CheckButtonSetGroupMethodInfo a signature where
    overloadedMethod = checkButtonSetGroup

instance O.OverloadedMethodInfo CheckButtonSetGroupMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonSetGroup",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonSetGroup"
        }


#endif

-- method CheckButton::set_inconsistent
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "check_button"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       , Arg
--           { argCName = "inconsistent"
--           , argType = TBasicType TBoolean
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "%TRUE if state is inconsistent"
--                 , sinceVersion = Nothing
--                 }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Nothing
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_set_inconsistent" gtk_check_button_set_inconsistent :: 
    Ptr CheckButton ->                      -- check_button : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    CInt ->                                 -- inconsistent : TBasicType TBoolean
    IO ()

-- | If the user has selected a range of elements (such as some text or
-- spreadsheet cells) that are affected by a check button, and the
-- current values in that range are inconsistent, you may want to
-- display the toggle in an \"in between\" state. Normally you would
-- turn off the inconsistent state again if the user checks the
-- check button. This has to be done manually,
-- gtk_check_button_set_inconsistent only affects visual appearance,
-- not the semantics of the button.
checkButtonSetInconsistent ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@checkButton@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> Bool
    -- ^ /@inconsistent@/: 'P.True' if state is inconsistent
    -> m ()
checkButtonSetInconsistent :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> Bool -> m ()
checkButtonSetInconsistent a
checkButton Bool
inconsistent = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
checkButton' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
checkButton
    let inconsistent' :: CInt
inconsistent' = (Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Int -> CInt) -> (Bool -> Int) -> Bool -> CInt
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Bool -> Int
forall a. Enum a => a -> Int
fromEnum) Bool
inconsistent
    Ptr CheckButton -> CInt -> IO ()
gtk_check_button_set_inconsistent Ptr CheckButton
checkButton' CInt
inconsistent'
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
checkButton
    () -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()

#if defined(ENABLE_OVERLOADING)
data CheckButtonSetInconsistentMethodInfo
instance (signature ~ (Bool -> m ()), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonSetInconsistentMethodInfo a signature where
    overloadedMethod = checkButtonSetInconsistent

instance O.OverloadedMethodInfo CheckButtonSetInconsistentMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonSetInconsistent",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonSetInconsistent"
        }


#endif

-- method CheckButton::set_label
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "self"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       , Arg
--           { argCName = "label"
--           , argType = TBasicType TUTF8
--           , direction = DirectionIn
--           , mayBeNull = True
--           , argDoc =
--               Documentation
--                 { rawDocText =
--                     Just
--                       "The text shown next to the indicator, or %NULL\n  to show no text"
--                 , sinceVersion = Nothing
--                 }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Nothing
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_set_label" gtk_check_button_set_label :: 
    Ptr CheckButton ->                      -- self : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    CString ->                              -- label : TBasicType TUTF8
    IO ()

-- | Sets the text of /@self@/. If t'GI.Gtk.Objects.CheckButton.CheckButton':@/use-underline/@ is 'P.True',
-- the underscore in /@label@/ is interpreted as mnemonic indicator,
-- see 'GI.Gtk.Objects.CheckButton.checkButtonSetUseUnderline' for details on this behavior.
checkButtonSetLabel ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@self@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> Maybe (T.Text)
    -- ^ /@label@/: The text shown next to the indicator, or 'P.Nothing'
    --   to show no text
    -> m ()
checkButtonSetLabel :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> Maybe Text -> m ()
checkButtonSetLabel a
self Maybe Text
label = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
self' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
    Ptr CChar
maybeLabel <- case Maybe Text
label of
        Maybe Text
Nothing -> Ptr CChar -> IO (Ptr CChar)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CChar
forall a. Ptr a
nullPtr
        Just Text
jLabel -> do
            Ptr CChar
jLabel' <- Text -> IO (Ptr CChar)
textToCString Text
jLabel
            Ptr CChar -> IO (Ptr CChar)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr CChar
jLabel'
    Ptr CheckButton -> Ptr CChar -> IO ()
gtk_check_button_set_label Ptr CheckButton
self' Ptr CChar
maybeLabel
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
    Ptr CChar -> IO ()
forall a. Ptr a -> IO ()
freeMem Ptr CChar
maybeLabel
    () -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()

#if defined(ENABLE_OVERLOADING)
data CheckButtonSetLabelMethodInfo
instance (signature ~ (Maybe (T.Text) -> m ()), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonSetLabelMethodInfo a signature where
    overloadedMethod = checkButtonSetLabel

instance O.OverloadedMethodInfo CheckButtonSetLabelMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonSetLabel",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonSetLabel"
        }


#endif

-- method CheckButton::set_use_underline
-- method type : OrdinaryMethod
-- Args: [ Arg
--           { argCName = "self"
--           , argType =
--               TInterface Name { namespace = "Gtk" , name = "CheckButton" }
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "a #GtkCheckButton" , sinceVersion = Nothing }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       , Arg
--           { argCName = "setting"
--           , argType = TBasicType TBoolean
--           , direction = DirectionIn
--           , mayBeNull = False
--           , argDoc =
--               Documentation
--                 { rawDocText = Just "the new value to set"
--                 , sinceVersion = Nothing
--                 }
--           , argScope = ScopeTypeInvalid
--           , argClosure = -1
--           , argDestroy = -1
--           , argCallerAllocates = False
--           , transfer = TransferNothing
--           }
--       ]
-- Lengths: []
-- returnType: Nothing
-- throws : False
-- Skip return : False

foreign import ccall "gtk_check_button_set_use_underline" gtk_check_button_set_use_underline :: 
    Ptr CheckButton ->                      -- self : TInterface (Name {namespace = "Gtk", name = "CheckButton"})
    CInt ->                                 -- setting : TBasicType TBoolean
    IO ()

-- | Sets the new value of the t'GI.Gtk.Objects.CheckButton.CheckButton':@/use-underline/@ property.
-- See also 'GI.Gtk.Objects.CheckButton.checkButtonGetUseUnderline'.
-- 
-- If /@setting@/ is 'P.True', an underscore character in /@self@/\'s label indicates
-- a mnemonic accelerator key. This behavior is similar to t'GI.Gtk.Objects.Label.Label':@/use-underline/@.
checkButtonSetUseUnderline ::
    (B.CallStack.HasCallStack, MonadIO m, IsCheckButton a) =>
    a
    -- ^ /@self@/: a t'GI.Gtk.Objects.CheckButton.CheckButton'
    -> Bool
    -- ^ /@setting@/: the new value to set
    -> m ()
checkButtonSetUseUnderline :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsCheckButton a) =>
a -> Bool -> m ()
checkButtonSetUseUnderline a
self Bool
setting = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
    Ptr CheckButton
self' <- a -> IO (Ptr CheckButton)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
self
    let setting' :: CInt
setting' = (Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Int -> CInt) -> (Bool -> Int) -> Bool -> CInt
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Bool -> Int
forall a. Enum a => a -> Int
fromEnum) Bool
setting
    Ptr CheckButton -> CInt -> IO ()
gtk_check_button_set_use_underline Ptr CheckButton
self' CInt
setting'
    a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
self
    () -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()

#if defined(ENABLE_OVERLOADING)
data CheckButtonSetUseUnderlineMethodInfo
instance (signature ~ (Bool -> m ()), MonadIO m, IsCheckButton a) => O.OverloadedMethod CheckButtonSetUseUnderlineMethodInfo a signature where
    overloadedMethod = checkButtonSetUseUnderline

instance O.OverloadedMethodInfo CheckButtonSetUseUnderlineMethodInfo a where
    overloadedMethodInfo = O.MethodInfo {
        O.overloadedMethodName = "GI.Gtk.Objects.CheckButton.checkButtonSetUseUnderline",
        O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Objects-CheckButton.html#v:checkButtonSetUseUnderline"
        }


#endif