1 /************************************************************
2 Copyright (c) 1994 by Silicon Graphics Computer Systems, Inc.
4 Permission to use, copy, modify, and distribute this
5 software and its documentation for any purpose and without
6 fee is hereby granted, provided that the above copyright
7 notice appear in all copies and that both that copyright
8 notice and this permission notice appear in supporting
9 documentation, and that the name of Silicon Graphics not be
10 used in advertising or publicity pertaining to distribution
11 of the software without specific prior written permission.
12 Silicon Graphics makes no representation about the suitability
13 of this software for any purpose. It is provided "as is"
14 without any express or implied warranty.
16 SILICON GRAPHICS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS
17 SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
18 AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON
19 GRAPHICS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
20 DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
21 DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
22 OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH
23 THE USE OR PERFORMANCE OF THIS SOFTWARE.
25 ********************************************************/
31 #define DEBUG_VAR debugFlags
35 #include <X11/Xdefs.h>
39 #include <X11/extensions/XKM.h>
40 #include <X11/extensions/XKBstrcommon.h>
41 #include <X11/extensions/XKBrulescommon.h>
42 #include "X11/extensions/XKBcommon.h"
43 #include "XKBcommonint.h"
45 extern char *scanFile;
58 #define StmtKeycodeDef 2
59 #define StmtKeyAliasDef 3
62 #define StmtKeyTypeDef 6
63 #define StmtInterpDef 7
65 #define StmtSymbolsDef 9
66 #define StmtModMapDef 10
67 #define StmtGroupCompatDef 11
68 #define StmtIndicatorMapDef 12
69 #define StmtIndicatorNameDef 13
70 #define StmtOutlineDef 14
71 #define StmtShapeDef 15
74 #define StmtSectionDef 18
75 #define StmtOverlayKeyDef 19
76 #define StmtOverlayDef 20
77 #define StmtDoodadDef 21
79 #define FileSymInterp 100
81 typedef struct _ParseCommon
84 struct _ParseCommon *next;
89 #define ExprActionDecl 2
90 #define ExprFieldRef 3
91 #define ExprArrayRef 4
92 #define ExprKeysymList 5
93 #define ExprActionList 6
104 #define OpUnaryPlus 28
106 #define MergeDefault 0
107 #define MergeAugment 1
108 #define MergeOverride 2
109 #define MergeReplace 3
110 #define MergeAltForm 4
112 #define AutoKeyNames (1L << 0)
113 #define CreateKeyNames(x) ((x)->flags&AutoKeyNames)
115 extern unsigned warningLevel;
117 typedef struct _IncludeStmt
126 struct _IncludeStmt *next;
177 typedef struct _VarDef
185 typedef struct _VModDef
193 typedef struct _KeycodeDef
201 typedef struct _KeyAliasDef
209 typedef struct _KeyTypeDef
217 typedef struct _SymbolsDef
225 typedef struct _ModMapDef
233 typedef struct _GroupCompatDef
241 typedef struct _InterpDef
250 typedef struct _IndicatorNameDef
259 typedef struct _OutlineDef
267 typedef struct _ShapeDef
273 OutlineDef *outlines;
276 typedef struct _KeyDef
284 typedef struct _RowDef
291 typedef struct _SectionDef
300 typedef struct _OverlayKeyDef
307 typedef struct _OverlayDef
316 typedef struct _DoodadDef
325 /* IndicatorMapDef doesn't use the type field, but the rest of the fields
326 need to be at the same offsets as in DoodadDef. Use #define to avoid
327 any strict aliasing problems. */
328 #define IndicatorMapDef DoodadDef
330 typedef struct _XkbFile
343 CompileKeymap(XkbFile *file, XkbcDescPtr xkb, unsigned merge);
346 CompileKeycodes(XkbFile *file, XkbcDescPtr xkb, unsigned merge);
349 CompileGeometry(XkbFile *file, XkbcDescPtr xkb, unsigned merge);
352 CompileKeyTypes(XkbFile *file, XkbcDescPtr xkb, unsigned merge);
354 typedef struct _LEDInfo *LEDInfoPtr;
357 CompileCompatMap(XkbFile *file, XkbcDescPtr xkb, unsigned merge,
358 LEDInfoPtr *unboundLEDs);
361 CompileSymbols(XkbFile *file, XkbcDescPtr xkb, unsigned merge);
363 #endif /* XKBCOMP_H */