* Binding ``' in info-mode-only
@ 2010-02-27 13:45 Tim Visher
2010-02-27 15:50 ` Drew Adams
0 siblings, 1 reply; 4+ messages in thread
From: Tim Visher @ 2010-02-27 13:45 UTC (permalink / raw)
To: emacs
Hello Everyone,
I'd like to bind the ``' key to `Info-scroll-down` in Info mode only
so that I can comfortably read with my left hand as I do with my
right. I don't want to use (add-hook … '(global-set-key)) because
that would set the key in all of my other buffers.
How would I go about doing this?
--
In Christ,
Timmy V.
http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Binding ``' in info-mode-only
2010-02-27 13:45 Binding ``' in info-mode-only Tim Visher
@ 2010-02-27 15:50 ` Drew Adams
2010-02-27 16:28 ` Tim Visher
0 siblings, 1 reply; 4+ messages in thread
From: Drew Adams @ 2010-02-27 15:50 UTC (permalink / raw)
To: 'Tim Visher', 'emacs'
> I'd like to bind the ``' key to `Info-scroll-down` in Info mode only
> I don't want to use (add-hook . '(global-set-key)) because
> that would set the key in all of my other buffers.
> How would I go about doing this?
(define-key Info-mode-map "`" 'Info-scroll-down)
No need to use any hook. This is the case for most modes: they have their own
map; you can define keys directly in their maps.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Binding ``' in info-mode-only
2010-02-27 15:50 ` Drew Adams
@ 2010-02-27 16:28 ` Tim Visher
0 siblings, 0 replies; 4+ messages in thread
From: Tim Visher @ 2010-02-27 16:28 UTC (permalink / raw)
To: Drew Adams; +Cc: emacs
On Sat, Feb 27, 2010 at 10:50 AM, Drew Adams <drew.adams@oracle.com> wrote:
>> I'd like to bind the ``' key to `Info-scroll-down` in Info mode only
>> I don't want to use (add-hook . '(global-set-key)) because
>> that would set the key in all of my other buffers.
>> How would I go about doing this?
>
> (define-key Info-mode-map "`" 'Info-scroll-down)
>
> No need to use any hook. This is the case for most modes: they have their own
> map; you can define keys directly in their maps.
>
Nice! Thanks so much!
--
In Christ,
Timmy V.
http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Binding ``' in info-mode-only
[not found] <mailman.1974.1267278346.14305.help-gnu-emacs@gnu.org>
@ 2010-02-27 20:14 ` Stefan Monnier
0 siblings, 0 replies; 4+ messages in thread
From: Stefan Monnier @ 2010-02-27 20:14 UTC (permalink / raw)
To: help-gnu-emacs
> I'd like to bind the ``' key to `Info-scroll-down` in Info mode only
> so that I can comfortably read with my left hand as I do with my
> right. I don't want to use (add-hook … '(global-set-key)) because
> that would set the key in all of my other buffers.
If you don't want the binding to be global, then don't use
"global-set-key" but "local-set-key" instead.
I hope it sounds obvious enough,
Stefan
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-02-27 20:14 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-27 13:45 Binding ``' in info-mode-only Tim Visher
2010-02-27 15:50 ` Drew Adams
2010-02-27 16:28 ` Tim Visher
[not found] <mailman.1974.1267278346.14305.help-gnu-emacs@gnu.org>
2010-02-27 20:14 ` Stefan Monnier
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).