00001
00002
00009 #include "hcontainer.h"
00010
00011 #ifndef _EXPUTL_KEYMAP_H
00012 #define _EXPUTL_KEYMAP_H
00013
00014
00015
00016
00017
00018 typedef enum Exputl_KeyMapClass_enum {
00019 kKEYMAPCLASS_DEFAULT = 0,
00020 kKEYMAPCLASS_DSDS = 1,
00021 kKEYMAPCLASS_LOCAL = 2,
00022 kKEYMAPCLASS_SSW = 3,
00023 kKEYMAPCLASS_GNG = 4,
00024 kKEYMAPCLASS_NUMTABLESPLUSONE
00025
00026 } Exputl_KeyMapClass_t;
00027
00029 struct Exputl_KeyMap_struct {
00030 HContainer_t int2ext;
00031 HContainer_t ext2int;
00032 };
00033
00035 typedef struct Exputl_KeyMap_struct Exputl_KeyMap_t;
00036
00037
00038 int exputl_keymap_init(void);
00039 void exputl_keymap_term(void *data);
00040
00041
00042
00043
00044
00045 const char *exputl_keymap_extname(Exputl_KeyMap_t *keymap, const char *intName);
00046 const char *exputl_keymap_classidextname(Exputl_KeyMapClass_t, const char *intName);
00047 const char *exputl_keymap_classextname(const char *class, const char *intName);
00048 const char *exputl_keymap_intname(Exputl_KeyMap_t *keymap, const char *extName);
00049 const char *exputl_keymap_classidintname(Exputl_KeyMapClass_t, const char *extName);
00050 const char *exputl_keymap_classintname(const char *class, const char *extName);
00051
00052
00053
00054
00055 Exputl_KeyMap_t *exputl_keymap_create(void);
00056 void exputl_keymap_destroy(Exputl_KeyMap_t **km);
00057 int exputl_keymap_parsetable(Exputl_KeyMap_t *keymap, const char *text);
00058 int exputl_keymap_parsefile(Exputl_KeyMap_t *keymap, FILE *fPtr);
00059 const char *exputl_keymap_getclname(Exputl_KeyMapClass_t clid);
00060
00061
00062
00063
00064
00065
00112 #endif