keid-core-0.1.6.0: Core parts of Keid engine.
Safe HaskellNone
LanguageHaskell2010

Engine.Window.Key

Documentation

type Callback st = Int -> (ModifierKeys, KeyState, Key) -> StageRIO st () Source #

callback :: Callback st -> StageRIO st ReleaseKey Source #

data Key #

Instances

Instances details
Bounded Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

minBound :: Key #

maxBound :: Key #

Enum Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

succ :: Key -> Key #

pred :: Key -> Key #

toEnum :: Int -> Key #

fromEnum :: Key -> Int #

enumFrom :: Key -> [Key] #

enumFromThen :: Key -> Key -> [Key] #

enumFromTo :: Key -> Key -> [Key] #

enumFromThenTo :: Key -> Key -> Key -> [Key] #

Eq Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

(==) :: Key -> Key -> Bool #

(/=) :: Key -> Key -> Bool #

Data Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Key -> c Key #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Key #

toConstr :: Key -> Constr #

dataTypeOf :: Key -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Key) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Key) #

gmapT :: (forall b. Data b => b -> b) -> Key -> Key #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Key -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Key -> r #

gmapQ :: (forall d. Data d => d -> u) -> Key -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Key -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Key -> m Key #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Key -> m Key #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Key -> m Key #

Ord Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

compare :: Key -> Key -> Ordering #

(<) :: Key -> Key -> Bool #

(<=) :: Key -> Key -> Bool #

(>) :: Key -> Key -> Bool #

(>=) :: Key -> Key -> Bool #

max :: Key -> Key -> Key #

min :: Key -> Key -> Key #

Read Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Show Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

showsPrec :: Int -> Key -> ShowS #

show :: Key -> String #

showList :: [Key] -> ShowS #

Generic Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Associated Types

type Rep Key :: Type -> Type #

Methods

from :: Key -> Rep Key x #

to :: Rep Key x -> Key #

NFData Key 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

rnf :: Key -> () #

type Rep Key 
Instance details

Defined in Graphics.UI.GLFW.Types

type Rep Key = D1 ('MetaData "Key" "Graphics.UI.GLFW.Types" "GLFW-b-3.3.0.0-d8a73439230c7e9903a1b69fb9494df5a664d234b82fb3508164a609440c877e" 'False) ((((((C1 ('MetaCons "Key'Unknown" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "Key'Space" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Apostrophe" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'Comma" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Minus" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Period" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Slash" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'0" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'1" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'2" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'3" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'4" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'5" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'6" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'7" 'PrefixI 'False) (U1 :: Type -> Type))))) :+: (((C1 ('MetaCons "Key'8" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "Key'9" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Semicolon" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'Equal" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'A" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'B" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'C" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'D" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'E" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'F" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'G" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'H" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'I" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'J" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'K" 'PrefixI 'False) (U1 :: Type -> Type)))))) :+: ((((C1 ('MetaCons "Key'L" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "Key'M" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'N" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'O" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'P" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Q" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'R" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'S" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'T" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'U" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'V" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'W" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'X" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Y" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Z" 'PrefixI 'False) (U1 :: Type -> Type))))) :+: (((C1 ('MetaCons "Key'LeftBracket" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "Key'Backslash" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'RightBracket" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'GraveAccent" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'World1" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'World2" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Escape" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'Enter" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Tab" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Backspace" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Insert" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'Delete" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Right" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Left" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Down" 'PrefixI 'False) (U1 :: Type -> Type))))))) :+: (((((C1 ('MetaCons "Key'Up" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "Key'PageUp" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'PageDown" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'Home" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'End" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'CapsLock" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'ScrollLock" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'NumLock" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'PrintScreen" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Pause" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F1" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'F2" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F3" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'F4" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F5" 'PrefixI 'False) (U1 :: Type -> Type))))) :+: (((C1 ('MetaCons "Key'F6" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "Key'F7" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F8" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'F9" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F10" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'F11" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F12" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'F13" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F14" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'F15" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F16" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'F17" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F18" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'F19" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F20" 'PrefixI 'False) (U1 :: Type -> Type)))))) :+: ((((C1 ('MetaCons "Key'F21" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "Key'F22" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F23" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'F24" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'F25" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Pad0" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Pad1" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'Pad2" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Pad3" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Pad4" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Pad5" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'Pad6" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Pad7" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'Pad8" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Pad9" 'PrefixI 'False) (U1 :: Type -> Type))))) :+: ((((C1 ('MetaCons "Key'PadDecimal" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'PadDivide" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'PadMultiply" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'PadSubtract" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'PadAdd" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'PadEnter" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'PadEqual" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'LeftShift" 'PrefixI 'False) (U1 :: Type -> Type)))) :+: (((C1 ('MetaCons "Key'LeftControl" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'LeftAlt" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'LeftSuper" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'RightShift" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "Key'RightControl" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'RightAlt" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Key'RightSuper" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Key'Menu" 'PrefixI 'False) (U1 :: Type -> Type))))))))

data KeyState #

Instances

Instances details
Bounded KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Enum KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Eq KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Data KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> KeyState -> c KeyState #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c KeyState #

toConstr :: KeyState -> Constr #

dataTypeOf :: KeyState -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c KeyState) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c KeyState) #

gmapT :: (forall b. Data b => b -> b) -> KeyState -> KeyState #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> KeyState -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> KeyState -> r #

gmapQ :: (forall d. Data d => d -> u) -> KeyState -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> KeyState -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> KeyState -> m KeyState #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> KeyState -> m KeyState #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> KeyState -> m KeyState #

Ord KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Read KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Show KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Generic KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Associated Types

type Rep KeyState :: Type -> Type #

Methods

from :: KeyState -> Rep KeyState x #

to :: Rep KeyState x -> KeyState #

NFData KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

rnf :: KeyState -> () #

type Rep KeyState 
Instance details

Defined in Graphics.UI.GLFW.Types

type Rep KeyState = D1 ('MetaData "KeyState" "Graphics.UI.GLFW.Types" "GLFW-b-3.3.0.0-d8a73439230c7e9903a1b69fb9494df5a664d234b82fb3508164a609440c877e" 'False) (C1 ('MetaCons "KeyState'Pressed" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "KeyState'Released" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "KeyState'Repeating" 'PrefixI 'False) (U1 :: Type -> Type)))

data ModifierKeys #

Instances

Instances details
Eq ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

Data ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ModifierKeys -> c ModifierKeys #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ModifierKeys #

toConstr :: ModifierKeys -> Constr #

dataTypeOf :: ModifierKeys -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ModifierKeys) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ModifierKeys) #

gmapT :: (forall b. Data b => b -> b) -> ModifierKeys -> ModifierKeys #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ModifierKeys -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ModifierKeys -> r #

gmapQ :: (forall d. Data d => d -> u) -> ModifierKeys -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ModifierKeys -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ModifierKeys -> m ModifierKeys #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ModifierKeys -> m ModifierKeys #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ModifierKeys -> m ModifierKeys #

Ord ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

Read ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

Show ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

Generic ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

Associated Types

type Rep ModifierKeys :: Type -> Type #

NFData ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

Methods

rnf :: ModifierKeys -> () #

type Rep ModifierKeys 
Instance details

Defined in Graphics.UI.GLFW.Types

type Rep ModifierKeys = D1 ('MetaData "ModifierKeys" "Graphics.UI.GLFW.Types" "GLFW-b-3.3.0.0-d8a73439230c7e9903a1b69fb9494df5a664d234b82fb3508164a609440c877e" 'False) (C1 ('MetaCons "ModifierKeys" 'PrefixI 'True) ((S1 ('MetaSel ('Just "modifierKeysShift") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool) :*: (S1 ('MetaSel ('Just "modifierKeysControl") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool) :*: S1 ('MetaSel ('Just "modifierKeysAlt") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool))) :*: (S1 ('MetaSel ('Just "modifierKeysSuper") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool) :*: (S1 ('MetaSel ('Just "modifierKeysCapsLock") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool) :*: S1 ('MetaSel ('Just "modifierKeysNumLock") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Bool)))))

mkCallback :: UnliftIO (StageRIO st) -> Callback st -> KeyCallback Source #