Mercurial > emacs
changeset 97703:81b9b3976a29
(text-mode-map): Unbind "\es" from `center-line' and "\eS" from `center-paragraph'.
(facemenu-keymap): Bind "\es" to `center-line' and "\eS" to `center-paragraph'.
author | Juri Linkov <juri@jurta.org> |
---|---|
date | Mon, 25 Aug 2008 20:31:52 +0000 |
parents | 2c1e7cb9cccd |
children | 28f4b07771b0 |
files | lisp/textmodes/text-mode.el |
diffstat | 1 files changed, 5 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/textmodes/text-mode.el Mon Aug 25 20:15:07 2008 +0000 +++ b/lisp/textmodes/text-mode.el Mon Aug 25 20:31:52 2008 +0000 @@ -50,8 +50,6 @@ (defvar text-mode-map (let ((map (make-sparse-keymap))) (define-key map "\e\t" 'ispell-complete-word) - (define-key map "\es" 'center-line) - (define-key map "\eS" 'center-paragraph) map) "Keymap for `text-mode'. Many other modes, such as `mail-mode', `outline-mode' and `indented-text-mode', @@ -123,6 +121,9 @@ (message "Auto Fill %s in Text modes" (if enable-mode "enabled" "disabled")))) + +(define-key facemenu-keymap "\eS" 'center-paragraph) + (defun center-paragraph () "Center each nonblank line in the paragraph at or after point. See `center-line' for more info." @@ -150,6 +151,8 @@ (center-line)) (forward-line 1))))) +(define-key facemenu-keymap "\es" 'center-line) + (defun center-line (&optional nlines) "Center the line point is on, within the width specified by `fill-column'. This means adjusting the indentation so that it equals