Ooops
November 25, 2020, 05:20:11 AM

Author Topic: [bmx] Key name from key code by Who was John Galt? [ 1+ years ago ]  (Read 560 times)

Offline BlitzBot

  • Jr. Member
  • **
  • Posts: 1
Title : Key name from key code
Author : Who was John Galt?
Posted : 1+ years ago

Description : What it says on the tin

Code :
Code: BlitzMax
  1. 'Key names
  2. 'Falken '05
  3.  
  4. Graphics 800,600,32
  5.  
  6. Local keystring$[300]
  7. RestoreData key_data
  8.  
  9. Repeat
  10.         ReadData tempkey$
  11.         ReadData put_index
  12.         keystring(put_index)=tempkey
  13. Until put_index=191
  14.  
  15. While Not KeyDown(KEY_ESCAPE)
  16.         Cls
  17.         DrawText keystring(WaitKey()),100,100
  18.         Flip
  19. Wend
  20.  
  21. #key_data
  22. DefData "Mouse button (Left)",1
  23. DefData "Mouse button (Right)",2
  24. DefData "Mouse button (Middle)" ,4
  25. DefData "Backspace",8
  26. DefData "Tab",9
  27. DefData "Return",13
  28. DefData "Clear",12
  29. DefData "Enter",13
  30. DefData "Shift",16
  31. DefData "Control",17
  32. DefData "Alt",18
  33. DefData "Pause",19
  34. DefData "Caps Lock",20
  35. DefData "Escape",27
  36. DefData "Space",32
  37. DefData "Page Up",33
  38. DefData "Page Down",34
  39. DefData "End",35
  40. DefData "Home",36
  41. DefData "Cursor (Left)",37
  42. DefData "Cursor (Up)",38
  43. DefData "Cursor (Right)",39
  44. DefData "Cursor (Down)",40
  45. DefData "Select",41
  46. DefData "Print",42
  47. DefData "Execute",43
  48. DefData "Screen",44
  49. DefData "Insert",45
  50. DefData "Delete",46
  51. DefData "Help",47
  52. DefData "0",48
  53. DefData "1",49
  54. DefData "2",50
  55. DefData "3",51
  56. DefData "4",52
  57. DefData "5",53
  58. DefData "6",54
  59. DefData "7",55
  60. DefData "8",56
  61. DefData "9",57
  62. DefData "A",65
  63. DefData "B",66
  64. DefData "C",67
  65. DefData "D",68
  66. DefData "E", 69
  67. DefData "F",70
  68. DefData "G",71
  69. DefData "H",72
  70. DefData "I",73
  71. DefData "J",74
  72. DefData "K",75
  73. DefData "L",76
  74. DefData "M",77
  75. DefData "N",78
  76. DefData "O",79
  77. DefData "P",80
  78. DefData "Q",81
  79. DefData "R",82
  80. DefData "S",83
  81. DefData "T",84
  82. DefData "U",85
  83. DefData "V",86
  84. DefData "W",87
  85. DefData "X",88
  86. DefData "Y", 89
  87. DefData "Z", 90
  88. DefData "Sys key (Left)",91
  89. DefData "Sys key (Right)",92
  90. DefData "Numpad 0",96
  91. DefData "Numpad 1",97
  92. DefData "Numpad 2",98
  93. DefData "Numpad 3",99
  94. DefData "Numpad 4",100
  95. DefData "Numpad 5",101
  96. DefData "Numpad 6",102
  97. DefData "Numpad 7",103
  98. DefData "Numpad 8",104
  99. DefData "Numpad 9",105
  100. DefData "Numpad *",106
  101. DefData "Numpad +",107
  102. DefData "Numpad /",108
  103. DefData "Numpad -",109
  104. DefData "Numpad .",110
  105. DefData "Numpad /",111
  106. DefData "F1",112
  107. DefData "F2",113
  108. DefData "F3",114
  109. DefData "F4",115
  110. DefData "F5",116
  111. DefData "F6",117
  112. DefData "F7",118
  113. DefData "F8",119
  114. DefData "F9",120
  115. DefData "F10",121
  116. DefData "F11", 122
  117. DefData "F12",123
  118. DefData "Num Lock",144
  119. DefData "Scroll Lock",145
  120. DefData "Shift (Left)",160
  121. DefData "Shift (Right)",161
  122. DefData "Control (Left)",162
  123. DefData "Control (Right)",163
  124. DefData "Alt key (Left)",164
  125. DefData "Alt key (Right)",165
  126. DefData "Tilde",192
  127. DefData "Minus",107
  128. DefData "Equals",109
  129. DefData "Bracket (Open)",219
  130. DefData "Bracket (Close)",221
  131. DefData "Backslash",226
  132. DefData "Semi-colon",186
  133. DefData "Quote",222
  134. DefData "Comma",188
  135. DefData "Period",190
  136. DefData "Slash",191


Comments :


dan_upright(Posted 1+ years ago)

 Thanks for this.


 

SimplePortal 2.3.6 © 2008-2014, SimplePortal