root/include/linux/keyboard.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 #ifndef __LINUX_KEYBOARD_H
   2 #define __LINUX_KEYBOARD_H
   3 
   4 #define KG_SHIFT        0
   5 #define KG_CTRL         2
   6 #define KG_ALT          3
   7 #define KG_ALTGR        1
   8 #define KG_SHIFTL       4
   9 #define KG_SHIFTR       5
  10 #define KG_CTRLL        6
  11 #define KG_CTRLR        7
  12 
  13 #define NR_KEYS 128
  14 #define NR_KEYMAPS 16
  15 extern const int NR_TYPES;
  16 extern const int max_vals[];
  17 extern unsigned short key_map[NR_KEYMAPS][NR_KEYS];
  18 
  19 #define NR_FUNC 36
  20 #define FUNC_BUFSIZE 512
  21 extern char func_buf[FUNC_BUFSIZE];
  22 extern char *func_table[NR_FUNC];
  23 
  24 #define KT_LATIN        0       /* we depend on this being zero */
  25 #define KT_LETTER      11       /* symbol that can be acted upon by CapsLock */
  26 #define KT_FN           1
  27 #define KT_SPEC         2
  28 #define KT_PAD          3
  29 #define KT_DEAD         4
  30 #define KT_CONS         5
  31 #define KT_CUR          6
  32 #define KT_SHIFT        7
  33 #define KT_META         8
  34 #define KT_ASCII        9
  35 #define KT_LOCK         10
  36 
  37 #define K(t,v)          (((t)<<8)|(v))
  38 #define KTYP(x)         ((x) >> 8)
  39 #define KVAL(x)         ((x) & 0xff)
  40 
  41 #define K_F1            K(KT_FN,0)
  42 #define K_F2            K(KT_FN,1)
  43 #define K_F3            K(KT_FN,2)
  44 #define K_F4            K(KT_FN,3)
  45 #define K_F5            K(KT_FN,4)
  46 #define K_F6            K(KT_FN,5)
  47 #define K_F7            K(KT_FN,6)
  48 #define K_F8            K(KT_FN,7)
  49 #define K_F9            K(KT_FN,8)
  50 #define K_F10           K(KT_FN,9)
  51 #define K_F11           K(KT_FN,10)
  52 #define K_F12           K(KT_FN,11)
  53 #define K_F13           K(KT_FN,12)
  54 #define K_F14           K(KT_FN,13)
  55 #define K_F15           K(KT_FN,14)
  56 #define K_F16           K(KT_FN,15)
  57 #define K_F17           K(KT_FN,16)
  58 #define K_F18           K(KT_FN,17)
  59 #define K_F19           K(KT_FN,18)
  60 #define K_F20           K(KT_FN,19)
  61 #define K_FIND          K(KT_FN,20)
  62 #define K_INSERT        K(KT_FN,21)
  63 #define K_REMOVE        K(KT_FN,22)
  64 #define K_SELECT        K(KT_FN,23)
  65 #define K_PGUP          K(KT_FN,24)
  66 #define K_PGDN          K(KT_FN,25)
  67 #define K_MACRO         K(KT_FN,26)
  68 #define K_HELP          K(KT_FN,27)
  69 #define K_DO            K(KT_FN,28)
  70 #define K_PAUSE         K(KT_FN,29)
  71 
  72 #define K_HOLE          K(KT_SPEC,0)
  73 #define K_ENTER         K(KT_SPEC,1)
  74 #define K_SH_REGS       K(KT_SPEC,2)
  75 #define K_SH_MEM        K(KT_SPEC,3)
  76 #define K_SH_STAT       K(KT_SPEC,4)
  77 #define K_BREAK         K(KT_SPEC,5)
  78 #define K_CONS          K(KT_SPEC,6)
  79 #define K_CAPS          K(KT_SPEC,7)
  80 #define K_NUM           K(KT_SPEC,8)
  81 #define K_HOLD          K(KT_SPEC,9)
  82 #define K_SCROLLFORW    K(KT_SPEC,10)
  83 #define K_SCROLLBACK    K(KT_SPEC,11)
  84 #define K_BOOT          K(KT_SPEC,12)
  85 #define K_CAPSON        K(KT_SPEC,13)
  86 #define K_COMPOSE       K(KT_SPEC,14)
  87 #define K_SAK           K(KT_SPEC,15)
  88 
  89 #define K_P0            K(KT_PAD,0)
  90 #define K_P1            K(KT_PAD,1)
  91 #define K_P2            K(KT_PAD,2)
  92 #define K_P3            K(KT_PAD,3)
  93 #define K_P4            K(KT_PAD,4)
  94 #define K_P5            K(KT_PAD,5)
  95 #define K_P6            K(KT_PAD,6)
  96 #define K_P7            K(KT_PAD,7)
  97 #define K_P8            K(KT_PAD,8)
  98 #define K_P9            K(KT_PAD,9)
  99 #define K_PPLUS         K(KT_PAD,10)    /* key-pad plus                    */
 100 #define K_PMINUS        K(KT_PAD,11)    /* key-pad minus                   */
 101 #define K_PSTAR         K(KT_PAD,12)    /* key-pad asterisk (star)         */
 102 #define K_PSLASH        K(KT_PAD,13)    /* key-pad slash                   */
 103 #define K_PENTER        K(KT_PAD,14)    /* key-pad enter                   */
 104 #define K_PCOMMA        K(KT_PAD,15)    /* key-pad comma: kludge...        */
 105 #define K_PDOT          K(KT_PAD,16)    /* key-pad dot (period): kludge... */
 106 #define K_PPLUSMINUS    K(KT_PAD,17)    /* key-pad plus/minus              */
 107 
 108 #define K_DGRAVE        K(KT_DEAD,0)
 109 #define K_DACUTE        K(KT_DEAD,1)
 110 #define K_DCIRCM        K(KT_DEAD,2)
 111 #define K_DTILDE        K(KT_DEAD,3)
 112 #define K_DDIERE        K(KT_DEAD,4)
 113 
 114 #define K_DOWN          K(KT_CUR,0)
 115 #define K_LEFT          K(KT_CUR,1)
 116 #define K_RIGHT         K(KT_CUR,2)
 117 #define K_UP            K(KT_CUR,3)
 118 
 119 #define K_SHIFT         K(KT_SHIFT,KG_SHIFT)
 120 #define K_CTRL          K(KT_SHIFT,KG_CTRL)
 121 #define K_ALT           K(KT_SHIFT,KG_ALT)
 122 #define K_ALTGR         K(KT_SHIFT,KG_ALTGR)
 123 #define K_SHIFTL        K(KT_SHIFT,KG_SHIFTL)
 124 #define K_SHIFTR        K(KT_SHIFT,KG_SHIFTR)
 125 #define K_CTRLL         K(KT_SHIFT,KG_CTRLL)
 126 #define K_CTRLR         K(KT_SHIFT,KG_CTRLR)
 127 
 128 #define NR_SHIFT        4
 129 
 130 #define K_CAPSSHIFT     K(KT_SHIFT,NR_SHIFT)
 131 
 132 #define K_ASC0          K(KT_ASCII,0)
 133 #define K_ASC1          K(KT_ASCII,1)
 134 #define K_ASC2          K(KT_ASCII,2)
 135 #define K_ASC3          K(KT_ASCII,3)
 136 #define K_ASC4          K(KT_ASCII,4)
 137 #define K_ASC5          K(KT_ASCII,5)
 138 #define K_ASC6          K(KT_ASCII,6)
 139 #define K_ASC7          K(KT_ASCII,7)
 140 #define K_ASC8          K(KT_ASCII,8)
 141 #define K_ASC9          K(KT_ASCII,9)
 142 
 143 #define K_SHIFTLOCK     K(KT_LOCK,KG_SHIFT)
 144 #define K_CTRLLOCK      K(KT_LOCK,KG_CTRL)
 145 #define K_ALTLOCK       K(KT_LOCK,KG_ALT)
 146 #define K_ALTGRLOCK     K(KT_LOCK,KG_ALTGR)
 147 
 148 #define MAX_DIACR       256
 149 #endif

/* [previous][next][first][last][top][bottom][index][help] */