unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Kevin Rodgers <ihs_4664@yahoo.com>
Subject: Re: define-key minibuffer-mode-map
Date: Wed, 29 Mar 2006 13:54:39 -0700	[thread overview]
Message-ID: <e0es7q$p2h$1@sea.gmane.org> (raw)
In-Reply-To: <1143657579.323150.295360@z34g2000cwc.googlegroups.com>

Florian Kaufmann wrote:
> I try to change the keybindings for the minibuffer. I put the following
> in my init.el
> 
> (add-hook 'minibuffer-mode-hook
>           '(lambda ()
>              (define-key minibuffer-mode-map [(control j)]
> 'backward-char)
>              (define-key minibuffer-mode-map [(control l)]
> 'forward-char) ))
> 
> But it doesn't seem to work. If I'm in the minibuffer invoked trough a
> grep-find, C-j still exits the minibuffer. Has anybody an idea what
> went wrong?

;; This buffer is for notes you don't want to save, and for Lisp evaluation.
;; If you want to create a file, visit that file with C-x C-f,
;; then enter the text in that file's own buffer.

Where did you get the idea that there is a hook called
minibuffer-mode-hook and a keymap called minibuffer-mode-map (or a mode
called minibuffer-mode)?

Try minibuffer-setup-hook, and use local-set-key (which does not take a
keymap argument) instead of define-key.

-- 
Kevin Rodgers

      reply	other threads:[~2006-03-29 20:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-29 18:39 define-key minibuffer-mode-map Florian Kaufmann
2006-03-29 20:54 ` Kevin Rodgers [this message]

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to='e0es7q$p2h$1@sea.gmane.org' \
    --to=ihs_4664@yahoo.com \
    /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.
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 read-only IMAP folder(s) and NNTP newsgroup(s).