home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c222 / 1.ddi / INC / KB_DEFS.H < prev    next >
Encoding:
Text File  |  1990-05-21  |  2.2 KB  |  106 lines

  1. /*********************
  2.  *
  3.  *  kb_defs.h [NON-ANSI] - keyboard definition header file.
  4.  *
  5.  *  Purpose: This file contains the global definitons for the keyboard module.
  6.  *
  7.  *  Blackstar C Function Library
  8.  *  (c) Copyright 1985,1989 Sterling Castle Software
  9.  *
  10.  *******/
  11.  
  12. /* 
  13.  *  table pointers
  14.  */
  15.  
  16. char    *keyftbl_;              /* keyboard function table to use */
  17. char     *keyxtbl_;        /* keyboard translation table to use */
  18. char     *keystbl_;        /* keyboard scan table */
  19. char     *keybrktbl_;        /* keyboard break table */
  20.  
  21. char    insmodef_ ;        /* insert mode for input */
  22. char    chinf_ ;        /* flag if text field has been modified */
  23. char    echof_;            /* flag to echo characters to screen */
  24. char    breakf_;        /* keyboard break flag */
  25.  
  26. /*
  27.  *  Keyboard translate tables
  28.  */
  29.  
  30. char keyxtbl1_[]   = {0,0};
  31. char keybrktbl1_[] = {ESC,CTRL_C,0};
  32. char keyftbl1_[]   = {ESC,CR,NEWLINE,0};
  33.  
  34. char keyftbl2_[] ={   /* functions including control codes */
  35. BKSP    ,  /* backspace character */
  36. BK_TAB  ,  /* back tab (shift-tab) */
  37. CTRL_A  ,  /* control keys */
  38. CTRL_B  ,
  39. CTRL_C    ,
  40. CTRL_D  ,
  41. CTRL_E  ,
  42. CTRL_F  ,
  43. CTRL_G  ,
  44. CTRL_I  ,
  45. CTRL_R  ,
  46. CTRL_S  ,
  47. CTRL_T  ,
  48. CTRL_V  ,
  49. CTRL_X  ,
  50. CTRL_Y  ,
  51. CUR_DN    ,/* cursor down */
  52. CUR_LF  ,/* cursor left */
  53. CUR_RT,  /* cursor right */
  54. CUR_UP,    /* cursor up command */
  55. DEL,    /* delete key */
  56. END_KY,  /* end key */
  57. ESC    ,/* escape key */
  58. F1    ,/* function key */
  59. F2    ,/* add an entry key */
  60. F3    ,/* delete an entry key*/
  61. F4    ,/* funciton key */
  62. F5,    
  63. F6,    /* calendar set key */
  64. F7,    /* directory search key */
  65. F8,    
  66. F9,    
  67. F10,    /* last function key */
  68. HOME,    /* home key */
  69. INS,    /* insert character */
  70. PG_DN,   /* page down character */
  71. PG_UP,    /* page up character */
  72. SHF9,    /* shift F9 used to change the password */
  73. 0};
  74.  
  75. /*
  76.  *  keyboard scan code translate table for extended keys
  77.  *
  78.  *  Extended codes are translated using this table.  To add a new key
  79.  *  simply insert the extended code lower byte, then the byte to translate
  80.  *  to into the table. The table is terminated by a 0,0 pair.
  81.  */
  82.  
  83. char keystbl1_[] = {
  84. 15,BK_TAB,
  85. 59,F1,
  86. 60,F2,
  87. 61,F3,
  88. 62,F4,
  89. 63,F5,
  90. 64,F6,
  91. 65,F7,
  92. 66,F8,
  93. 67,F9,
  94. 68,F10,
  95. 72,CUR_UP,
  96. 73,PG_UP,
  97. 75,CUR_LF,
  98. 77,CUR_RT,
  99. 80,CUR_DN,
  100. 81,PG_DN,
  101. 82,INS,
  102. 83,DEL,
  103. 92,SHF9,
  104. 0,0
  105. };
  106.