KeyCode.lua 4.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. return {
  2. summary = 'Keys that can be pressed.',
  3. description = [[
  4. Keys that can be pressed on a keyboard. Notably, numpad keys are missing right now.
  5. ]],
  6. values = {
  7. { name = 'a', description = 'The A key.' },
  8. { name = 'b', description = 'The B key.' },
  9. { name = 'c', description = 'The C key.' },
  10. { name = 'd', description = 'The D key.' },
  11. { name = 'e', description = 'The E key.' },
  12. { name = 'f', description = 'The F key.' },
  13. { name = 'g', description = 'The G key.' },
  14. { name = 'h', description = 'The H key.' },
  15. { name = 'i', description = 'The I key.' },
  16. { name = 'j', description = 'The J key.' },
  17. { name = 'k', description = 'The K key.' },
  18. { name = 'l', description = 'The L key.' },
  19. { name = 'm', description = 'The M key.' },
  20. { name = 'n', description = 'The N key.' },
  21. { name = 'o', description = 'The O key.' },
  22. { name = 'p', description = 'The P key.' },
  23. { name = 'q', description = 'The Q key.' },
  24. { name = 'r', description = 'The R key.' },
  25. { name = 's', description = 'The S key.' },
  26. { name = 't', description = 'The T key.' },
  27. { name = 'u', description = 'The U key.' },
  28. { name = 'v', description = 'The V key.' },
  29. { name = 'w', description = 'The W key.' },
  30. { name = 'x', description = 'The X key.' },
  31. { name = 'y', description = 'The Y key.' },
  32. { name = 'z', description = 'The Z key.' },
  33. { name = '0', description = 'The 0 key.' },
  34. { name = '1', description = 'The 1 key.' },
  35. { name = '2', description = 'The 2 key.' },
  36. { name = '3', description = 'The 3 key.' },
  37. { name = '4', description = 'The 4 key.' },
  38. { name = '5', description = 'The 5 key.' },
  39. { name = '6', description = 'The 6 key.' },
  40. { name = '7', description = 'The 7 key.' },
  41. { name = '8', description = 'The 8 key.' },
  42. { name = '9', description = 'The 9 key.' },
  43. { name = 'space', description = 'The space bar.' },
  44. { name = 'return', description = 'The enter key.' },
  45. { name = 'tab', description = 'The tab key.' },
  46. { name = 'escape', description = 'The escape key.' },
  47. { name = 'backspace', description = 'The backspace key.' },
  48. { name = 'up', description = 'The up arrow key.' },
  49. { name = 'down', description = 'The down arrow key.' },
  50. { name = 'left', description = 'The left arrow key.' },
  51. { name = 'right', description = 'The right arrow key.' },
  52. { name = 'home', description = 'The home key.' },
  53. { name = 'end', description = 'The end key.' },
  54. { name = 'pageup', description = 'The page up key.' },
  55. { name = 'pagedown', description = 'The page down key.' },
  56. { name = 'insert', description = 'The insert key.' },
  57. { name = 'delete', description = 'The delete key.' },
  58. { name = 'f1', description = 'The F1 key.' },
  59. { name = 'f2', description = 'The F2 key.' },
  60. { name = 'f3', description = 'The F3 key.' },
  61. { name = 'f4', description = 'The F4 key.' },
  62. { name = 'f5', description = 'The F5 key.' },
  63. { name = 'f6', description = 'The F6 key.' },
  64. { name = 'f7', description = 'The F7 key.' },
  65. { name = 'f8', description = 'The F8 key.' },
  66. { name = 'f9', description = 'The F9 key.' },
  67. { name = 'f10', description = 'The F10 key.' },
  68. { name = 'f11', description = 'The F11 key.' },
  69. { name = 'f12', description = 'The F12 key.' },
  70. { name = '`', description = 'The backtick/backquote/grave accent key.' },
  71. { name = '-', description = 'The dash/hyphen/minus key.' },
  72. { name = '=', description = 'The equal sign key.' },
  73. { name = '[', description = 'The left bracket key.' },
  74. { name = ']', description = 'The right bracket key.' },
  75. { name = '\\', description = 'The backslash key.' },
  76. { name = ';', description = 'The semicolon key.' },
  77. { name = '\'', description = 'The single quote key.' },
  78. { name = ',', description = 'The comma key.' },
  79. { name = '.', description = 'The period key.' },
  80. { name = '/', description = 'The slash key.' },
  81. { name = 'lctrl', description = 'The left control key.' },
  82. { name = 'lshift', description = 'The left shift key.' },
  83. { name = 'lalt', description = 'The left alt key.' },
  84. { name = 'lgui', description = 'The left OS key (windows, command, super).' },
  85. { name = 'rctrl', description = 'The right control key.' },
  86. { name = 'rshift', description = 'The right shift key.' },
  87. { name = 'ralt', description = 'The right alt key.' },
  88. { name = 'rgui', description = 'The right OS key (windows, command, super).' },
  89. { name = 'capslock', description = 'The caps lock key.' },
  90. { name = 'scrolllock', description = 'The scroll lock key.' },
  91. { name = 'numlock', description = 'The numlock key.' }
  92. },
  93. related = {
  94. 'lovr.keypressed',
  95. 'lovr.keyreleased'
  96. }
  97. }