emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] trunk r114600: * lisp/textmodes/text-mode.el (text-mode-ma


From: Glenn Morris
Subject: [Emacs-diffs] trunk r114600: * lisp/textmodes/text-mode.el (text-mode-map): Add a menu (tiny change)
Date: Thu, 10 Oct 2013 00:24:21 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 114600
revision-id: address@hidden
parent: address@hidden
fixes bug: http://debbugs.gnu.org/15562
author: John Anthony <address@hidden>
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Wed 2013-10-09 20:24:12 -0400
message:
  * lisp/textmodes/text-mode.el (text-mode-map): Add a menu (tiny change)
modified:
  lisp/ChangeLog                 changelog-20091113204419-o5vbwnq5f7feedwu-1432
  lisp/textmodes/text-mode.el    textmode.el-20091113204419-o5vbwnq5f7feedwu-90
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2013-10-09 23:52:46 +0000
+++ b/lisp/ChangeLog    2013-10-10 00:24:12 +0000
@@ -1,3 +1,7 @@
+2013-10-10  John Anthony  <address@hidden>  (tiny change)
+
+       * textmodes/text-mode.el (text-mode-map): Add a menu.  (Bug#15562)
+
 2013-10-09  Juri Linkov  <address@hidden>
 
        * isearch.el (isearch-pre-command-hook): Use this-single-command-keys

=== modified file 'lisp/textmodes/text-mode.el'
--- a/lisp/textmodes/text-mode.el       2013-01-01 09:11:05 +0000
+++ b/lisp/textmodes/text-mode.el       2013-10-10 00:24:12 +0000
@@ -51,6 +51,27 @@
 (defvar text-mode-map
   (let ((map (make-sparse-keymap)))
     (define-key map "\e\t" 'ispell-complete-word)
+    (define-key map [menu-bar text]
+      (cons "Text" (make-sparse-keymap "Text")))
+    (bindings--define-key map [menu-bar text toggle-text-mode-auto-fill]
+      '(menu-item "Auto Fill" toggle-text-mode-auto-fill
+                  :button (:toggle . (memq 'turn-on-auto-fill text-mode-hook))
+                  :help "Toggle auto fill within text modes"))
+    (bindings--define-key map [menu-bar text paragraph-indent-minor-mode]
+      '(menu-item "Paragraph Indent" paragraph-indent-minor-mode
+                  :button (:toggle . (bound-and-true-p 
paragraph-indent-minor-mode))
+                  :help "Toggle paragraph indent minor mode"))
+    (bindings--define-key map [menu-bar text sep] menu-bar-separator)
+    (bindings--define-key map [menu-bar text center-region]
+      '(menu-item "Center Region" center-region
+                  :help "Center the marked region"
+                  :enable (region-active-p)))
+    (bindings--define-key map [menu-bar text center-paragraph]
+      '(menu-item "Center Paragraph" center-paragraph
+                  :help "Center the current paragraph"))
+    (bindings--define-key map [menu-bar text center-line]
+      '(menu-item "Center Line" center-line
+                  :help "Center the current line"))
     map)
   "Keymap for `text-mode'.
 Many other modes, such as `mail-mode', `outline-mode' and `indented-text-mode',


reply via email to

[Prev in Thread] Current Thread [Next in Thread]