{-# LINE 2 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
module Graphics.UI.Gtk.Windows.Dialog (
Dialog,
DialogClass,
castToDialog, gTypeDialog,
toDialog,
ResponseId(..),
dialogNew,
dialogGetContentArea,
dialogGetActionArea,
dialogRun,
dialogResponse,
dialogAddButton,
dialogAddActionWidget,
dialogSetDefaultResponse,
dialogSetResponseSensitive,
dialogGetResponseForWidget,
dialogAlternativeDialogButtonOrder,
dialogSetAlternativeButtonOrderFromArray,
dialogGetWidgetForResponse,
dialogActionAreaBorder,
dialogButtonSpacing,
dialogContentAreaBorder,
dialogContentAreaSpacing,
response,
) where
import Control.Monad (liftM)
import System.Glib.FFI
import System.Glib.UTFString
import System.Glib.Attributes
import System.Glib.Properties
import Graphics.UI.Gtk.Abstract.Object (makeNewObject)
import Graphics.UI.Gtk.Types
{-# LINE 159 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
import Graphics.UI.Gtk.Signals
{-# LINE 160 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
import Graphics.UI.Gtk.General.Structs (
ResponseId(..), fromResponse, toResponse)
{-# LINE 167 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
dialogNew :: IO Dialog
dialogNew :: IO Dialog
dialogNew =
(ForeignPtr Dialog -> Dialog, FinalizerPtr Dialog)
-> IO (Ptr Dialog) -> IO Dialog
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
makeNewObject (ForeignPtr Dialog -> Dialog, FinalizerPtr Dialog)
forall {a}. (ForeignPtr Dialog -> Dialog, FinalizerPtr a)
mkDialog (IO (Ptr Dialog) -> IO Dialog) -> IO (Ptr Dialog) -> IO Dialog
forall a b. (a -> b) -> a -> b
$
(Ptr Widget -> Ptr Dialog) -> IO (Ptr Widget) -> IO (Ptr Dialog)
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM (Ptr Widget -> Ptr Dialog
forall a b. Ptr a -> Ptr b
castPtr :: Ptr Widget -> Ptr Dialog) (IO (Ptr Widget) -> IO (Ptr Dialog))
-> IO (Ptr Widget) -> IO (Ptr Dialog)
forall a b. (a -> b) -> a -> b
$
IO (Ptr Widget)
gtk_dialog_new
{-# LINE 180 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
dialogRun :: DialogClass self => self
-> IO ResponseId
dialogRun :: forall self. DialogClass self => self -> IO ResponseId
dialogRun self
self =
(CInt -> ResponseId) -> IO CInt -> IO ResponseId
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> ResponseId
forall a. Integral a => a -> ResponseId
toResponse (IO CInt -> IO ResponseId) -> IO CInt -> IO ResponseId
forall a b. (a -> b) -> a -> b
$
(\(Dialog ForeignPtr Dialog
arg1) -> ForeignPtr Dialog -> (Ptr Dialog -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO CInt) -> IO CInt)
-> (Ptr Dialog -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> IO CInt
gtk_dialog_run Ptr Dialog
argPtr1)
{-# LINE 214 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
dialogResponse :: DialogClass self => self
-> ResponseId
-> IO ()
dialogResponse :: forall self. DialogClass self => self -> ResponseId -> IO ()
dialogResponse self
self ResponseId
responseId =
(\(Dialog ForeignPtr Dialog
arg1) CInt
arg2 -> ForeignPtr Dialog -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO ()) -> IO ()) -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> CInt -> IO ()
gtk_dialog_response Ptr Dialog
argPtr1 CInt
arg2)
{-# LINE 229 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
(ResponseId -> CInt
forall a. Integral a => ResponseId -> a
fromResponse ResponseId
responseId)
dialogAddButton :: (DialogClass self, GlibString string) => self
-> string
-> ResponseId
-> IO Button
dialogAddButton :: forall self string.
(DialogClass self, GlibString string) =>
self -> string -> ResponseId -> IO Button
dialogAddButton self
self string
buttonText ResponseId
responseId =
(ForeignPtr Button -> Button, FinalizerPtr Button)
-> IO (Ptr Button) -> IO Button
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
makeNewObject (ForeignPtr Button -> Button, FinalizerPtr Button)
forall {a}. (ForeignPtr Button -> Button, FinalizerPtr a)
mkButton (IO (Ptr Button) -> IO Button) -> IO (Ptr Button) -> IO Button
forall a b. (a -> b) -> a -> b
$ (Ptr Widget -> Ptr Button) -> IO (Ptr Widget) -> IO (Ptr Button)
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM Ptr Widget -> Ptr Button
forall a b. Ptr a -> Ptr b
castPtr (IO (Ptr Widget) -> IO (Ptr Button))
-> IO (Ptr Widget) -> IO (Ptr Button)
forall a b. (a -> b) -> a -> b
$
string -> (CString -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a. string -> (CString -> IO a) -> IO a
forall s a. GlibString s => s -> (CString -> IO a) -> IO a
withUTFString string
buttonText ((CString -> IO (Ptr Widget)) -> IO (Ptr Widget))
-> (CString -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. (a -> b) -> a -> b
$ \CString
buttonTextPtr ->
(\(Dialog ForeignPtr Dialog
arg1) CString
arg2 CInt
arg3 -> ForeignPtr Dialog
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget))
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> CString -> CInt -> IO (Ptr Widget)
gtk_dialog_add_button Ptr Dialog
argPtr1 CString
arg2 CInt
arg3)
{-# LINE 246 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
CString
buttonTextPtr
(ResponseId -> CInt
forall a. Integral a => ResponseId -> a
fromResponse ResponseId
responseId)
dialogAddActionWidget :: (DialogClass self, WidgetClass child) => self
-> child
-> ResponseId
-> IO ()
dialogAddActionWidget :: forall self child.
(DialogClass self, WidgetClass child) =>
self -> child -> ResponseId -> IO ()
dialogAddActionWidget self
self child
child ResponseId
responseId =
(\(Dialog ForeignPtr Dialog
arg1) (Widget ForeignPtr Widget
arg2) CInt
arg3 -> ForeignPtr Dialog -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO ()) -> IO ()) -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->ForeignPtr Widget -> (Ptr Widget -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Widget
arg2 ((Ptr Widget -> IO ()) -> IO ()) -> (Ptr Widget -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Widget
argPtr2 ->Ptr Dialog -> Ptr Widget -> CInt -> IO ()
gtk_dialog_add_action_widget Ptr Dialog
argPtr1 Ptr Widget
argPtr2 CInt
arg3)
{-# LINE 262 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
(child -> Widget
forall o. WidgetClass o => o -> Widget
toWidget child
child)
(ResponseId -> CInt
forall a. Integral a => ResponseId -> a
fromResponse ResponseId
responseId)
{-# LINE 287 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
dialogSetDefaultResponse :: DialogClass self => self
-> ResponseId
-> IO ()
dialogSetDefaultResponse :: forall self. DialogClass self => self -> ResponseId -> IO ()
dialogSetDefaultResponse self
self ResponseId
responseId =
(\(Dialog ForeignPtr Dialog
arg1) CInt
arg2 -> ForeignPtr Dialog -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO ()) -> IO ()) -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> CInt -> IO ()
gtk_dialog_set_default_response Ptr Dialog
argPtr1 CInt
arg2)
{-# LINE 300 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
(ResponseId -> CInt
forall a. Integral a => ResponseId -> a
fromResponse ResponseId
responseId)
dialogSetResponseSensitive :: DialogClass self => self
-> ResponseId
-> Bool
-> IO ()
dialogSetResponseSensitive :: forall self.
DialogClass self =>
self -> ResponseId -> Bool -> IO ()
dialogSetResponseSensitive self
self ResponseId
responseId Bool
setting =
(\(Dialog ForeignPtr Dialog
arg1) CInt
arg2 CInt
arg3 -> ForeignPtr Dialog -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO ()) -> IO ()) -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> CInt -> CInt -> IO ()
gtk_dialog_set_response_sensitive Ptr Dialog
argPtr1 CInt
arg2 CInt
arg3)
{-# LINE 313 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
(ResponseId -> CInt
forall a. Integral a => ResponseId -> a
fromResponse ResponseId
responseId)
(Bool -> CInt
forall a. Num a => Bool -> a
fromBool Bool
setting)
dialogGetResponseForWidget :: (DialogClass self, WidgetClass widget) => self
-> widget
-> IO ResponseId
dialogGetResponseForWidget :: forall self widget.
(DialogClass self, WidgetClass widget) =>
self -> widget -> IO ResponseId
dialogGetResponseForWidget self
self widget
widget = (CInt -> ResponseId) -> IO CInt -> IO ResponseId
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> ResponseId
forall a. Integral a => a -> ResponseId
toResponse (IO CInt -> IO ResponseId) -> IO CInt -> IO ResponseId
forall a b. (a -> b) -> a -> b
$
(\(Dialog ForeignPtr Dialog
arg1) (Widget ForeignPtr Widget
arg2) -> ForeignPtr Dialog -> (Ptr Dialog -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO CInt) -> IO CInt)
-> (Ptr Dialog -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->ForeignPtr Widget -> (Ptr Widget -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Widget
arg2 ((Ptr Widget -> IO CInt) -> IO CInt)
-> (Ptr Widget -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr Widget
argPtr2 ->Ptr Dialog -> Ptr Widget -> IO CInt
gtk_dialog_get_response_for_widget Ptr Dialog
argPtr1 Ptr Widget
argPtr2)
{-# LINE 323 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
(widget -> Widget
forall o. WidgetClass o => o -> Widget
toWidget widget
widget)
dialogAlternativeDialogButtonOrder ::
Maybe Screen
-> IO Bool
dialogAlternativeDialogButtonOrder :: Maybe Screen -> IO Bool
dialogAlternativeDialogButtonOrder (Just Screen
screen) = (CInt -> Bool) -> IO CInt -> IO Bool
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Bool
forall a. (Eq a, Num a) => a -> Bool
toBool (IO CInt -> IO Bool) -> IO CInt -> IO Bool
forall a b. (a -> b) -> a -> b
$
(\(Screen ForeignPtr Screen
arg1) -> ForeignPtr Screen -> (Ptr Screen -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Screen
arg1 ((Ptr Screen -> IO CInt) -> IO CInt)
-> (Ptr Screen -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr Screen
argPtr1 ->Ptr Screen -> IO CInt
gtk_alternative_dialog_button_order Ptr Screen
argPtr1) Screen
screen
dialogAlternativeDialogButtonOrder Maybe Screen
Nothing = (CInt -> Bool) -> IO CInt -> IO Bool
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Bool
forall a. (Eq a, Num a) => a -> Bool
toBool (IO CInt -> IO Bool) -> IO CInt -> IO Bool
forall a b. (a -> b) -> a -> b
$
(\(Screen ForeignPtr Screen
arg1) -> ForeignPtr Screen -> (Ptr Screen -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Screen
arg1 ((Ptr Screen -> IO CInt) -> IO CInt)
-> (Ptr Screen -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr Screen
argPtr1 ->Ptr Screen -> IO CInt
gtk_alternative_dialog_button_order Ptr Screen
argPtr1) (ForeignPtr Screen -> Screen
Screen ForeignPtr Screen
forall a. ForeignPtr a
nullForeignPtr)
dialogSetAlternativeButtonOrderFromArray :: DialogClass self => self
-> [ResponseId]
-> IO ()
dialogSetAlternativeButtonOrderFromArray :: forall self. DialogClass self => self -> [ResponseId] -> IO ()
dialogSetAlternativeButtonOrderFromArray self
self [ResponseId]
newOrder =
[CInt] -> (Ptr CInt -> IO ()) -> IO ()
forall a b. Storable a => [a] -> (Ptr a -> IO b) -> IO b
withArray ((ResponseId -> CInt) -> [ResponseId] -> [CInt]
forall a b. (a -> b) -> [a] -> [b]
map ResponseId -> CInt
forall a. Integral a => ResponseId -> a
fromResponse [ResponseId]
newOrder) ((Ptr CInt -> IO ()) -> IO ()) -> (Ptr CInt -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr CInt
newOrderPtr ->
(\(Dialog ForeignPtr Dialog
arg1) CInt
arg2 Ptr CInt
arg3 -> ForeignPtr Dialog -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO ()) -> IO ()) -> (Ptr Dialog -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> CInt -> Ptr CInt -> IO ()
gtk_dialog_set_alternative_button_order_from_array Ptr Dialog
argPtr1 CInt
arg2 Ptr CInt
arg3)
{-# LINE 359 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
(Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral ([ResponseId] -> Int
forall a. [a] -> Int
forall (t :: * -> *) a. Foldable t => t a -> Int
length [ResponseId]
newOrder))
Ptr CInt
newOrderPtr
dialogGetWidgetForResponse :: DialogClass self => self
-> ResponseId
-> IO (Maybe Widget)
dialogGetWidgetForResponse :: forall self.
DialogClass self =>
self -> ResponseId -> IO (Maybe Widget)
dialogGetWidgetForResponse self
self ResponseId
responseId =
(IO (Ptr Widget) -> IO Widget)
-> IO (Ptr Widget) -> IO (Maybe Widget)
forall a. (IO (Ptr a) -> IO a) -> IO (Ptr a) -> IO (Maybe a)
maybeNull ((ForeignPtr Widget -> Widget, FinalizerPtr Widget)
-> IO (Ptr Widget) -> IO Widget
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
makeNewObject (ForeignPtr Widget -> Widget, FinalizerPtr Widget)
forall {a}. (ForeignPtr Widget -> Widget, FinalizerPtr a)
mkWidget) (IO (Ptr Widget) -> IO (Maybe Widget))
-> IO (Ptr Widget) -> IO (Maybe Widget)
forall a b. (a -> b) -> a -> b
$
(\(Dialog ForeignPtr Dialog
arg1) CInt
arg2 -> ForeignPtr Dialog
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget))
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> CInt -> IO (Ptr Widget)
gtk_dialog_get_widget_for_response Ptr Dialog
argPtr1 CInt
arg2)
{-# LINE 371 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
(ResponseId -> CInt
forall a. Integral a => ResponseId -> a
fromResponse ResponseId
responseId)
dialogGetContentArea :: DialogClass self => self -> IO Widget
dialogGetContentArea :: forall self. DialogClass self => self -> IO Widget
dialogGetContentArea self
self =
(ForeignPtr Widget -> Widget, FinalizerPtr Widget)
-> IO (Ptr Widget) -> IO Widget
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
makeNewObject (ForeignPtr Widget -> Widget, FinalizerPtr Widget)
forall {a}. (ForeignPtr Widget -> Widget, FinalizerPtr a)
mkWidget (IO (Ptr Widget) -> IO Widget) -> IO (Ptr Widget) -> IO Widget
forall a b. (a -> b) -> a -> b
$
(\(Dialog ForeignPtr Dialog
arg1) -> ForeignPtr Dialog
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget))
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> IO (Ptr Widget)
gtk_dialog_get_content_area Ptr Dialog
argPtr1)
{-# LINE 381 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
dialogGetActionArea :: DialogClass self => self -> IO Widget
dialogGetActionArea :: forall self. DialogClass self => self -> IO Widget
dialogGetActionArea self
self =
(ForeignPtr Widget -> Widget, FinalizerPtr Widget)
-> IO (Ptr Widget) -> IO Widget
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
makeNewObject (ForeignPtr Widget -> Widget, FinalizerPtr Widget)
forall {a}. (ForeignPtr Widget -> Widget, FinalizerPtr a)
mkWidget (IO (Ptr Widget) -> IO Widget) -> IO (Ptr Widget) -> IO Widget
forall a b. (a -> b) -> a -> b
$
(\(Dialog ForeignPtr Dialog
arg1) -> ForeignPtr Dialog
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr Dialog
arg1 ((Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget))
-> (Ptr Dialog -> IO (Ptr Widget)) -> IO (Ptr Widget)
forall a b. (a -> b) -> a -> b
$ \Ptr Dialog
argPtr1 ->Ptr Dialog -> IO (Ptr Widget)
gtk_dialog_get_content_area Ptr Dialog
argPtr1)
{-# LINE 392 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
(toDialog self)
{-# LINE 411 "./Graphics/UI/Gtk/Windows/Dialog.chs" #-}
dialogActionAreaBorder :: DialogClass self => ReadAttr self Int
dialogActionAreaBorder :: forall self. DialogClass self => ReadAttr self Int
dialogActionAreaBorder = String -> ReadAttr self Int
forall gobj. GObjectClass gobj => String -> ReadAttr gobj Int
readAttrFromIntProperty String
"action-area-border"
dialogButtonSpacing :: DialogClass self => ReadAttr self Int
dialogButtonSpacing :: forall self. DialogClass self => ReadAttr self Int
dialogButtonSpacing = String -> ReadAttr self Int
forall gobj. GObjectClass gobj => String -> ReadAttr gobj Int
readAttrFromIntProperty String
"button-spacing"
dialogContentAreaBorder :: DialogClass self => ReadAttr self Int
dialogContentAreaBorder :: forall self. DialogClass self => ReadAttr self Int
dialogContentAreaBorder = String -> ReadAttr self Int
forall gobj. GObjectClass gobj => String -> ReadAttr gobj Int
readAttrFromIntProperty String
"content-area-border"
dialogContentAreaSpacing :: DialogClass self => ReadAttr self Int
dialogContentAreaSpacing :: forall self. DialogClass self => ReadAttr self Int
dialogContentAreaSpacing = String -> ReadAttr self Int
forall gobj. GObjectClass gobj => String -> ReadAttr gobj Int
readAttrFromIntProperty String
"content-area-spacing"
response :: DialogClass self => Signal self (ResponseId -> IO ())
response :: forall self. DialogClass self => Signal self (ResponseId -> IO ())
response = (Bool -> self -> (ResponseId -> IO ()) -> IO (ConnectId self))
-> Signal self (ResponseId -> IO ())
forall object handler.
(Bool -> object -> handler -> IO (ConnectId object))
-> Signal object handler
Signal (\Bool
after self
obj ResponseId -> IO ()
fun ->
String -> Bool -> self -> (Int -> IO ()) -> IO (ConnectId self)
forall obj.
GObjectClass obj =>
String -> Bool -> obj -> (Int -> IO ()) -> IO (ConnectId obj)
connect_INT__NONE String
"response" Bool
after self
obj (\Int
i -> ResponseId -> IO ()
fun (Int -> ResponseId
forall a. Integral a => a -> ResponseId
toResponse Int
i)))
foreign import ccall unsafe "gtk_dialog_new"
gtk_dialog_new :: (IO (Ptr Widget))
foreign import ccall safe "gtk_dialog_run"
gtk_dialog_run :: ((Ptr Dialog) -> (IO CInt))
foreign import ccall safe "gtk_dialog_response"
gtk_dialog_response :: ((Ptr Dialog) -> (CInt -> (IO ())))
foreign import ccall safe "gtk_dialog_add_button"
gtk_dialog_add_button :: ((Ptr Dialog) -> ((Ptr CChar) -> (CInt -> (IO (Ptr Widget)))))
foreign import ccall safe "gtk_dialog_add_action_widget"
gtk_dialog_add_action_widget :: ((Ptr Dialog) -> ((Ptr Widget) -> (CInt -> (IO ()))))
foreign import ccall safe "gtk_dialog_set_default_response"
gtk_dialog_set_default_response :: ((Ptr Dialog) -> (CInt -> (IO ())))
foreign import ccall safe "gtk_dialog_set_response_sensitive"
gtk_dialog_set_response_sensitive :: ((Ptr Dialog) -> (CInt -> (CInt -> (IO ()))))
foreign import ccall safe "gtk_dialog_get_response_for_widget"
gtk_dialog_get_response_for_widget :: ((Ptr Dialog) -> ((Ptr Widget) -> (IO CInt)))
foreign import ccall safe "gtk_alternative_dialog_button_order"
gtk_alternative_dialog_button_order :: ((Ptr Screen) -> (IO CInt))
foreign import ccall safe "gtk_dialog_set_alternative_button_order_from_array"
gtk_dialog_set_alternative_button_order_from_array :: ((Ptr Dialog) -> (CInt -> ((Ptr CInt) -> (IO ()))))
foreign import ccall safe "gtk_dialog_get_widget_for_response"
gtk_dialog_get_widget_for_response :: ((Ptr Dialog) -> (CInt -> (IO (Ptr Widget))))
foreign import ccall safe "gtk_dialog_get_content_area"
gtk_dialog_get_content_area :: ((Ptr Dialog) -> (IO (Ptr Widget)))