all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* .emacs keybindings in gnus
@ 2007-08-27 13:29 peter hodgson
  2007-08-27 13:59 ` Michaël Cadilhac
  0 siblings, 1 reply; 3+ messages in thread
From: peter hodgson @ 2007-08-27 13:29 UTC (permalink / raw)
  To: help-gnu-emacs


distro/release: ubuntu/feisty
emacs21        21.4a+1-2ubunt 
emacsen-common 1.4.17         
gnus           5.11+v0.5.dfsg 
               [NB so says "dpkg -l gnus",  
                but "M-x gnus-version" in gnus yields: 
                "No Gnus v0.6"
--------------------------------
Each new version of gnus resists one or another of my .emacs key bindings.
This time it's next-line, previous-line, end-of-line.

I can impose them, each time I load gnus, by typing: 
 'M-x local-set-key'
and then setting the key bindings by hand,
1/ in the summary buffer, and 
2/ in the *mail* buffer 
    [which says (Message MML Fly Abbrev Fill), and which I assume is the
     "message" buffer, not the "article" buffer.]

But I would like to hardcode them into my .gnus.el file.

I tried:
(define-key gnus-summary-mode-map "\ei" 'previous-line)                
(define-key gnus-summary-mode-map "\en" 'next-line)                
(define-key gnus-message-mode-map "\en" 'next-line)                
(define-key gnus-message-mode-map "\e;" 'end-of-line)                

   [also 'gnus-article-mode-map' instead of 'gnus-message-mode-map']

THERE was no resulting change in gnus' behavior.

Then I tried:

(add-hook 'gnus-summary-mode-hook                                                       
          (lambda ()                                                                    
            (local-set-key (kbd "\ei") 'previous-line)))                          
(add-hook 'gnus-summary-mode-hook                                                       
          (lambda ()                                                                    
            (local-set-key (kbd "\en") 'next-line)))                          
(add-hook 'gnus-message-mode-hook                                                       
          (lambda ()                                                                    
            (local-set-key (kbd "\en") 'next-line)))                          
(add-hook 'gnus-message-mode-hook                                                       
          (lambda ()                                                                    
            (local-set-key (kbd "\e;") 'end-of-line)))                          

   [also 'gnus-article-mode-hook' instead of 'gnus-message-mode-hook]
   [also 'global-set-key' instead of 'local-set-key]

This time the changes WERE effected in the summary mode, but NOT in the
message/article mode.

Here are four lines from my present .gnus.el file:
(defun my-message-mode-setup ()
  (setq fill-column 72)
(turn-on-auto-fill))
  (add-hook 'message-mode-hook 'my-message-mode-setup)

Does this mean the buffer for composing mail is the "message" mode?
Is there somewhere i can define my very own "message-mode-setup"? 

Here are two lines from one of those mammoth, posted, compiled .gnus
     [http://www.math.tu-berlin.de/~freundt/.gnus]:
  ;; posting styles et. al.
  (load-file "~/.user.mail")

Does this mean i should put my .emacs key bindings in to a ~/.user.mail
file and reference this file somehow in .gnus.el?

So, what can I do to get the next-line and end-on-line key bindings
installed in .gnus.el so they'll be there when i compose mail?

I would also like to get the effects of:
M-x paragraph-indent-minor-mode
hardcoded into .gnus.el 
because i have to load that for each mail message.

Thanks for your help.

imputerate@puteracy.com

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

end of thread, other threads:[~2007-08-29  8:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-27 13:29 .emacs keybindings in gnus peter hodgson
2007-08-27 13:59 ` Michaël Cadilhac
     [not found]   ` <87zm0cgeeb.fsf@cadilhac.name>
2007-08-29  8:48     ` imputerate

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.