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

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

Re: Trying to global-set-key


From: Kevin Rodgers
Subject: Re: Trying to global-set-key
Date: Tue, 03 Jun 2003 15:07:19 -0600
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:0.9.4.1) Gecko/20020406 Netscape6/6.2.2

Harshdeep S Jawanda wrote:

I want to global-set-key C-u 1 C-v (scroll-up) to C-down in my .emacs file. How do I do that?


You can't, exactly: that would mean that `C-u 1' is a prefix key, but `C-u'
is already bound to universal-argument (which is a binding you want to retain
-- trust me).  But if you mean that you want to be able to type C-down instead
of `C-u 1 C-v', then the simplest thing is to define a keyboard macro:

(global-set-key [C-down] (kbd "C-u 1 C-v"))


As a starting point I tried: (global-set-key [C-down] 'scroll-up), but that doesn't seem to do even a simple scroll-up. When I do C-h a for scroll-up, the keybinding shows up, but it doesn't seem to work.

That ought to work, but perhaps a local key binding is shadowing the global
binding.  What happens if you type `C-h k' followed by C-down?  What does
`C-h l' show immediately after that?

--
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;";>Kevin Rodgers</a>



reply via email to

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