{-# LINE 2 "./Graphics/UI/Gtk/Gdk/Cursor.chs" #-}
module Graphics.UI.Gtk.Gdk.Cursor (
Cursor(..),
CursorType(..),
cursorNew,
cursorNewFromPixmap,
cursorNewFromPixbuf,
cursorNewFromName,
cursorNewForDisplay,
cursorGetDisplay,
cursorGetImage
) where
import Control.Monad (liftM)
import System.Glib.FFI
import System.Glib.UTFString
import Graphics.UI.Gtk.General.Structs (Color)
import Graphics.UI.Gtk.Types hiding (Arrow)
{-# LINE 62 "./Graphics/UI/Gtk/Gdk/Cursor.chs" #-}
newtype Cursor = Cursor (ForeignPtr (Cursor))
{-# LINE 66 "./Graphics/UI/Gtk/Gdk/Cursor.chs" #-}
data CursorType = XCursor
| Arrow
| BasedArrowDown
| BasedArrowUp
| Boat
| Bogosity
| BottomLeftCorner
| BottomRightCorner
| BottomSide
| BottomTee
| BoxSpiral
| CenterPtr
| Circle
| Clock
| CoffeeMug
| Cross
| CrossReverse
| Crosshair
| DiamondCross
| Dot
| Dotbox
| DoubleArrow
| DraftLarge
| DraftSmall
| DrapedBox
| Exchange
| Fleur
| Gobbler
| Gumby
| Hand1
| Hand2
| Heart
| Icon
| IronCross
| LeftPtr
| LeftSide
| LeftTee
| Leftbutton
| LlAngle
| LrAngle
| Man
| Middlebutton
| Mouse
| Pencil
| Pirate
| Plus
| QuestionArrow
| RightPtr
| RightSide
| RightTee
| Rightbutton
| RtlLogo
| Sailboat
| SbDownArrow
| SbHDoubleArrow
| SbLeftArrow
| SbRightArrow
| SbUpArrow
| SbVDoubleArrow
| Shuttle
| Sizing
| Spider
| Spraycan
| Star
| Target
| Tcross
| TopLeftArrow
| TopLeftCorner
| TopRightCorner
| TopSide
| TopTee
| Trek
| UlAngle
| Umbrella
| UrAngle
| Watch
| Xterm
| LastCursor
| BlankCursor
| CursorIsPixmap
deriving (CursorType
CursorType -> CursorType -> Bounded CursorType
forall a. a -> a -> Bounded a
$cminBound :: CursorType
minBound :: CursorType
$cmaxBound :: CursorType
maxBound :: CursorType
Bounded,CursorType -> CursorType -> Bool
(CursorType -> CursorType -> Bool)
-> (CursorType -> CursorType -> Bool) -> Eq CursorType
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: CursorType -> CursorType -> Bool
== :: CursorType -> CursorType -> Bool
$c/= :: CursorType -> CursorType -> Bool
/= :: CursorType -> CursorType -> Bool
Eq,Int -> CursorType -> ShowS
[CursorType] -> ShowS
CursorType -> String
(Int -> CursorType -> ShowS)
-> (CursorType -> String)
-> ([CursorType] -> ShowS)
-> Show CursorType
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> CursorType -> ShowS
showsPrec :: Int -> CursorType -> ShowS
$cshow :: CursorType -> String
show :: CursorType -> String
$cshowList :: [CursorType] -> ShowS
showList :: [CursorType] -> ShowS
Show)
instance Enum CursorType where
fromEnum XCursor = 0
fromEnum Arrow = 2
fromEnum BasedArrowDown = 4
fromEnum BasedArrowUp = 6
fromEnum Boat = 8
fromEnum Bogosity = 10
fromEnum BottomLeftCorner = 12
fromEnum BottomRightCorner = 14
fromEnum BottomSide = 16
fromEnum BottomTee = 18
fromEnum BoxSpiral = 20
fromEnum CenterPtr = 22
fromEnum Circle = 24
fromEnum Clock = 26
fromEnum CoffeeMug = 28
fromEnum Cross = 30
fromEnum CrossReverse = 32
fromEnum Crosshair = 34
fromEnum DiamondCross = 36
fromEnum Dot = 38
fromEnum Dotbox = 40
fromEnum DoubleArrow = 42
fromEnum DraftLarge = 44
fromEnum DraftSmall = 46
fromEnum DrapedBox = 48
fromEnum Exchange = 50
fromEnum Fleur = 52
fromEnum Gobbler = 54
fromEnum Gumby = 56
fromEnum Hand1 = 58
fromEnum Hand2 = 60
fromEnum Heart = 62
fromEnum Icon = 64
fromEnum IronCross = 66
fromEnum LeftPtr = 68
fromEnum LeftSide = 70
fromEnum LeftTee = 72
fromEnum Leftbutton = 74
fromEnum LlAngle = 76
fromEnum LrAngle = 78
fromEnum Man = 80
fromEnum Middlebutton = 82
fromEnum Mouse = 84
fromEnum Pencil = 86
fromEnum Pirate = 88
fromEnum Plus = 90
fromEnum QuestionArrow = 92
fromEnum RightPtr = 94
fromEnum RightSide = 96
fromEnum RightTee = 98
fromEnum Rightbutton = 100
fromEnum RtlLogo = 102
fromEnum Sailboat = 104
fromEnum SbDownArrow = 106
fromEnum SbHDoubleArrow = 108
fromEnum SbLeftArrow = 110
fromEnum SbRightArrow = 112
fromEnum SbUpArrow = 114
fromEnum SbVDoubleArrow = 116
fromEnum Shuttle = 118
fromEnum Sizing = 120
fromEnum Spider = 122
fromEnum Spraycan = 124
fromEnum Star = 126
fromEnum Target = 128
fromEnum Tcross = 130
fromEnum TopLeftArrow = 132
fromEnum TopLeftCorner = 134
fromEnum TopRightCorner = 136
fromEnum TopSide = 138
fromEnum TopTee = 140
fromEnum Trek = 142
fromEnum UlAngle = 144
fromEnum Umbrella = 146
fromEnum UrAngle = 148
fromEnum Watch = 150
fromEnum Xterm = 152
fromEnum LastCursor = 153
fromEnum BlankCursor = (-2)
fromEnum CursorIsPixmap = (-1)
toEnum :: Int -> CursorType
toEnum Int
0 = CursorType
XCursor
toEnum Int
2 = CursorType
Arrow
toEnum Int
4 = CursorType
BasedArrowDown
toEnum Int
6 = CursorType
BasedArrowUp
toEnum Int
8 = CursorType
Boat
toEnum Int
10 = CursorType
Bogosity
toEnum Int
12 = CursorType
BottomLeftCorner
toEnum Int
14 = CursorType
BottomRightCorner
toEnum Int
16 = CursorType
BottomSide
toEnum Int
18 = CursorType
BottomTee
toEnum Int
20 = CursorType
BoxSpiral
toEnum Int
22 = CursorType
CenterPtr
toEnum Int
24 = CursorType
Circle
toEnum Int
26 = CursorType
Clock
toEnum Int
28 = CursorType
CoffeeMug
toEnum Int
30 = CursorType
Cross
toEnum Int
32 = CursorType
CrossReverse
toEnum Int
34 = CursorType
Crosshair
toEnum Int
36 = CursorType
DiamondCross
toEnum Int
38 = CursorType
Dot
toEnum Int
40 = CursorType
Dotbox
toEnum Int
42 = CursorType
DoubleArrow
toEnum Int
44 = CursorType
DraftLarge
toEnum Int
46 = CursorType
DraftSmall
toEnum Int
48 = CursorType
DrapedBox
toEnum Int
50 = CursorType
Exchange
toEnum Int
52 = CursorType
Fleur
toEnum Int
54 = CursorType
Gobbler
toEnum Int
56 = CursorType
Gumby
toEnum Int
58 = CursorType
Hand1
toEnum Int
60 = CursorType
Hand2
toEnum Int
62 = CursorType
Heart
toEnum Int
64 = CursorType
Icon
toEnum Int
66 = CursorType
IronCross
toEnum Int
68 = CursorType
LeftPtr
toEnum Int
70 = CursorType
LeftSide
toEnum Int
72 = CursorType
LeftTee
toEnum Int
74 = CursorType
Leftbutton
toEnum Int
76 = CursorType
LlAngle
toEnum Int
78 = CursorType
LrAngle
toEnum Int
80 = CursorType
Man
toEnum Int
82 = CursorType
Middlebutton
toEnum Int
84 = CursorType
Mouse
toEnum Int
86 = CursorType
Pencil
toEnum Int
88 = CursorType
Pirate
toEnum Int
90 = CursorType
Plus
toEnum Int
92 = CursorType
QuestionArrow
toEnum Int
94 = CursorType
RightPtr
toEnum Int
96 = CursorType
RightSide
toEnum Int
98 = CursorType
RightTee
toEnum Int
100 = CursorType
Rightbutton
toEnum Int
102 = CursorType
RtlLogo
toEnum Int
104 = CursorType
Sailboat
toEnum Int
106 = CursorType
SbDownArrow
toEnum Int
108 = CursorType
SbHDoubleArrow
toEnum Int
110 = CursorType
SbLeftArrow
toEnum Int
112 = CursorType
SbRightArrow
toEnum Int
114 = CursorType
SbUpArrow
toEnum Int
116 = CursorType
SbVDoubleArrow
toEnum Int
118 = CursorType
Shuttle
toEnum Int
120 = CursorType
Sizing
toEnum Int
122 = CursorType
Spider
toEnum Int
124 = CursorType
Spraycan
toEnum Int
126 = CursorType
Star
toEnum Int
128 = CursorType
Target
toEnum Int
130 = CursorType
Tcross
toEnum Int
132 = CursorType
TopLeftArrow
toEnum Int
134 = CursorType
TopLeftCorner
toEnum Int
136 = CursorType
TopRightCorner
toEnum Int
138 = CursorType
TopSide
toEnum Int
140 = CursorType
TopTee
toEnum Int
142 = CursorType
Trek
toEnum Int
144 = CursorType
UlAngle
toEnum Int
146 = CursorType
Umbrella
toEnum Int
148 = CursorType
UrAngle
toEnum Int
150 = CursorType
Watch
toEnum Int
152 = CursorType
Xterm
toEnum Int
153 = CursorType
LastCursor
toEnum (-2) = CursorType
BlankCursor
toEnum (-1) = CursorType
CursorIsPixmap
toEnum Int
unmatched = String -> CursorType
forall a. HasCallStack => String -> a
error (String
"CursorType.toEnum: Cannot match " String -> ShowS
forall a. [a] -> [a] -> [a]
++ Int -> String
forall a. Show a => a -> String
show Int
unmatched)
succ :: CursorType -> CursorType
succ CursorType
XCursor = CursorType
Arrow
succ CursorType
Arrow = CursorType
BasedArrowDown
succ CursorType
BasedArrowDown = CursorType
BasedArrowUp
succ CursorType
BasedArrowUp = CursorType
Boat
succ CursorType
Boat = CursorType
Bogosity
succ CursorType
Bogosity = CursorType
BottomLeftCorner
succ CursorType
BottomLeftCorner = CursorType
BottomRightCorner
succ CursorType
BottomRightCorner = CursorType
BottomSide
succ CursorType
BottomSide = CursorType
BottomTee
succ CursorType
BottomTee = CursorType
BoxSpiral
succ CursorType
BoxSpiral = CursorType
CenterPtr
succ CursorType
CenterPtr = CursorType
Circle
succ CursorType
Circle = CursorType
Clock
succ CursorType
Clock = CursorType
CoffeeMug
succ CursorType
CoffeeMug = CursorType
Cross
succ CursorType
Cross = CursorType
CrossReverse
succ CursorType
CrossReverse = CursorType
Crosshair
succ CursorType
Crosshair = CursorType
DiamondCross
succ CursorType
DiamondCross = CursorType
Dot
succ CursorType
Dot = CursorType
Dotbox
succ CursorType
Dotbox = CursorType
DoubleArrow
succ CursorType
DoubleArrow = CursorType
DraftLarge
succ CursorType
DraftLarge = CursorType
DraftSmall
succ CursorType
DraftSmall = CursorType
DrapedBox
succ CursorType
DrapedBox = CursorType
Exchange
succ CursorType
Exchange = CursorType
Fleur
succ CursorType
Fleur = CursorType
Gobbler
succ CursorType
Gobbler = CursorType
Gumby
succ CursorType
Gumby = CursorType
Hand1
succ CursorType
Hand1 = CursorType
Hand2
succ CursorType
Hand2 = CursorType
Heart
succ CursorType
Heart = CursorType
Icon
succ CursorType
Icon = CursorType
IronCross
succ CursorType
IronCross = CursorType
LeftPtr
succ CursorType
LeftPtr = CursorType
LeftSide
succ CursorType
LeftSide = CursorType
LeftTee
succ CursorType
LeftTee = CursorType
Leftbutton
succ CursorType
Leftbutton = CursorType
LlAngle
succ CursorType
LlAngle = CursorType
LrAngle
succ CursorType
LrAngle = CursorType
Man
succ CursorType
Man = CursorType
Middlebutton
succ CursorType
Middlebutton = CursorType
Mouse
succ CursorType
Mouse = CursorType
Pencil
succ CursorType
Pencil = CursorType
Pirate
succ CursorType
Pirate = CursorType
Plus
succ CursorType
Plus = CursorType
QuestionArrow
succ CursorType
QuestionArrow = CursorType
RightPtr
succ CursorType
RightPtr = CursorType
RightSide
succ CursorType
RightSide = CursorType
RightTee
succ CursorType
RightTee = CursorType
Rightbutton
succ CursorType
Rightbutton = CursorType
RtlLogo
succ CursorType
RtlLogo = CursorType
Sailboat
succ CursorType
Sailboat = CursorType
SbDownArrow
succ CursorType
SbDownArrow = CursorType
SbHDoubleArrow
succ CursorType
SbHDoubleArrow = CursorType
SbLeftArrow
succ CursorType
SbLeftArrow = CursorType
SbRightArrow
succ CursorType
SbRightArrow = CursorType
SbUpArrow
succ CursorType
SbUpArrow = CursorType
SbVDoubleArrow
succ CursorType
SbVDoubleArrow = CursorType
Shuttle
succ CursorType
Shuttle = CursorType
Sizing
succ CursorType
Sizing = CursorType
Spider
succ CursorType
Spider = CursorType
Spraycan
succ CursorType
Spraycan = CursorType
Star
succ CursorType
Star = CursorType
Target
succ CursorType
Target = CursorType
Tcross
succ CursorType
Tcross = CursorType
TopLeftArrow
succ CursorType
TopLeftArrow = CursorType
TopLeftCorner
succ CursorType
TopLeftCorner = CursorType
TopRightCorner
succ CursorType
TopRightCorner = CursorType
TopSide
succ CursorType
TopSide = CursorType
TopTee
succ CursorType
TopTee = CursorType
Trek
succ CursorType
Trek = CursorType
UlAngle
succ CursorType
UlAngle = CursorType
Umbrella
succ CursorType
Umbrella = CursorType
UrAngle
succ CursorType
UrAngle = CursorType
Watch
succ CursorType
Watch = CursorType
Xterm
succ CursorType
Xterm = CursorType
LastCursor
succ CursorType
LastCursor = CursorType
BlankCursor
succ CursorType
BlankCursor = CursorType
CursorIsPixmap
succ CursorType
_ = CursorType
forall a. HasCallStack => a
undefined
pred :: CursorType -> CursorType
pred CursorType
Arrow = CursorType
XCursor
pred CursorType
BasedArrowDown = CursorType
Arrow
pred CursorType
BasedArrowUp = CursorType
BasedArrowDown
pred CursorType
Boat = CursorType
BasedArrowUp
pred CursorType
Bogosity = CursorType
Boat
pred CursorType
BottomLeftCorner = CursorType
Bogosity
pred CursorType
BottomRightCorner = CursorType
BottomLeftCorner
pred CursorType
BottomSide = CursorType
BottomRightCorner
pred CursorType
BottomTee = CursorType
BottomSide
pred CursorType
BoxSpiral = CursorType
BottomTee
pred CursorType
CenterPtr = CursorType
BoxSpiral
pred CursorType
Circle = CursorType
CenterPtr
pred CursorType
Clock = CursorType
Circle
pred CursorType
CoffeeMug = CursorType
Clock
pred CursorType
Cross = CursorType
CoffeeMug
pred CursorType
CrossReverse = CursorType
Cross
pred CursorType
Crosshair = CursorType
CrossReverse
pred CursorType
DiamondCross = CursorType
Crosshair
pred CursorType
Dot = CursorType
DiamondCross
pred CursorType
Dotbox = CursorType
Dot
pred CursorType
DoubleArrow = CursorType
Dotbox
pred CursorType
DraftLarge = CursorType
DoubleArrow
pred CursorType
DraftSmall = CursorType
DraftLarge
pred CursorType
DrapedBox = CursorType
DraftSmall
pred CursorType
Exchange = CursorType
DrapedBox
pred CursorType
Fleur = CursorType
Exchange
pred CursorType
Gobbler = CursorType
Fleur
pred CursorType
Gumby = CursorType
Gobbler
pred CursorType
Hand1 = CursorType
Gumby
pred CursorType
Hand2 = CursorType
Hand1
pred CursorType
Heart = CursorType
Hand2
pred CursorType
Icon = CursorType
Heart
pred CursorType
IronCross = CursorType
Icon
pred CursorType
LeftPtr = CursorType
IronCross
pred CursorType
LeftSide = CursorType
LeftPtr
pred CursorType
LeftTee = CursorType
LeftSide
pred CursorType
Leftbutton = CursorType
LeftTee
pred CursorType
LlAngle = CursorType
Leftbutton
pred CursorType
LrAngle = CursorType
LlAngle
pred CursorType
Man = CursorType
LrAngle
pred CursorType
Middlebutton = CursorType
Man
pred CursorType
Mouse = CursorType
Middlebutton
pred CursorType
Pencil = CursorType
Mouse
pred CursorType
Pirate = CursorType
Pencil
pred CursorType
Plus = CursorType
Pirate
pred CursorType
QuestionArrow = CursorType
Plus
pred CursorType
RightPtr = CursorType
QuestionArrow
pred CursorType
RightSide = CursorType
RightPtr
pred CursorType
RightTee = CursorType
RightSide
pred CursorType
Rightbutton = CursorType
RightTee
pred CursorType
RtlLogo = CursorType
Rightbutton
pred CursorType
Sailboat = CursorType
RtlLogo
pred CursorType
SbDownArrow = CursorType
Sailboat
pred CursorType
SbHDoubleArrow = CursorType
SbDownArrow
pred CursorType
SbLeftArrow = CursorType
SbHDoubleArrow
pred CursorType
SbRightArrow = CursorType
SbLeftArrow
pred CursorType
SbUpArrow = CursorType
SbRightArrow
pred CursorType
SbVDoubleArrow = CursorType
SbUpArrow
pred CursorType
Shuttle = CursorType
SbVDoubleArrow
pred CursorType
Sizing = CursorType
Shuttle
pred CursorType
Spider = CursorType
Sizing
pred CursorType
Spraycan = CursorType
Spider
pred CursorType
Star = CursorType
Spraycan
pred CursorType
Target = CursorType
Star
pred CursorType
Tcross = CursorType
Target
pred CursorType
TopLeftArrow = CursorType
Tcross
pred CursorType
TopLeftCorner = CursorType
TopLeftArrow
pred CursorType
TopRightCorner = CursorType
TopLeftCorner
pred CursorType
TopSide = CursorType
TopRightCorner
pred CursorType
TopTee = CursorType
TopSide
pred CursorType
Trek = CursorType
TopTee
pred CursorType
UlAngle = CursorType
Trek
pred CursorType
Umbrella = CursorType
UlAngle
pred CursorType
UrAngle = CursorType
Umbrella
pred CursorType
Watch = CursorType
UrAngle
pred CursorType
Xterm = CursorType
Watch
pred CursorType
LastCursor = CursorType
Xterm
pred CursorType
BlankCursor = CursorType
LastCursor
pred CursorType
CursorIsPixmap = CursorType
BlankCursor
pred CursorType
_ = CursorType
forall a. HasCallStack => a
undefined
enumFromTo :: CursorType -> CursorType -> [CursorType]
enumFromTo CursorType
x CursorType
y | CursorType -> Int
forall a. Enum a => a -> Int
fromEnum CursorType
x Int -> Int -> Bool
forall a. Eq a => a -> a -> Bool
== CursorType -> Int
forall a. Enum a => a -> Int
fromEnum CursorType
y = [ CursorType
y ]
| Bool
otherwise = CursorType
x CursorType -> [CursorType] -> [CursorType]
forall a. a -> [a] -> [a]
: CursorType -> CursorType -> [CursorType]
forall a. Enum a => a -> a -> [a]
enumFromTo (CursorType -> CursorType
forall a. Enum a => a -> a
succ CursorType
x) CursorType
y
enumFrom :: CursorType -> [CursorType]
enumFrom CursorType
x = CursorType -> CursorType -> [CursorType]
forall a. Enum a => a -> a -> [a]
enumFromTo CursorType
x CursorType
CursorIsPixmap
enumFromThen :: CursorType -> CursorType -> [CursorType]
enumFromThen CursorType
_ CursorType
_ = String -> [CursorType]
forall a. HasCallStack => String -> a
error String
"Enum CursorType: enumFromThen not implemented"
enumFromThenTo :: CursorType -> CursorType -> CursorType -> [CursorType]
enumFromThenTo CursorType
_ CursorType
_ CursorType
_ = String -> [CursorType]
forall a. HasCallStack => String -> a
error String
"Enum CursorType: enumFromThenTo not implemented"
{-# LINE 71 "./Graphics/UI/Gtk/Gdk/Cursor.chs" #-}
makeNewCursor :: Ptr Cursor -> IO Cursor
makeNewCursor rPtr = do
cursor <- newForeignPtr rPtr cursor_unref
return (Cursor cursor)
foreign import ccall unsafe "&gdk_cursor_unref"
cursor_unref :: FinalizerPtr Cursor
cursorNew ::
CursorType
-> IO Cursor
cursorNew cursorType = do
cursorPtr <- gdk_cursor_new $fromIntegral (fromEnum cursorType)
makeNewCursor cursorPtr
cursorNewFromPixmap ::
Pixmap
-> Pixmap
-> Color
-> Color
-> Int
-> Int
-> IO Cursor
cursorNewFromPixmap source mask fg bg x y =
with fg $ \fgPtr ->
with bg $ \bgPtr -> do
rPtr <- (\(Pixmap arg1) (Pixmap arg2) arg3 arg4 arg5 arg6 -> withForeignPtr arg1 $ \argPtr1 ->withForeignPtr arg2 $ \argPtr2 ->gdk_cursor_new_from_pixmap argPtr1 argPtr2 arg3 arg4 arg5 arg6) source mask (castPtr fgPtr) (castPtr bgPtr) (fromIntegral x) (fromIntegral y)
makeNewCursor rPtr
cursorNewFromPixbuf ::
Display
-> Pixbuf
-> Int
-> Int
-> IO Cursor
cursorNewFromPixbuf display pixbuf x y = do
cursorPtr <- (\(Display arg1) (Pixbuf arg2) arg3 arg4 -> withForeignPtr arg1 $ \argPtr1 ->withForeignPtr arg2 $ \argPtr2 ->gdk_cursor_new_from_pixbuf argPtr1 argPtr2 arg3 arg4) display pixbuf (fromIntegral x) (fromIntegral y)
makeNewCursor cursorPtr
cursorNewFromName :: GlibString string
=> Display
-> string
-> IO (Maybe Cursor)
cursorNewFromName display name =
withUTFString name $ \namePtr -> do
cursorPtr <- (\(Display arg1) arg2 -> withForeignPtr arg1 $ \argPtr1 ->gdk_cursor_new_from_name argPtr1 arg2) display namePtr
if cursorPtr == nullPtr then return Nothing else liftM Just $ makeNewCursor cursorPtr
cursorNewForDisplay ::
Display
-> CursorType
-> IO Cursor
cursorNewForDisplay display cursorType = do
cursorPtr <- (\(Display arg1) arg2 -> withForeignPtr arg1 $ \argPtr1 ->gdk_cursor_new_for_display argPtr1 arg2) display $fromIntegral (fromEnum cursorType)
makeNewCursor cursorPtr
cursorGetDisplay ::
Cursor
-> IO Display
cursorGetDisplay cursor =
makeNewGObject mkDisplay $ (\(Cursor arg1) -> withForeignPtr arg1 $ \argPtr1 ->gdk_cursor_get_display argPtr1) cursor
cursorGetImage ::
Cursor
-> IO (Maybe Pixbuf)
cursorGetImage cursor =
maybeNull (makeNewGObject mkPixbuf) $ (\(Cursor arg1) -> withForeignPtr arg1 $ \argPtr1 ->gdk_cursor_get_image argPtr1) cursor
foreign import ccall safe "gdk_cursor_new"
gdk_cursor_new :: (CInt -> (IO (Ptr Cursor)))
foreign import ccall unsafe "gdk_cursor_new_from_pixmap"
gdk_cursor_new_from_pixmap :: ((Ptr Pixmap) -> ((Ptr Pixmap) -> ((Ptr ()) -> ((Ptr ()) -> (CInt -> (CInt -> (IO (Ptr Cursor))))))))
foreign import ccall safe "gdk_cursor_new_from_pixbuf"
gdk_cursor_new_from_pixbuf :: ((Ptr Display) -> ((Ptr Pixbuf) -> (CInt -> (CInt -> (IO (Ptr Cursor))))))
foreign import ccall safe "gdk_cursor_new_from_name"
gdk_cursor_new_from_name :: ((Ptr Display) -> ((Ptr CChar) -> (IO (Ptr Cursor))))
foreign import ccall safe "gdk_cursor_new_for_display"
gdk_cursor_new_for_display :: ((Ptr Display) -> (CInt -> (IO (Ptr Cursor))))
foreign import ccall safe "gdk_cursor_get_display"
gdk_cursor_get_display :: ((Ptr Cursor) -> (IO (Ptr Display)))
foreign import ccall safe "gdk_cursor_get_image"
gdk_cursor_get_image :: ((Ptr Cursor) -> (IO (Ptr Pixbuf)))