On 2001-11-08, Matt Armstrong wrote: > Of course, if point is already at the sweet spot, message-bol should > then go to the real beginning of line. This does what you want (I'm not sure if I duplicated some functionality with message-point-in-header-p, maybe some more experienced gnus hacker can tell me): (defun message-point-in-header-p () (let* ((point-in-header (point)) (body-begin (progn (message-goto-body) (point)))) (prog1 (< point-in-header body-begin) (goto-char point-in-header)))) ; saves the save-excursion overhead (defun message-beginning-of-line (&optional n) (interactive "p") (let ((cur-point (point))) (beginning-of-line n) (when (message-point-in-header-p) (let ((to-point (save-excursion (end-of-line) (re-search-backward "^[^:]*: " nil t) (match-end 0)))) (unless (= cur-point to-point) (goto-char to-point)))))) (define-key message-mode-map "\C-a" 'message-beginning-of-line) Have fun, -- Andreas Fuchs, , asf@jabber.at, antifuchs