Safe Haskell | None |
---|---|
Language | Haskell98 |
- type Label = Char
- type Weight = Int
- type Node = (Label, Pos, ColorG)
- type Edge = (Label, Label, ColorG, Weight)
- data Graph = Graph {}
- data ColorG
- data Thickness
- data Directed
- data Weighted
- data GraphOutput
- data GraphInput
- type Pos = (Float, Float)
- data MouseButton :: *
- type KeyboardButton = [Char]
- onNode :: [Node] -> Pos -> Maybe Node
- preEventloop :: (a -> GraphInput -> ([GraphOutput], a)) -> a -> IO ()
Documentation
data GraphOutput Source
data GraphInput Source
Type to express a position on the screen. It uses the format (x,y). As Canvas is used in the example implementation, remember that the lefttop corner is (0,0) and the leftbottom corner is (0, height of screen).
data MouseButton :: *
The MouseButton
on the mouse.
Show MouseButton | |
FromJSON MouseButton | How to parse a |
type KeyboardButton = [Char]
Type to express how a KeyboardButton
is modelled.
preEventloop :: (a -> GraphInput -> ([GraphOutput], a)) -> a -> IO () Source