Gnus development mailing list
 help / color / mirror / Atom feed
* Redefining keys in the pGnus summary buffer
@ 1999-10-22  1:03 Daniel Pittman
  1999-10-22  3:13 ` John Palmieri
  1999-10-22 15:34 ` Colin Rafferty
  0 siblings, 2 replies; 3+ messages in thread
From: Daniel Pittman @ 1999-10-22  1:03 UTC (permalink / raw)


I am having some trouble customizing the keyboard interface to pGnus
("Pterodactyl Gnus v0.96")

What I want to do is redefine the keystroke M-k to lower the score of a
thread. This is easy to do and I have it working.

Getting the redefinition to happen automatically is a little harder
however. I tried doing '(define-key gnus-summary-mode-map ...)' in .gnus
and that didn't work -- I got the original binding.

OK, I thought, and went hunting for where the keymap was frobnicated.
'gnus-sum.el' seemed to be the place that did it. So, I wrapped my
redefinitions in an '(eval-after-load "gnus-sum" ...)' form.

No joy. I still get the original key definition.

So, can someone out there tell me where I am being stupid? I would like
to be able to customize the keyboard interface quite a bit :)

        Daniel

-- 
Moloch whose mind is pure machinery! Moloch whose blood is running
money! Moloch whose fingers are ten armies! Moloch whose breast is a
cannibal dynamo! Moloch whose ear is a smoking tomb!
        -- Allen Ginsberg, _Howl_


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Redefining keys in the pGnus summary buffer
  1999-10-22  1:03 Redefining keys in the pGnus summary buffer Daniel Pittman
@ 1999-10-22  3:13 ` John Palmieri
  1999-10-22 15:34 ` Colin Rafferty
  1 sibling, 0 replies; 3+ messages in thread
From: John Palmieri @ 1999-10-22  3:13 UTC (permalink / raw)


Daniel Pittman <daniel@danann.net> writes:

> I am having some trouble customizing the keyboard interface to pGnus
> ("Pterodactyl Gnus v0.96")
> 
> What I want to do is redefine the keystroke M-k to lower the score of a
> thread. This is easy to do and I have it working.
> 
> Getting the redefinition to happen automatically is a little harder
> however. I tried doing '(define-key gnus-summary-mode-map ...)' in .gnus
> and that didn't work -- I got the original binding.
> 
> OK, I thought, and went hunting for where the keymap was frobnicated.
> 'gnus-sum.el' seemed to be the place that did it. So, I wrapped my
> redefinitions in an '(eval-after-load "gnus-sum" ...)' form.
> 
> No joy. I still get the original key definition.
> 
> So, can someone out there tell me where I am being stupid? I would like
> to be able to customize the keyboard interface quite a bit :)

I would expect that something like this would work, but I haven't
tried it:

(add-hook 'gnus-summary-mode-hook
	  '(lambda ()
	     (define-key gnus-summary-mode-map ...)))

(There are lots of "gnus-summary-BLAH-hook"s; gnus-summary-mode-hook
looks like it should work, but maybe you need
gnus-summary-generate-hook or gnus-summary-prepare-hook or one of the
other ones.  Do M-x apropos-variable gnus-summary.*hook for a list.)

-- 
John H. Palmieri                      
Dept of Mathematics, Box 354350    palmieri@math.washington.edu
University of Washington	   http://www.math.washington.edu/~palmieri
Seattle, WA 98195-4350


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Redefining keys in the pGnus summary buffer
  1999-10-22  1:03 Redefining keys in the pGnus summary buffer Daniel Pittman
  1999-10-22  3:13 ` John Palmieri
@ 1999-10-22 15:34 ` Colin Rafferty
  1 sibling, 0 replies; 3+ messages in thread
From: Colin Rafferty @ 1999-10-22 15:34 UTC (permalink / raw)


Daniel Pittman writes:

> What I want to do is redefine the keystroke M-k to lower the score of a
> thread. This is easy to do and I have it working.

> Getting the redefinition to happen automatically is a little harder
> however. 

The trick is to make sure that gnus-sum.el is already loaded.  Since
you are putting this in your .gnus, you are not killing your process
space with a require:

(require 'gnus-sum)
(define-key gnus-summary-mode-map [(meta k)] 'gnus-summary-lower-thread)

-- 
Colin


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1999-10-22 15:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-10-22  1:03 Redefining keys in the pGnus summary buffer Daniel Pittman
1999-10-22  3:13 ` John Palmieri
1999-10-22 15:34 ` Colin Rafferty

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).