home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 5 Edit / 05-Edit.zip / vile-src.zip / vile-8.1 / os2keys.h < prev    next >
Text File  |  1997-11-30  |  1KB  |  61 lines

  1. /*
  2.  * $Header: /usr/build/vile/vile/RCS/os2keys.h,v 1.1 1997/11/30 23:51:25 tom Exp $
  3.  *
  4.  * Function-key definitions used for OS/2 VIO driver, as well as OS/2 EMX
  5.  * driver.
  6.  */
  7.  
  8. /* Extended key prefix macros. */
  9. #define    KE0(code)        { 0xe0, code }
  10. #define    K00(code)        { 0x00, code }
  11.  
  12. static struct
  13. {
  14.     char seq[2];
  15.     int code;
  16. }
  17. VIO_KeyMap[] =
  18. {
  19.     { KE0('H'), KEY_Up },
  20.     { KE0('P'), KEY_Down },
  21.     { KE0('K'), KEY_Left },
  22.     { KE0('M'), KEY_Right },
  23.     { KE0('R'), KEY_Insert },
  24.     { KE0('S'), KEY_Delete },
  25.     { KE0('G'), KEY_Home },
  26.     { KE0('O'), KEY_End },
  27.     { KE0('I'), KEY_Prior },
  28.     { KE0('Q'), KEY_Next },
  29.  
  30.     /*
  31.      * Unshifted function keys.  The VIO console driver generates
  32.      * different scan codes when these keys are pressed with Shift,
  33.      * Ctrl, and Alt; those codes are presently unsupported.
  34.      */
  35.     { K00(';'), KEY_F1 },
  36.     { K00('<'), KEY_F2 },
  37.     { K00('='), KEY_F3 },
  38.     { K00('>'), KEY_F4 },
  39.     { K00('?'), KEY_F5 },
  40.     { K00('@'), KEY_F6 },
  41.     { K00('A'), KEY_F7 },
  42.     { K00('B'), KEY_F8 },
  43.     { K00('C'), KEY_F9 },
  44.     { K00('D'), KEY_F10 },
  45.     { K00(133), KEY_F11 },
  46.     { K00(134), KEY_F12 },
  47.  
  48.     /* Keypad codes (with Num Lock off): */
  49.     { K00('G'), KEY_Home },
  50.     { K00('H'), KEY_Up },
  51.     { K00('I'), KEY_Prior },
  52.     { K00('K'), KEY_Left },
  53.     { K00('L'), KEY_Select },
  54.     { K00('M'), KEY_Right },
  55.     { K00('O'), KEY_End },
  56.     { K00('P'), KEY_Down },
  57.     { K00('Q'), KEY_Next },
  58.     { K00('R'), KEY_Insert },
  59.     { K00('S'), KEY_Delete }
  60. };
  61.