zsh-workers
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-workers@sunsite.dk
Subject: More on getkeycmd()
Date: Tue, 27 Sep 2005 14:53:04 +0000	[thread overview]
Message-ID: <1050927145304.ZM23258@candle.brasslantern.com> (raw)

It occurred to me that the patch I posted in 21760 causes longer bindings
in the local map to hide prefixes in the global map.  That's probably not
the desired behavior; the change would be as follows.  Should this get
committed also?

Index: Src/Zle/zle_keymap.c
===================================================================
diff -c -r1.11 zle_keymap.c
--- Src/Zle/zle_keymap.c	27 Sep 2005 14:40:38 -0000	1.11
+++ Src/Zle/zle_keymap.c	27 Sep 2005 14:47:10 -0000
@@ -1300,10 +1300,9 @@
 	    loc = ((f = keybind(localkeymap, keybuf, &s)) != t_undefinedkey);
 	    ispfx = keyisprefix(localkeymap, keybuf);
 	}
-	if (!loc && !ispfx) {
+	if (!loc)
 	    f = keybind(km, keybuf, &s);
-	    ispfx = keyisprefix(km, keybuf);
-	}
+	ispfx |= keyisprefix(km, keybuf);
 
 	if (f != t_undefinedkey) {
 	    lastlen = keybuflen;


             reply	other threads:[~2005-09-27 14:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-27 14:53 Bart Schaefer [this message]
2005-09-27 15:01 ` Peter Stephenson
2005-09-27 15:43   ` Bart Schaefer
2014-11-03  8:45 ` PATCH: give precedence to local keymaps (was Re: More on getkeycmd()) Oliver Kiddle
2014-11-03  9:33   ` Bart Schaefer
2014-11-03 16:30     ` Oliver Kiddle
2014-11-04  3:58       ` Bart Schaefer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1050927145304.ZM23258@candle.brasslantern.com \
    --to=schaefer@brasslantern.com \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).