zsh-workers
 help / color / mirror / code / Atom feed
From: "Bart Schaefer" <schaefer@candle.brasslantern.com>
To: zsh-workers@sunsite.auc.dk
Subject: Re: PATCH: local keymaps
Date: Thu, 24 Jun 1999 15:29:58 +0000	[thread overview]
Message-ID: <990624152958.ZM1704@candle.brasslantern.com> (raw)
In-Reply-To: <199906230953.LAA06757@beta.informatik.hu-berlin.de>

} Andrej Borsenkow wrote:
} 
} > Unforunately, after
} > 
} > bindkey -A vicmd main
} > 
} > no more input is possible. I would expect, that at least `a' would
} > bring me back to viins.

In vi mode, the main keymap is viins and vicmd is the alternate keymap.
ESC in viins switches to the alternate keymap, and `a' in vicmd switches
to the main keymap.  So if you make vicmd the main keymap, you can never
make it go away, because it just switches to itself.

I don't know whether it'd be possible to make `a' in vicmd always switch
to viins even when that isn't the usual main keymap.  Now that we have
this local keymap stuff, it might be easier.

I'm not sure whether there are any restrictions on what goes into the
alternate keymap.  For example, you could make viins the main keymap and
emacs the alternate keymap, so that hitting ESC takes you into emacs
bindings -- but then I'm not sure whether something in the emacs keymap
might assume that it's the main keymap and/or accidentally pop you back
into the main keymap.

On Jun 23, 11:53am, Sven Wischnowsky wrote:
} Subject: RE: PATCH: local keymaps
}
} > May be, it's time to allow for binding of generic keys instead of just
} > escape sequences. E.g. in vim (or elvis) you can map charaters Right,
} > Left, Home, F1 etc. Let's be more user friendly :-)
} 
} Yes, I was wishing we had this when adding the keymap to complist (we
} would need an option for this to bindkey, though, because `bindkey Up' 
} currently binds the two-character sequence `U' `p').

You just need a special syntax for the named keys.  Z-Mail Lite has vaguely
emacs-like key-rebinding capabilities and keymaps, and uses the sequence
\<name> to refer to named keys, e.g. \<ctrl+A>, \<newline>, \<pageup>, etc.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


  reply	other threads:[~1999-06-24 15:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-06-23  9:53 Sven Wischnowsky
1999-06-24 15:29 ` Bart Schaefer [this message]
  -- strict thread matches above, loose matches on Subject: below --
1999-06-23  7:50 Sven Wischnowsky
1999-06-23  7:46 ` Peter Stephenson
1999-06-23  7:59 ` Andrej Borsenkow
1999-06-23  8:00 ` Andrej Borsenkow

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=990624152958.ZM1704@candle.brasslantern.com \
    --to=schaefer@candle.brasslantern.com \
    --cc=zsh-workers@sunsite.auc.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).