-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | Maps web browser keycodes to their corresponding keyboard keys
--
@package keycode
@version 0.1.1
-- | Keyboard events in web browsers are often represented as keycodes,
-- which (1) are difficult to remember, and (2) sometimes vary from
-- browser to browser. This module allows one to look up a key press's
-- KeyCode and get a plain English description of the Key
-- that was pressed, to reduce confusion.
--
-- Since: 0.1
module Web.KeyCode
-- | Represents a typical keyboard's keys. The lowercase and uppercase
-- variants of any particular key have the same KeyCode, so there
-- are not separate constructors for them. There is also an
-- UnknownKey constructor for keys without a particular
-- KeyCode.
--
-- Note that the Enum instance does not correspond to the
-- KeyCodes, but is simply provided for convenience.
--
-- Since: 0.1
data Key
Backspace :: Key
Tab :: Key
NumLock :: Key
Enter :: Key
Shift :: Key
Control :: Key
Alt :: Key
Pause :: Key
CapsLock :: Key
Escape :: Key
Space :: Key
PageUp :: Key
PageDown :: Key
End :: Key
Home :: Key
ArrowLeft :: Key
ArrowUp :: Key
ArrowRight :: Key
ArrowDown :: Key
PrintScreen :: Key
Insert :: Key
Delete :: Key
-- | Without Shift: 0. With Shift: ).
Digit0 :: Key
-- | Without Shift: 1. With Shift: !.
Digit1 :: Key
-- | Without Shift: 2. With Shift: @.
Digit2 :: Key
-- | Without Shift: 3. With Shift: #.
Digit3 :: Key
-- | Without Shift: 4. With Shift: $.
Digit4 :: Key
-- | Without Shift: 5. With Shift: %.
Digit5 :: Key
-- | Without Shift: 6. With Shift: ^.
Digit6 :: Key
-- | Without Shift: 7. With Shift: &.
Digit7 :: Key
-- | Without Shift: 8. With Shift: *.
Digit8 :: Key
-- | Without Shift: 9. With Shift: (.
Digit9 :: Key
-- | Without Shift: a. With Shift: A.
KeyA :: Key
-- | Without Shift: b. With Shift: B.
KeyB :: Key
-- | Without Shift: c. With Shift: C.
KeyC :: Key
-- | Without Shift: d. With Shift: D.
KeyD :: Key
-- | Without Shift: e. With Shift: E.
KeyE :: Key
-- | Without Shift: f. With Shift: F.
KeyF :: Key
-- | Without Shift: g. With Shift: G.
KeyG :: Key
-- | Without Shift: h. With Shift: H.
KeyH :: Key
-- | Without Shift: i. With Shift: I.
KeyI :: Key
-- | Without Shift: j. With Shift: J.
KeyJ :: Key
-- | Without Shift: k. With Shift: K.
KeyK :: Key
-- | Without Shift: l. With Shift: L.
KeyL :: Key
-- | Without Shift: m. With Shift: M.
KeyM :: Key
-- | Without Shift: n. With Shift: N.
KeyN :: Key
-- | Without Shift: o. With Shift: O.
KeyO :: Key
-- | Without Shift: p. With Shift: P.
KeyP :: Key
-- | Without Shift: q. With Shift: Q.
KeyQ :: Key
-- | Without Shift: r. With Shift: R.
KeyR :: Key
-- | Without Shift: s. With Shift: S.
KeyS :: Key
-- | Without Shift: t. With Shift: T.
KeyT :: Key
-- | Without Shift: u. With Shift: U.
KeyU :: Key
-- | Without Shift: v. With Shift: V.
KeyV :: Key
-- | Without Shift: w. With Shift: W.
KeyW :: Key
-- | Without Shift: x. With Shift: X.
KeyX :: Key
-- | Without Shift: y. With Shift: Y.
KeyY :: Key
-- | Without Shift: z. With Shift: Z.
KeyZ :: Key
-- | Might also be the Windows key or the Super key
Command :: Key
Numpad0 :: Key
Numpad1 :: Key
Numpad2 :: Key
Numpad3 :: Key
Numpad4 :: Key
Numpad5 :: Key
Numpad6 :: Key
Numpad7 :: Key
Numpad8 :: Key
Numpad9 :: Key
NumpadMultiply :: Key
NumpadAdd :: Key
NumpadEnter :: Key
NumpadSubtract :: Key
NumpadDecimal :: Key
NumpadDivide :: Key
F1 :: Key
F2 :: Key
F3 :: Key
F4 :: Key
F5 :: Key
F6 :: Key
F7 :: Key
F8 :: Key
F9 :: Key
F10 :: Key
F11 :: Key
F12 :: Key
ScrollLock :: Key
-- | Without Shift: ;. With Shift: :.
Semicolon :: Key
-- | Without Shift: =. With Shift: +.
Equals :: Key
-- | Without Shift: ,. With Shift: <.
Comma :: Key
-- | Without Shift: -. With Shift: _.
Subtract :: Key
-- | Without Shift: .. With Shift: >.
Period :: Key
-- | Without Shift: /. With Shift: ?.
ForwardSlash :: Key
-- | Without Shift: `. With Shift: ~.
Backquote :: Key
-- | Without Shift: [. With Shift: {.
BracketLeft :: Key
-- | Without Shift: \. With Shift: |.
Backslash :: Key
-- | Without Shift: ]. With Shift: }.
BracketRight :: Key
-- | Without Shift: '. With Shift: ".
Apostrophe :: Key
UnknownKey :: Key
-- | A numeric code representing the value of a pressed Key. Note
-- that a particular Key may not uniquely map to a particular
-- KeyCode, as the implementation of key codes is
-- browser-dependent.
--
-- Since: 0.1
type KeyCode = Int
-- | Determine the Key that a KeyCode represents. If one
-- cannot be found, UnknownKey is returned.
--
-- Since: 0.1
keyCodeLookup :: KeyCode -> Key
-- | An map of known KeyCodes to Keys.
--
-- Since: 0.1
keyCodeMap :: IntMap Key
instance Bounded Key
instance Enum Key
instance Eq Key
instance Ix Key
instance Ord Key
instance Read Key
instance Show Key