blob: 2a5396cee5025c1a7766c48511bd6dfddc217584 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
definition module Gtk.State
from StdMaybe import :: Maybe
from Control.Applicative import class pure, class <*>, class Applicative
from Control.Monad import class Monad
from Data.Functor import class Functor
from Data.Map import :: Map
from Gtk.Signal import :: GSignalHandlerInternal
:: GtkState =
{ world :: !()
, return :: !Bool
, signal_handlers :: !Map Int GSignalHandlerInternal
, signal_counter :: !Int
}
:: GtkM a =: GtkM (GtkState -> (a, GtkState))
instance Functor GtkM
instance pure GtkM
instance <*> GtkM
instance Monad GtkM
where
(>>|) infixl 1 :: (GtkM a) (GtkM b) -> GtkM b
newGtkState :: GtkState
runGtk :: !(GtkM a) !*World -> (!a, !*World)
getState :: GtkM GtkState
modState :: !(GtkState -> GtkState) -> GtkM GtkState
toState :: !(A.a: a -> a) -> GtkM ()
toStateR :: !(A.a: a -> (r,a)) -> GtkM r
appWorld :: !(*World -> *World) -> GtkM ()
accWorld :: !(*World -> (r,*World)) -> GtkM r
quit :: GtkM ()
|