help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to build a conditional keymap?


From: Ian Eure
Subject: Re: How to build a conditional keymap?
Date: Fri, 5 Dec 2008 22:43:52 -0800

On Dec 5, 2008, at 2:06 AM, rejeep wrote:

Hi,

I'm trying to create a minor mode. But I get stuck on the mode-map.
I'm trying to set the keybindings depending on some condition.

But this will not work. So basically my question is: How do I best
build a conditional keymap?

What's wrong with:

(define-key mm-minor-mode-map "\C-m" 'mm-b))
(defun mm-b ()
  (interactive)
  (and (< 3 -1) (print "b")))

 - Ian




reply via email to

[Prev in Thread] Current Thread [Next in Thread]