return ReportIllegal(PrivateAction, field);
}
-typedef Bool(*actionHandler) (struct xkb_keymap * /* xkb */ ,
- struct xkb_any_action * /* action */ ,
- unsigned /* field */ ,
- ExprDef * /* array_ndx */ ,
- ExprDef * /* value */
- );
+typedef Bool (*actionHandler) (struct xkb_keymap *xkb,
+ struct xkb_any_action *action, unsigned field,
+ ExprDef *array_ndx, ExprDef *value);
static const actionHandler handleAction[XkbSA_NumActions + 1] = {
[XkbSA_NoAction] = HandleNoAction,
struct _ActionInfo *next;
} ActionInfo;
-extern int HandleActionDef(ExprDef * /* def */ ,
- struct xkb_keymap * /* xkb */ ,
- struct xkb_any_action * /* action */ ,
- unsigned /* mergeMode */ ,
- ActionInfo * /* info */
- );
+extern int
+HandleActionDef(ExprDef *def, struct xkb_keymap *xkb,
+ struct xkb_any_action *action, unsigned mergeMode,
+ ActionInfo *info);
-extern int SetActionField(struct xkb_keymap * /* xkb */ ,
- char * /* elem */ ,
- char * /* field */ ,
- ExprDef * /* index */ ,
- ExprDef * /* value */ ,
- ActionInfo ** /* info_rtrn */
- );
+extern int
+SetActionField(struct xkb_keymap *xkb, char *elem, char *field,
+ ExprDef *index, ExprDef *value, ActionInfo **info_rtrn);
extern const LookupEntry ctrlNames[];
char real[XkbKeyNameLength + 1];
} AliasInfo;
-extern int HandleAliasDef(KeyAliasDef * /* def */ ,
- unsigned /* merge */ ,
- unsigned /* file_id */ ,
- AliasInfo ** /* info */
- );
-
-extern void ClearAliases(AliasInfo ** /* info */
- );
-
-extern Bool MergeAliases(AliasInfo ** /* into */ ,
- AliasInfo ** /* merge */ ,
- unsigned /* how_merge */
- );
-
-extern int ApplyAliases(struct xkb_keymap * /* xkb */ ,
- AliasInfo ** /* info */
- );
+extern int
+HandleAliasDef(KeyAliasDef *def, unsigned merge, unsigned file_id,
+ AliasInfo **info);
+
+extern void
+ClearAliases(AliasInfo **info);
+
+extern Bool
+MergeAliases(AliasInfo **into, AliasInfo **merge, unsigned how_merge);
+
+extern int
+ApplyAliases(struct xkb_keymap *xkb, AliasInfo **info);
#endif /* ALIAS_H */
}
}
-typedef void (*FileHandler) (XkbFile * /* rtrn */ ,
- struct xkb_keymap * /* xkb */ ,
- unsigned /* merge */ ,
- CompatInfo * /* info */
- );
+typedef void (*FileHandler) (XkbFile *rtrn, struct xkb_keymap *xkb,
+ unsigned merge, CompatInfo *info);
static Bool
HandleIncludeCompatMap(IncludeStmt * stmt,
/***====================================================================***/
-typedef Bool(*IdentLookupFunc) (const void * /* priv */ ,
- xkb_atom_t /* field */ ,
- unsigned /* type */ ,
- ExprResult * /* val_rtrn */
- );
+typedef Bool (*IdentLookupFunc) (const void *priv, xkb_atom_t field,
+ unsigned type, ExprResult *val_rtrn);
/***====================================================================***/
struct xkb_key_name keyName;
} ExprResult;
-extern int ExprResolveLhs(ExprDef * /* expr */ ,
- ExprResult * /* elem_rtrn */ ,
- ExprResult * /* field_rtrn */ ,
- ExprDef ** /* index_rtrn */
- );
+extern int
+ExprResolveLhs(ExprDef *expr, ExprResult *elem_rtrn, ExprResult *field_rtrn,
+ ExprDef **index_rtrn);
typedef struct _LookupEntry
{
} LookupEntry;
-extern const char *exprOpText(unsigned /* type */
- );
-
-extern int LookupModMask(const void * /* priv */ ,
- xkb_atom_t /* field */ ,
- unsigned /* type */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int LookupVModMask(const void * /* priv */ ,
- xkb_atom_t /* field */ ,
- unsigned /* type */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int LookupModIndex(const void * /* priv */ ,
- xkb_atom_t /* field */ ,
- unsigned /* type */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveModMask(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveVModMask(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */ ,
- struct xkb_keymap * /* xkb */
- );
-
-extern int ExprResolveBoolean(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveKeyCode(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveInteger(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveLevel(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveGroup(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveButton(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveFloat(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveString(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveKeyName(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
-
-extern int ExprResolveEnum(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */ ,
- const LookupEntry * /* values */
- );
-
-extern int ExprResolveMask(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */ ,
- const LookupEntry * /* values */
- );
-
-extern int ExprResolveKeySym(ExprDef * /* expr */ ,
- ExprResult * /* val_rtrn */
- );
+extern const char *
+exprOpText(unsigned type);
+
+extern int
+LookupModMask(const void *priv, xkb_atom_t field, unsigned type,
+ ExprResult *val_rtrn);
+
+extern int
+LookupVModMask(const void *priv, xkb_atom_t field, unsigned type,
+ ExprResult *val_rtrn);
+
+extern int
+LookupModIndex(const void *priv, xkb_atom_t field, unsigned type,
+ ExprResult *val_rtrn);
+
+extern int
+ExprResolveModMask(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveVModMask(ExprDef *expr, ExprResult *val_rtrn,
+ struct xkb_keymap *xkb);
+
+extern int
+ExprResolveBoolean(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveKeyCode(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveInteger(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveLevel(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveGroup(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveButton(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveFloat(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveString(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveKeyName(ExprDef *expr, ExprResult *val_rtrn);
+
+extern int
+ExprResolveEnum(ExprDef *expr, ExprResult *val_rtrn,
+ const LookupEntry *values);
+
+extern int
+ExprResolveMask(ExprDef *expr, ExprResult *val_rtrn,
+ const LookupEntry *values);
+
+extern int ExprResolveKeySym(ExprDef *expr, ExprResult *val_rtrn);
#endif /* EXPR_H */
unsigned int ctrls;
} LEDInfo;
-extern void ClearIndicatorMapInfo(LEDInfo * /* info */
- );
+extern void
+ClearIndicatorMapInfo(LEDInfo *info);
-extern LEDInfo *AddIndicatorMap(LEDInfo * /* oldLEDs */ ,
- LEDInfo * /* newLED */
- );
+extern LEDInfo *
+AddIndicatorMap(LEDInfo *oldLEDs, LEDInfo *newLED);
-extern int SetIndicatorMapField(LEDInfo * /* led */ ,
- struct xkb_keymap * /* xkb */ ,
- char * /* field */ ,
- ExprDef * /* arrayNdx */ ,
- ExprDef * /* value */
- );
+extern int
+SetIndicatorMapField(LEDInfo *led, struct xkb_keymap *xkb, char *field,
+ ExprDef *arrayNdx, ExprDef *value);
-extern LEDInfo *HandleIndicatorMapDef(IndicatorMapDef * /* stmt */ ,
- struct xkb_keymap * /* xkb */ ,
- LEDInfo * /* dflt */ ,
- LEDInfo * /* oldLEDs */ ,
- unsigned /* mergeMode */
- );
+extern LEDInfo *
+HandleIndicatorMapDef(IndicatorMapDef *stmt, struct xkb_keymap *xkb,
+ LEDInfo *dflt, LEDInfo *oldLEDs, unsigned mergeMode);
extern Bool
-CopyIndicatorMapDefs(struct xkb_keymap * xkb, LEDInfo *leds, LEDInfo **unboundRtrn);
+CopyIndicatorMapDefs(struct xkb_keymap *xkb, LEDInfo *leds,
+ LEDInfo **unboundRtrn);
extern Bool
-BindIndicators(struct xkb_keymap * xkb, Bool force, LEDInfo *unbound,
+BindIndicators(struct xkb_keymap *xkb, Bool force, LEDInfo *unbound,
LEDInfo **unboundRtrn);
#endif /* INDICATORS_H */
#ifndef KEYCODES_H
#define KEYCODES_H 1
-#define KeyNameToLong(n) ((((unsigned long)n[0])<<24)|(((unsigned long)n[1])<<16)|(((unsigned long)n[2])<<8)|n[3])
+#define KeyNameToLong(n) ( \
+ (((unsigned long)n[0]) << 24) | \
+ (((unsigned long)n[1]) << 16) | \
+ (((unsigned long)n[2]) << 8) | \
+ (((unsigned long)n[3]) << 0))
-extern const char *longText(unsigned long /* val */
- );
+extern const
+char *longText(unsigned long val);
-extern void LongToKeyName(unsigned long /* val */ ,
- char * /* name_rtrn */
- );
+extern void
+LongToKeyName(unsigned long val, char *name_rtrn);
#endif /* KEYCODES_H */
into->stdPresent |= from->stdPresent;
}
-typedef void (*FileHandler) (XkbFile * /* file */ ,
- struct xkb_keymap * /* xkb */ ,
- unsigned /* merge */ ,
- KeyTypesInfo * /* included */
- );
+typedef void (*FileHandler) (XkbFile *file, struct xkb_keymap *xkb,
+ unsigned merge, KeyTypesInfo *included);
static Bool
HandleIncludeKeyTypes(IncludeStmt * stmt,
struct _CommonInfo *next;
} CommonInfo;
-extern Bool UseNewField(unsigned /* field */ ,
- CommonInfo * /* oldDefs */ ,
- CommonInfo * /* newDefs */ ,
- unsigned * /* pCollide */
- );
-
-extern char * ClearCommonInfo(CommonInfo * /* cmn */
- );
-
-extern char * AddCommonInfo(CommonInfo * /* old */ ,
- CommonInfo * /* new */
- );
-
-extern int ReportNotArray(const char * /* type */ ,
- const char * /* field */ ,
- const char * /* name */
- );
-
-extern int ReportShouldBeArray(const char * /* type */ ,
- const char * /* field */ ,
- const char * /* name */
- );
-
-extern int ReportBadType(const char * /* type */ ,
- const char * /* field */ ,
- const char * /* name */ ,
- const char * /* wanted */
- );
-
-extern int ReportBadField(const char * /* type */ ,
- const char * /* field */ ,
- const char * /* name */
- );
-
-extern Bool ProcessIncludeFile(struct xkb_context * /* context */,
- IncludeStmt * /* stmt */ ,
- unsigned /* file_type */ ,
- XkbFile ** /* file_rtrn */ ,
- unsigned * /* merge_rtrn */
- );
-
-extern Bool FindNamedKey(struct xkb_keymap * /* xkb */ ,
- unsigned long /* name */ ,
- xkb_keycode_t * /* kc_rtrn */ ,
- Bool /* use_aliases */ ,
- Bool /* create */ ,
- xkb_keycode_t /* start_from */
- );
-
-extern Bool FindKeyNameForAlias(struct xkb_keymap * /* xkb */ ,
- unsigned long /* lname */ ,
- unsigned long * /* real_name */
- );
+extern Bool
+UseNewField(unsigned field, CommonInfo *oldDefs, CommonInfo *newDefs,
+ unsigned *pCollide);
+
+extern char *
+ClearCommonInfo(CommonInfo *cmn);
+
+extern char *
+AddCommonInfo(CommonInfo *old, CommonInfo *new);
+
+extern int
+ReportNotArray(const char *type, const char *field, const char *name);
+
+extern int
+ReportShouldBeArray(const char *type, const char *field, const char *name);
+
+extern int
+ReportBadType(const char *type, const char *field, const char *name,
+ const char *wanted);
+
+extern int
+ReportBadField(const char *type, const char *field, const char *name);
+
+extern Bool
+ProcessIncludeFile(struct xkb_context *context,
+ IncludeStmt *stmt, unsigned file_type, XkbFile **file_rtrn,
+ unsigned *merge_rtrn);
+
+extern Bool
+FindNamedKey(struct xkb_keymap *xkb, unsigned long name, xkb_keycode_t *kc_rtrn,
+ Bool use_aliases, Bool create, xkb_keycode_t start_from);
+
+extern Bool
+FindKeyNameForAlias(struct xkb_keymap *xkb, unsigned long lname,
+ unsigned long *real_name);
#endif /* MISC_H */
char *s;
};
-extern ParseCommon *AppendStmt(ParseCommon * /* to */ ,
- ParseCommon * /* append */
- );
+extern ParseCommon *
+AppendStmt(ParseCommon *to, ParseCommon *append);
-extern ExprDef *ExprCreate(unsigned /* op */ ,
- unsigned /* type */
- );
+extern ExprDef *
+ExprCreate(unsigned op, unsigned type);
-extern ExprDef *ExprCreateUnary(unsigned /* op */ ,
- unsigned /* type */ ,
- ExprDef * /* child */
- );
+extern ExprDef *
+ExprCreateUnary(unsigned op, unsigned type, ExprDef *child);
-extern ExprDef *ExprCreateBinary(unsigned /* op */ ,
- ExprDef * /* left */ ,
- ExprDef * /* right */
- );
+extern ExprDef *
+ExprCreateBinary(unsigned op, ExprDef *left, ExprDef *right);
-extern KeycodeDef *KeycodeCreate(const char * /* name */ ,
- unsigned long /* value */
- );
+extern KeycodeDef *
+KeycodeCreate(const char *name, unsigned long value);
-extern KeyAliasDef *KeyAliasCreate(const char * /* alias */ ,
- const char * /* real */
- );
+extern KeyAliasDef *
+KeyAliasCreate(const char *alias, const char *real);
-extern VModDef *VModCreate(xkb_atom_t /* name */ ,
- ExprDef * /* value */
- );
+extern VModDef *
+VModCreate(xkb_atom_t name, ExprDef *value);
-extern VarDef *VarCreate(ExprDef * /* name */ ,
- ExprDef * /* value */
- );
+extern VarDef *
+VarCreate(ExprDef *name, ExprDef *value);
-extern VarDef *BoolVarCreate(xkb_atom_t /* nameToken */ ,
- unsigned /* set */
- );
+extern VarDef *
+BoolVarCreate(xkb_atom_t nameToken, unsigned set);
-extern InterpDef *InterpCreate(char * /* sym */ ,
- ExprDef * /* match */
- );
+extern InterpDef *
+InterpCreate(char *sym, ExprDef *match);
-extern KeyTypeDef *KeyTypeCreate(xkb_atom_t /* name */ ,
- VarDef * /* body */
- );
+extern KeyTypeDef *
+KeyTypeCreate(xkb_atom_t name, VarDef *body);
-extern SymbolsDef *SymbolsCreate(const char * /* keyName */ ,
- ExprDef * /* symbols */
- );
+extern SymbolsDef *
+SymbolsCreate(const char *keyName, ExprDef *symbols);
-extern GroupCompatDef *GroupCompatCreate(int /* group */ ,
- ExprDef * /* def */
- );
+extern GroupCompatDef *
+GroupCompatCreate(int group, ExprDef *def);
-extern ModMapDef *ModMapCreate(uint32_t /* modifier */ ,
- ExprDef * /* keys */
- );
+extern ModMapDef *
+ModMapCreate(uint32_t modifier, ExprDef *keys);
-extern IndicatorMapDef *IndicatorMapCreate(xkb_atom_t /* name */ ,
- VarDef * /* body */
- );
+extern IndicatorMapDef *
+IndicatorMapCreate(xkb_atom_t name, VarDef *body);
-extern IndicatorNameDef *IndicatorNameCreate(int /* ndx */ ,
- ExprDef * /* name */ ,
- Bool /* virtual */
- );
+extern IndicatorNameDef *
+IndicatorNameCreate(int ndx, ExprDef *name, Bool virtual);
-extern ExprDef *ActionCreate(xkb_atom_t /* name */ ,
- ExprDef * /* args */
- );
+extern ExprDef *
+ActionCreate(xkb_atom_t name, ExprDef *args);
-extern ExprDef *CreateMultiKeysymList(ExprDef * /* list */
- );
+extern ExprDef *
+CreateMultiKeysymList(ExprDef *list);
-extern ExprDef *CreateKeysymList(char * /* sym */
- );
+extern ExprDef *
+CreateKeysymList(char *sym);
-extern ExprDef *AppendMultiKeysymList(ExprDef * /* list */ ,
- ExprDef * /* append */
- );
+extern ExprDef *
+AppendMultiKeysymList(ExprDef *list, ExprDef *append);
-extern ExprDef *AppendKeysymList(ExprDef * /* list */ ,
- char * /* sym */
- );
+extern ExprDef *
+AppendKeysymList(ExprDef *list, char *sym);
-extern int LookupKeysym(const char * /* str */ ,
- xkb_keysym_t * /* sym_rtrn */
- );
+extern int
+LookupKeysym(const char *str, xkb_keysym_t *sym_rtrn);
-extern IncludeStmt *IncludeCreate(char * /* str */ ,
- unsigned /* merge */
- );
+extern IncludeStmt *
+IncludeCreate(char *str, unsigned merge);
-extern unsigned StmtSetMerge(ParseCommon * /* stmt */ ,
- unsigned /* merge */,
- YYLTYPE * /* loc */,
- void * /* scanner */
- );
+extern unsigned
+StmtSetMerge(ParseCommon *stmt, unsigned merge, YYLTYPE *loc, void *scanner);
#ifdef DEBUG
-extern void PrintStmtAddrs(ParseCommon * /* stmt */
- );
+extern void
+PrintStmtAddrs(ParseCommon *stmt);
#endif
-extern int XKBParseFile(FILE * /* file */ ,
- const char * /* fileName */,
- XkbFile ** /* pRtrn */
- );
+extern void
+CheckDefaultMap(XkbFile *maps, const char *fileName);
-extern int XKBParseString(const char *string, const char *fileName,
- XkbFile ** pRtrn);
+extern int
+XKBParseFile(FILE *file, const char *fileName, XkbFile **pRtrn);
-extern void CheckDefaultMap(XkbFile * maps, const char *fileName);
+extern int
+XKBParseString(const char *string, const char *fileName, XkbFile **pRtrn);
-extern XkbFile *CreateXKBFile(int /* type */ ,
- char * /* name */ ,
- ParseCommon * /* defs */ ,
- unsigned /* flags */
- );
+extern XkbFile *
+CreateXKBFile(int type, char *name, ParseCommon *defs, unsigned flags);
-extern void FreeXKBFile(XkbFile *file);
+extern void
+FreeXKBFile(XkbFile *file);
-extern void FreeStmt(ParseCommon * /* stmt */
- );
+extern void
+FreeStmt(ParseCommon *stmt);
-extern void yyerror(struct YYLTYPE *loc, void *scanner, const char *msg);
+extern void
+yyerror(struct YYLTYPE *loc, void *scanner, const char *msg);
#endif /* XKBPARSE_H */
into->errorCount++;
}
-typedef void (*FileHandler) (XkbFile * /* rtrn */ ,
- struct xkb_keymap * /* xkb */ ,
- unsigned /* merge */ ,
- SymbolsInfo * /* included */
- );
+typedef void (*FileHandler) (XkbFile *rtrn, struct xkb_keymap *xkb,
+ unsigned merge, SymbolsInfo *included);
static Bool
HandleIncludeSymbols(IncludeStmt * stmt,
typedef struct _VModInfo
{
- struct xkb_keymap * xkb;
+ struct xkb_keymap *xkb;
unsigned defined;
unsigned available;
unsigned newlyDefined;
int errorCount;
} VModInfo;
-extern void InitVModInfo(VModInfo * /* info */ ,
- struct xkb_keymap * /* xkb */
- );
+extern void
+InitVModInfo(VModInfo *info, struct xkb_keymap *xkb);
-extern void ClearVModInfo(VModInfo * /* info */ ,
- struct xkb_keymap * /* xkb */
- );
+extern void
+ClearVModInfo(VModInfo *info, struct xkb_keymap *xkb);
-extern Bool HandleVModDef(VModDef * /* stmt */ ,
- struct xkb_keymap * /* xkb */ ,
- unsigned /* mergeMode */ ,
- VModInfo * /* info */
- );
+extern Bool
+HandleVModDef(VModDef *stmt, struct xkb_keymap *xkb, unsigned mergeMode,
+ VModInfo *info);
-extern Bool ApplyVModDefs(VModInfo * /* info */ ,
- struct xkb_keymap * /* xkb */
- );
+extern Bool
+ApplyVModDefs(VModInfo *info, struct xkb_keymap *xkb);
-extern int FindKeypadVMod(struct xkb_keymap * /* xkb */
- );
+extern int
+FindKeypadVMod(struct xkb_keymap *xkb);
-extern Bool ResolveVirtualModifier(ExprDef * /* def */ ,
- struct xkb_keymap * /* xkb */ ,
- ExprResult * /* value_rtrn */ ,
- VModInfo * /* info */
- );
+extern Bool
+ResolveVirtualModifier(ExprDef *def, struct xkb_keymap *xkb,
+ ExprResult *value_rtrn, VModInfo *info);
#endif /* VMOD_H */
#include "XKBcommonint.h"
-extern const char *XkbDirectoryForInclude(unsigned /* type */
- );
-
-extern FILE *XkbFindFileInPath(struct xkb_context * /* context */,
- const char * /* name */ ,
- unsigned /* type */ ,
- char ** /* pathRtrn */
- );
-
-extern Bool XkbParseIncludeMap(char ** /* str_inout */ ,
- char ** /* file_rtrn */ ,
- char ** /* map_rtrn */ ,
- char * /* nextop_rtrn */ ,
- char ** /* extra_data */
- );
+extern const char *
+XkbDirectoryForInclude(unsigned type);
+
+extern FILE *
+XkbFindFileInPath(struct xkb_context *context, const char *name,
+ unsigned type, char **pathRtrn);
+
+extern Bool
+XkbParseIncludeMap(char **str_inout, char **file_rtrn, char **map_rtrn,
+ char *nextop_rtrn, char **extra_data);
#endif /* _XKBPATH_H_ */