version 1.60, 2015/03/19 21:22:15 |
version 1.61, 2015/03/24 22:28:10 |
|
|
#include "key.h" |
#include "key.h" |
#include "macro.h" |
#include "macro.h" |
|
|
#ifndef BINDKEY |
|
#define BINDKEY /* bindkey is used by FKEYS startup code */ |
|
#endif /* !BINDKEY */ |
|
|
|
static int remap(KEYMAP *, int, PF, KEYMAP *); |
static int remap(KEYMAP *, int, PF, KEYMAP *); |
static KEYMAP *reallocmap(KEYMAP *); |
static KEYMAP *reallocmap(KEYMAP *); |
static void fixmap(KEYMAP *, KEYMAP *, KEYMAP *); |
static void fixmap(KEYMAP *, KEYMAP *, KEYMAP *); |
static int dobind(KEYMAP *, const char *, int); |
static int dobind(KEYMAP *, const char *, int); |
static char *skipwhite(char *); |
static char *skipwhite(char *); |
static char *parsetoken(char *); |
static char *parsetoken(char *); |
#ifdef BINDKEY |
|
static int bindkey(KEYMAP **, const char *, KCHAR *, int); |
static int bindkey(KEYMAP **, const char *, KCHAR *, int); |
#endif /* BINDKEY */ |
|
|
|
/* |
/* |
* Insert a string, mainly for use from macros (created by selfinsert). |
* Insert a string, mainly for use from macros (created by selfinsert). |
|
|
* calling sequence, should just pass KEYMAP *curmap rather than |
* calling sequence, should just pass KEYMAP *curmap rather than |
* KEYMAP **mapp. |
* KEYMAP **mapp. |
*/ |
*/ |
#ifdef BINDKEY |
|
static int |
static int |
bindkey(KEYMAP **mapp, const char *fname, KCHAR *keys, int kcount) |
bindkey(KEYMAP **mapp, const char *fname, KCHAR *keys, int kcount) |
{ |
{ |
|
|
key.k_count = i; |
key.k_count = i; |
return (bindkey(&map, func, key.k_chars, key.k_count)); |
return (bindkey(&map, func, key.k_chars, key.k_count)); |
} |
} |
#endif /* BINDKEY */ |
|
|
|
/* |
/* |
* This function modifies the fundamental keyboard map. |
* This function modifies the fundamental keyboard map. |