{-# LANGUAGE TypeApplications #-}


-- | Copyright  : Will Thompson, Iñaki García Etxebarria and Jonas Platte
-- License    : LGPL-2.1
-- Maintainer : Iñaki García Etxebarria
-- 
-- Generated from button presses for the buttons 4 to 7. Wheel mice are
-- usually configured to generate button press events for buttons 4 and 5
-- when the wheel is turned.
-- 
-- Some GDK backends can also generate “smooth” scroll events, which
-- can be recognized by the 'GI.Gdk.Enums.ScrollDirectionSmooth' scroll direction. For
-- these, the scroll deltas can be obtained with
-- 'GI.Gdk.Unions.Event.eventGetScrollDeltas'.

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

module GI.Gdk.Structs.EventScroll
    ( 

-- * Exported types
    EventScroll(..)                         ,
    newZeroEventScroll                      ,


 -- * Methods
-- ** Overloaded methods #method:Overloaded methods#

#if defined(ENABLE_OVERLOADING)
    ResolveEventScrollMethod                ,
#endif




 -- * Properties
-- ** deltaX #attr:deltaX#
-- | the x coordinate of the scroll delta

#if defined(ENABLE_OVERLOADING)
    eventScroll_deltaX                      ,
#endif
    getEventScrollDeltaX                    ,
    setEventScrollDeltaX                    ,


-- ** deltaY #attr:deltaY#
-- | the y coordinate of the scroll delta

#if defined(ENABLE_OVERLOADING)
    eventScroll_deltaY                      ,
#endif
    getEventScrollDeltaY                    ,
    setEventScrollDeltaY                    ,


-- ** device #attr:device#
-- | the master device that the event originated from. Use
-- 'GI.Gdk.Unions.Event.eventGetSourceDevice' to get the slave device.

    clearEventScrollDevice                  ,
#if defined(ENABLE_OVERLOADING)
    eventScroll_device                      ,
#endif
    getEventScrollDevice                    ,
    setEventScrollDevice                    ,


-- ** direction #attr:direction#
-- | the direction to scroll to (one of 'GI.Gdk.Enums.ScrollDirectionUp',
--   'GI.Gdk.Enums.ScrollDirectionDown', 'GI.Gdk.Enums.ScrollDirectionLeft', 'GI.Gdk.Enums.ScrollDirectionRight' or
--   'GI.Gdk.Enums.ScrollDirectionSmooth').

#if defined(ENABLE_OVERLOADING)
    eventScroll_direction                   ,
#endif
    getEventScrollDirection                 ,
    setEventScrollDirection                 ,


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

#if defined(ENABLE_OVERLOADING)
    eventScroll_isStop                      ,
#endif
    getEventScrollIsStop                    ,
    setEventScrollIsStop                    ,


-- ** sendEvent #attr:sendEvent#
-- | 'P.True' if the event was sent explicitly.

#if defined(ENABLE_OVERLOADING)
    eventScroll_sendEvent                   ,
#endif
    getEventScrollSendEvent                 ,
    setEventScrollSendEvent                 ,


-- ** state #attr:state#
-- | a bit-mask representing the state of
--   the modifier keys (e.g. Control, Shift and Alt) and the pointer
--   buttons. See t'GI.Gdk.Flags.ModifierType'.

#if defined(ENABLE_OVERLOADING)
    eventScroll_state                       ,
#endif
    getEventScrollState                     ,
    setEventScrollState                     ,


-- ** time #attr:time#
-- | the time of the event in milliseconds.

#if defined(ENABLE_OVERLOADING)
    eventScroll_time                        ,
#endif
    getEventScrollTime                      ,
    setEventScrollTime                      ,


-- ** type #attr:type#
-- | the type of the event ('GI.Gdk.Enums.EventTypeScroll').

#if defined(ENABLE_OVERLOADING)
    eventScroll_type                        ,
#endif
    getEventScrollType                      ,
    setEventScrollType                      ,


-- ** window #attr:window#
-- | the window which received the event.

    clearEventScrollWindow                  ,
#if defined(ENABLE_OVERLOADING)
    eventScroll_window                      ,
#endif
    getEventScrollWindow                    ,
    setEventScrollWindow                    ,


-- ** x #attr:x#
-- | the x coordinate of the pointer relative to the window.

#if defined(ENABLE_OVERLOADING)
    eventScroll_x                           ,
#endif
    getEventScrollX                         ,
    setEventScrollX                         ,


-- ** xRoot #attr:xRoot#
-- | the x coordinate of the pointer relative to the root of the
--   screen.

#if defined(ENABLE_OVERLOADING)
    eventScroll_xRoot                       ,
#endif
    getEventScrollXRoot                     ,
    setEventScrollXRoot                     ,


-- ** y #attr:y#
-- | the y coordinate of the pointer relative to the window.

#if defined(ENABLE_OVERLOADING)
    eventScroll_y                           ,
#endif
    getEventScrollY                         ,
    setEventScrollY                         ,


-- ** yRoot #attr:yRoot#
-- | the y coordinate of the pointer relative to the root of the
--   screen.

#if defined(ENABLE_OVERLOADING)
    eventScroll_yRoot                       ,
#endif
    getEventScrollYRoot                     ,
    setEventScrollYRoot                     ,




    ) where

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

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

import {-# SOURCE #-} qualified GI.Gdk.Enums as Gdk.Enums
import {-# SOURCE #-} qualified GI.Gdk.Flags as Gdk.Flags
import {-# SOURCE #-} qualified GI.Gdk.Objects.Device as Gdk.Device
import {-# SOURCE #-} qualified GI.Gdk.Objects.Window as Gdk.Window

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

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

instance BoxedPtr EventScroll where
    boxedPtrCopy :: EventScroll -> IO EventScroll
boxedPtrCopy = \EventScroll
p -> EventScroll
-> (Ptr EventScroll -> IO EventScroll) -> IO EventScroll
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
B.ManagedPtr.withManagedPtr EventScroll
p (Int -> Ptr EventScroll -> IO (Ptr EventScroll)
forall a. (HasCallStack, CallocPtr a) => Int -> Ptr a -> IO (Ptr a)
copyBytes Int
96 (Ptr EventScroll -> IO (Ptr EventScroll))
-> (Ptr EventScroll -> IO EventScroll)
-> Ptr EventScroll
-> IO EventScroll
forall (m :: * -> *) a b c.
Monad m =>
(a -> m b) -> (b -> m c) -> a -> m c
>=> (ManagedPtr EventScroll -> EventScroll)
-> Ptr EventScroll -> IO EventScroll
forall a.
(HasCallStack, BoxedPtr a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
B.ManagedPtr.wrapPtr ManagedPtr EventScroll -> EventScroll
EventScroll)
    boxedPtrFree :: EventScroll -> IO ()
boxedPtrFree = \EventScroll
x -> EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
SP.withManagedPtr EventScroll
x Ptr EventScroll -> IO ()
forall a. Ptr a -> IO ()
SP.freeMem
instance CallocPtr EventScroll where
    boxedPtrCalloc :: IO (Ptr EventScroll)
boxedPtrCalloc = Int -> IO (Ptr EventScroll)
forall a. Int -> IO (Ptr a)
callocBytes Int
96


-- | Construct a `EventScroll` struct initialized to zero.
newZeroEventScroll :: MonadIO m => m EventScroll
newZeroEventScroll :: m EventScroll
newZeroEventScroll = IO EventScroll -> m EventScroll
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO EventScroll -> m EventScroll)
-> IO EventScroll -> m EventScroll
forall a b. (a -> b) -> a -> b
$ IO (Ptr EventScroll)
forall a. CallocPtr a => IO (Ptr a)
boxedPtrCalloc IO (Ptr EventScroll)
-> (Ptr EventScroll -> IO EventScroll) -> IO EventScroll
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= (ManagedPtr EventScroll -> EventScroll)
-> Ptr EventScroll -> IO EventScroll
forall a.
(HasCallStack, BoxedPtr a) =>
(ManagedPtr a -> a) -> Ptr a -> IO a
wrapPtr ManagedPtr EventScroll -> EventScroll
EventScroll

instance tag ~ 'AttrSet => Constructible EventScroll tag where
    new :: (ManagedPtr EventScroll -> EventScroll)
-> [AttrOp EventScroll tag] -> m EventScroll
new ManagedPtr EventScroll -> EventScroll
_ [AttrOp EventScroll tag]
attrs = do
        EventScroll
o <- m EventScroll
forall (m :: * -> *). MonadIO m => m EventScroll
newZeroEventScroll
        EventScroll -> [AttrOp EventScroll 'AttrSet] -> m ()
forall o (m :: * -> *).
MonadIO m =>
o -> [AttrOp o 'AttrSet] -> m ()
GI.Attributes.set EventScroll
o [AttrOp EventScroll tag]
[AttrOp EventScroll 'AttrSet]
attrs
        EventScroll -> m EventScroll
forall (m :: * -> *) a. Monad m => a -> m a
return EventScroll
o


-- | Get the value of the “@type@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #type
-- @
getEventScrollType :: MonadIO m => EventScroll -> m Gdk.Enums.EventType
getEventScrollType :: EventScroll -> m EventType
getEventScrollType EventScroll
s = IO EventType -> m EventType
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO EventType -> m EventType) -> IO EventType -> m EventType
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO EventType) -> IO EventType
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO EventType) -> IO EventType)
-> (Ptr EventScroll -> IO EventType) -> IO EventType
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CInt
val <- Ptr CInt -> IO CInt
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CInt
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) :: IO CInt
    let val' :: EventType
val' = (Int -> EventType
forall a. Enum a => Int -> a
toEnum (Int -> EventType) -> (CInt -> Int) -> CInt -> EventType
forall b c a. (b -> c) -> (a -> b) -> a -> c
. CInt -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral) CInt
val
    EventType -> IO EventType
forall (m :: * -> *) a. Monad m => a -> m a
return EventType
val'

-- | Set the value of the “@type@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #type 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollType :: MonadIO m => EventScroll -> Gdk.Enums.EventType -> m ()
setEventScrollType :: EventScroll -> EventType -> m ()
setEventScrollType EventScroll
s EventType
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CInt
val' = (Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Int -> CInt) -> (EventType -> Int) -> EventType -> CInt
forall b c a. (b -> c) -> (a -> b) -> a -> c
. EventType -> Int
forall a. Enum a => a -> Int
fromEnum) EventType
val
    Ptr CInt -> CInt -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CInt
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0) (CInt
val' :: CInt)

#if defined(ENABLE_OVERLOADING)
data EventScrollTypeFieldInfo
instance AttrInfo EventScrollTypeFieldInfo where
    type AttrBaseTypeConstraint EventScrollTypeFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollTypeFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollTypeFieldInfo = (~) Gdk.Enums.EventType
    type AttrTransferTypeConstraint EventScrollTypeFieldInfo = (~)Gdk.Enums.EventType
    type AttrTransferType EventScrollTypeFieldInfo = Gdk.Enums.EventType
    type AttrGetType EventScrollTypeFieldInfo = Gdk.Enums.EventType
    type AttrLabel EventScrollTypeFieldInfo = "type"
    type AttrOrigin EventScrollTypeFieldInfo = EventScroll
    attrGet = getEventScrollType
    attrSet = setEventScrollType
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_type :: AttrLabelProxy "type"
eventScroll_type = AttrLabelProxy

#endif


-- | Get the value of the “@window@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #window
-- @
getEventScrollWindow :: MonadIO m => EventScroll -> m (Maybe Gdk.Window.Window)
getEventScrollWindow :: EventScroll -> m (Maybe Window)
getEventScrollWindow EventScroll
s = IO (Maybe Window) -> m (Maybe Window)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe Window) -> m (Maybe Window))
-> IO (Maybe Window) -> m (Maybe Window)
forall a b. (a -> b) -> a -> b
$ EventScroll
-> (Ptr EventScroll -> IO (Maybe Window)) -> IO (Maybe Window)
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO (Maybe Window)) -> IO (Maybe Window))
-> (Ptr EventScroll -> IO (Maybe Window)) -> IO (Maybe Window)
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr Window
val <- Ptr (Ptr Window) -> IO (Ptr Window)
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr (Ptr Window)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) :: IO (Ptr Gdk.Window.Window)
    Maybe Window
result <- Ptr Window -> (Ptr Window -> IO Window) -> IO (Maybe Window)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr Window
val ((Ptr Window -> IO Window) -> IO (Maybe Window))
-> (Ptr Window -> IO Window) -> IO (Maybe Window)
forall a b. (a -> b) -> a -> b
$ \Ptr Window
val' -> do
        Window
val'' <- ((ManagedPtr Window -> Window) -> Ptr Window -> IO Window
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr Window -> Window
Gdk.Window.Window) Ptr Window
val'
        Window -> IO Window
forall (m :: * -> *) a. Monad m => a -> m a
return Window
val''
    Maybe Window -> IO (Maybe Window)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Window
result

-- | Set the value of the “@window@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #window 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollWindow :: MonadIO m => EventScroll -> Ptr Gdk.Window.Window -> m ()
setEventScrollWindow :: EventScroll -> Ptr Window -> m ()
setEventScrollWindow EventScroll
s Ptr Window
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr (Ptr Window) -> Ptr Window -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr (Ptr Window)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) (Ptr Window
val :: Ptr Gdk.Window.Window)

-- | Set the value of the “@window@” field to `Nothing`.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.clear' #window
-- @
clearEventScrollWindow :: MonadIO m => EventScroll -> m ()
clearEventScrollWindow :: EventScroll -> m ()
clearEventScrollWindow EventScroll
s = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr (Ptr Window) -> Ptr Window -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr (Ptr Window)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8) (Ptr Window
forall a. Ptr a
FP.nullPtr :: Ptr Gdk.Window.Window)

#if defined(ENABLE_OVERLOADING)
data EventScrollWindowFieldInfo
instance AttrInfo EventScrollWindowFieldInfo where
    type AttrBaseTypeConstraint EventScrollWindowFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollWindowFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
    type AttrSetTypeConstraint EventScrollWindowFieldInfo = (~) (Ptr Gdk.Window.Window)
    type AttrTransferTypeConstraint EventScrollWindowFieldInfo = (~)(Ptr Gdk.Window.Window)
    type AttrTransferType EventScrollWindowFieldInfo = (Ptr Gdk.Window.Window)
    type AttrGetType EventScrollWindowFieldInfo = Maybe Gdk.Window.Window
    type AttrLabel EventScrollWindowFieldInfo = "window"
    type AttrOrigin EventScrollWindowFieldInfo = EventScroll
    attrGet = getEventScrollWindow
    attrSet = setEventScrollWindow
    attrConstruct = undefined
    attrClear = clearEventScrollWindow
    attrTransfer _ v = do
        return v

eventScroll_window :: AttrLabelProxy "window"
eventScroll_window = AttrLabelProxy

#endif


-- | Get the value of the “@send_event@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #sendEvent
-- @
getEventScrollSendEvent :: MonadIO m => EventScroll -> m Int8
getEventScrollSendEvent :: EventScroll -> m Int8
getEventScrollSendEvent EventScroll
s = IO Int8 -> m Int8
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Int8 -> m Int8) -> IO Int8 -> m Int8
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Int8) -> IO Int8
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Int8) -> IO Int8)
-> (Ptr EventScroll -> IO Int8) -> IO Int8
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Int8
val <- Ptr Int8 -> IO Int8
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr Int8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) :: IO Int8
    Int8 -> IO Int8
forall (m :: * -> *) a. Monad m => a -> m a
return Int8
val

-- | Set the value of the “@send_event@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #sendEvent 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollSendEvent :: MonadIO m => EventScroll -> Int8 -> m ()
setEventScrollSendEvent :: EventScroll -> Int8 -> m ()
setEventScrollSendEvent EventScroll
s Int8
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr Int8 -> Int8 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr Int8
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16) (Int8
val :: Int8)

#if defined(ENABLE_OVERLOADING)
data EventScrollSendEventFieldInfo
instance AttrInfo EventScrollSendEventFieldInfo where
    type AttrBaseTypeConstraint EventScrollSendEventFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollSendEventFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollSendEventFieldInfo = (~) Int8
    type AttrTransferTypeConstraint EventScrollSendEventFieldInfo = (~)Int8
    type AttrTransferType EventScrollSendEventFieldInfo = Int8
    type AttrGetType EventScrollSendEventFieldInfo = Int8
    type AttrLabel EventScrollSendEventFieldInfo = "send_event"
    type AttrOrigin EventScrollSendEventFieldInfo = EventScroll
    attrGet = getEventScrollSendEvent
    attrSet = setEventScrollSendEvent
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_sendEvent :: AttrLabelProxy "sendEvent"
eventScroll_sendEvent = AttrLabelProxy

#endif


-- | Get the value of the “@time@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #time
-- @
getEventScrollTime :: MonadIO m => EventScroll -> m Word32
getEventScrollTime :: EventScroll -> m Word32
getEventScrollTime EventScroll
s = IO Word32 -> m Word32
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Word32 -> m Word32) -> IO Word32 -> m Word32
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Word32) -> IO Word32
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Word32) -> IO Word32)
-> (Ptr EventScroll -> IO Word32) -> IO Word32
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Word32
val <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
20) :: IO Word32
    Word32 -> IO Word32
forall (m :: * -> *) a. Monad m => a -> m a
return Word32
val

-- | Set the value of the “@time@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #time 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollTime :: MonadIO m => EventScroll -> Word32 -> m ()
setEventScrollTime :: EventScroll -> Word32 -> m ()
setEventScrollTime EventScroll
s Word32
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
20) (Word32
val :: Word32)

#if defined(ENABLE_OVERLOADING)
data EventScrollTimeFieldInfo
instance AttrInfo EventScrollTimeFieldInfo where
    type AttrBaseTypeConstraint EventScrollTimeFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollTimeFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollTimeFieldInfo = (~) Word32
    type AttrTransferTypeConstraint EventScrollTimeFieldInfo = (~)Word32
    type AttrTransferType EventScrollTimeFieldInfo = Word32
    type AttrGetType EventScrollTimeFieldInfo = Word32
    type AttrLabel EventScrollTimeFieldInfo = "time"
    type AttrOrigin EventScrollTimeFieldInfo = EventScroll
    attrGet = getEventScrollTime
    attrSet = setEventScrollTime
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_time :: AttrLabelProxy "time"
eventScroll_time = AttrLabelProxy

#endif


-- | Get the value of the “@x@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #x
-- @
getEventScrollX :: MonadIO m => EventScroll -> m Double
getEventScrollX :: EventScroll -> m Double
getEventScrollX EventScroll
s = IO Double -> m Double
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Double -> m Double) -> IO Double -> m Double
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Double) -> IO Double
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Double) -> IO Double)
-> (Ptr EventScroll -> IO Double) -> IO Double
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CDouble
val <- Ptr CDouble -> IO CDouble
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24) :: IO CDouble
    let val' :: Double
val' = CDouble -> Double
forall a b. (Real a, Fractional b) => a -> b
realToFrac CDouble
val
    Double -> IO Double
forall (m :: * -> *) a. Monad m => a -> m a
return Double
val'

-- | Set the value of the “@x@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #x 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollX :: MonadIO m => EventScroll -> Double -> m ()
setEventScrollX :: EventScroll -> Double -> m ()
setEventScrollX EventScroll
s Double
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CDouble
val' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
val
    Ptr CDouble -> CDouble -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24) (CDouble
val' :: CDouble)

#if defined(ENABLE_OVERLOADING)
data EventScrollXFieldInfo
instance AttrInfo EventScrollXFieldInfo where
    type AttrBaseTypeConstraint EventScrollXFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollXFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollXFieldInfo = (~) Double
    type AttrTransferTypeConstraint EventScrollXFieldInfo = (~)Double
    type AttrTransferType EventScrollXFieldInfo = Double
    type AttrGetType EventScrollXFieldInfo = Double
    type AttrLabel EventScrollXFieldInfo = "x"
    type AttrOrigin EventScrollXFieldInfo = EventScroll
    attrGet = getEventScrollX
    attrSet = setEventScrollX
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_x :: AttrLabelProxy "x"
eventScroll_x = AttrLabelProxy

#endif


-- | Get the value of the “@y@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #y
-- @
getEventScrollY :: MonadIO m => EventScroll -> m Double
getEventScrollY :: EventScroll -> m Double
getEventScrollY EventScroll
s = IO Double -> m Double
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Double -> m Double) -> IO Double -> m Double
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Double) -> IO Double
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Double) -> IO Double)
-> (Ptr EventScroll -> IO Double) -> IO Double
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CDouble
val <- Ptr CDouble -> IO CDouble
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) :: IO CDouble
    let val' :: Double
val' = CDouble -> Double
forall a b. (Real a, Fractional b) => a -> b
realToFrac CDouble
val
    Double -> IO Double
forall (m :: * -> *) a. Monad m => a -> m a
return Double
val'

-- | Set the value of the “@y@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #y 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollY :: MonadIO m => EventScroll -> Double -> m ()
setEventScrollY :: EventScroll -> Double -> m ()
setEventScrollY EventScroll
s Double
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CDouble
val' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
val
    Ptr CDouble -> CDouble -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32) (CDouble
val' :: CDouble)

#if defined(ENABLE_OVERLOADING)
data EventScrollYFieldInfo
instance AttrInfo EventScrollYFieldInfo where
    type AttrBaseTypeConstraint EventScrollYFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollYFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollYFieldInfo = (~) Double
    type AttrTransferTypeConstraint EventScrollYFieldInfo = (~)Double
    type AttrTransferType EventScrollYFieldInfo = Double
    type AttrGetType EventScrollYFieldInfo = Double
    type AttrLabel EventScrollYFieldInfo = "y"
    type AttrOrigin EventScrollYFieldInfo = EventScroll
    attrGet = getEventScrollY
    attrSet = setEventScrollY
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_y :: AttrLabelProxy "y"
eventScroll_y = AttrLabelProxy

#endif


-- | Get the value of the “@state@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #state
-- @
getEventScrollState :: MonadIO m => EventScroll -> m [Gdk.Flags.ModifierType]
getEventScrollState :: EventScroll -> m [ModifierType]
getEventScrollState EventScroll
s = IO [ModifierType] -> m [ModifierType]
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO [ModifierType] -> m [ModifierType])
-> IO [ModifierType] -> m [ModifierType]
forall a b. (a -> b) -> a -> b
$ EventScroll
-> (Ptr EventScroll -> IO [ModifierType]) -> IO [ModifierType]
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO [ModifierType]) -> IO [ModifierType])
-> (Ptr EventScroll -> IO [ModifierType]) -> IO [ModifierType]
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CUInt
val <- Ptr CUInt -> IO CUInt
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CUInt
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
40) :: IO CUInt
    let val' :: [ModifierType]
val' = CUInt -> [ModifierType]
forall a b. (Storable a, Integral a, Bits a, IsGFlag b) => a -> [b]
wordToGFlags CUInt
val
    [ModifierType] -> IO [ModifierType]
forall (m :: * -> *) a. Monad m => a -> m a
return [ModifierType]
val'

-- | Set the value of the “@state@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #state 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollState :: MonadIO m => EventScroll -> [Gdk.Flags.ModifierType] -> m ()
setEventScrollState :: EventScroll -> [ModifierType] -> m ()
setEventScrollState EventScroll
s [ModifierType]
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CUInt
val' = [ModifierType] -> CUInt
forall b a. (Num b, IsGFlag a) => [a] -> b
gflagsToWord [ModifierType]
val
    Ptr CUInt -> CUInt -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CUInt
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
40) (CUInt
val' :: CUInt)

#if defined(ENABLE_OVERLOADING)
data EventScrollStateFieldInfo
instance AttrInfo EventScrollStateFieldInfo where
    type AttrBaseTypeConstraint EventScrollStateFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollStateFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollStateFieldInfo = (~) [Gdk.Flags.ModifierType]
    type AttrTransferTypeConstraint EventScrollStateFieldInfo = (~)[Gdk.Flags.ModifierType]
    type AttrTransferType EventScrollStateFieldInfo = [Gdk.Flags.ModifierType]
    type AttrGetType EventScrollStateFieldInfo = [Gdk.Flags.ModifierType]
    type AttrLabel EventScrollStateFieldInfo = "state"
    type AttrOrigin EventScrollStateFieldInfo = EventScroll
    attrGet = getEventScrollState
    attrSet = setEventScrollState
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_state :: AttrLabelProxy "state"
eventScroll_state = AttrLabelProxy

#endif


-- | Get the value of the “@direction@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #direction
-- @
getEventScrollDirection :: MonadIO m => EventScroll -> m Gdk.Enums.ScrollDirection
getEventScrollDirection :: EventScroll -> m ScrollDirection
getEventScrollDirection EventScroll
s = IO ScrollDirection -> m ScrollDirection
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO ScrollDirection -> m ScrollDirection)
-> IO ScrollDirection -> m ScrollDirection
forall a b. (a -> b) -> a -> b
$ EventScroll
-> (Ptr EventScroll -> IO ScrollDirection) -> IO ScrollDirection
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ScrollDirection) -> IO ScrollDirection)
-> (Ptr EventScroll -> IO ScrollDirection) -> IO ScrollDirection
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CUInt
val <- Ptr CUInt -> IO CUInt
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CUInt
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
44) :: IO CUInt
    let val' :: ScrollDirection
val' = (Int -> ScrollDirection
forall a. Enum a => Int -> a
toEnum (Int -> ScrollDirection)
-> (CUInt -> Int) -> CUInt -> ScrollDirection
forall b c a. (b -> c) -> (a -> b) -> a -> c
. CUInt -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral) CUInt
val
    ScrollDirection -> IO ScrollDirection
forall (m :: * -> *) a. Monad m => a -> m a
return ScrollDirection
val'

-- | Set the value of the “@direction@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #direction 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollDirection :: MonadIO m => EventScroll -> Gdk.Enums.ScrollDirection -> m ()
setEventScrollDirection :: EventScroll -> ScrollDirection -> m ()
setEventScrollDirection EventScroll
s ScrollDirection
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CUInt
val' = (Int -> CUInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Int -> CUInt)
-> (ScrollDirection -> Int) -> ScrollDirection -> CUInt
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ScrollDirection -> Int
forall a. Enum a => a -> Int
fromEnum) ScrollDirection
val
    Ptr CUInt -> CUInt -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CUInt
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
44) (CUInt
val' :: CUInt)

#if defined(ENABLE_OVERLOADING)
data EventScrollDirectionFieldInfo
instance AttrInfo EventScrollDirectionFieldInfo where
    type AttrBaseTypeConstraint EventScrollDirectionFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollDirectionFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollDirectionFieldInfo = (~) Gdk.Enums.ScrollDirection
    type AttrTransferTypeConstraint EventScrollDirectionFieldInfo = (~)Gdk.Enums.ScrollDirection
    type AttrTransferType EventScrollDirectionFieldInfo = Gdk.Enums.ScrollDirection
    type AttrGetType EventScrollDirectionFieldInfo = Gdk.Enums.ScrollDirection
    type AttrLabel EventScrollDirectionFieldInfo = "direction"
    type AttrOrigin EventScrollDirectionFieldInfo = EventScroll
    attrGet = getEventScrollDirection
    attrSet = setEventScrollDirection
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_direction :: AttrLabelProxy "direction"
eventScroll_direction = AttrLabelProxy

#endif


-- | Get the value of the “@device@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #device
-- @
getEventScrollDevice :: MonadIO m => EventScroll -> m (Maybe Gdk.Device.Device)
getEventScrollDevice :: EventScroll -> m (Maybe Device)
getEventScrollDevice EventScroll
s = IO (Maybe Device) -> m (Maybe Device)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe Device) -> m (Maybe Device))
-> IO (Maybe Device) -> m (Maybe Device)
forall a b. (a -> b) -> a -> b
$ EventScroll
-> (Ptr EventScroll -> IO (Maybe Device)) -> IO (Maybe Device)
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO (Maybe Device)) -> IO (Maybe Device))
-> (Ptr EventScroll -> IO (Maybe Device)) -> IO (Maybe Device)
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr Device
val <- Ptr (Ptr Device) -> IO (Ptr Device)
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr (Ptr Device)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
48) :: IO (Ptr Gdk.Device.Device)
    Maybe Device
result <- Ptr Device -> (Ptr Device -> IO Device) -> IO (Maybe Device)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
SP.convertIfNonNull Ptr Device
val ((Ptr Device -> IO Device) -> IO (Maybe Device))
-> (Ptr Device -> IO Device) -> IO (Maybe Device)
forall a b. (a -> b) -> a -> b
$ \Ptr Device
val' -> do
        Device
val'' <- ((ManagedPtr Device -> Device) -> Ptr Device -> IO Device
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
newObject ManagedPtr Device -> Device
Gdk.Device.Device) Ptr Device
val'
        Device -> IO Device
forall (m :: * -> *) a. Monad m => a -> m a
return Device
val''
    Maybe Device -> IO (Maybe Device)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Device
result

-- | Set the value of the “@device@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #device 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollDevice :: MonadIO m => EventScroll -> Ptr Gdk.Device.Device -> m ()
setEventScrollDevice :: EventScroll -> Ptr Device -> m ()
setEventScrollDevice EventScroll
s Ptr Device
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr (Ptr Device) -> Ptr Device -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr (Ptr Device)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
48) (Ptr Device
val :: Ptr Gdk.Device.Device)

-- | Set the value of the “@device@” field to `Nothing`.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.clear' #device
-- @
clearEventScrollDevice :: MonadIO m => EventScroll -> m ()
clearEventScrollDevice :: EventScroll -> m ()
clearEventScrollDevice EventScroll
s = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr (Ptr Device) -> Ptr Device -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr (Ptr Device)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
48) (Ptr Device
forall a. Ptr a
FP.nullPtr :: Ptr Gdk.Device.Device)

#if defined(ENABLE_OVERLOADING)
data EventScrollDeviceFieldInfo
instance AttrInfo EventScrollDeviceFieldInfo where
    type AttrBaseTypeConstraint EventScrollDeviceFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollDeviceFieldInfo = '[ 'AttrSet, 'AttrGet, 'AttrClear]
    type AttrSetTypeConstraint EventScrollDeviceFieldInfo = (~) (Ptr Gdk.Device.Device)
    type AttrTransferTypeConstraint EventScrollDeviceFieldInfo = (~)(Ptr Gdk.Device.Device)
    type AttrTransferType EventScrollDeviceFieldInfo = (Ptr Gdk.Device.Device)
    type AttrGetType EventScrollDeviceFieldInfo = Maybe Gdk.Device.Device
    type AttrLabel EventScrollDeviceFieldInfo = "device"
    type AttrOrigin EventScrollDeviceFieldInfo = EventScroll
    attrGet = getEventScrollDevice
    attrSet = setEventScrollDevice
    attrConstruct = undefined
    attrClear = clearEventScrollDevice
    attrTransfer _ v = do
        return v

eventScroll_device :: AttrLabelProxy "device"
eventScroll_device = AttrLabelProxy

#endif


-- | Get the value of the “@x_root@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #xRoot
-- @
getEventScrollXRoot :: MonadIO m => EventScroll -> m Double
getEventScrollXRoot :: EventScroll -> m Double
getEventScrollXRoot EventScroll
s = IO Double -> m Double
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Double -> m Double) -> IO Double -> m Double
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Double) -> IO Double
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Double) -> IO Double)
-> (Ptr EventScroll -> IO Double) -> IO Double
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CDouble
val <- Ptr CDouble -> IO CDouble
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
56) :: IO CDouble
    let val' :: Double
val' = CDouble -> Double
forall a b. (Real a, Fractional b) => a -> b
realToFrac CDouble
val
    Double -> IO Double
forall (m :: * -> *) a. Monad m => a -> m a
return Double
val'

-- | Set the value of the “@x_root@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #xRoot 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollXRoot :: MonadIO m => EventScroll -> Double -> m ()
setEventScrollXRoot :: EventScroll -> Double -> m ()
setEventScrollXRoot EventScroll
s Double
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CDouble
val' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
val
    Ptr CDouble -> CDouble -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
56) (CDouble
val' :: CDouble)

#if defined(ENABLE_OVERLOADING)
data EventScrollXRootFieldInfo
instance AttrInfo EventScrollXRootFieldInfo where
    type AttrBaseTypeConstraint EventScrollXRootFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollXRootFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollXRootFieldInfo = (~) Double
    type AttrTransferTypeConstraint EventScrollXRootFieldInfo = (~)Double
    type AttrTransferType EventScrollXRootFieldInfo = Double
    type AttrGetType EventScrollXRootFieldInfo = Double
    type AttrLabel EventScrollXRootFieldInfo = "x_root"
    type AttrOrigin EventScrollXRootFieldInfo = EventScroll
    attrGet = getEventScrollXRoot
    attrSet = setEventScrollXRoot
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_xRoot :: AttrLabelProxy "xRoot"
eventScroll_xRoot = AttrLabelProxy

#endif


-- | Get the value of the “@y_root@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #yRoot
-- @
getEventScrollYRoot :: MonadIO m => EventScroll -> m Double
getEventScrollYRoot :: EventScroll -> m Double
getEventScrollYRoot EventScroll
s = IO Double -> m Double
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Double -> m Double) -> IO Double -> m Double
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Double) -> IO Double
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Double) -> IO Double)
-> (Ptr EventScroll -> IO Double) -> IO Double
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CDouble
val <- Ptr CDouble -> IO CDouble
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
64) :: IO CDouble
    let val' :: Double
val' = CDouble -> Double
forall a b. (Real a, Fractional b) => a -> b
realToFrac CDouble
val
    Double -> IO Double
forall (m :: * -> *) a. Monad m => a -> m a
return Double
val'

-- | Set the value of the “@y_root@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #yRoot 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollYRoot :: MonadIO m => EventScroll -> Double -> m ()
setEventScrollYRoot :: EventScroll -> Double -> m ()
setEventScrollYRoot EventScroll
s Double
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CDouble
val' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
val
    Ptr CDouble -> CDouble -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
64) (CDouble
val' :: CDouble)

#if defined(ENABLE_OVERLOADING)
data EventScrollYRootFieldInfo
instance AttrInfo EventScrollYRootFieldInfo where
    type AttrBaseTypeConstraint EventScrollYRootFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollYRootFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollYRootFieldInfo = (~) Double
    type AttrTransferTypeConstraint EventScrollYRootFieldInfo = (~)Double
    type AttrTransferType EventScrollYRootFieldInfo = Double
    type AttrGetType EventScrollYRootFieldInfo = Double
    type AttrLabel EventScrollYRootFieldInfo = "y_root"
    type AttrOrigin EventScrollYRootFieldInfo = EventScroll
    attrGet = getEventScrollYRoot
    attrSet = setEventScrollYRoot
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_yRoot :: AttrLabelProxy "yRoot"
eventScroll_yRoot = AttrLabelProxy

#endif


-- | Get the value of the “@delta_x@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #deltaX
-- @
getEventScrollDeltaX :: MonadIO m => EventScroll -> m Double
getEventScrollDeltaX :: EventScroll -> m Double
getEventScrollDeltaX EventScroll
s = IO Double -> m Double
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Double -> m Double) -> IO Double -> m Double
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Double) -> IO Double
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Double) -> IO Double)
-> (Ptr EventScroll -> IO Double) -> IO Double
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CDouble
val <- Ptr CDouble -> IO CDouble
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
72) :: IO CDouble
    let val' :: Double
val' = CDouble -> Double
forall a b. (Real a, Fractional b) => a -> b
realToFrac CDouble
val
    Double -> IO Double
forall (m :: * -> *) a. Monad m => a -> m a
return Double
val'

-- | Set the value of the “@delta_x@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #deltaX 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollDeltaX :: MonadIO m => EventScroll -> Double -> m ()
setEventScrollDeltaX :: EventScroll -> Double -> m ()
setEventScrollDeltaX EventScroll
s Double
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CDouble
val' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
val
    Ptr CDouble -> CDouble -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
72) (CDouble
val' :: CDouble)

#if defined(ENABLE_OVERLOADING)
data EventScrollDeltaXFieldInfo
instance AttrInfo EventScrollDeltaXFieldInfo where
    type AttrBaseTypeConstraint EventScrollDeltaXFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollDeltaXFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollDeltaXFieldInfo = (~) Double
    type AttrTransferTypeConstraint EventScrollDeltaXFieldInfo = (~)Double
    type AttrTransferType EventScrollDeltaXFieldInfo = Double
    type AttrGetType EventScrollDeltaXFieldInfo = Double
    type AttrLabel EventScrollDeltaXFieldInfo = "delta_x"
    type AttrOrigin EventScrollDeltaXFieldInfo = EventScroll
    attrGet = getEventScrollDeltaX
    attrSet = setEventScrollDeltaX
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_deltaX :: AttrLabelProxy "deltaX"
eventScroll_deltaX = AttrLabelProxy

#endif


-- | Get the value of the “@delta_y@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #deltaY
-- @
getEventScrollDeltaY :: MonadIO m => EventScroll -> m Double
getEventScrollDeltaY :: EventScroll -> m Double
getEventScrollDeltaY EventScroll
s = IO Double -> m Double
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Double -> m Double) -> IO Double -> m Double
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Double) -> IO Double
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Double) -> IO Double)
-> (Ptr EventScroll -> IO Double) -> IO Double
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    CDouble
val <- Ptr CDouble -> IO CDouble
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
80) :: IO CDouble
    let val' :: Double
val' = CDouble -> Double
forall a b. (Real a, Fractional b) => a -> b
realToFrac CDouble
val
    Double -> IO Double
forall (m :: * -> *) a. Monad m => a -> m a
return Double
val'

-- | Set the value of the “@delta_y@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #deltaY 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollDeltaY :: MonadIO m => EventScroll -> Double -> m ()
setEventScrollDeltaY :: EventScroll -> Double -> m ()
setEventScrollDeltaY EventScroll
s Double
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    let val' :: CDouble
val' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
val
    Ptr CDouble -> CDouble -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr CDouble
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
80) (CDouble
val' :: CDouble)

#if defined(ENABLE_OVERLOADING)
data EventScrollDeltaYFieldInfo
instance AttrInfo EventScrollDeltaYFieldInfo where
    type AttrBaseTypeConstraint EventScrollDeltaYFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollDeltaYFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollDeltaYFieldInfo = (~) Double
    type AttrTransferTypeConstraint EventScrollDeltaYFieldInfo = (~)Double
    type AttrTransferType EventScrollDeltaYFieldInfo = Double
    type AttrGetType EventScrollDeltaYFieldInfo = Double
    type AttrLabel EventScrollDeltaYFieldInfo = "delta_y"
    type AttrOrigin EventScrollDeltaYFieldInfo = EventScroll
    attrGet = getEventScrollDeltaY
    attrSet = setEventScrollDeltaY
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_deltaY :: AttrLabelProxy "deltaY"
eventScroll_deltaY = AttrLabelProxy

#endif


-- | Get the value of the “@is_stop@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.get' eventScroll #isStop
-- @
getEventScrollIsStop :: MonadIO m => EventScroll -> m Word32
getEventScrollIsStop :: EventScroll -> m Word32
getEventScrollIsStop EventScroll
s = IO Word32 -> m Word32
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO Word32 -> m Word32) -> IO Word32 -> m Word32
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO Word32) -> IO Word32
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO Word32) -> IO Word32)
-> (Ptr EventScroll -> IO Word32) -> IO Word32
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Word32
val <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
88) :: IO Word32
    Word32 -> IO Word32
forall (m :: * -> *) a. Monad m => a -> m a
return Word32
val

-- | Set the value of the “@is_stop@” field.
-- When <https://github.com/haskell-gi/haskell-gi/wiki/Overloading overloading> is enabled, this is equivalent to
-- 
-- @
-- 'Data.GI.Base.Attributes.set' eventScroll [ #isStop 'Data.GI.Base.Attributes.:=' value ]
-- @
setEventScrollIsStop :: MonadIO m => EventScroll -> Word32 -> m ()
setEventScrollIsStop :: EventScroll -> Word32 -> m ()
setEventScrollIsStop EventScroll
s Word32
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ EventScroll -> (Ptr EventScroll -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
withManagedPtr EventScroll
s ((Ptr EventScroll -> IO ()) -> IO ())
-> (Ptr EventScroll -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr EventScroll
ptr -> do
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr EventScroll
ptr Ptr EventScroll -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
88) (Word32
val :: Word32)

#if defined(ENABLE_OVERLOADING)
data EventScrollIsStopFieldInfo
instance AttrInfo EventScrollIsStopFieldInfo where
    type AttrBaseTypeConstraint EventScrollIsStopFieldInfo = (~) EventScroll
    type AttrAllowedOps EventScrollIsStopFieldInfo = '[ 'AttrSet, 'AttrGet]
    type AttrSetTypeConstraint EventScrollIsStopFieldInfo = (~) Word32
    type AttrTransferTypeConstraint EventScrollIsStopFieldInfo = (~)Word32
    type AttrTransferType EventScrollIsStopFieldInfo = Word32
    type AttrGetType EventScrollIsStopFieldInfo = Word32
    type AttrLabel EventScrollIsStopFieldInfo = "is_stop"
    type AttrOrigin EventScrollIsStopFieldInfo = EventScroll
    attrGet = getEventScrollIsStop
    attrSet = setEventScrollIsStop
    attrConstruct = undefined
    attrClear = undefined
    attrTransfer _ v = do
        return v

eventScroll_isStop :: AttrLabelProxy "isStop"
eventScroll_isStop = AttrLabelProxy

#endif



#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList EventScroll
type instance O.AttributeList EventScroll = EventScrollAttributeList
type EventScrollAttributeList = ('[ '("type", EventScrollTypeFieldInfo), '("window", EventScrollWindowFieldInfo), '("sendEvent", EventScrollSendEventFieldInfo), '("time", EventScrollTimeFieldInfo), '("x", EventScrollXFieldInfo), '("y", EventScrollYFieldInfo), '("state", EventScrollStateFieldInfo), '("direction", EventScrollDirectionFieldInfo), '("device", EventScrollDeviceFieldInfo), '("xRoot", EventScrollXRootFieldInfo), '("yRoot", EventScrollYRootFieldInfo), '("deltaX", EventScrollDeltaXFieldInfo), '("deltaY", EventScrollDeltaYFieldInfo), '("isStop", EventScrollIsStopFieldInfo)] :: [(Symbol, *)])
#endif

#if defined(ENABLE_OVERLOADING)
type family ResolveEventScrollMethod (t :: Symbol) (o :: *) :: * where
    ResolveEventScrollMethod l o = O.MethodResolutionFailed l o

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

#endif