about summary refs log tree commit diff
path: root/Src/Zle/zle_params.c
diff options
context:
space:
mode:
authorAndrew Main <zefram@users.sourceforge.net>2001-09-03 01:39:19 +0000
committerAndrew Main <zefram@users.sourceforge.net>2001-09-03 01:39:19 +0000
commitb73d71105eaca6ae001a3e836ab08406ef188789 (patch)
tree691753f67199df3b7c9cfdaec6b5dd88cb14bf18 /Src/Zle/zle_params.c
parente8f8c3abee5763d58cfcb8eb89e50ec40dbcfde2 (diff)
downloadzsh-b73d71105eaca6ae001a3e836ab08406ef188789.tar.gz
zsh-b73d71105eaca6ae001a3e836ab08406ef188789.tar.xz
zsh-b73d71105eaca6ae001a3e836ab08406ef188789.zip
15734: zle -K option to select a keymap, and zle KEYMAP parameter to
examine the current selection.
Diffstat (limited to 'Src/Zle/zle_params.c')
-rw-r--r--Src/Zle/zle_params.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/Src/Zle/zle_params.c b/Src/Zle/zle_params.c
index 7db5d6698..dfdc0dcd7 100644
--- a/Src/Zle/zle_params.c
+++ b/Src/Zle/zle_params.c
@@ -69,6 +69,8 @@ static struct zleparam {
         zleunsetfn, NULL },
     { "LASTWIDGET", PM_SCALAR | PM_READONLY, NULL, FN(get_lwidget),
         zleunsetfn, NULL },
+    { "KEYMAP", PM_SCALAR | PM_READONLY, NULL, FN(get_keymap),
+        zleunsetfn, NULL },
     { "KEYS", PM_SCALAR | PM_READONLY, NULL, FN(get_keys),
         zleunsetfn, NULL },
     { "NUMERIC", PM_INTEGER | PM_UNSET, FN(set_numeric), FN(get_numeric),
@@ -273,6 +275,13 @@ get_lwidget(Param pm)
 
 /**/
 static char *
+get_keymap(Param pm)
+{
+    return dupstring(curkeymapname);
+}
+
+/**/
+static char *
 get_keys(Param pm)
 {
     return keybuf;