;;; text-mode.el --- text mode, and its idiosyncratic commands
-;; Copyright (C) 1985, 1992, 1994, 2001, 2002, 2003, 2004,
-;; 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1992, 1994, 2001-2011 Free Software Foundation, Inc.
;; Maintainer: FSF
;; Keywords: wp
+;; Package: emacs
;; This file is part of GNU Emacs.
"Normal hook run when entering Text mode and many related modes."
:type 'hook
:options '(turn-on-auto-fill turn-on-flyspell)
- :group 'data)
+ :group 'wp)
(defvar text-mode-variant nil
"Non-nil if this buffer's major mode is a variant of Text mode.
(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',
(message "Auto Fill %s in Text modes"
(if enable-mode "enabled" "disabled"))))
\f
+
+(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."
(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
(setq nlines (1+ nlines))
(forward-line -1)))))
-;; arch-tag: a07ccaad-da13-4d7b-9c61-cd04f5926aab
;;; text-mode.el ends here