3 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
4 ;; DOS - NLS Support - KEYB Command
5 ;; (C) Copyright 1988 Microsoft
7 ;; File Name: KEYBSYS.INC
10 ;; Root File Name: KEYB.ASM
15 ;; Include file containing structure definitions and equates
16 ;; for the KEYBOARD.SYS file.
22 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
24 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
25 ;; File header - contains pointers to keyboard tables for each language
26 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
28 KEYBSYS_HEADER STRUC ;;
30 KH_SIGNATURE DB 0FFh,'KEYB ' ;; signature
31 KH_RESV_1 DB 8 DUP(0) ;; reserved
32 KH_MAX_COM_SZ DW 0 ;AN000;**chg ;; maximum size of Common Xlat Sect
33 KH_MAX_SPEC_SZ DW 0 ;AN000;;**chg ;; max size of Specific Xlat Sect
34 KH_MAX_LOGIC_SZ DW 0 ;AN000;;**chg ;; max size of State Logic
35 KH_RESV_2 Dw 0 ;AN000;;**chg ;; reserved CNS
36 KH_NUM_ID Dw 0 ;AN000;;; ************* CNS
37 KH_NUM_LANG DW 0 ;; number of languages
38 KH_LANG_PTRS DB 0 ;; language pointers start here
39 ;********************* CNS **********************
40 ;KH_NUM_ID DW 0 ;; number of languages
41 ;KH_ID_PTRS DB 0 ;; id pointers start here
42 ;********************* CNS **********************
43 KEYBSYS_HEADER ENDS ;;
44 ;******************CNS*******************
47 KP_ID_CODE DW 0 ;AN000;
48 KP_LANG_PTR DD 0 ;AN000;
52 ;*****************CNS********************
53 KEYBSYS_LANG_PTRS STRUC ;;
54 ;; Next two entries repeat:
55 KP_LANG_CODE DW 0 ;; language code
56 KP_ENTRY_PTR DD 0 ;; language entry pointer
58 KEYBSYS_LANG_PTRS ENDS ;;
60 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
61 ;; Language Entry - pointed to by KH_ENTRY_PTR in KEYBSYS_HEADER
62 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
64 KEYBSYS_LANG_ENTRY STRUC ;;
66 KL_LANG_CODE DW 'XX' ;; language code
67 KL_ID_CODE DW 0 ;; reserved (ID CODE)
68 KL_LOGIC_PTR DD 0 ;AC000;;**chg ;; State Logic pointer
69 KL_NUM_ID DB 0 ;AN000;;CNS ;; number of valid IDs for this lang
70 KL_NUM_CP DB 0 ;; number of valid CPs for this lang
71 KL_CP_PTRS DB 0 ;; CP table pointers start here
73 KEYBSYS_LANG_ENTRY ENDS ;;
75 KEYBSYS_CP_PTRS STRUC ;;
76 ;; Next two entries repeat:
77 KC_CODE_PAGE DW 0 ;; code page
78 KC_ENTRY_PTR DD 0 ;; ptr to Specific Translate Section
80 KEYBSYS_CP_PTRS ENDS ;;
83 ;; Everything from here down is new
84 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
85 ;; State Logic - pointed to by KL_LOGIC_PTR in KEYBSYS_LANG_ENTRY
86 ;; Common Translate Section follows immediately after the State Logic.
87 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
89 KEYBSYS_STATE_LOGIC STRUC ;;
91 KT_LOGIC_LEN DW ? ;; length of state logic
92 KT_SPECIAL_FEATURES DW ? ;; Special Features (see KEYBSHAR.INC)
93 KT_LOGIC_CMDS DB 0 ;; state logic commands begin here
95 KEYBSYS_STATE_LOGIC ENDS ;;
98 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
99 ;; Translate Section - Common and Specific Translate Sections
100 ;; are both in this form.
101 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
103 KEYBSYS_XLAT_SECT STRUC ;;
105 KX_SECTION_LEN DW ? ;; Length of this section
106 KX_CP_ID DW ? ;; code page id
107 KX_FIRST_STATE DB ? ;;
109 KEYBSYS_XLAT_SECT ENDS ;;
112 KEYBSYS_STATE STRUC ;;
113 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
114 ;; Translate Sections contains multiple States.
115 ;; A State contains the translate tables for a single
116 ;; shift state (IE lower case, upper case ....)
117 ;; The last State is a null State containing only the
118 ;; KX_STATE_LEN field with a value of 0.
119 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
120 KX_STATE_LEN DW ? ;; length of state section
121 KX_STATE_ID DB ? ;; State ID
122 KX_KBD_TYPE DW ? ;; Keyboard Type
123 KX_ERROR_CHAR DW ? ;; Buffer entry for error character
124 KX_FIRST_XLAT DB ? ;; XLAT tables begin here
125 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
126 ;; Each State consists of multiple translate tables.
127 ;; The last translate table within a state is a null
128 ;; table containing only the
129 ;; KX_XLAT_LEN field with a value of 0.
130 ;; Refer to KEYBSHAR.INC for translate table format.
131 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
133 KEYBSYS_STATE ENDS ;;
135 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;