package lambda-term

  1. Overview
  2. Docs

Keys

type code =
  1. | Char of CamomileLibrary.UChar.t
    (*

    A unicode character.

    *)
  2. | Enter
  3. | Escape
  4. | Tab
  5. | Up
  6. | Down
  7. | Left
  8. | Right
  9. | F1
  10. | F2
  11. | F3
  12. | F4
  13. | F5
  14. | F6
  15. | F7
  16. | F8
  17. | F9
  18. | F10
  19. | F11
  20. | F12
  21. | Next_page
  22. | Prev_page
  23. | Home
  24. | End
  25. | Insert
  26. | Delete
  27. | Backspace

Type of key code.

type t = {
  1. control : bool;
    (*

    Is the control key down ?

    *)
  2. meta : bool;
    (*

    Is the meta key down ?

    *)
  3. shift : bool;
    (*

    Is the shift key down ?

    *)
  4. code : code;
    (*

    The code of the key.

    *)
}

Type of key.

val compare : t -> t -> int

Same as Pervasives.compare.

val control : t -> bool
val meta : t -> bool
val code : t -> code
val to_string : t -> string

Returns the string representation of the given key.

val to_string_compact : t -> string

Returns the string representation of the given key in the form "C-M-a".

OCaml

Innovation. Community. Security.